A clean and scalable Task Management API built using FastAPI. This project demonstrates real-world backend concepts like CRUD operations, filtering, and partial updates.
- Create tasks π
- Get all tasks π
- Get single task by ID π
- Update tasks βοΈ
- Delete tasks β
- Filter tasks by completion status β‘
- Filter tasks by priority π―
- Combined filtering support π₯
- Partial updates using PATCH (toggle task status)
- FastAPI
- Python
- Uvicorn
- Pydantic
app/
βββ main.py
βββ schemas.py
βββ mock_data.py
βββ routers/
β βββ tasks.py
git clone https://github.com/your-username/fastapi-task-manager.git
cd fastapi-task-manager
python -m venv venv
source venv/bin/activate
pip install -r requirements.txt
uvicorn app.main:app --reload| Method | Endpoint | Description |
|---|---|---|
| POST | /tasks | Create Task |
| GET | /tasks | Get All Tasks |
| GET | /tasks/{id} | Get Single Task |
| PUT | /tasks/{id} | Update Task |
| DELETE | /tasks/{id} | Delete Task |
| GET | /tasks?completed=true | Filter by status |
| GET | /tasks?priority=high | Filter by priority |
| PATCH | /tasks/{id}/toggle | Toggle task status |
Swagger UI available at:
π http://127.0.0.1:8000/docs
- Designing REST APIs using FastAPI
- Implementing CRUD operations
- Handling query parameters and filtering
- Using PATCH for partial updates
- Structuring scalable backend projects
- Database integration (PostgreSQL + SQLAlchemy)
- Authentication system (JWT)
- Pagination & sorting
- Docker deployment
Built with consistency and focus πͺ More projects coming soon π