https://github.com/danielfreitassc/spring-api
https://github.com/danielfreitassc/spring-api
Last synced: 7 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/danielfreitassc/spring-api
- Owner: DanielFreitassc
- Created: 2023-11-26T02:19:08.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-29T20:22:44.000Z (over 2 years ago)
- Last Synced: 2024-04-21T17:24:30.451Z (about 2 years ago)
- Language: Java
- Size: 69.3 KB
- Stars: 0
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
# Spring Initializr
```
https://start.spring.io/#!type=maven-project&language=java&platformVersion=3.2.0&packaging=jar&jvmVersion=17&groupId=com.example&artifactId=springboot&name=springboot&description=Demo%20project%20for%20Spring%20Boot&packageName=com.example.springboot&dependencies=web,data-jpa,postgresql,validation
```
# API RESTful Spring Boot 3
- Spring Boot 3 e Java 17
- Spring Web MVC
- Spring Data JPA
- Spring Validation
- Spring Hateoas
# Requests
## POST
```
http://localhost:8080/products
```
## Json do POST
```
{
"name": "nome do produto",
"value": 0
}
```
____
## GET
```
http://localhost:8080/products
```
## GET Com id
```
http://localhost:8080/products/066ed68b-c7fc-4b26-bd39-14f2c8305fb2
```
## PUT com id
```
http://localhost:8080/products/066ed68b-c7fc-4b26-bd39-14f2c8305fb2
```
## Json do PUT
```
{
"name": "Pc Gamer Terabyte",
"value": 7600.89
}
```
### DELETE com id
```
http://localhost:8080/products/066ed68b-c7fc-4b26-bd39-14f2c8305fb2
```