POST/store/order

Place a pet order

Creates a new order for a pet in the store. Provide order details such as petId, quantity, shipDate, status, and complete when your order flow requires them.

  • IdempotentThe SDK sends Idempotency-Key, so a retried request is only applied once.

6 body fields

Order details for a pet purchase; all fields are optional in the request schema.

idintegeroptional

The unique numeric identifier of the order.

petIdintegeroptional

The unique numeric identifier of the pet being ordered.

quantityintegeroptional

The number of pets included in the order.

shipDatestringoptional

The requested shipping date and time in ISO 8601 date-time format.

statusstringoptional

Order Status

Allowed:placedapproveddelivered
completebooleanoptional

Whether the order is complete.

4 status codes
200Returns the created order object with its identifier, pet identifier, quantity, shipping date, status, and completion flag.
idintegeroptional
petIdintegeroptional
quantityintegeroptional
shipDatestringoptional
statusstringoptional

Order Status

Allowed:placedapproveddelivered
completebooleanoptional
400Returned when the order input is invalid.
422Returned when the order data fails schema validation.
defaultReturned when an unexpected error occurs.

Error handling

When supplied, shipDate must use ISO 8601 date-time format and status must be one of placed, approved, or delivered. Invalid order input returns a 400, and schema validation failures return a 422.