Get All Orders
GET/v2/orders
This endpoint returns all orders with custom flow fields. The pagination offset is set to fetch a maximum of 10,000 orders. If the store has 10,000 orders and you fetch the orders without using filters, an error is returned. Use a filter to view orders when the order is beyond the 10,000 mark.
- Pass the
X-Moltin-Customer-Token
header to limit orders to a specific customer. See Customer Tokens. - Pass the
EP-Account-Management-Authentication-Token
header to limit orders to a specific account. See Account Management Token. - You can use pagination with this resource. For more information, see pagination.
Filtering
The following operators and attributes are available for filtering orders.
Attribute | Type | Operator | Example |
---|---|---|---|
status | string | eq | eq(status,complete) |
payment | string | eq | eq(payment,paid) |
shipping | string | eq | eq(shipping,unfulfilled) |
name (customer.name ) | string | eq / like | like(name,Brad*) |
email (customer.email ) | string | eq / like | like(email,*@elasticpath.com) |
customer_id | string | eq / like | eq(customer_id, e5a0d684-a4af-4919-a348-f66b0b4955e0) |
account_id | string | eq / like | eq(account_id,3d7200c9-a9bc-4085-9822-63e80fd94a09) |
account_member_id | string | eq / like | eq(account_member_id,2a8a3a92-2ccd-4b2b-a7af-52d3896eaecb) |
contact.name | string | eq / like | eq(name,John Doe) |
contact.email | string | eq / like | eq(email,John Doe) |
shipping_postcode | string | eq / like | like(shipping_postcode,117*) |
billing_postcode | string | eq / like | like(billing_postcode,117*) |
with_tax | integer | gt /ge /lt /le | ge(with_tax,10000) |
without_tax | integer | gt /ge /lt /le | ge(without_tax,10000) |
currency | string | eq | eq(currency,USD) |
product_id | string | eq | eq(product_id,6837058c-ae42-46db-b3c6-7f01e0c34b40) |
product_sku | string | eq | eq(product_sku,deck-shoe-001) |
created_at | date | eq / gt / ge / le / lt | gt(created_at,YYYY-MM-DD) |
updated_at | date | eq / gt / ge / le / lt | lt(updated_at,YYYY-MM-DD) |
external_ref | string | eq / like | like(external_ref, 16be*) |
Request
Header Parameters
A customer token to access a specific customer's orders.
Responses
- 200
- 401
Response Headers
- application/json
- Schema
- Example (from schema)
Schema
- Array [
- ]
data object[]
Specifies the type of object being returned. You must use order
.
Specifies the unique identifier of the order.
Specifies the status of the order, such as incomplete
, complete
, processing
, or cancelled
.
Specifies the status of the payment, such as unpaid
, authorized
, paid
, or refunded
.
Specifies the status of the shipment, such as fulfilled
or unfulfilled
.
Specifies if the order is anonymized.
meta object
timestamps object
The date this was created.
The date this was last updated.
with_tax object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
without_tax object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
tax object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
discount object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
paid object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
authorized object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
without_discount object
The raw total of this cart.
The currency set for this cart.
The tax inclusive formatted total based on the currency.
billing_address object
Company name of the billing recipient.
Specifies the country of the billing address.
Specifies the county of the billing address.
First name of the billing recipient.
Last name of the billing recipient.
First line of the billing address.
Second line of the billing address.
Postcode of the billing address.
Specifies state, province, or region of the billing address.
contact object
The email address of the contact.
The name of the contact.
shipping_address object
Company of the shipping recipient.
Specifies the country of the shipping address.
Specifies the county of the shipping address.
First name of the shipping recipient.
Last name of the shipping recipient.
First line of the shipping address.
Second line of the shipping address.
Post code of the shipping address.
Specifies the state, province, or region of the shipping address.
links object
Always the current page.
Always the first page.
If there is only one page, it is null
.
If there is only one page, it is null
.
if the user is on the first page, it is null
.
meta object
page object
The current page.
The maximum number of records per page for this response. You can set this value up to 100.
The current offset by number of records, not pages. Offset is zero-based.
The total page count.
results object
The total page count.
{
"data": [
{
"type": "string",
"id": "3fa85f64-5717-4562-b3fc-2c963f66afa6",
"status": "string",
"payment": "string",
"shipping": "string",
"anonymized": true,
"meta": {
"timestamps": {
"created_at": "string"
},
"with_tax": {
"amount": 0,
"currency": "string",
"formatted": "string"
},
"without_tax": {
"amount": 0,
"currency": "string",
"formatted": "string"
},
"tax": {
"amount": 0,
"currency": "string",
"formatted": "string"
},
"discount": {
"amount": 0,
"currency": "string",
"formatted": "string"
},
"paid": {
"amount": 0,
"currency": "string",
"formatted": "string"
},
"authorized": {
"amount": 0,
"currency": "string",
"formatted": "string"
},
"without_discount": {
"amount": 0,
"currency": "string",
"formatted": "string"
}
},
"billing_address": {
"company_name": "string",
"country": "string",
"county": "string",
"first_name": "string",
"last_name": "string",
"line_1": "string",
"line_2": "string",
"postcode": "string",
"region": "string"
},
"contact": {
"email": "string",
"name": "string"
},
"shipping_address": {
"company_name": "string",
"country": "string",
"county": "string",
"first_name": "string",
"last_name": "string",
"line_1": "string",
"line_2": "string",
"postcode": "string",
"region": "string"
}
}
],
"links": {
"current": "string",
"first": "string",
"last": "string",
"next": "string",
"prev": "string"
},
"meta": {
"page": {
"current": 0,
"limit": 0,
"offset": 0,
"total": 0
},
"results": {
"total": 0
}
}
}
Unauthorized
- application/json
- Schema
- Example (from schema)
- Example
Schema
[
null
]
{
"errors": {
"status": 401,
"title": "Unauthorized"
}
}