customerOrders
Requires a customer (portal or buyer app) session.
Customer portal: lists the signed-in customer's own orders, paged and filterable, within the caller's visibility scope. Needs a customer (portal or buyer app) session.
Errors: a failed call returns a GraphQL errors entry, not a field on the result, and data may be null or partial. Read the entry's extensions.code and message; every shape and code is in the Error reference.
Example:
- GraphQL
- cURL
query CustomerOrders {
customerOrders {
items {
id
orderNumber
status
createdAt
branchAddressId
branchLabel
}
}
}
curl -X POST "https://<api-host>/graphql" \
-H "Content-Type: application/json" \
-H "Authorization: Bearer $ACCESS_TOKEN" \
--data @- <<'EOF'
{
"query": "query CustomerOrders {\n customerOrders {\n items {\n id\n orderNumber\n status\n createdAt\n branchAddressId\n branchLabel\n }\n }\n}"
}
EOF
Response:
{
"data": {
"customerOrders": {
"items": [
{
"id": "id",
"orderNumber": "string",
"status": "string",
"createdAt": "2025-01-15T00:00:00Z",
"branchAddressId": "string",
"branchLabel": "string"
}
]
}
}
}
customerOrders(
filter: CustomerOrderFilterInput
): CustomerOrderConnection!
Arguments
customerOrders.filter ● CustomerOrderFilterInput input
Paging, search and status filters.
Type
CustomerOrderConnection object
A page of orders.