Post-call Extraction
Post-call extraction lets you define a Custom Analysis schema (a free-form prompt + typed keys) once on the agent. After every completed call, the platform runs a structured-output LLM over the transcript and ships the extracted values inline in the samesession.completed webhook — no second webhook to handle.
Partner API (v2) only for the endpoints below.
1. Define the Custom Analysis schema
extraction_config: null to remove the schema entirely.
Enable / disable without losing your schema
Automatic extraction runs after a completed call only when the agent has a config and theextraction_enabled master switch is on. The flag defaults to true,
so configured agents extract automatically out of the box.
To pause automatic extraction while keeping your prompt and keys intact, set
extraction_enabled: false instead of nulling the config:
Manual replay (
POST /api/v2/calls/{call_id}/extract) ignores extraction_enabled —
it runs as long as a config exists. So you can keep iterating on a config with
dry_run replays while automatic extraction stays paused.extraction_enabled value is returned on the agent object from
GET /api/v2/agent/{id}.
Supported types
Each configured key is returned in the extraction result. When a value cannot be found, Vocobase returns
null for that key so partners receive a consistent object shape.
2. Receive results in the webhook
After every completed call where the agent has anextraction_config, Vocobase runs extraction and ships the result inline in session.completed:
3. Read results via the API
extraction object on data.session.extraction. Useful for partners that prefer polling over webhooks, or for backfilling values into a CRM after the fact.
4. Replay extraction against past calls
Edited the prompt or added a new key? Backfill any past session by replaying the extractor:dry_run: true returns the values without persisting and without re-firing the partner webhook (useful for prompt iteration). The replay always uses the agent’s current extraction_config, not the config at original-call time. Returns 400 when the agent has no extraction_config defined.
5. Auto-export every extraction to Google Sheets
Instead of (or alongside) handling the webhook, you can have Vocobase append each completed call’s extraction to a Google Sheet automatically — via a post-call lifecycle hook, with no endpoint to host.Prerequisite: connect Google Sheets on the agent
The agent must have an activegoogle_sheets integration bound to it:
connection_id.
Add the post-call hook
Lifecycle-hook body fields are camelCase (
toolSlug, toolFn) — unlike the snake_case agent fields elsewhere on this page. append_extraction is POST_CALL only. The spreadsheet_id is the ID in the sheet URL: docs.google.com/spreadsheets/d/THIS_PART/edit (not the #gid=... tab). Add "sheet_name": "Leads" to target a specific tab — defaults to Sheet1.extraction_config.keys order, so columns stay stable across calls even when a value is null.
Map columns explicitly
To control the column layout, passinput.columns on append_extraction — an ordered list of { header, value } pairs. Each value is a template token ({{extraction.<field>}}, or a call-metadata field), and a standalone placeholder keeps its type (numbers stay numeric). This is what the dashboard’s column-mapping UI generates.
headers) is written once — only when the target tab is empty. Available call-metadata tokens: {{session_id}}, {{caller_phone}}, {{callee_phone}}, {{duration_secs}}, {{ended_at}}, {{transcript_summary}}. Omit columns to fall back to the default all-keys row shown above.
Append a raw row
For full control with no header management, useappend_row with a flat values array of templates:
session.completed webhook.
Failure semantics
Extraction failures never block webhook delivery. Thesession.completed payload always ships, with extraction.status indicating outcome:
Partners that need extracted values can branch on
status === 'success'; partners that just need transcript + recording can ignore the field entirely.
Next steps
Pre-call Variables
Template the agent’s prompt and greeting with per-call values via
{{name}} placeholders.Webhook Payloads
Full reference for the
session.completed payload, including the extraction block.