Get sales summary
Returns aggregated sales totals for the date range. Pass expand=summary to include a daily breakdown, paginated with 0-based page and size (default 20, max 100). registerId narrows the sales totals to one register but not the returns total or the daily breakdown. from and to are dates (YYYY-MM-DD) and both default to today.
BearerAuthAuthorizationBearer <JWT>from?stringStart date (YYYY-MM-DD), defaults to today
dateto?stringEnd date (YYYY-MM-DD), defaults to today
dateexpand?stringOptional expansions. Use 'summary' to include daily breakdown rows.
page?integerPage number for summary breakdown when expand=summary (default 0)
int320size?integerPage size for summary breakdown when expand=summary (default 20, max 100)
int3220registerId?integerOptional — scope results to a single register/terminal (used by the mobile app to show only its own device's sales)
int64X-TenantID*stringYour merchant's tenant code — the value typed in the Domain field on the iotoms login screen. See Concepts.
OK
*/*- response
status*stringOutcome of the call: SUCCESS when it worked, ERROR when it failed.
message*stringShort human-readable message describing the outcome, for example "Vendor created". Do not parse it.
data?Sales totals for the range, with an optional daily breakdown.
curl -X GET 'https://beta.iotoms.com/api/v1/reports/sales/summary' \ -H 'X-TenantID: your-tenant-code'{ "status": "string", "message": "string", "data": { "from": "2019-08-24", "to": "2019-08-24", "totalRevenue": 0, "totalTransactions": 0, "averageOrderValue": 0, "totalDiscount": 0, "totalReturns": 0, "netRevenue": 0, "cashCollected": 0, "creditTotal": 0, "dailyBreakdown": { "content": [ { "date": "2019-08-24", "revenue": 0, "transactions": 0, "returns": 0, "averageOrderValue": 0, "netSales": 0, "discount": 0 } ], "page": 0, "size": 0, "totalElements": 0, "totalPages": 0, "hasNext": true, "hasPrevious": true } }}