Regenerates the bolt11 refund invoice for a Lightning transaction whose current invoice has expired. The provider uses this invoice to return crypto to Kotani if settlement fails. Only applicable to Lightning transactions. Allowed only after the existing invoice expires. Maximum 3 regenerations per transaction. Minimum 30 seconds between requests.
expires_at in the Get Refund Config response is in the past.
expires_atexpires_at is in the past, call this endpoint to regenerate| Rule | Detail |
|---|---|
| Chain | Lightning (CHAIN: LIGHTNING) only — on-chain deposits use a static address and never expire |
| Maximum regenerations | 3 per transaction |
| Minimum interval | 30 seconds between consecutive regeneration requests |
| Terminal states | Cannot regenerate once the transaction is COMPLETED or REFUNDED |
| Invoice must be expired | Returns 400 if the current invoice has not yet expired |
| Status | Reason |
|---|---|
400 | Non-Lightning transaction, maximum regenerations (3) reached, invoice not yet expired, or called too soon (< 30 s since last regeneration) |
400 | Transaction is in a terminal state (COMPLETED or REFUNDED) |
404 | Transaction not found for the given kotani_reference_id |
Bearer authentication header of the form Bearer <token>, where <token> is your auth token.
Kotani reference ID of the transaction
"KOTANI-BR-1732454321-ABC123"