What Is an Analytics Block?
An analytics block is a prompt plus a field spec. Attach it to an agent and it runs automatically on every session that agent finishes - there is no “run” call. Attach it, place calls, read results.client.analytics reads the org-scoped platform plane, like
client.voice_profiles and client.telephony. It needs UNPOD_PLATFORM_TOKEN
plus UNPOD_ORG_HANDLE; a bare Bearer UNPOD_API_KEY cannot reach it.The Field Spec
Each entry offields is {name, type, description?, choices?}:
A summary is extracted for every block whether or not you declare one - pass
summary_description to steer what it emphasises. model overrides the
service’s default LLM for that block alone.
Authoring Blocks
Attaching to Agents
attach() is idempotent, and one block serves as many agents as you attach it
to. Every session those agents finish runs the block.
Reading Results
AnalyticsResult fields
AnalyticsBlock fields
block_id, name, prompt, fields (fields_spec on the model),
summary_description, model, project_id, org_id, success_enabled,
success_description, success_type, success_choices, condition,
template_id, version, state, agent_ids, created, modified.
Next Steps
Agents
The
agent_id you attach blocks to.Recordings & Transcripts
The raw turns a block reads before it extracts.