Returns totals and a daily breakdown for calls created in a date range, optionally for one agent. This is the data behind the summary cards on the Analytics page. For custom charts use Query analytics.
Request#
| Field | Type | Required | Description |
|---|---|---|---|
from |
integer | No | Start of the range, Unix ms. Default 30 days before to. |
to |
integer | No | End of the range, Unix ms. Default now. |
agent_id |
string | No | Only calls from this agent. |
tz |
string | No | IANA time zone used to group calls into days. Default Australia/Sydney. An unknown zone falls back to UTC. |
All are query parameters. Calls are selected by creation time.
Example request#
curl "https://api.tried.com.au/analytics/summary?from=1792195200000&to=1792368000000&tz=Australia/Sydney" \
-H "Authorization: Bearer $TRIED_API_KEY"const res = await fetch("https://api.tried.com.au/analytics/summary?from=1792195200000&to=1792368000000&tz=Australia/Sydney", {
headers: { Authorization: `Bearer ${process.env.TRIED_API_KEY}` },
});
const summary = await res.json();import os, requests
res = requests.get(
"https://api.tried.com.au/analytics/summary",
headers={"Authorization": f"Bearer {os.environ['TRIED_API_KEY']}"},
params={
"from": 1792195200000,
"to": 1792368000000,
"tz": "Australia/Sydney",
},
)
summary = res.json()Response#
200 OK
{
"from": 1792195200000,
"to": 1792368000000,
"agent_id": null,
"total_calls": 42,
"ended_calls": 40,
"successful_calls": 31,
"success_rate": 0.8158,
"avg_duration_ms": 142350,
"total_duration_ms": 5694000,
"total_cost": 9.4875,
"avg_cost": 0.2259,
"sentiment": {
"Positive": 22,
"Negative": 4,
"Neutral": 12,
"Unknown": 0
},
"disconnection_reasons": {
"user_hangup": 28,
"agent_hangup": 9,
"call_transfer": 3
},
"by_direction": {
"inbound": 30,
"outbound": 10,
"web": 2
},
"latency": {
"e2e_p50": 880,
"e2e_p90": 1240,
"e2e_p99": 1710,
"e2e_avg": 932
},
"daily": [
{
"date": "2026-10-17",
"calls": 14,
"successful": 10,
"success_rate": 0.7692,
"avg_duration_ms": 130214,
"cost": 3.0125,
"e2e_p50": 870,
"e2e_p90": 1210
},
{
"date": "2026-10-18",
"calls": 17,
"successful": 13,
"success_rate": 0.8125,
"avg_duration_ms": 148588,
"cost": 3.9,
"e2e_p50": 890,
"e2e_p90": 1260
},
{
"date": "2026-10-19",
"calls": 11,
"successful": 8,
"success_rate": 0.8889,
"avg_duration_ms": 136727,
"cost": 2.575,
"e2e_p50": 875,
"e2e_p90": 1230
}
]
}| Field | Type | Description |
|---|---|---|
total_calls |
integer | Calls created in the range. |
ended_calls |
integer | Calls with status ended. |
successful_calls |
integer | Calls whose post-call analysis marked them successful. |
success_rate |
number | successful_calls divided by calls that have a success value, from 0 to 1. 0 when none are analysed. |
avg_duration_ms |
integer | Average duration of ended calls. |
total_cost, avg_cost |
number | Sum and per-call average of the combined call cost in dollars, rounded to 4 decimals. |
sentiment |
object | Count of calls per user sentiment. |
disconnection_reasons |
object | Count of calls per disconnection reason. |
by_direction |
object | Count of calls per direction. Calls with no direction count as web. |
latency |
object | End-to-end latency in ms across every turn of every call: p50, p90, p99 and average. null when there are no samples. |
daily |
object[] | One row per day in tz, including days with no calls. Days use the call start time, or creation time if the call never started. avg_duration_ms is the day's ended-call duration divided by the day's calls. |
Errors#
| Status | When |
|---|---|
400 |
A query parameter failed validation, for example from: Expected number, received nan. |
401 |
Missing or invalid API key. |
403 |
The key's IP allowlist or scopes reject the request. This route needs the analytics scope. |
404 |
agent_id does not exist in the workspace: Agent <id> not found. |
429 |
Rate limit exceeded. See Rate limits. |
See Errors for the body format.
Retell compatibility#
Retell's public API reference has no analytics endpoints, so this route has no Retell SDK equivalent.