Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 

Repository files navigation

springboot-todo-api

A clean Spring Boot REST API you can demo in minutes.

Features

  • CRUD endpoints for TODO items
  • Input validation
  • H2 in-memory DB (easy local run)
  • OpenAPI/Swagger UI
  • Unit/integration tests with MockMvc

Prerequisites

  • Java 17+
  • Maven 3.8+

Run locally

cd springboot-todo-api
mvn spring-boot:run

API runs at:

Swagger UI:

Example endpoints

  • GET /api/todos
  • POST /api/todos
  • GET /api/todos/{id}
  • PUT /api/todos/{id}
  • DELETE /api/todos/{id}
  • GET /api/health

Run tests

mvn test

Sample curl

curl -X POST http://localhost:8080/api/todos \
  -H "Content-Type: application/json" \
  -d '{ "title": "Build portfolio", "done": false }'

About

**springboot-todo-api**: “Spring Boot REST API with validation, OpenAPI/Swagger, H2, and MockMvc tests

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages