v1
latestOpenAPI 3.0.12026-07-1318302.2 MBQuery date_breakdown on carts
Date breakdowns summarizes metrics data grouped by time intervals on a defined time range. They also support support breakdowns over the main date breakdown query and also supports all breakdown queries capabilities through the "breakdown" key, this also includes the possibility of nesting the breakdown over the main breakdown.
Single date breakdown request (no breakdown)
{ "date_breakdown": { "by": "order.created_at", "field": "order.total_amount_with_taxes", "operator": "stats", "interval": "year" } }
Single date breakdown request with one breakdown
{ "date_breakdown": { "by": "order.created_at", "field": "order.total_amount_with_taxes", "operator": "stats", "interval": "year", "breakdown": { "by": "order.customer_type", "field": "line_items.total_amount", "operator": "sum", "sort": "desc", "limit": 20 } } }
Single date breakdown request with breakdown with a nested breakdown
"date_breakdown": { "by": "order.created_at", "field": "order.total_amount_with_taxes", "operator": "stats", "interval": "year", "breakdown": { "by": "order.customer_type", "field": "line_items.total_amount", "operator": "sum", "sort": "desc", "limit": 20, "breakdown": { "by": "order.currency_code", "field": "line_items.total_amount", "operator": "sum", "sort": "desc", "limit": 21 } } } }
Response
The date_breakdown result from carts