~/spellbook/idempotency-keys-for-people-in-a-hurry.md
Idempotency keys for people in a hurry
2nd level, swords · inscribed 20 Aug 2026
- casting time
- 6 minutes
- range
- any client that retries
- components
- Postgres, a unique index, patience
A payment request times out. The client retries. Did the first one go through? Without a key nobody knows, and the safest answer is the one that charges twice.
6 minutes · the whole spell inside