A one-time invoice can be created on demand for a subscription. It is configurable in the request where the order lines for the invoice should come from. The following are possible:
- Subscription plan (and attached subscription add-ons)
- Pending additional costs
- Pending credits
- Optionally given additional order lines
Control when the invoice is charged using the instant and due parameters. By default (instant=false), invoices are queued for automatic processing (typically within 5 minutes) and follow your dunning plan if payment fails, providing automatic retries for standard subscription billing. Set instant: true to process payment immediately and synchronously: the API call will return the invoice as either settled or failed with no dunning, ideal when you need instant confirmation for pay-per-use features or point-of-sale scenarios. Alternatively, set a due date (e.g., "2026-12-01T00:00:00") to defer processing until a specific time: the invoice remains pending until that date, then enters automatic processing with dunning support, perfect for scheduled renewals or planned future charges. Note that instant=true and due cannot be combined; attempting to use both will return error code 1.
Optionally either an offline manual transfer or a settle with an alternative payment method can be given for the invoice creation. The manual transfer will always settle the invoice. If a settle using an alternative payment method fails, the invoice will left pending if instant is not used, and failed otherwise.
Errors
The operation can generate the following errors beside the generic HTTP error codes described here.
| Error code | HTTP code | Description |
|---|---|---|
12 | 404 | Subscription not found |
13 | 400 | Subscription expired |
95 | 400 | Subscription on-hold |
54 | 400 | The request results in an invoice with no order lines |
1 | 400 | Due argument was given for an instant invoice request |
76 | 400 | Payment method not provided and settle requested |
40 | 404 | Payment method provided not found |
