Skip to content

Latest commit

 

History

History
87 lines (58 loc) · 2.87 KB

requests.rest

File metadata and controls

87 lines (58 loc) · 2.87 KB

POST http://localhost:8080/signup Content-Type: application/json

{ "username":"test", "password":"123456" }

###

POST http://localhost:8080/signin Content-Type: application/json

{
"username":"wakhiwe", "password":"123456"

}

###

DELETE http://localhost:8080/logout

###

GET http://localhost:8080/refresh-token

###

POST http://localhost:8080/posts Content-Type: application/json Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6Indha2hpd2UiLCJyb2xlcyI6WzEwMDYxMF19LCJpYXQiOjE3MTQ5MjkwNDksImV4cCI6MTcxNDkyOTA3OX0.HJoopyS16aBk7U67N-n2FUftv1xl0libX6c7mw9DwT0

{
"title":"Dogs", "message":"dogs are adorable pets"

}

###

GET http://localhost:8080/posts Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6Indha2hpd2UiLCJyb2xlcyI6WzEwMDYxMF19LCJpYXQiOjE3MTQ5MjkyMDMsImV4cCI6MTcxNDkyOTIzM30.UVgYTcojT8f8PhnU4szoUkPqnBIT2nb7oZoQ6_sfZHg

###

GET http://localhost:8080/posts/919f012c-7357-4444-ac91-a3b3a9666611 Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6InRlc3QiLCJyb2xlcyI6eyJ1c2VyIjoxMDA2MTB9fSwiaWF0IjoxNzEyNTE0NTk2LCJleHAiOjE3MTI1MTQ2MjZ9.UQASWp_B_chv2cf1wi_a_iYnwiSiQpZUZUv9MWg1lic

###

PUT http://localhost:8080/posts/919f012c-7357-4444-ac91-a3b3a9666611 Content-Type: application/json Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6InRlc3QiLCJyb2xlcyI6eyJ1c2VyIjoxMDA2MTB9fSwiaWF0IjoxNzEyNTE0NzI0LCJleHAiOjE3MTI1MTQ3NTR9.sysXRQOmHwoCUZTxJU3x9Lejp8zP0sQbHBcxZzSPeug

{
"title":"stars", "message":""

}

###

DELETE http://localhost:8080/posts/bdf3f5cb-1a14-4d14-97f0-d1aea8b1b5f9 Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6Indha2hpd2UiLCJyb2xlcyI6WzEwMDYxMF19LCJpYXQiOjE3MTQ5MjkxNTAsImV4cCI6MTcxNDkyOTE4MH0.g04ielWompe4PFuYgEv0XofO10wnRd_ALliKBnmHbQQ

###

GET http://localhost:8080/users Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6Indha2hpd2UiLCJyb2xlcyI6WzEwMDYxMF19LCJpYXQiOjE3MTI1MTgyMjEsImV4cCI6MTcxMjUxODI1MX0.dNNjkc8CM40Y9ZoHsC2pRKmXYsc9m-rzkMs4g5W2i0o

###

GET http://localhost:8080/users/wakhiwe Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6Indha2hpd2UiLCJpYXQiOjE3MTI1MDE1MDUsImV4cCI6MTcxMjUwMTUzNX0.aBIYxImbCrr0EFT2ZS7v3vjL7mP_mArmgtKbOaR6Qoc

###

PUT http://localhost:8080/users/wakhiwe Content-Type: application/json Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VybmFtZSI6Indha2hpd2UiLCJpYXQiOjE3MTI0OTgyMjMsImV4cCI6MTcxMjQ5ODI1M30.WBHRY8Pl2DR4mpBQC1rO1mzqWPxTyCKRmBoQjOP1y9Y

{
"username":"wakhiwe"

}

###

DELETE http://localhost:8080/users/test Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJ1c2VySW5mbyI6eyJ1c2VybmFtZSI6InRlc3QiLCJyb2xlcyI6eyJ1c2VyIjoxMDA2MTB9fSwiaWF0IjoxNzEyNTE0ODc3LCJleHAiOjE3MTI1MTQ5MDd9.dzdXfHvkw-pVf7kCJ4MIXiJVduyGWvRGnYjtwvXuf-E