Phase 1 Β· Project Report Β· 2025–26

AharaSetu

Connecting surplus food with people in need

5User Roles
18+Features
10Weeks
100%Tests Pass
MERNStack

Ramaiah Institute of Technology Β· Department of MCA Β· 25MCA26 Full Stack Development

What is AharaSetu?

AharaSetu β€” meaning Food Bridge in Sanskrit β€” is a full-stack MERN web application built to bridge the gap between surplus food at restaurants and people in need, particularly in underserved communities and slum areas across Indian cities.

Every day, restaurants discard enormous quantities of perfectly edible food while millions struggle to find a single meal. AharaSetu creates a structured, accountable platform connecting food donors with receivers through real payments, admin oversight, and end-to-end transaction tracking.

πŸ›

Free Listings

Restaurants donate leftover food at no cost to volunteers and NGOs

πŸ’°

Paid Listings

Restaurants offer surplus food at a significantly reduced price

πŸ›‘οΈ

Admin Oversight

Every listing reviewed and approved by admin before going live

πŸ“§

Email at Every Step

Automated HTML emails keep all parties informed throughout

The Team

A
Anubhav Singh
Frontend Developer
B
Bhanupratap Reddy
Backend Developer
G
G. Divya
Database Designer
M
Monika Reddy
Testing & Documentation

The Problem We Solve

ProblemWho is AffectedImpact
Daily food wastage at restaurantsRestaurants, EnvironmentTons of edible food discarded daily
Food insecurity in slum areasLow-income communitiesMalnutrition and persistent hunger
No centralized digital platformNGOs and VolunteersInefficient food redistribution
Lack of real-time coordinationAll stakeholdersUneven, untracked food sharing

Existing Systems & Their Gaps

PlatformHow it WorksKey Limitation
Too Good To GoSells surplus as "surprise bags"Paid only, no free option, no food transparency
OlioCommunity food sharing appNo admin oversight or payment system
Zomato Feeding IndiaRestaurant to NGO donationsNo volunteer/user involvement
Swiggy Hope Not HungerSurplus food to NGOsNo real-time tracking or payments
Informal NetworksStaff consume surplus foodNo accountability or digital tracking

MERN Architecture

Built on the MERN stack with industry-standard tools for authentication, payments, and email communications.

Frontend
React.js
UI, routing, state management
Backend
Node.js + Express
REST API and business logic
Database
MongoDB + Mongoose
Data storage and schemas
Auth
JWT Tokens
Secure session management
Payment
Stripe
Real payments and refunds
Email
Nodemailer + Gmail
OTP, receipts, notifications
Forms
Formspree
Contact Us and Report Issue
Version Control
Git + GitHub
Source code management

Role-Based Access System

πŸͺ
Restaurant
  • Post food listings
  • Approve/reject claims
  • Acknowledge food provided
  • View listing IDs
  • Report issues
🀝
Volunteer
  • Browse listings
  • Claim food
  • Make payments
  • Acknowledge pickup
  • Report issues
🏒
NGO
  • Browse listings
  • Claim food
  • Pay & acknowledge
  • Report issues
πŸ›‘οΈ
Admin
  • Approve/reject listings
  • Complete transactions
  • View all data & filters
  • Manage reports
πŸ‘€
Regular User
  • Browse listings
  • Claim free food
  • Contact admin

Phase 1 β€” Complete Feature Set

Authentication & Security

FeatureDescriptionStatus
OTP Registration6-digit OTP sent to email, expires in 10 minutes, with resend optionDone
Email VerificationUsers must verify OTP before login is allowedDone
Auto-verify AdminAdmin accounts auto-verified without OTP requirementDone
JWT LoginSecure login with JSON Web Token, role embedded in tokenDone
Session ManagementsessionStorage β€” clears automatically on browser closeDone
Forgot PasswordReset link sent to email, expires in 15 minutesDone
Reset PasswordSecure token-based reset with live validation hintsDone

Food Listing Management

FeatureDescriptionStatus
Post Food ListingTitle, description, quantity, expiry, type, price, address, phone, emailDone
Dual Mode ListingsFree and Paid listings supported on the same platformDone
Admin Approval WorkflowAll listings reviewed by admin before going liveDone
Listing ID SystemUnique MongoDB ID shown to restaurant and admin for trackingDone
Auto-refreshAll pages auto-refresh every 5 seconds for real-time updatesDone
Contact DetailsRestaurant address, phone, email visible on each listingDone

Claim & Payment System

FeatureDescriptionStatus
Claim FoodVolunteers/NGOs claim food listings with one clickDone
Stripe PaymentReal Stripe payment integration for paid listingsDone
Payment Receipt EmailVolunteer receives HTML receipt email after paymentDone
Restaurant Notification EmailRestaurant receives full payment details via emailDone
Stripe RefundReal Stripe refund when restaurant rejects claimDone
Refund EmailVolunteer receives refund confirmation emailDone
Restaurant ApprovalRestaurant can approve or reject each claimDone

