A full-stack web application built with the MERN stack (MongoDB, Express.js, React.js, Node.js) that connects donors with NGOs/admins for seamless resource donation management, approval, and tracking.
- User Authentication: Secure signup, login, forgot password, and change password
- Profile Management: View and update personal information
- Browse Categories: Explore available donation categories
- Make Donations: Submit donation requests with item details and quantities
- Donation Tracking: View donation history with real-time status updates
- Responsive Design: Mobile-friendly interface with modern UI
- Admin Dashboard: Comprehensive statistics and overview
- Category Management: Create, read, update, and delete donation categories
- Donation Management: View all donations, approve/reject requests
- User Management: View and manage all registered users
- Role-based Access: Secure admin-only functionality
- Node.js - Runtime environment
- Express.js - Web framework
- MongoDB - NoSQL database
- Mongoose - ODM for MongoDB
- JWT - Authentication
- bcryptjs - Password hashing
- CORS - Cross-origin resource sharing
- React.js - UI library
- Vite - Build tool and dev server
- React Router - Client-side routing
- CSS3 - Custom styling with modern design system
- MongoDB Compass - Database management
- Postman - API testing
- Git/GitHub - Version control
- ESLint - Code linting
Before running this application, make sure you have the following installed:
- Node.js (v16 or higher)
- MongoDB (local installation)
- npm or yarn package manager
- Git for version control
git clone https://github.com/haripatel07/Smart-Donation-System.git
cd smart-donation-systemcd Backend
npm installCreate a .env file in the Backend directory:
PORT=5000
MONGODB_URI=mongodb://localhost:27017/smart-donation-system
JWT_SECRET=your-super-secret-jwt-key-hereStart MongoDB locally, then run the backend:
npm startcd ../Frontend
npm install
npm run dev- Frontend: http://localhost:5173
- Backend API: http://localhost:5000
For detailed technical documentation, API specifications, and project details, see the docs/ folder:
- API Endpoints - Complete API documentation with request/response formats
- Frontend Routes - Frontend page routing and component mapping
- Project Details - Comprehensive project overview and team contributions
- Technical Docs - Implementation details, known issues, and recommendations
- Viva Questions - Academic presentation questions
POST /api/auth/signup- Register new userPOST /api/auth/login- User loginGET /api/auth/me- Get current user detailsPOST /api/auth/forgot-password- Reset passwordPOST /api/auth/change-password- Change password
GET /api/categories- List all categoriesPOST /api/categories- Create category (Admin)PUT /api/categories/:id- Update category (Admin)DELETE /api/categories/:id- Delete category (Admin)
POST /api/donations- Create donationGET /api/donations- List all donationsGET /api/donations/user/:userId- Get user donationsPUT /api/donations/:id- Update donationDELETE /api/donations/:id- Delete donationPATCH /api/donations/:id/status- Approve/Reject donation (Admin)
PUT /api/users/profile- Update user profile
GET /api/admin/users- List all users (Admin)
smart-donation-system/
├── Backend/
│ ├── app.js # Main application file
│ ├── package.json # Backend dependencies
│ ├── config/
│ │ ├── db.js # Database configuration
│ │ └── jwt.js # JWT configuration
│ ├── controllers/ # Route controllers
│ ├── middleware/ # Custom middleware
│ ├── models/ # Mongoose schemas
│ └── routes/ # API routes
├── Frontend/
│ ├── public/ # Static assets
│ ├── src/
│ │ ├── components/ # Reusable React components
│ │ ├── pages/ # Page components
│ │ ├── styles/ # CSS stylesheets
│ │ ├── utils/ # Utility functions
│ │ └── main.jsx # App entry point
│ ├── package.json # Frontend dependencies
│ └── vite.config.js # Vite configuration
├── docs/ # Documentation files
└── README.md # Project documentation
- Hari Patel - Backend Development & Database Design
- Dev Patel - Frontend Development & UI/UX
- Het Patel - Admin Features & Quality Assurance
- Planning: Define requirements and divide tasks
- Development: Implement features in separate branches
- Testing: Test APIs with Postman and UI functionality
- Code Review: Create pull requests for team review
- Integration: Merge approved changes to main branch
- Import the Postman collection from
docs/directory - Test all endpoints with appropriate authentication
- Verify response formats and error handling
- Use MongoDB Compass to verify data integrity
- Check schema relationships and data population
cd Backend
npm run build # If build script exists
npm startcd Frontend
npm run build
npm run preview # For preview
# Deploy the dist/ folder to your hosting service- Fork the repository
- Create a feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is licensed under the ISC License - see the LICENSE file for details.
For questions or support, please contact the development team or create an issue in the repository.
Built with ❤️ for connecting donors with those in need