Skip to content

Do I need idempotency keys?

Yes: every request that creates, changes or deletes something needs one, so a retry never acts twice.

An idempotency key is a unique value you send with a request, so you can retry it safely after a timeout or a network error. Sovgate requires one on every request that creates, changes or deletes something. Reads don't need one. The API reference shows where it goes.

How it works

  • Same key, same request: you get the first result again, marked as a replay. Nothing happens twice.
  • Same key, different request: refused, with its own error code.
  • First request still running: the repeat is refused straight away with an "in progress" answer. Retry shortly.
  • Keys are kept for 7 days, then can be used again.
  • A key belongs to your business and mode, not to one API key: if you roll your API key, retries still match.

Good practice

Use a new random value (such as a UUID) for each operation, and reuse it only to retry that same operation.

Still need help?

Tell us what happened, and our support team will help.

Search help articles

Find an answer in the Sovgate help center and jump straight to it.