A robust and scalable backend API built with Node.js and Express, designed to manage authentication, users, jobs, reports, and media services.
This project provides a well-structured MVC architecture with secure middleware, efficient database integration, and reusable service modules.
ITAG Backend serves as the core API for the ITAG ecosystem — handling all server-side logic, authentication, admin management, and CRUD operations for users, jobs, and multimedia content.
It follows clean architecture principles and is production-ready for deployment with Docker, PM2, or cloud environments like AWS, Vercel, or Render.
- User Authentication — JWT-based login and registration system
- Admin Management — Admin-level access for sensitive actions
- Database Integration — MongoDB-based models with schema validation
- File Uploads — Multer-based file handling for images and videos
- Email Service — Integrated mailing system for notifications
- Error Handling — Centralized and structured error responses
- Security — Auth middleware, input sanitization, and secure headers
- Extensible Architecture — Clean separation of concerns with controllers, models, and routes
| Layer | Technology |
|---|---|
| Runtime | Node.js (v18+) |
| Framework | Express.js |
| Database | MongoDB (Mongoose ODM) |
| File Uploads | Multer |
| Authentication | JWT |
| Mailing | Nodemailer |
| Middleware | Custom Auth + Express Middleware |
| Services | Mailer Service, Multer Service |
Itag-backend-main/
├── app.js # Main entry point
├── config/
│ └── db.js # MongoDB connection
├── controllers/
│ ├── admin.controller.js
│ ├── auth.controller.js
│ └── user.controller.js
├── middlewares/
│ └── AuthMiddleware.js # JWT authentication middleware
├── models/
│ ├── client.model.js
│ ├── email.model.js
│ ├── guide.model.js
│ ├── job.model.js
│ ├── jobApp.model.js
│ ├── report.model.js
│ └── video.model.js
├── routes/
│ ├── admin.route.js
│ ├── auth.route.js
│ └── user.route.js
├── services/
│ ├── mailer.service.js
│ └── multer.service.js
├── images/
│ ├── logo.png
│ └── logo.svg
├── package.json
└── .gitignore
git clone https://github.com/devdixit-dev/Itag-backend.git
cd Itag-backendnpm installPORT=5000
MONGODB_URI=mongodb://localhost:27017/itag
JWT_SECRET=your_jwt_secret
EMAIL_USER=your_email@example.com
EMAIL_PASS=your_passwordnpm startor for live-reload:
npm run devServer runs at:
👉 http://localhost:5000
| Method | Endpoint | Description |
|---|---|---|
| POST | /api/auth/register |
Register new user |
| POST | /api/auth/login |
Login existing user |
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/admin/users |
Get all users |
| DELETE | /api/admin/user/:id |
Delete user |
| POST | /api/admin/announce |
Send announcement email |
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/user/profile |
Get user profile |
| PUT | /api/user/update |
Update profile |
| GET | /api/user/jobs |
Get available jobs |
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/jobs |
Get all jobs |
| POST | /api/jobs/create |
Create new job |
| PUT | /api/jobs/update/:id |
Update job |
| DELETE | /api/jobs/delete/:id |
Delete job |
| Command | Description |
|---|---|
npm start |
Start production server |
npm run dev |
Start development server with nodemon |
npm test |
Run tests (if configured) |
npm run lint |
Lint code for style issues |
- Uses JWT for secure authentication
- Protects routes with AuthMiddleware
- Sanitizes user inputs to prevent XSS/SQL injection
- Uses Helmet.js and CORS for secure HTTP headers
- Environment variables managed via
.env
Author: Dev Dixit
Email: devdixitsocial@gmail.com
GitHub: https://github.com/devdixit-dev
This project is licensed under the MIT License.