wholesale_orders

Fetch wholesale orders matching the supplied arguments.

Arguments

ArgumentTypeRequiredDefaultDescription
customer_account_idStringNo

If you are a 3PL you can specify one of your customer's account.

partner_order_idStringNo

Filter by partner order ID; use the external/store order identifier.

updated_fromISODateTimeNo

Inclusive start of the updated range, in ISO-8601 datetime format.

updated_toISODateTimeNo

Inclusive end of the updated range, in ISO-8601 datetime format.

order_date_fromISODateTimeNo

Inclusive start of the order date range, in ISO-8601 datetime format.

order_date_toISODateTimeNo

Inclusive end of the order date range, in ISO-8601 datetime format.

analyzeBooleanNo

If true, the query will only be analyzed (cost estimated) without executing it.

Return Type

WholesaleOrdersQueryResult

Query

query wholesale_orders(
  $customer_account_id: String,
  $partner_order_id: String,
  $updated_from: ISODateTime,
  $updated_to: ISODateTime,
  $order_date_from: ISODateTime,
  $order_date_to: ISODateTime,
  $analyze: Boolean
) {
  wholesale_orders(
    customer_account_id: $customer_account_id,
    partner_order_id: $partner_order_id,
    updated_from: $updated_from,
    updated_to: $updated_to,
    order_date_from: $order_date_from,
    order_date_to: $order_date_to,
    analyze: $analyze
  ) {
    request_id
    complexity
    data {
      ...WholesaleOrderConnectionFragment
    }
  }
}

Variables

{
  "customer_account_id": "QWNjb3VudDoxMjM0",
  "partner_order_id": "SHOPIFY-100045",
  "updated_from": "2026-07-09T15:30:00Z",
  "updated_to": "2026-07-09T15:30:00Z",
  "order_date_from": "2026-07-09T15:30:00Z",
  "order_date_to": "2026-07-09T15:30:00Z",
  "analyze": true
}

Response

{
  "data": {
    "wholesale_orders": {
      "request_id": "UmVjb3JkOjEyMzQ=",
      "complexity": 100,
      "data": [{id: "T3JkZXI6MTIzNA==", order_number: "SO-100045"}]
    }
  }
}