Returns the people currently watching a call through the stream or Listen. A call allows 5 viewers at once. Beyond Retell
Request#
Path parameters#
| Parameter | Type | Required | Description |
|---|---|---|---|
call_id |
string | Yes | The call. |
Example request#
curl "https://api.tried.com.au/v2/calls/call_8d1e0f2a3b4c5d6e7f8a9b0c/viewers" \
-H "Authorization: Bearer $TRIED_API_KEY"const res = await fetch("https://api.tried.com.au/v2/calls/call_8d1e0f2a3b4c5d6e7f8a9b0c/viewers", {
headers: { Authorization: `Bearer ${process.env.TRIED_API_KEY}` },
});
const data = await res.json();import os, requests
res = requests.get(
"https://api.tried.com.au/v2/calls/call_8d1e0f2a3b4c5d6e7f8a9b0c/viewers",
headers={"Authorization": f"Bearer {os.environ['TRIED_API_KEY']}"},
)
data = res.json()Response#
200 OK
{
"call_id": "call_8d1e0f2a3b4c5d6e7f8a9b0c",
"max_viewers": 5,
"viewers": [{ "viewer": "user_1a2b3c4d5e6f7a8b9c0d1e2f", "since": 1792310420000, "modes": ["stream", "listen"] }]
}One entry per person: viewer is the dashboard user ID, or key:<api key id> for API keys; since is when they started (epoch ms); modes lists stream and/or listen. Viewer slots are held in Redis when REDIS_URL is set, so the limit applies across API instances.
Errors#
| Status | When |
|---|---|
401 |
Missing or invalid API key. |
403 |
The key's IP allowlist or scopes reject the request. This route needs the calls scope. |
404 |
No call with this ID in the workspace. |
429 |
Rate limit exceeded. See Rate limits. |
See Errors for the body format.