https://github.com/priyansusahoo/springboot_hibernate_crud
Backend for Spring-Hibernate CRUD App using MySQL DB
https://github.com/priyansusahoo/springboot_hibernate_crud
api controllers entity hibernate-jpa json mysql-database spring-boot
Last synced: 3 months ago
JSON representation
Backend for Spring-Hibernate CRUD App using MySQL DB
- Host: GitHub
- URL: https://github.com/priyansusahoo/springboot_hibernate_crud
- Owner: Priyansusahoo
- License: mit
- Created: 2024-01-08T17:28:44.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-11T14:26:41.000Z (over 2 years ago)
- Last Synced: 2025-02-25T16:43:36.087Z (over 1 year ago)
- Topics: api, controllers, entity, hibernate-jpa, json, mysql-database, spring-boot
- Language: Java
- Homepage: https://github.com/Priyansusahoo/SpringBoot_Hibernate_crud_API_EndPoints
- Size: 128 KB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: MIT-LICENSE.txt
Awesome Lists containing this project
README
# Spring Boot and Hibernate CRUD App using MySQL Database
## API Endpoints for SpringBoot_Hibernate_CRUD with Sample INPUT:
## 1. getAllEmployees API :
- (GET) Request
- URL : http://localhost:9090/myapp/getAllEmployees
Response Body ->
(JSON)
[
{
"id": 2,
"firstName": "Priyansu",
"lastName": "Sahoo",
"email": "priyansusahoo1@gmail.com"
},
{
"id": 3,
"firstName": "Priyansu",
"lastName": "Sahoo",
"email": "priyansusahoo1@gmail.com"
}
]
## 2. addEmployee API :
- (POST) Request
- URL : http://localhost:9090/myapp/addEmployee
Request Body :
(raw -> JSON)
{
"firstName" : "Priyansu",
"lastName" : "Sahoo",
"email" : "priyansusahoo1@gmail.com"
}
Response Body ->
(JSON)
true
## 3. getById :
- (GET) Request
- URL : http://localhost:9090/myapp/getById?id=7
Request Body :

Response Body ->
(JSON)
{
"id": 7,
"firstName": "Priyansu",
"lastName": "Sahoo",
"email": "abc@gmail.com"
}
## 4. deleteById :
- (PUT) Request
- URL : http://localhost:9090/myapp/deleteById?id=9
Request Body :

Response Body ->
(JSON)
true
## 5. updateEmailById :
- (PUT) Request
- URL : http://localhost:9090/myapp/updateEmailById?id=5&email=sddfsadf@gmail.com
Request Body :

Response Body ->
(JSON)
true
## 6. updateAddressById :
- (PUT) Request
- URL : http://localhost:9090/myapp/updateEmailById?id=5&email=sddfsadf@gmail.com
Request Body :

Response Body ->
(JSON)
true