Pre-Call Workflows
Pre-call workflows run before a call starts. They give you a window to prepare for the conversation — looking up the caller, loading their account data, checking for open issues, running routing logic, or anything else that helps the agent start the call with full context. Think of it as a journey that runs before the first word is spoken.What You Can Do
- Look up the caller — query your CRM, database, or identity provider by phone number to identify who is calling
- Load account context — pull in account status, plan details, recent orders, open tickets, or any other data the agent needs
- Run routing logic — decide which agent or flow to use based on the caller’s profile, time of day, or business rules
- Check for open issues — see if the caller has an active support case and pass that context into the call
- Enrich from multiple sources — call multiple APIs in sequence or in parallel to build a complete picture before the agent picks up
- Apply business rules — flag VIP customers, check eligibility, validate accounts, or set priority levels
How It Works
- A call comes in to a number with an assigned agent
- Simple AI triggers your pre-call workflow
- Your workflow runs its logic — database lookups, API calls, business rules, whatever you need
- Your workflow responds with a
parametersobject - Simple AI merges those parameters into the call
- The agent starts the conversation with full context already loaded
Example
Your pre-call workflow receives the incoming call details:Configuration
Configure pre-call workflows on an agent via the dashboard or the Update Agent API:pre_call_webhook_url— your workflow endpointpre_call_webhook_auth_token— optional bearer token for authenticationpre_call_webhook_timeout— how long to wait for a response (default: 5 seconds)pre_call_webhook_enabled— set totrueto activate
Post-Call Workflows
Post-call workflows run after a call completes. They let you trigger a full sequence of downstream actions — not just a single notification, but an entire journey of follow-up steps.What You Can Do
- Sync to your CRM — create or update contact records, log call activity, attach transcripts and recordings
- Send follow-ups — trigger follow-up emails, SMS messages, or scheduled callbacks based on what happened on the call
- Update tickets — create, update, or resolve support tickets based on the call outcome
- Route to humans — alert your team when a call needs manual follow-up, assign tasks, or escalate to a manager
- Feed analytics — push call data, analyzer results, and sentiment scores into your data warehouse or BI tools
- Run multi-step workflows — chain together any combination of the above. A single call completion can kick off a CRM update, a follow-up email, a Slack notification, and a task assignment all at once
Available Events
Simple AI fires two events that can trigger post-call workflows:- call.completed — fires when a call ends. Use this to kick off your post-call workflow.
- call.transcript_update — fires during the call with transcript updates. Use this for real-time monitoring or mid-call actions.
Example: Post-Call Journey
A typical post-call workflow might look like:Best Practices
- Keep pre-call workflows fast — the default timeout is 5 seconds. If you need to do heavy processing, return the essentials quickly and handle the rest asynchronously.
- Return only what the agent needs — do not send your entire customer record. Pick the fields the agent will actually use in the conversation.
- Make post-call handlers idempotent — due to retries, your server may receive the same event more than once. Processing the same event twice should be safe.
- Log everything — log incoming requests and outgoing responses so you can debug issues in your workflows.
- Use authentication — set an auth token on your pre-call workflow and validate it on your server to prevent unauthorized requests.
- Think in journeys — pre-call and post-call workflows are at their most powerful when you treat them as full orchestration points, not just single API calls. Chain together the actions that make sense for your business.