Skip to content

Latest commit

 

History

History
21 lines (17 loc) · 906 Bytes

restclient.rest

File metadata and controls

21 lines (17 loc) · 906 Bytes

# get token from server POST http://api-secretcodez.herokuapp.com/user_token Content-Type: application/json {"auth": {"email": "[email protected]", "password": "password"}} #

# Get the list of posts GET http://api-secretcodez.herokuapp.com/posts Content-Type: application/json Authorization: "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE0ODg4NzkwMDAsInN1YiI6MX0.-r1nCEb3vlll95pFs6PtqygLDAzrlN-6UP2HbLAzGto"

# GET current user GET http://api-secretcodez.herokuapp.com/current_user Content-Type: applicaiton/json Authorization: "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE0ODg4NzkwMDAsInN1YiI6MX0.-r1nCEb3vlll95pFs6PtqygLDAzrlN-6UP2HbLAzGto"

# GET current user GET http://api-secretcodez.herokuapp.com/users/1 Content-Type: applicaiton/json Authorization: "Bearer eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJleHAiOjE0ODg4NzkwMDAsInN1YiI6MX0.-r1nCEb3vlll95pFs6PtqygLDAzrlN-6UP2HbLAzGto"