post

POST /v2/invoices/{id}/actions/pay — Pay an invoice

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Charges a finalized, overdue, or failed invoice via Stripe (stripe.invoices.pay). The invoice must already be linked to a Stripe invoice — Stripe determines which payment method is charged based on what's set on the Stripe customer/invoice, this endpoint does not select a payment method itself.

Required role

affiliate_super_admin or affiliate_admin

Response 200

Returns the full invoice detail (same shape as GET /v2/invoices/{id}) plus a stripeInvoice summary. status is not guaranteed to be paid — some payment methods (e.g. ACH) settle asynchronously, so the invoice can come back processing:

{
  "id": "inv::abc123",
  "status": "processing",
  "totalCents": 15000,
  "totalDollars": 150.00,
  "chargeFailureReason": null,
  "...": "full invoice detail fields — see GET /v2/invoices/{id}",
  "stripeInvoice": {
    "id": "in_...",
    "status": "open"
  }
}

There is no top-level success field on a 200 response.

Errors

StatusCodeDescription
422INVOICE_INVALID_STATUSInvoice is not finalized, overdue, or failed (e.g. already paid, still draft, or void)
422INVOICE_NOT_LINKED_TO_STRIPEInvoice has no stripeInvoiceId — cannot be charged through this endpoint
402INVOICE_CHARGE_FAILEDStripe declined the charge (e.g. insufficient funds, card declined). The invoice is transitioned to failed and chargeFailureReason is set. Response body is the full invoice detail plus a top-level error message — not the {success, id, status} shape shown for 200
404Invoice not found for this affiliate
Language
LoadingLoading…
Response
Click Try It! to start a request and see the response here!