Acknowledgement & Completion

FeatureDescriptionStatus
Restaurant ProvidesRestaurant clicks "I Have Provided the Food" buttonDone
Volunteer PickupVolunteer clicks "I Have Picked Up the Food" buttonDone
Dual AcknowledgementAdmin sees both confirmations before completing transactionDone
Admin CompletesAdmin marks transaction complete after both acknowledgeDone
Status VisibilityEach role sees role-specific status messages in real timeDone

Notification System

Restaurant posts food
β†’ All Admins notified
Admin approves listing
β†’ Restaurant + All Volunteers/NGOs
Admin rejects listing
β†’ Restaurant notified
Volunteer claims food
β†’ Restaurant notified
Restaurant approves claim
β†’ Volunteer/NGO notified
Restaurant rejects claim
β†’ Volunteer/NGO notified
Both parties acknowledge
β†’ All Admins notified
Admin completes transaction
β†’ Restaurant + Volunteer/NGO

Admin Panel

FeatureDescriptionStatus
Dashboard StatsTotal, pending, action needed, completed count widgetsDone
Filter TabsAll / Pending / Approved / Action Needed / Completed / RejectedDone
Listing ID DisplayUnique MongoDB ID shown on every listing cardDone
Approve/Reject ListingsAdmin can approve or reject any submitted listingDone
Complete TransactionsMark complete after both parties acknowledgeDone

Contact & Support

FeatureDescriptionStatus
Contact Us PageFormspree-powered form for all users to message adminDone
Report IssueVolunteers and restaurants report listing-specific problemsDone
Pre-filled Listing IDReport form auto-fills listing ID and title from listing cardDone
Issue CategoriesStructured predefined issue types for organized admin trackingDone

10-Week Build Journey

Week 01
Project setup, MERN stack installation, folder structure, MongoDB connection, Express server setup
Week 02
User authentication β€” Register, Login, JWT tokens, role-based access, auth middleware
Week 03
Food listing CRUD β€” Create, Read, Claim routes, MongoDB models for User and FoodListing
Week 04
Admin panel β€” Approve/reject listings, role-based dashboard, frontend pages for all roles
Week 05
Payment integration β€” Stripe payment intent, card processing, real refunds on rejection
Week 06
Email system β€” Payment receipts, refund notifications, restaurant alerts via Gmail SMTP
Week 07
Acknowledgement system β€” Restaurant provided, volunteer pickup, admin completion workflow
Week 08
OTP verification β€” 6-digit OTP on registration, resend, countdown timer, forgot/reset password
Week 09
Notification system β€” Bell icon, real-time unread count, dropdown, mark read, delete all
Week 10
Contact Us, Report Issue, Listing ID system, auto-refresh, session management, final testing

How It All Works

Food Listing Flow

1
Restaurant registers and verifies OTP to activate their account
2
Restaurant posts food listing with title, quantity, address, phone, type and price
3
Admin receives bell notification and reviews the listing
4
Admin approves β†’ All volunteers/NGOs notified of new food available
5
Listing goes live on Home page for all users to browse

Claim & Payment Flow

1
Volunteer sees listing on Home page and clicks Claim
2
If free β†’ goes directly to pending restaurant approval
3
If paid β†’ redirected to Stripe payment page with order summary
4
Volunteer enters card details β†’ real Stripe payment processed
5
HTML receipt email sent to volunteer, payment notification sent to restaurant
6
Restaurant approves or rejects the claim from My Listings page
7
If rejected β†’ real Stripe refund issued + refund email sent to volunteer

Acknowledgement & Completion Flow

1
Restaurant clicks "I Have Provided the Food" on My Listings page
2
Volunteer clicks "I Have Picked Up the Food" on My Claims page
3
Admin receives notification: both parties have acknowledged
4
Admin clicks "Mark Transaction as Completed" on Admin Panel
5
Both restaurant and volunteer see Transaction Completed status

MongoDB Data Models

πŸ‘€ User Schema
nameString
emailString Β· unique
passwordString Β· bcrypt
roleEnum Β· 5 values
isVerifiedBoolean
otpString
otpExpireDate Β· 10min
resetPasswordTokenString Β· hashed
resetPasswordExpireDate Β· 15min
🍱 FoodListing Schema
title, description, quantityString
expiryTimeDate
typeEnum: free | paid
priceNumber Β· INR
address, phone, contactEmailString
adminApproved, adminRejectedBoolean
statusEnum Β· 6 states
paymentDone, paymentIdMixed
restaurantProvided, volunteerPickedUp, adminCompletedBoolean
postedBy, claimedByObjectId ref
πŸ”” Notification Schema
recipientObjectId β†’ User
messageString
typeEnum Β· 9 types
listingIdObjectId β†’ FoodListing
isReadBoolean
createdAtDate Β· auto

REST API Endpoints

Auth Routes β€” /api/auth

