Skip to main content
Glama

Get session analytics across sessions

anam_session_stats
Read-onlyIdempotent

Returns latency percentiles (p50, p90, p95, p99, max, avg) for each stage from transcription through the LLM and TTS to first audio, interruption and error rates, tool call outcomes and the slowest turns, across sessions. Only sessions where Anam runs the conversation (turnkey, custom LLM, ElevenLabs agent) have analytics; LiveKit and audio-passthrough ones count in sessionCount only. It reads the 1,000 newest matching sessions with analytics; truncated says more matched. The last 24 hours by default, up to 31 days.

anam_session_insights summarises the same with findings.

Tool call template

This tool declares no required parameters. Add optional parameters from the input schema as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {},
    "name": "anam_session_stats"
  }
}

Input Schema

NameRequiredDescriptionDefault
toNoEnd of the time range (ISO 8601). Defaults to now.
fromNoStart of the time range (ISO 8601). Defaults to 24 hours before `to`.
apiKeyIdNoOnly include sessions minted by this API key.
personaIdNoOnly include sessions for this persona.
clientLabelNoOnly include sessions whose client label matches exactly.
sessionTypeNoOnly include sessions of this type.

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Annotations already cover the read-only, idempotent, non-destructive profile, and the description adds substantive behavior on top: a hard cap of 1,000 newest matching sessions, the `truncated` flag that signals more matches exist, and which session types yield no analytics at all. These are exactly the operational constraints an agent cannot infer from annotations or schema.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with what is returned, followed by coverage caveats and then the recency cap, so the highest-value facts come first. It is dense but nearly every clause carries information; the opening percentiles list is long, though justified for a metrics tool.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

No output schema exists, and the description compensates by naming the metrics returned, two response fields (`truncated`, `sessionCount`), the exact default window, and the record cap. An agent knows the scope, limits, and return shape well enough to call it and interpret the result.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters4/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

With 100% schema coverage the baseline is 3, but the description adds real meaning: the default 24-hour lookback relative to `to`, the 31-day ceiling on the range, and the practical consequence of `sessionType` values (three of the five yield analytics). Filter-specific semantics like exact-match `clientLabel` are left to the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States specific deliverables: latency percentiles (p50/p90/p95/p99/max/avg) per pipeline stage, interruption and error rates, tool call outcomes, and slowest turns, scoped across sessions. It also distinguishes itself from anam_session_insights ('summarises the same with findings'), so an agent can pick between them without opening either schema.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly flags coverage limits (only turnkey, custom LLM, and ElevenLabs agent sessions produce analytics; LiveKit and audio-passthrough appear only in `sessionCount`) and states the default 24-hour window with a 31-day maximum. It names the sibling alternative, though it does not spell out a conditional rule for choosing between the two beyond 'summarises ... with findings'.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources