POST /payments to initiate a payment for a hosted checkout page — supporting credit card (single or two-card split), Pix, and bank slip — and use POST /payments/{id}/refund to issue full or partial refunds against any completed payment.
POST /payments
If any product in the order has
subscription: true, the payment is processed as a recurring subscription rather than a one-time charge.payment_plan_id.
Base URL: https://pay.nova.money/api/v1
Request Body
The payment plan identifier retrieved from
GET /payment_plans. Must follow the format "{plan_id}-{installments}" — for example, "42-3" means plan 42 paid in 3 installments.Card Fields (Pagar.me)
For a two-card split, include both
credit_card_0_* and credit_card_1_* fields and provide an amount for each card. The two amounts must sum to the order total.Card token obtained from client-side Pagar.me tokenization. Use this or
credit_card_0_card_id, not both.Saved card ID from a previous transaction (alternative to
credit_card_0_token).Payment plan for this card, in
"{plan_id}-{installments}" format. Required when using a two-card split.Amount charged to this card, in the order’s currency. Required when performing a two-card split.
Card token for the second card in a split payment (Pagar.me tokenization).
Saved card ID for the second card (alternative to
credit_card_1_token).Payment plan for the second card, in
"{plan_id}-{installments}" format.Amount charged to the second card. Required when performing a two-card split.
Card Fields (Stripe)
A Stripe
ConfirmationToken ID generated client-side using the Stripe.js SDK. Use this field when gateway is set to "stripe".Customer
ID of an existing Nova.Pay customer. When provided, customer contact fields are optional.
Customer’s email address.
Customer’s phone number (digits only, including area code).
Customer’s billing or shipping address.
Checkout Context
UUID of the Nova.Pay checkout page associated with this order.
ID of the primary product being purchased.
List of products included in the order. Each item must contain an
id and a quantity.Optional Fields
Coupon or discount code to apply to the order.
Payment gateway to use. Accepted values:
pagarme, stripe. Defaults to the checkout page’s configured gateway.Arbitrary tag string for internal labeling or filtering.
ISO 8601 datetime to schedule the charge for a future date and time.
Free-text note attached to the order.
Arbitrary key/value metadata stored alongside the order. Useful for tracking campaign sources, funnel steps, or custom attributes.
Response — PaymentResult
Current status of the order. Possible values:
List of gateway-side payment IDs (e.g., Pagar.me charge IDs or Stripe PaymentIntent IDs) associated with this order.
URL to the printable bank slip (boleto). Present only when the payment method is
bank_slip.Base64-encoded Pix QR code image. Present only for Pix payments.
URL to a hosted Pix QR code page. Present only for Pix payments.
ISO 8601 datetime after which the Pix QR code is no longer valid. Present only for Pix payments.
Success redirect URL, if a post-payment redirect is configured on the checkout page.
Signed GlobalID (SGID) for a one-click upsell offer. Present only when the checkout page has an upsell configured and the payment succeeded. Pass this value to
POST /upsell to confirm the offer.true when the order was processed as a subscription (i.e., at least one product has subscription: true).Request Examples
- Credit Card
- Pix
- Boleto
Two-Card Split
When splitting a payment across two cards, include bothcredit_card_0_* and credit_card_1_* fields. The amount values must sum to the full order total.
POST /payments/{id}/refund
Issue a full or partial refund for a completed payment. To refund the full amount, omit theamount field.
Path Parameters
The numeric ID of the payment to refund.
Request Body
Amount to refund, in the payment’s currency. Omit this field to issue a full refund.
ISO 8601 datetime for the refund. Defaults to the current date and time if omitted.
Refund type identifier. Consult your Nova.Pay account configuration for accepted values.
Gateway-side transaction ID to target for the refund (useful when an order has multiple charges).
Response
Returns200 OK with an empty body on success.