Rate this page:
Access to Petstore orders
Returns a map of status codes to quantities
This request has no parameters.
successful operation
1
2
3
curl --request GET \
--url 'https://petstore.swagger.io/v2/store/inventory' \
--header 'Accept: application/json'
order placed for purchasing the pet
integer
integer
integer
string
string
boolean
successful operation
1
2
3
4
5
6
7
8
9
10
11
12
curl --request POST \
--url 'https://petstore.swagger.io/v2/store/order' \
--header 'Accept: application/xml' \
--header 'Content-Type: application/json' \
--data '{
"id": 2154,
"petId": 2154,
"quantity": 2154,
"shipDate": "<string>",
"status": "placed",
"complete": true
}'
1
2
3
4
5
6
7
8
{
"id": 2154,
"petId": 2154,
"quantity": 2154,
"shipDate": "<string>",
"status": "placed",
"complete": true
}
For valid response try integer IDs with value >= 1 and <= 10. Other values will generated exceptions
integer
Requiredsuccessful operation
1
2
3
curl --request GET \
--url 'https://petstore.swagger.io/v2/store/order/{orderId}' \
--header 'Accept: application/xml'
1
2
3
4
5
6
7
8
{
"id": 2154,
"petId": 2154,
"quantity": 2154,
"shipDate": "<string>",
"status": "placed",
"complete": true
}
For valid response try integer IDs with positive integer value. Negative or non-integer values will generate API errors
integer
RequiredInvalid ID supplied
1
2
curl --request DELETE \
--url 'https://petstore.swagger.io/v2/store/order/{orderId}'