Skip to content

Latest commit

 

History

History
42 lines (30 loc) · 730 Bytes

api.rest

File metadata and controls

42 lines (30 loc) · 730 Bytes

@host = localhost:8080

// Create Product POST http://{{host}}/api/products HTTP/1.1 content-type: application/json

{
"name": "test-product", "description": "random-description", "price": 100.00

}

###

// Get Product By ID GET http://{{host}}/api/products/23 HTTP/1.1 content-type: application/json

###

// Get All Products GET http://{{host}}/api/products/ HTTP/1.1 content-type: application/json

###

// Update Product PUT http://{{host}}/api/products/23 HTTP/1.1 content-type: application/json

{
"name": "updated-product", "description": "random-description-updated", "price": 100.00

}

###

// Delete Product DELETE http://{{host}}/api/products/23 HTTP/1.1 content-type: application/json