SMAO API Documentation
Public APIStatistics

Per-assistant usage for a week

GET
/statistics/assistants

Returns one breakdown row per assistant that had at least one completed call in the selected week. Includes assistants that have since been deleted — their calls still count and the row carries is_deleted: true. All duration fields are integer seconds (billable, with 60s minimum).

Authorization

bearerAuth
AuthorizationBearer <token>

API key in the Authorization: Bearer <key> header. Keys are created in the SMAO dashboard (Settings → API Keys).

In: header

Query Parameters

week*integer
Range1 <= value <= 53
year*integer
Range2020 <= value <= 2100

Response Body

application/json

application/json

application/json

application/json

application/json

application/json

application/json

curl -X GET "https://example.com/statistics/assistants?week=1&year=2020"
{  "data": {    "period": {      "week": 0,      "year": 0    },    "total_assistants": 0,    "total_calls": 0,    "assistants": [      {        "assistant_id": "string",        "assistant_name": "string",        "assistant_language": "string",        "is_deleted": true,        "total_calls": 0,        "total_call_seconds": 0,        "average_call_seconds": 0,        "average_calls_per_day": 0,        "weekly_call_counts": [          0,          0,          0,          0,          0,          0,          0        ],        "weekly_call_seconds": [          0,          0,          0,          0,          0,          0,          0        ],        "daily_call_counts": [          {            "date": "string",            "count": 0          }        ]      }    ]  }}