Skip to main content
Networks fail. If a POST times out you can’t tell whether it reached us. Send an Idempotency-Key header and you can retry the exact same request safely: we run it at most once and replay the saved response.

Rules

  • Every POST accepts Idempotency-Key: any string up to 255 characters. Use a UUIDv4.
  • It is required on POST /v1/chapters and POST /v1/chapters/{id}/start. Without it, a retried create would make a second chapter.
  • Keys are scoped to your account and to live or test mode.
  • GET and DELETE ignore the header; they’re idempotent already. Deleting an already deleted chapter returns 200.

What happens on a retry

All other responses, including 402 and 500, are saved and replayed.
Use a new key after a 402. If start returned 402 insufficient_credits, buying credits and retrying with the same key just replays the saved 402. Generate a fresh key for the new attempt.

Generate one key per operation

Create the key once per logical operation and reuse it only for retries of that operation:

Starting is idempotent by state too

start on a chapter that is already queued or processing returns 200 with the chapter and holds nothing extra. A chapter can never be queued twice.