Difficulty Distribution
Skills You'll Practice (10)
All 3 Scenarios
Click any scenario to practice it. No account required.
Design Payment Processing API
Design a payment processing API for an e-commerce platform. Requirements: handle credit cards, PayPal, Apple Pay; process refunds; PCI compliant; handle 10K transactions/sec at peak; must be idempotent. Walk me through the API design, data model, and security considerations.
Design Notification Service
Design a notification service that sends emails, SMS, and push notifications. Requirements: 100M notifications/day, must support scheduling, retry failed sends, respect user preferences, and provide delivery analytics. Walk me through architecture, queueing, and failure handling.
Race Condition in Order Creation
Your production is showing duplicate orders. Same user, same items, same timestamp. It happens ~5x per day. Your endpoint is POST /orders. You use PostgreSQL. Walk me through how you find the race condition and fix it.