A Node.js RESTful API server for the TasteMonash restaurant discovery platform. Provides secure authentication, review management, business operations, and automated deal management for the Monash University dining community.
- RESTful API design with Express.js
- Role-based authentication (customers vs business owners)
- Anonymous review system with multi-criteria ratings
- Restaurant and business management
- Image upload and cloud storage integration
- Search and filtering capabilities with pagination
- PassportJS authentication strategy
- Session management with MongoDB storage
- Encrypted authentication cookies
- Role-based access control middleware
- Input validation and sanitization
- Scheduled jobs for deal expiration management
- Database indexing for optimized queries
- Error handling and logging
- File upload processing with Multer
- Runtime: Node.js
- Framework: Express.js
- Database: MongoDB with Mongoose ODM
- Authentication: PassportJS
- File Upload: Multer
- Cloud Storage: Cloudinary
- Job Scheduling: Node-cron
- Environment: dotenv
- Node.js (version 16 or higher)
- MongoDB (local installation or cloud instance)
- npm or yarn package manager
- Cloud storage account (for image uploads)
- Clone the repository:
git clone https://github.com/Nutty1704/eprp-backend.git
cd eprp-backend- Install dependencies:
npm install- Create environment configuration:
cp .env.sample .env- Configure environment variables in
.env:
Start the development server:
npm run devThe API will be available at http://localhost:5000
Start the production server:
npm start- Follow existing code organization patterns
- Maintain RESTful API conventions
- Add appropriate middleware for new routes
- Include proper error handling