Read metrics
Get your account's usage metrics — total conversations, messages and averages — in a single request.
A simple endpoint to take the pulse of your account’s usage: how many conversations and messages have accumulated, how many conversations are still active, and the average number of messages per conversation. Handy for your own dashboards or reports.
Authentication
The request is authenticated with your public API key in the X-API-Key header.
The metrics are always those of your own account.
Get metrics
Base path: /v1/public/v1/analytics
| Method | Path | Purpose |
|---|---|---|
GET |
/analytics |
Basic usage metrics for your account. |
Request
GET /v1/public/v1/analytics
X-API-Key: <your-api-key>
Response (200 OK)
{
"total_conversations": 1280,
"total_messages": 5920,
"active_conversations": 37,
"avg_messages_per_conversation": 4.63
}
| Field | Type | Description |
|---|---|---|
total_conversations |
integer | All conversations ever created for your account. |
total_messages |
integer | All messages across every conversation. |
active_conversations |
integer | Conversations currently in the active state. |
avg_messages_per_conversation |
float | Mean messages per conversation. |
Errors
| Code | Meaning |
|---|---|
401 |
The X-API-Key header is missing or the key is invalid. |
403 |
Your plan doesn’t include public API access. |