v4

latestOpenAPI 3.1.02026-08-086635375.7 KB
Sessions

get aggregated session analytics

Returns aggregated latency analytics across sessions — percentile distributions (p50/p90/p95/p99/max/avg) for each stage of the transcription → LLM → TTS → first-audio path, interruption and error rates, tool call outcomes, and a sample of the slowest turns. Only sessions where Anam runs the conversational pipeline (turnkey, custom LLM and ElevenLabs agent sessions) produce analytics reports; LiveKit and audio-passthrough sessions count toward sessionCount but never carry analytics. Defaults to the last 24 hours; the maximum range is 31 days. Reports are aggregated from the 1000 most recent report-capable sessions matching the filters — session types that never produce reports don't consume that window — and the truncated field reports when more report-capable sessions matched. Narrow the time range or filters to analyse busier periods exhaustively.

get/v1/sessions/analytics

Query parameters

fromstring date-time

Start of the time range (ISO 8601). Defaults to 24 hours before to.

tostring date-time

End of the time range (ISO 8601). Defaults to now.

personaIdstring uuid

Only include sessions for this persona.

apiKeyIdstring uuid

Only include sessions minted by this API key.

clientLabelstring

Only include sessions whose client label matches exactly.

sessionType'turnkey' | 'custom_llm_server' | 'custom_llm_client' | 'livekit' | 'elevenlabs_agent'

Only include sessions of this type.

organizationIdstring

Aggregate sessions of another organization. Restricted to Anam-internal admin API keys; other keys receive 403.

Response

Successfully computed aggregate analytics

fromstring date-time
tostring date-time
sessionCountinteger

Total sessions matching the filters in the range, whether or not they produced an analytics report.

sessionsWithReportsinteger

Sessions whose analytics report was aggregated. Reports are read from the 1000 most recent report-capable matching sessions; session types that never produce reports don't consume that window.

truncatedboolean

True when more than 1000 report-capable sessions matched; only reports among the most recent 1000 of them were aggregated.

turnCountinteger