PracHub
QuestionsPremiumCoachesLearningGuidesInterview Prep
|Home/System Design/DoorDash

Design donation database and failure handling

Last updated: Mar 29, 2026

Quick Overview

This question evaluates a candidate's understanding of backend system design for payment workflows, including data modeling for donations and pledges, transactional integrity, asynchronous webhook reconciliation, and failure-recovery strategies, and it falls under the System Design domain.

  • hard
  • DoorDash
  • System Design
  • Software Engineer

Design donation database and failure handling

Company: DoorDash

Role: Software Engineer

Category: System Design

Difficulty: hard

Interview Round: Onsite

Design the database schema and transaction workflow for a donations platform that supports campaigns and both one-time and recurring donations. Model entities for users, campaigns, pledges, payments, receipts, refunds, audit logs, and reconciliation records. Explain how you would handle payment failures and retries using idempotency keys, status state machines, and outbox/queue patterns with a third-party payment gateway. Describe how to ensure atomicity and consistency when creating a pledge and recording a payment, how to process chargebacks and partial refunds, and how to reconcile asynchronous gateway webhooks with your internal state. Provide key tables with primary/foreign keys and outline the failure-handling logic end to end.

Quick Answer: This question evaluates a candidate's understanding of backend system design for payment workflows, including data modeling for donations and pledges, transactional integrity, asynchronous webhook reconciliation, and failure-recovery strategies, and it falls under the System Design domain.

Related Interview Questions

  • Design a Food Rating System - DoorDash (medium)
  • Design a resilient bootstrap API - DoorDash (medium)
  • Design Real-Time Driver Pay Aggregation - DoorDash (hard)
  • Design Food Ratings and Driver Payouts - DoorDash (medium)
  • Design personalized restaurant search and recommendations - DoorDash (medium)
DoorDash logo
DoorDash
Sep 6, 2025, 12:00 AM
Software Engineer
Onsite
System Design
3
0

System Design: Donations Platform with One-Time and Recurring Payments

Context

Design a backend for a donations platform that supports campaigns, one-time donations, and recurring donations. The platform uses a third-party payment gateway and must be resilient to failures, retries, and asynchronous webhooks.

Requirements

  1. Model core entities: users, campaigns, pledges (donation intent), payments (charge attempts), receipts, refunds, audit logs, and reconciliation records.
  2. Support both one-time and recurring donations (e.g., monthly), including scheduling and retries for failed payments.
  3. Ensure atomicity and consistency when creating a pledge and initiating a payment.
  4. Use idempotency keys, explicit status state machines, and outbox/queue patterns to integrate with a payment gateway.
  5. Handle payment failures and retries end-to-end.
  6. Support chargebacks/disputes and partial refunds.
  7. Reconcile asynchronous gateway webhooks with internal state.
  8. Provide key database tables with primary keys, foreign keys, and important indexes.
  9. Outline the failure-handling logic and retry strategy.

Solution

Show

Submit Your Answer to Earn 20XP

Sign in to leave a comment

Loading comments...

Browse More Questions

More System Design•More DoorDash•More Software Engineer•DoorDash Software Engineer•DoorDash System Design•Software Engineer System Design
PracHub

Master your tech interviews with 8,000+ real questions from top companies.

Product

  • Questions
  • Learning Tracks
  • Interview Guides
  • Resources
  • Premium
  • For Universities
  • Student Access

Browse

  • By Company
  • By Role
  • By Category
  • Topic Hubs
  • SQL Questions
  • Compare Platforms
  • Discord Community

Support

  • support@prachub.com
  • (916) 541-4762

Legal

  • Privacy Policy
  • Terms of Service
  • About Us

© 2026 PracHub. All rights reserved.