← DoorDash Interview Insights

DoorDash·Software Engineer·Onsite - System Design / Architecture·Senior

Senior
May 2026

Summary

System design round at DoorDash focused entirely on payment reliability for the dasher payout flow. Pretty deep dive, lots of follow-ups, felt more like a distributed systems exam than a typical interview.

Questions Asked (1)

Q1

Your service processes real payouts to dashers. Walk through how you'd handle a payment that fails mid-flight due to a timeout, partial failure, or a downstream provider error without losing money or double-paying anyone.

System DesignTechnical Trade-offsAPI & Integrations
Author's notes

This question sprawled fast.

Create a free account to read the full note

AI HintsAI Generated

Suggested Approach

Start by framing the core challenge: ensuring exactly-once payment semantics in a distributed system with unreliable downstream providers. Then walk through a concrete design using idempotency keys, a state machine with reconciliation, and compensating actions for partial failures. Emphasize trade-offs between consistency and availability, and how you'd handle edge cases like timeouts and provider errors.

Pro tip: Mention that you'd treat the payment provider as untrusted and design for idempotency at every layer, including using a unique idempotency key per payment attempt that the provider honors. Also, highlight the importance of a reconciliation job that runs periodically to catch and resolve stuck payments, as this shows you think about long-term operational reliability.

1. Clarify requirements and constraints

Ask about the payment provider's capabilities (idempotency support, timeout behavior), the expected failure modes, and the business impact of double-paying or losing money. Confirm the need for exactly-once semantics and the acceptable latency for resolution.

2. Design for idempotency and state management

Propose generating a unique idempotency key for each payment attempt and persisting a payment record with a state machine (e.g., INITIATED, PENDING, SUCCEEDED, FAILED, UNKNOWN). Ensure all state transitions are atomic and logged.

3. Handle timeouts and unknown outcomes

On timeout, do not assume failure; instead, mark the payment as UNKNOWN and trigger a reconciliation process. Use the idempotency key to query the provider for the actual status, and only update the state based on confirmed responses.

4. Implement compensating actions for partial failures

If a downstream provider partially fails (e.g., debits but doesn't credit), use compensating transactions (like refunds or credits) to restore consistency. Ensure these actions are also idempotent and tracked.

5. Build reconciliation and monitoring

Run a periodic reconciliation job that compares internal payment records with provider reports, resolves discrepancies, and alerts on anomalies. Add monitoring for stuck payments and failure rates.

Key Points to Mention

  • Idempotency keys to prevent duplicate payments
  • State machine with explicit states like PENDING, SUCCEEDED, FAILED, UNKNOWN
  • Reconciliation process to resolve unknown outcomes
  • Compensating transactions (refunds/credits) for partial failures
  • Trade-offs between consistency and availability (e.g., CAP theorem)
  • Monitoring and alerting for payment failures and stuck transactions

AI-generated suggestions, not part of the candidate's original notes. May be inaccurate — verify before relying on them.