Usage breakdown for a week + assistant filter
Returns the monthly + weekly + last-24h breakdown for the selected
week/year window. assistant_id=all aggregates across every assistant;
passing a concrete 24-hex ID filters to that assistant's calls only.
Supplying an ID that does not belong to the caller's organization
returns 404.
All duration fields are whole seconds (rounded down), not minutes,
rated the way SMAO invoices calls: each call counts its recorded assistant session
time with a minimum of 60 seconds, and the time stops once the platform
hands the call off completely (a completed SIP REFER transfer). A call
without recorded session time counts 0 seconds, for example a call
bypassed to another destination before it reaches the assistant or one
rejected by admission policy. Calls fall into weeks, days and hours by
their start time in German time (Europe/Berlin); deleted calls count the
usage recorded when they were deleted. hourly_call_counts_last_24h
always reflects the 24h window ending at request time - it ignores the
week/year filter.
Authorization
bearerAuth API key in the Authorization: Bearer <key> header.
Keys are created in the SMAO dashboard (Settings → API Keys).
In: header
Query Parameters
ISO week number (1–53). The week runs Monday 00:00 to Sunday 24:00 in German time (Europe/Berlin).
1 <= value <= 532020 <= value <= 2100Either the sentinel all or a 24-hex assistant id.
Response Body
application/json
application/json
application/json
application/json
application/json
application/json
application/json
application/json
curl -X GET "https://example.com/statistics/usage?week=1&year=2020&assistant_id=all"{ "data": { "period": { "week": 0, "year": 0 }, "assistant_id": "all", "monthly": { "property1": { "call_count": 0, "overall_call_seconds": 0, "average_calls_per_day": 0, "daily_call_counts": [ { "date": "string", "count": 0 } ] }, "property2": { "call_count": 0, "overall_call_seconds": 0, "average_calls_per_day": 0, "daily_call_counts": [ { "date": "string", "count": 0 } ] } }, "weekly_call_counts": [], "weekly_call_seconds": [], "hourly_call_counts_last_24h": [ 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0 ] }}List available statistics filters GET
Returns the filter values that populate statistics dashboards: every ISO (week, year) pair, in German time (Europe/Berlin), in which at least one completed call of the organization started, plus every assistant in the organization. The `all` assistant sentinel is **not** returned - clients can always pass `assistant_id=all` to the `/usage` endpoint regardless of this list.
Per-assistant usage for a week GET
Returns one breakdown row per assistant that had at least one completed call starting in the selected week. Includes assistants that have since been deleted - their calls still count and the row carries `is_deleted: true`. Duration fields are integer seconds, rated as described for `/statistics/usage`.