Skip to main content
If the connection drops while your client creates an order, the exchange may have accepted it. Check the operation’s state first. To retry, send the same Idempotency-Key and the same request with a fresh signature.

Send a request with an operation key

  1. Generate a UUID or another unique key 8 to 191 characters long. Use ASCII letters, digits, or the characters ., _, :, and -.
  2. Before sending, save the key, HTTP method, path, query parameters, and original body. Keep the same bytes for JSON retries. For a supported multipart upload, resend a single file with the same bytes, client file name, and MIME type. The multipart boundary can change.
  3. Send Idempotency-Key as a header and include it in the canonical signing string. Keep a stable X-Correlation-Id if you want to trace attempts for the same operation.
Run the example against a test exchange. Save a checked order payload as order.json and use the HTTP request signing script. Substitute the key you saved for that order.
To retry, run the same command with the same file and key. Sign with a new X-Api-Nonce and current X-Api-Timestamp even when the body is unchanged. When you rotate an API key within the same integration, keep the operation’s Idempotency-Key. Its scope is the account and integration. If you recreate the integration, look up the original operation by its saved ID first.

How long the API keeps a key

The default retention period for ordinary receipts is 24 hours. The exchange configures this period. After it ends, reusing a temporary key can start a new operation. Check the saved order, receipt, payout, or subscription ID before retrying outside that window.

Handle the retry response

A temporary receipt can hold a completed 4xx response. Before resubmitting corrected input, check the resource and assign a separate key to the corrected operation. If the quota is exhausted, the API can still return an existing successful receipt after checking the signature, access, and parameters. Rate limits still apply.
The incoming webhook event ID deduplicates notifications. Store it separately from the outgoing HTTP request key.