Skip to content

Event Management & Expense Tracker — Full Architecture

Introduction

Planning events like Hindu marriages, birthdays, and other family gatherings requires high coordination, guest engagement, and strict budget management. This system design focuses on a centralized platform for both mobile and web users to manage guest lists, send invitations, and track expenses with detailed history and analytics.

The system is built on MongoDB to handle the flexible data structures needed for various event types and a Microservices-based architecture for scalability and platform independence.


1. High-Level Architecture


2. Core Feature Design

📋 Guest Management & Relatives Connection

To simplify guest coordination, the system allows importing contacts from a phone or CSV.

  • Categories: Immediate Family, Close Relatives, Friends, In-laws, etc.
  • Connection Options:
    • Phone Call: Integrated VoIP or deep-link to native dialer with a "Call Log" tracker.
    • Digital Card: Custom SVG/Canvas generated invites sent via WhatsApp/SMS.
    • Physical Card Tracking: Marks whether a physical card was hand-delivered or mailed.

💰 Expense Tracker with Full Statistics

A robust system to track every penny spent during multiple sub-events (e.g., Haldi, Mehndi, Reception).

  • Expense History: Full timeline of transactions with receipts attached.
  • Multi-user Sync: Family members can add expenses in real-time.
  • Statistics Engine:
    • Budget vs. Actual: Visual progress bars showing over-expenditure.
    • Category Breakdown: Food, Decoration, Venue, Clothing, Logistics.
    • Settlement Tracking: Payments to vendors (Advance, Due, Completed).

3. Database Schema (MongoDB)

Using MongoDB allows for flexible event types (a birthday might not have "Mehndi" sub-event, while a Hindu marriage will).

Event Collection

json
{
  "_id": "ObjectId",
  "name": "Arjun & Priya's Wedding",
  "type": "Hindu Marriage",
  "host_id": "ObjectId",
  "sub_events": [
    { "name": "Haldi", "date": "2026-12-10", "venue": "Garden Hall" },
    { "name": "Muhurtham", "date": "2026-12-12", "venue": "Temple Square" }
  ],
  "budget": 50000.0,
  "created_at": "ISODate"
}

Guest Collection

json
{
  "_id": "ObjectId",
  "event_id": "ObjectId",
  "name": "Vikram Singh",
  "phone": "+91-9876543210",
  "category": "Relative",
  "invitation_status": "sent_digital",
  "rsvp_status": "attending",
  "members": 4,
  "communication_history": [
    { "type": "WhatsApp", "time": "ISODate", "message_id": "wa_123" },
    { "type": "Call", "time": "ISODate", "note": "Confirmed verbally" }
  ]
}

Expense Collection

json
{
  "_id": "ObjectId",
  "event_id": "ObjectId",
  "title": "Catering Final Payment",
  "amount": 15000.0,
  "category": "Food",
  "sub_event_id": "ObjectId",
  "paid_by": "ObjectId",
  "status": "completed",
  "receipt_url": "https://s3.aws.com/receipts/r1.jpg",
  "metadata": { "payment_method": "UPI", "vendor_id": "v123" }
}

4. Communication Engine — Request Flow

The Communication Service acts as an abstraction over various providers.


5. Analytics & Statistics Generation

To provide real-time statistics, the system utilizes MongoDB's Aggregation Pipeline.

Key Statistical View: Expense vs. Budget by Category

javascript
db.expenses.aggregate([
  { $match: { event_id: ObjectId("event123") } },
  {
    $group: {
      _id: "$category",
      totalSpent: { $sum: "$amount" },
    },
  },
  { $sort: { totalSpent: -1 } },
]);

6. Deployment & Tech Stack

LayerTechnology
FrontendReact (Web), Flutter (Mobile)
BackendNode.js / Express (Microservices)
DatabaseMongoDB Atlas (Cluster for High Availability)
CachingRedis (OTP & Session)
Cloud ServicesAWS S3 (Receipts), Twilio (SMS/Calls), Meta Graph API (WhatsApp)
DevOpsDocker, Kubernetes (EKS), GitHub Actions

7. Scalability & Resilience

  1. Read Replicas: Use MongoDB read-replicas for guest list viewing, as it's read-intensive on the event day.
  2. Delayed Processing: Expense statistics generation should be asynchronous (using a Message Queue) if the data grows large.
  3. Offline Support (Mobile): Since venues may have poor network, the Mobile App should use SQLite (or Hive/Room) for local caching and sync when online.
  4. Idempotency: Use Request IDs for communication and payment transactions to prevent duplicate charges or messages.

8. Summary Checklist for Implementation

  • [ ] Auth: OTP-based login (no password needed for relatives).
  • [ ] Guest Module: Import from contacts and group creation.
  • [ ] Comm Module: Webhook handler to track "Read" status on WhatsApp.
  • [ ] Expense Module: Receipt scanning using OCR (Optional/Premium).
  • [ ] Stats Module: Pre-computed dashboards for faster loading.

Released under the ISC License.