wishlist-app/examples.http
Benny Samir Hierl 2b5f4a9fd6 #1 update api added
Signed-off-by: Benny Samir Hierl <bennysamir@posteo.de>
2022-02-05 13:43:55 +01:00

45 lines
1 KiB
HTTP

@BASE_URL=http://localhost:5000/api
###
# @name createWishlistFirst
POST {{BASE_URL}}/wishlist
Content-Type: application/json
{
"title": "Junior",
"imageSrc": "https://unsplash.com/photos/JZ51o_-UOY8/download?force=true&w=200",
"slugUrlText": "junior"
}
###
# @name createWishlistSecond
POST {{BASE_URL}}/wishlist
Content-Type: application/json
{
"title": "Wedding",
"imageSrc": "https://unsplash.com/photos/8vaQKYnawHw/download?ixid=MnwxMjA3fDB8MXxhbGx8fHx8fHx8fHwxNjQ0MDQ4MTIy&force=true&w=200",
"description": "We are getting married",
"slugUrlText": "wedding"
}
###
# @name getWishlists
GET {{BASE_URL}}/wishlist
###
# @name getFirstWishlist
GET {{BASE_URL}}/wishlist/{{getWishlists.response.body.0.slugUrlText}}
###
# @name updateFirstWishlist
PUT {{BASE_URL}}/wishlist/{{getWishlists.response.body.0.id}}
Content-Type: application/json
{
"title": "Junior",
"imageSrc": "https://unsplash.com/photos/JZ51o_-UOY8/download?force=true&w=200",
"description": "Juniors Wishlist",
"slugUrlText": "junior"
}