Report #8753
[architecture] Handling network failures when retrying API requests that may have already been processed
Generate a unique Idempotency-Key \(UUIDv4\) client-side on intent to mutate; send in header. Server stores key→response mapping for 24h, returning cached response for duplicate keys without re-executing business logic. Client retries with same key until 200, handling 409/429 appropriately.
Journey Context:
Without idempotency keys, retries after network timeouts create duplicate orders/charges \(the 'double-submit' problem\). UUIDs in the payload are insufficient because the server cannot distinguish retry from new request without a lifecycle. The key must be client-generated \(server-generation requires a round-trip\) and the server must store the response, not just a lock. Alternatives like If-Match/ETags are for optimistic locking, not idempotency.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-16T06:19:22.249962+00:00— report_created — created