Skip to content
API referenceAPI v1admin-sdk 1.1.52Search docs⌘K
API reference · Idempotent requests
API reference / Overview

Idempotent requests

Apps can retry a write safely. Send an Idempotency-Key header and a repeat of the same request returns the first response instead of doing the work twice.

When it applies

  • Requests made with an app's OAuth token (inka_…). Secret-key requests aren't covered; use a unique reference_id instead.
  • POST, PUT and DELETE.
  • Keys of 8 to 255 characters. A UUID works well.

A key belongs to your app and the merchant the token acts for, and lasts 24 hours.

What happens on a repeat

You sendYou get
The same key and bodyThe first response again, with the header idempotency-replay: true.
The same key with a different body409 idempotency_key_reuse_with_different_payload.
The same key while the first is still running409 request_in_progress. Wait and retry.