Payment System — Mock Interview
HardA Stripe-like payment system: move money through external card networks and banks with exactly-once semantics and a strongly consistent double-entry ledger.
Interviewer
Payment System — Mock Interview
You're designing a Stripe-like payment system for a live system-design interview. Merchants charge customers' cards; funds flow through external card networks and banks; merchants are paid out later. The defining challenge is that this system moves real money, where two failure modes are unacceptable: double-charging a customer on a retry, and losing or inventing money so the books don't balance.
Scale assumptions:
- ~100M payments/day → ~1,000 charges/s average, ~5,000/s peak.
- ~4 double-entry ledger postings per payment → ~20,000 ledger writes/s peak.
- ~$5B/day moved; the append-only ledger is retained 7+ years for audit.
- Targets: authorize < 500 ms p99, synchronous ledger commit < 50 ms p99, 99.99% on the charge API, zero double-charges or lost postings.
We'll move through requirements, estimation and the ledger schema, architecture, the idempotency + double-entry deep dive, and trade-offs. Think out loud and state your assumptions.
Sign in to start the interview.
The interviewer grades each stage against a hidden rubric and asks a probing follow-up, mirroring a real system design round. Sessions are capped at 30 turns.