Clatter LabsHelp Center

If my create request times out, will retrying start a duplicate run?

FAQUpdated

Possibly. The docs don't describe an idempotency key for POST /v1/runs, so if the first request reached the API and you retry, you may start two runs.

Safer retries#

  1. Put a unique id of your own in metadata, like {"job": "build-8812"}.
  2. If the create call times out, call GET /v1/runs and look for a recent run with that metadata.
  3. Only retry if it isn't there.
  4. If you do end up with a duplicate, cancel it with POST /v1/runs/{id}/cancel.

The API normally answers 201 right away, so timeouts on create are rare.

Learn more#

Related articles

Still need help?

Tried the steps above and still stuck? Email us. We usually reply within the first hour, and always within 24 hours. A full support team is with you.

Infrastructure questions, or permanent deletion of your data
infrastructure@clatterlabs.xyz
For deleting your whole account or the data of one service.