Fetch orders
ordersFetch list of orders from ShopsBuilder GraphQL API.
This tool retrieves the list of orders. For each order it returns information such
as: ID, number, status, creation date, last update date, payment status, total
amount, shipping and billing address country, order lines which include:
quantity, product SKU, variant name, product ID, product name, unit price.
placedVia is "AI agent ()" for orders a shopper's AI agent placed
through the shop's UCP endpoint, and null for orders placed in the storefront.
Args: ctx (Context): The tool execution context. first (int | None): Number of orders to fetch (max 100 per request). after (str | None): Cursor for pagination - fetch orders after this cursor. sort_by (OrderSortingInput | None): Sort orders by specific field. filter (OrderFilterInput | None): Filter and search orders by specific criteria.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "orders"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| after | No | Cursor for pagination - fetch orders after this cursor | |
| first | No | Number of orders to fetch (max 100 per request) | |
| filter | No | Filter and search orders by specific criteria | |
| sort_by | No | Sort orders by specific field |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||