Skip to content

destrutoyt/spring-rest-demo

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

7 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

Spring REST API Demo

This project demonstrates how to design and build RESTful APIs with the Spring Framework.
It connects to a MySQL database, retrieves and manipulates data, converts it into JSON, and exposes it through REST endpoints that can be consumed by web applications or other clients.

The application showcases key backend development skills, including:

  • πŸš€ Building REST APIs with Spring Boot
  • πŸ—„οΈ CRUD operations (Create, Read, Update, Delete)
  • πŸ›’οΈ Database integration with MySQL using Spring Data JPA
  • πŸ”„ Object Relational Mapping (ORM)
  • πŸ“¦ Data serialization with Jackson (JSON)
  • ⚠️ Exception handling & validation
  • πŸ—οΈ Layered architecture (Controller β†’ Service β†’ Repository)
  • πŸ› οΈ API testing with Postman

πŸš€ Tech Stack

  • β˜• Java 21
  • 🌱 Spring Boot 3 / Spring Framework 6
  • πŸ›’οΈ MySQL

πŸ“¦ Dependencies

  • 🌐 Spring Web – RESTful API development
  • πŸ—„οΈ Spring Data JPA – ORM and database queries
  • πŸ”— MySQL Connector/J – JDBC driver for MySQL
  • πŸ“¦ Jackson – JSON serialization/deserialization
  • πŸ§ͺ Spring Boot Starter Test – unit & integration testing

πŸ› οΈ Development Tools

  • πŸ§‘β€πŸ’» VS Code – IDE for coding
  • πŸ› οΈ Postman – testing and documenting REST endpoints
  • πŸ”— Git & GitHub – version control & collaboration

πŸ“‚ Project Details

πŸ“Œ API Requirements

The API provides a simple Employee Directory service where REST clients can:

  • πŸ“‹ Get a list of employees
  • πŸ” Get a single employee by ID
  • βž• Add a new employee
  • ✏️ Update an existing employee
  • ❌ Delete an employee

🌐 API Endpoints

HTTP Method URL CRUD Action Description
POST /api/employees Create βž• Add a new employee
GET /api/employees Read πŸ“‹ Fetch all employees
GET /api/employees/{employeeID} Read πŸ” Fetch employee by ID
PUT /api/employees/{employeeID} Update ✏️ Update employee details
DELETE /api/employees/{employeeID} Delete ❌ Remove employee

About

No description or website provided.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages