Skip to content

jesperancinha/rockstars-manager

Repository files navigation

Rockstars Manager


Generic badge GitHub License

RSM Build, Test, Coverage and Report RSM Build on PR

Codacy Badge

Codacy Badge Coverage Status codecov

GitHub language count GitHub top language GitHub top language


Introduction

---- Under Construction ----

This application is a Rockstars manager

Stable releases

RESTfull requests

GET Requests

  • Get artist by name
curl http://localhost:8080/rockstars/artists/200
curl http://localhost:8080/rockstars/artists/filter/name/3%20Doors%20Down
  • Get song by name
curl http://localhost:8080/rockstars/songs/1901
curl http://localhost:8080/rockstars/songs/filter/name/666

POST requests

  • Post artist
curl -H "Content-Type: application/json" -X POST --data "{\"Name\": \"Ariana Grande\"}" http://localhost:8080/rockstars/artists
  • Post song
curl -H "Content-Type: application/json" -X POST --data "{\"Name\": \"God is a woman\",\"Year\": 2018,\"Artist\": \"Ariana Grande\", \"Shortname\": \"godisawoman\",\"Bpm\": 145,\"Duration\": 197000,\"Genre\": \"Pop\",\"Album\": \"Sweetener\"}" http://localhost:8080/rockstars/artists

PUT requests

  • Put artist
curl -H "Content-Type: application/json" -X PUT --data "{\"Name\": \"Ariana Grande\"}" http://localhost:8080/rockstars/artists/200
  • Put song
curl -H "Content-Type: application/json" -X PUT --data "{\"Name\": \"God is a woman\",\"Year\": 2018,\"Artist\": \"Ariana Grande\", \"Shortname\": \"godisawoman\",\"Bpm\": 145,\"Duration\": 197000,\"Genre\": \"Pop\",\"Album\": \"Sweetener\"}" http://localhost:8080/rockstars/songs/1901

DELETE requests

  • Delete artist
curl -X DELETE http://localhost:8080/rockstars/artists/200
  • Delete
curl -X DELETE http://localhost:8080/rockstars/songs/1901

OAUTH

curl -X POST -H "Content-Type: application/x-www-form-urlencoded" -d "grant_type=password&[email protected]&password=123&client_id=rockstars-client&client_secret=rockstars&scope=read&redirect_uri=http://localhost:8080/oauth" http://localhost:8080/rockstars/oauth/token
curl -H "Authorization: Bearer TOKEN" http://localhost:8080/rockstars/artists/200

Running everything

Please have docker desktop running. Finally run:

./build.sh

References

About me

GitHub followers

About

This simple project is a website to manage Rockstars

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Contributors 3

  •  
  •  
  •