cURL
curl --request GET \ --url https://api.example.com/products/:id
{ "error": true, "msg": "<string>", "product": { "id": "<string>", "name": "<string>", "description": "<string>", "price": "<string>", "stock": 123, "category_id": 123, "created_at": "<string>", "updated_at": "<string>" } }
Retrieve a single product by its ID
{ "error": false, "msg": "Product got sucessfully", "product": { "id": "b6da7bbc-14b9-11f1-9fcd-2418c6c96a00", "name": "Coca cola", "description": "Bebida gasificada de 2ltr", "price": "3000.00", "stock": 40, "category_id": 1, "created_at": "2026-02-28T15:25:29.000Z", "updated_at": "2026-02-28T15:25:29.000Z" } }
{ "error": true, "msg": "the id is invalid" }
{ "error": true, "msg": "Error message describing the issue" }