Shop

Get a order

get/orders/{id}

Request

  • Base URL
    https://gorest.co.in/public/v3
  • URL
    https://gorest.co.in/public/v3/orders/{id}
  • Auth
    • none
    • or HTTP bearer

Query parameters

ordersstring

fields[orders]=status,total_minor returns only those fields; included items are added whole.

includestring

Adds related items to each item, one level deep: user, items. Comma separated.

Headers

If-None-Matchstring

An ETag from an earlier answer; an unchanged item answers 304 with no body.

Response

The order. With include the ETag is weak, as it covers the included items too.

cart_idstring uuid nullable

The cart it was placed from; null once that cart is deleted.

created_atstring date-time
currencystring
idstring uuid required
read_onlyboolean

True for sample data (the seed); it cannot be changed.

status'pending' | 'paid' | 'fulfilled' | 'cancelled' | 'refunded'

pending to paid or cancelled; paid to fulfilled or refunded; fulfilled to refunded. A cancel puts the stock back.

total_minorinteger

The sum of the lines.

updated_atstring date-time
user_idstring uuid nullable

The cart's user; null once that user is deleted.

Example response

{
  "user": {
    "email": "aarav.sharma@example.com",
    "name": "Aarav Sharma"
  }
}

Changes

No recorded changes to this operation across all 1 revision of this API.