Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/bwhtdev/spring-rest-demo

Basic Spring Rest API deployed to Railway
https://github.com/bwhtdev/spring-rest-demo

java railway-app spring-boot

Last synced: about 1 month ago
JSON representation

Basic Spring Rest API deployed to Railway

Awesome Lists containing this project

README

        

# spring-rest-demo
Run `spring init --dependencies=data-jpa,h2,lombok --build=maven spring-demo`

Run `./mvnw spring-boot:run`

Run `curl http://localhost:8080/beers`
Run `curl http://localhost:8080/beers/3`
Run `curl -X POST -H "Content-Type: application/json" -d '{"name": "klinskoe", "abv": 7.5}' http://localhost:8080/beers`
Run `curl -X PUT -H "Content-Type: application/json" -d '{"name": "klinskoe", "abv": 8.9}' http://localhost:8080/beers/6`
Run `curl -X DELETE http://localhost:8080/beers/6`