Cenk Dalbudak
01/27/2026, 1:47 PMAI Evy
01/27/2026, 1:47 PMAI Evy
01/27/2026, 1:47 PM{{variable_name}} syntax. [(1) ]()
How to pass dynamic variables:
For Outbound Calls: Use the retell_llm_dynamic_variables field when calling the Create Phone Call API:
json
{
"user_name": "John Smith",
"product_name": "Premium Plan",
"account_status": "active"
}
For Inbound Calls: Supply dynamic variables via the Inbound Call Webhook.
Example prompt usage:
"Hello {{user_name}}, I understand you're interested in {{product_name}}. How can I help you today?"
Where dynamic variables work:
- Prompts
- Begin message
- Tool configurations (custom function URLs, tool descriptions, property descriptions)
- Voicemail prompts and messages
- Transfer call phone numbers
- Warm transfer instructions
- Webhook URL
You can also set default values for dynamic variables at the agent level in the dashboard, which serve as fallbacks when variables aren't included in the call request.
Note: All values in retell_llm_dynamic_variables must be strings—numbers, booleans, or other data types are not supported.AI Evy
01/27/2026, 1:47 PMAI Evy
01/27/2026, 1:47 PMCenk Dalbudak
01/27/2026, 1:48 PMCenk Dalbudak
01/27/2026, 1:49 PMAI Evy
01/27/2026, 1:49 PMAI Evy
01/27/2026, 1:49 PM"Hi {{fullname}}, how are you today?" follows the proper {{variable_name}} format for dynamic variables in prompts.
Just make sure you pass the fullname value when initiating the call. For outbound calls, include it in the retell_llm_dynamic_variables field:
json
{
"fullname": "John Smith"
}
Note: If fullname is not provided, the prompt will display the raw placeholder: "Hi {{fullname}}, how are you today?"AI Evy
01/27/2026, 1:49 PMAI Evy
01/27/2026, 1:49 PMCenk Dalbudak
01/27/2026, 1:52 PMAI Evy
01/27/2026, 1:52 PMAI Evy
01/27/2026, 1:52 PM"Hello {{user_name}}, I understand you're interested in {{product_name}}. How can I help you today?"
[(1) ]()
Common use cases from the documentation:
- **Personalized greetings**: "Hello {{customer_name}}, thanks for calling!"
- **Context-aware responses**: "I see you're calling about order {{order_id}}"
- **Time-sensitive information**: Reference {{appointment_date}} or {{deadline}}
When passing these variables for an outbound call:
json
{
"user_name": "John Smith",
"product_name": "Premium Plan",
"account_status": "active"
}
You can also use system variables that Retell provides automatically:
- {{current_time}} – Current time in America/Los_Angeles
- {{user_number}} – User's phone number
- {{direction}} – Call direction (inbound or outbound)
Tip: Ensure there are no spaces inside the curly braces. Use {{fullname}} not {{ fullname }}.
[(2) ]()AI Evy
01/27/2026, 1:52 PMAI Evy
01/27/2026, 1:52 PMCenk Dalbudak
01/28/2026, 2:32 PMAI Evy
01/28/2026, 2:32 PMAI Evy
01/28/2026, 2:33 PM<head> tag:
html
<script
id="retell-widget"
src="<https://dashboard.retellai.com/retell-widget.js%22>
type="module"
data-public-key="YOUR_RETELL_PUBLIC_KEY"
data-agent-id="YOUR_CHAT_AGENT_ID"
data-agent-version="YOUR_AGENT_VERSION"
data-title="YOUR_CUSTOM_TITLE"
></script>
How to embed the Callback Widget (for voice/phone) :
html
<script
id="retell-widget"
src="<https://dashboard.retellai.com/retell-widget.js%22>
type="module"
data-public-key="YOUR_RETELL_PUBLIC_KEY"
data-agent-id="YOUR_VOICE_AGENT_ID"
data-widget="callback"
data-phone-number="YOUR_RETELL_PHONE_NUMBER"
data-title="Request a Call"
></script>
Prerequisites:
- Create a [Public Key]() in your Retell dashboard
- For chat: Create a chat agent
- For callback: Create a voice agent and have a Retell phone number
Note: Currently, using both widgets on the same webpage has a known limitation—they share the same id="retell-widget", so only one displays at a time. This is on the roadmap to be resolved. [(2) ]()AI Evy
01/28/2026, 2:33 PMAI Evy
01/28/2026, 2:33 PMCenk Dalbudak
01/28/2026, 8:53 PMAI Evy
01/28/2026, 8:53 PMAI Evy
01/28/2026, 8:53 PMYou are going to call to a business and they may have IVR setup.
Listen carefully to their setup and press the right digit to navigate
the IVR to reach the support department.
Or if you know the digit beforehand:
Press digit 1 to reach the support department.
Important notes:
- This functionality only works with Call API v2
- Some IVRs accept audio input (just prompt your agent to speak) , while others require DTMF input (use the Press Digit Tool)
- You can also capture DTMF input from users via the Listen to User Keypad Input feature [(2) ]()AI Evy
01/28/2026, 8:53 PMAI Evy
01/28/2026, 8:53 PMCenk Dalbudak
01/28/2026, 8:57 PMAI Evy
01/28/2026, 8:57 PMAI Evy
01/28/2026, 8:58 PM## Identity
Your name is Mike.
## Goal
Your primary objective is to navigate the IVR menu to reach the support department.
## Personality
You are a patient customer.
Option 3: LLM Playground
[(1) ]()
Use the interactive text-based testing for rapid iteration and debugging. This allows real-time conversation testing and function call visualization.
Recommended workflow:
- Phase 1 (Development) : Use LLM Playground to iterate on prompts and debug function calling logic
- Phase 2 (QA) : Use LLM Simulation Testing to create comprehensive test scenarios
- Phase 3 (Production Validation) : Use actual phone calls to verify DTMF features work in real telephony conditions
Note: For testing Press Digit functionality specifically, actual phone call testing is recommended since it validates real DTMF tone transmission.AI Evy
01/28/2026, 8:58 PMAI Evy
01/28/2026, 8:58 PMCenk Dalbudak
01/28/2026, 9:02 PMAI Evy
01/28/2026, 9:02 PMAI Evy
01/28/2026, 9:02 PMAI Evy
01/28/2026, 9:02 PMAI Evy
01/28/2026, 9:02 PMCenk Dalbudak
01/30/2026, 10:21 PMAI Evy
01/30/2026, 10:21 PMAI Evy
01/30/2026, 10:22 PMAI Evy
01/30/2026, 10:22 PMAI Evy
01/30/2026, 10:22 PMCenk Dalbudak
02/01/2026, 3:51 PMAI Evy
02/01/2026, 3:51 PMAI Evy
02/01/2026, 3:51 PMcall_analyzed webhook event—not in call_started or call_ended. [(1) ]()
Key things to check:
1. Filter for the correct event type – Retell sends three webhooks per call: call_started, call_ended, and call_analyzed. The post-call analysis fields (call_analysis object) are only populated in the call_analyzed event. [(2) ]() , [(1) ]()
2. Webhook payload structure – The call_analyzed webhook includes the call object with the call_analysis field:
json
{
"event": "call_analyzed",
"call": {
"call_id": "123",
"call_analysis": {
"call_summary": "...",
"custom_analysis_data": {}
}
}
}AI Evy
02/01/2026, 3:51 PMcall_analyzed event specifically. , [(3) ]()
Troubleshooting tip: When testing, make a call, then check your webhook logs for three separate events. The post-call analysis data will only be in the third one (call_analyzed) . [(4) ]() , [(5) ]()AI Evy
02/01/2026, 3:51 PMAI Evy
02/01/2026, 3:51 PMCenk Dalbudak
02/01/2026, 3:53 PMAI Evy
02/01/2026, 3:53 PMAI Evy
02/01/2026, 3:53 PMpost_call_analysis_data on your agent. [(1) ]()
Step 1: Define custom extraction fields on your agent
Use the Update Voice Agent API to add your custom analysis categories:
json
"post_call_analysis_data": [
{
"type": "string",
"name": "customer_name",
"description": "The name of the customer.",
"examples": [
"John Doe",
"Jane Smith"
]
}
]
Available data types you can extract: [(2) ]()
- Boolean (True/False) – e.g., whether customer is a first-time caller
- Text (String) – e.g., call summaries, action items
- Number – e.g., transaction amounts, satisfaction scores
- Selector (Enum) – categorization from a fixed list
Step 2: Access your custom data via webhook
Your custom extraction data appears in the call_analyzed webhook under `custom_analysis_data`: [(3) ]() , [(4) ]()
json
{
"event_type": "call_analyzed",
"call": {
"call_analysis": {
"call_summary": "...",
"custom_analysis_data": {}
}
}
}AI Evy
02/01/2026, 3:53 PMAI Evy
02/01/2026, 3:53 PMpost_call_analysis_model to choose which model performs the analysis (default is gpt-4.1-mini) [(1) ]()AI Evy
02/01/2026, 3:53 PMCenk Dalbudak
02/01/2026, 3:54 PMAI Evy
02/01/2026, 3:54 PMAI Evy
02/01/2026, 3:54 PMcall_analyzed event includes the call_analysis field with your data:
json
{
"event_type": "call_analyzed",
"call": {
"call_analysis": {
"call_summary": "The agent called the user to ask question about his purchase inquiry...",
"in_voicemail": false,
"user_sentiment": "Positive",
"call_successful": true,
"custom_analysis_data": {}
}
}
}
, [(2) ]()
Key points:
- Post-call analysis is delivered in the call_analyzed webhook event (the third webhook after call_started and call_ended) [(1) ]()
- Your custom extraction data appears in the custom_analysis_data object [(2) ]()
- Fields will not be populated for calls that were not connected or where no conversation took place—check whether the field exists before using it [(1) ]()AI Evy
02/01/2026, 3:54 PMAI Evy
02/01/2026, 3:54 PMCenk Dalbudak
02/27/2026, 2:02 AMAI Evy
02/27/2026, 2:02 AMAI Evy
02/27/2026, 2:02 AMAI Evy
02/27/2026, 2:02 AMAI Evy
02/27/2026, 2:02 AM