POST/registerRegister user and send OTP
POST/verify-otpVerify OTP to activate account
POST/resend-otpResend OTP to email
POST/loginLogin and receive JWT token
POST/forgot-passwordSend password reset email
POST/reset-password/:tokenReset password with token

Food Routes β€” /api/food

GET/PublicGet all approved listings
POST/RestaurantCreate food listing
GET/my-listingsRestaurantGet own listings
PUT/approve-claim/:idRestaurantApprove volunteer claim
PUT/reject-claim/:idRestaurantReject claim and refund
PUT/restaurant-provided/:idRestaurantAcknowledge food provided
PUT/claim/:idVolunteerClaim a listing
PUT/pay/:idVolunteerConfirm Stripe payment
GET/my-claimsVolunteerGet claimed listings
PUT/volunteer-pickedup/:idVolunteerAcknowledge pickup
GET/admin/allAdminGet all listings
PUT/admin/approve/:idAdminApprove listing
PUT/admin/reject/:idAdminReject listing
PUT/admin/complete/:idAdminComplete transaction

Notification Routes β€” /api/notifications

GET/Get user notifications (last 20)
GET/unread-countGet unread count for bell badge
PUT/mark-all-readMark all notifications as read
PUT/mark-read/:idMark single notification read
DEL/delete-allDelete all notifications

All 18 Tests Passing

βœ“ PassRegister with new email β†’ OTP sent to inbox
βœ“ PassWrong OTP entered β†’ error message shown
βœ“ PassOTP expires after 10 min β†’ resend option appears
βœ“ PassLogin without OTP verification β†’ redirect to OTP page
βœ“ PassLogin with correct credentials β†’ JWT issued
βœ“ PassPost food as restaurant β†’ listing saved, admin notified
βœ“ PassAdmin approves listing β†’ listing goes live, all notified
βœ“ PassAdmin rejects listing β†’ restaurant receives notification
βœ“ PassVolunteer claims paid food β†’ Stripe payment page shown
βœ“ PassStripe test card payment β†’ processed, emails sent to both
βœ“ PassRestaurant rejects claim β†’ real Stripe refund + email
βœ“ PassBoth parties acknowledge β†’ admin notified to complete
βœ“ PassAdmin completes transaction β†’ status updated for all
βœ“ PassForgot password β†’ reset email with 15-min expiry link
βœ“ PassReport issue with listing ID β†’ submitted via Formspree
βœ“ PassNotification bell β†’ unread badge count, dropdown works
βœ“ PassAuto-refresh β†’ all pages update every 5 seconds
βœ“ PassBrowser close β†’ session cleared, fresh login required

What's Coming Next

High
⭐

Rating System

Volunteers rate restaurants 1–5 stars after pickup. Average rating visible on listings.

High
πŸ“Š

Analytics Dashboard

Admin charts: meals saved, active restaurants, transaction trends, top donors.

Medium
πŸ’³

Subscription Plans

Free plan (3 listings/month) vs Premium (unlimited). Stripe subscription billing.

Medium
πŸ—ΊοΈ

Map View

Google Maps showing nearby food listings with distance and directions.

Medium
πŸ“±

Push Notifications

Browser push notifications alongside the existing in-app bell icon system.

Low
🌐

Multi-language

Kannada, Hindi, Tamil support for wider reach across Indian cities.

Low
πŸ€–

AI Food Matching

ML-based system matching food types with NGO preferences automatically.

Low
πŸ”„

Recurring Listings

Restaurants set up recurring daily listings automatically without re-posting.

Technical Improvements Planned

ImprovementTechnologyDescription
Cloud DeploymentRender + VercelBackend on Render, frontend on Vercel for public access
Cloud DatabaseMongoDB AtlasProduction-grade cloud database migration
Real-time UpdatesSocket.ioWebSocket notifications replacing 5-second polling
Image UploadCloudinaryFood listing photos uploaded and stored in cloud
Mobile AppPWAInstall as native app on Android and iOS devices
Testing SuiteJest + RTLUnit and integration tests for all components and routes

Phase 1 β€” Mission Accomplished

Phase 1 of AharaSetu has been successfully completed with a comprehensive feature set addressing the core problems of food wastage and food insecurity. The platform delivers a complete end-to-end solution from food listing to transaction completion, with real Stripe payments, automated email communications, OTP security, and full admin oversight.

AharaSetu is the only platform offering a dual-mode system (free + paid), end-to-end three-party acknowledgement, real Stripe payments with automatic refunds, and admin-gated listing approvals β€” all in a single unified platform built specifically for the Indian context.

πŸ”„

Dual-Mode Platform

Free and paid listings on one unified system β€” no competitor offers both

πŸ“‹

Full Lifecycle Tracking

Three-party acknowledgement ensures every transaction is verified

πŸ’³

Real Payments

Stripe integration with actual card processing and automatic refunds

πŸ“§

Email at Every Step

Automated HTML email notifications keep all parties informed