Retrieve details of a specific product by ID
cURL
curl --request GET \ --url https://api.example.com/products/:id
{ "id": 123, "name": "<string>", "description": "<string>", "price": 123, "imageUrl": "<string>", "stock": 123, "categoryId": 123, "createdAt": {}, "updatedAt": {} }
GET /products/:id
{ "id": 1, "name": "Laptop", "description": "High-performance laptop for professionals", "price": "1299.99", "imageUrl": "https://example.com/uploads/laptop.jpg", "stock": 15, "categoryId": 2, "createdAt": "2026-01-15T10:30:00.000Z", "updatedAt": "2026-02-20T14:25:00.000Z" }
{ "error": "Product not found" }
404 Not Found