List Orders (Analytics)
Analytics API
List Orders (Analytics)
Get a paginated list of orders with optional type filter
GET
List Orders (Analytics)
Overview
The list orders endpoint returns a paginated list of TextYess-attributed orders. You can filter by date range and optionally by type (e.g. WhatsApp AI assistant, onsite AI assistant, or all). Results can be sorted by various keys.Authentication
This endpoint requires a valid JWT token in thex-auth-token header. You can find your token in the Developers section:
Query Parameters
string
Start date for filtering orders (ISO 8601).
string
End date for filtering orders (ISO 8601).
string
Sort direction:
1 for ascending, -1 for descending. Defaults to -1.string
Field to sort by:
createdAt, name, title, total_messages, cost, revenue, orders_number, campaign_conversion_rate, average_cart, roas.string
Filter by order source:
whatsapp-ai-assistant (WhatsApp AI), onsite-ai-assistant (onsite widget), or omit for all attributed orders.string
required
Page number (0-based). Use 0 for the first page.
string
required
Number of items per page. Must be at least 1.
Response
The response has two top-level keys:data (array of order objects) and pagination. Each order in data includes order fields (e.g. cms_id, order_number, total, items_number, paid, createdAt) and a populated conversation when available.
array
Array of order documents (TextYess-attributed orders).
object
Pagination metadata:
total (total count), perPage, page.