This is a Task Management API built with Node.js and Express. It includes user authentication and task management functionalities, with MongoDB as the database.
- User Registration and Authentication
- CRUD Operations for Tasks
- Email Verification
- Input Sanitization
- Response Compression
- CORS Handling
- Error Handling and Logging
Make sure you have the following installed on your system:
- Node.js (v20.x or higher)
- npm (v6.x or higher)
- MongoDB
Follow these instructions to set up and run the project on your local machine.
git clone https://github.com/HadiDevLabx/backend.git
cd task-management-api
### 2. Install Dependencies
```bash
npm installCreate a .env file in the root of the project and add the following environment variables:
PORT=3050
MONGO_URI=mongodb://localhost:27017/taskmanagement
JWT_SECRET=your_jwt_secret
EMAIL_SERVICE=your_email_service
EMAIL_USER=your_email@example.com
EMAIL_PASS=your_email_password
npm startThe server will start on the port specified in your .env file (default is 3050).