The Task Management System is a RESTful API designed to optimize task management processes. Built with Node.js and Express.js, this system facilitates efficient task handling with support for user authentication, task CRUD operations, and role-based access control (RBAC). The system is containerized using Docker for easy deployment and scalability.
- User Authentication: Secure JWT-based authentication for user verification.
- Role-Based Access Control (RBAC): Differentiated access for Admin and User roles.
- Task Management: Full CRUD capabilities for managing tasks.
- Task Assignment: Assign tasks to users for better task distribution.
- Filtering and Searching: Advanced task filtering and search functionalities.
- Dockerized Environment: Simplified deployment and environment setup.
├── config
│ └── dbConfig.js # Database configuration
├── controllers
│ ├── taskController.js # Task controller logic
│ └── userController.js # User controller logic
├── middleware
│ └── authMiddleware.js # Authentication middleware
├── models
│ ├── taskModel.js # Task schema/model
│ └── userModel.js # User schema/model
├── routes
│ ├── taskRoutes.js # Routes related to tasks
│ └── userRoutes.js # Routes related to users
├── node_modules # Node.js modules
├── .dockerignore # Docker ignore file
├── .env # Environment variables
├── .gitignore # Git ignore file
├── docker-compose.yml # Docker Compose file
├── Dockerfile # Dockerfile for building the image
├── index.js # Entry point of the application
├── package-lock.json # Package lock file
├── package.json # Project dependencies
└── README.md # Project documentation
- Docker: Ensure Docker is installed on your machine.
- Postman: Optional, but recommended if you want to test the API efficiently.
- Clone the Repository
git clone https://github.com/Souvik-Cyclic/task-management-system.git- Navigate to the project directory
cd task-management-system- Start Docker
Ensure Docker is running on your machine.
- Build with Docker Compose
docker compose buildIt may take some time depending on your machine and internet connection. Please allow it to complete.
- Run with Docker Compose
docker compose upPOST /api/register: Register a new userPOST /api/login: Authenticate user and get tokenGET /api/users: Fetch all users (requires authentication)GET /api/users/:id: Fetch a specific user by ID (requires authentication)PUT /api/users/:id: Update a user's details (requires authentication)DELETE /api/users/:id: Delete a user (requires authentication)PUT /api/users/:id/password: Change a user's password (requires authentication)
POST /api/tasks: Create a new task (requires authentication)GET /api/tasks: Get all tasks assigned to the authenticated userPUT /api/tasks/:id: Update a specific task (requires authentication)DELETE /api/tasks/:id: Delete a specific task (requires authentication)GET /api/tasks/all: Get all tasks in the system (requires authentication)GET /api/tasks/user/:id: Get all tasks assigned to a specific user (requires authentication)PUT /api/tasks/:id/assign: Assign a task to a user (requires authentication)
Note: All endpoints except /register and /login require a valid JWT token in the Authorization header.
API Documentation : Link