A simple Task Management REST API built with Spring Boot, Spring Data JPA (Hibernate), and PostgreSQL.
This project demonstrates industry-standard layering: Controller → Service → Repository → Database.
- Create, Read, Update, Delete (CRUD) tasks
- RESTful APIs with proper HTTP status codes
- Database persistence using PostgreSQL & Hibernate
- Layered architecture (Controller, Service, Repository)
- Error handling with
ResponseEntity
- GET
/tasks- Returns
200 OKwith list of tasks - Returns
204 No Contentif no tasks exist
- Returns
- GET
/tasks/{id}- Returns
200 OKwith task - Returns
404 Not Foundif task missing
- Returns
- POST
/tasks- Request body:
{ "title": "Learn Spring Boot", "description": "Build a REST API project" } - Returns
201 Createdwith saved task (including generated ID)
- Request body:
- PUT
/tasks/{id}- Request body:
{ "title": "Updated title", "description": "Updated description" } - Returns
200 OKwith updated task - Returns
404 Not Foundif task does not exist
- Request body:
- DELETE
/tasks/{id}- Returns
200 OKif deleted - Returns
404 Not Foundif task does not exist
- Returns