Orders
Place and manage customer orders.
Returns all orders placed in the store. Does not currently support filtering or pagination.
Pass your API key as a Bearer token in the Authorization header.
An array of orders.
Unique order identifier.
The ID of the animal in this order.
Number of units ordered.
Expected or actual ship date in ISO 8601 format.
Whether the order has been fulfilled.
Missing or invalid API key.
curl -L https://petstore.example.com/v1/store/orders \
-H 'Authorization: Bearer YOUR_API_KEY'
[
{
"id": 1,
"petId": 1,
"quantity": 1,
"shipDate": "2026-01-01T00:00:00.000Z",
"complete": true
}
]Cancels an order by ID. Only orders with a status of pending can be cancelled — orders that have already shipped cannot be reversed.
Pass your API key as a Bearer token in the Authorization header.
The ID of the order to cancel.
Order cancelled successfully.
No content
Missing or invalid API key.
The requested resource could not be found.
Order cannot be cancelled — it has already shipped.
curl -L -X DELETE https://petstore.example.com/v1/store/orders/42 \
-H 'Authorization: Bearer YOUR_API_KEY'
No content
Last updated