Ghosts in the Machine: Rebuilding API Reliability and Idempotency at Scale

A deep dive into token refresh races, TOCTOU bugs, and retry storms that turn one tap into a double charge.