Skip to content

timcy/play_it

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

  1. To create new User using API

curl -v -H “Accept: application/json” -H “Content-type: application/json” -X POST -d ‘ {“user”:{“email”:“[email protected]”,“password”:“password”,“password_confirmation”:“password”}}’ localhost:3000/api/v1/users

  1. Login Using API curl -X POST -H “Content-type: application/json” -d ‘{“email”:“[email protected]”,“password”:“password”}’ localhost:3000/api/v1/sessions

  2. To create new Player

curl -v -H “Accept: application/json” -H “Content-type: application/json” -X POST -d ‘{“player”:{“first_name”:“ffffff”,“last_name”:“lllll”,“age”:“22”,“user_attributes”:{“email”:“[email protected]”,“password”:“password”,“password_confirmation”:“password”}},“sports”:}’ localhost:3000/api/v1/players

  1. To update Player

curl -X PUT -H “Content-type: application/json” -H “token:<auth_token>” -d ‘{“player”:{“first_name”:“firstname”,“last_name”:“lastname”,“age”:“33”},“sports”:}’ localhost:3000/api/v1/players/4

  1. Get All Players

curl -X GET -H “Content-type: application/json” localhost:3000/api/v1/players

  1. Destroy a player recored.

curl -X DELETE localhost:3000/api/v1/players/<id>

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published