externalOrderCode as an idempotency key.
How it works
externalOrderCodemust be unique per order within your account.- If you
POST /ordersagain with anexternalOrderCodethat already exists, Kalixo does not create a second order. It returns202 Acceptedwith the existing order: the sameorderId, its currentstatusand a freshwalletsnapshot. - This means you can safely retry a request whose response you never received.
The replay response never contains codes. Fetch them with
GET /orders/{externalOrderCode}, as for any order.
Generate a stable
externalOrderCode before you send the request (for example, your
own order reference), so a retry uses the exact same code.Handling 409 Conflict
A 409 means another request with the same externalOrderCode was being placed at that
moment. The order exists. Do not place it again with a new code: fetch it with
GET /orders/{externalOrderCode} and continue polling.
Example
The first call creates the order; an identical retry returns the sameorderId.