Agent-readable docs index: /llms.txt. Download /docs.zip to grep all markdown files locally.

cartsByQuery

Returned carts are sorted by createdAt in descending order (newest first).
The maximum page size is 10.
This query requires API key authentication

Arguments

path filterCartsFilterInput
Filter parameters to narrow down the search results based on cart creation datetime.
path paginationCursorPaginationInput
Pagination parameters to control the fetching of data, such as specifying the number of items before or after a cursor.

Returns

path CartsConnectionCartsConnection
Returns a CartsConnection object containing the carts that satisfy the criteria together with pagination details.

Example - request

{ "filter": { "createdBefore" : "2025-06-20T21:24:00.000Z", "createdAfter" : "2025-05-10T21:24:00.000Z" }, "pagination": { "first": 2 } }

Example - query

GraphQL
query CartsByQuery($pagination: CursorPaginationInput!, $filter: CartsFilterInput!) { cartsByQuery(pagination: $pagination, filter: $filter) { edges { cursor node { cart { id createdAt buyerIdentity { firstName } stores { ... on AmazonStore { isSubmitted } } } } }, pageInfo { hasNextPage hasPreviousPage startCursor endCursor } } }

Example - response

{ "data": { "cartsByQuery": { "edges": [ { "cursor": "1hbiiW6YWUioHklegdRq", "node": { "cart": { "id": "1hbiiW6YWUioHklegdRq", "createdAt": "2025-06-26T20:18:52.671Z", "buyerIdentity": { "firstName": "Eric" }, "stores": [ { "isSubmitted": false } ] } } } ], "pageInfo": { "hasNextPage": false, "hasPreviousPage": true, "startCursor": "1hbiiW6YWUioHklegdRq", "endCursor": "1hbiiW6YWUioHklegdRq" } } }, "extensions": { "cost": { "queryCost": 16, "queryCostLimit": 750 } } }