Skip to main content

Overview

Echo’s variable system lets you write a single agent prompt that works for any customer and any call scenario. Use {{variable_name}} syntax anywhere in your system_prompt — Echo resolves the values before the call is initiated.
"Hi {{recipient_first_name}}, I'm calling from {{business_name}} about your {{appointment_type}} on {{appointment_time}}."

Built-in Variables

Echo automatically resolves these from your business account and the customer record. You never need to pass them in variables.
VariableSourceValue
{{business_name}}BusinessYour business name from signup
{{business_summary}}BusinessYour business summary from signup
{{industry}}BusinessYour industry from signup
{{recipient_name}}CustomerFull name (first_name last_name)
{{recipient_first_name}}CustomerCustomer’s first name
{{message}}Notification requestThe message field
{{context}}Notification requestThe context field (optional)

Custom Variables

Any {{token}} that isn’t in the built-in list must be supplied in the variables map when triggering a notification.
System prompt
"...your appointment at {{appointment_time}} with {{doctor_name}}. Tone: {{tone}}."
                               ↑ custom                  ↑ custom           ↑ custom
Notification request
{
  "customer_id": "...",
  "agent_id": "...",
  "variables": {
    "appointment_time": "Thursday March 20th at 2:00 PM",
    "doctor_name": "Dr. Patel",
    "tone": "warm and professional"
  }
}
Custom variables can be any string values you want. There’s no predefined list — anything you put in variables becomes available as {{key}} in the prompt.

Override Behavior

If a caller-provided variable and a built-in share the same name, the caller-provided value wins.
"variables": {
  "recipient_first_name": "Johnny"
}
This overrides the built-in {{recipient_first_name}} with "Johnny" for this specific call.

Missing Variables

If a {{token}} appears in the system prompt but has no corresponding value (neither built-in nor custom), the token is left as-is in the rendered prompt — which will cause the AI to read out {{token_name}} literally. To avoid this:
  • Check that every {{token}} in your prompt is either a built-in or included in variables
  • Use the prompt checklist before going to production

Variable Resolution Order

1. Built-in variables (auto-resolved from business + customer records)
2. Notification-time variables (from the "variables" map in the request)
   └── Overrides built-ins on name collision

Examples by Use Case

"variables": {
  "appointment_time": "Friday April 4th at 3:30 PM",
  "doctor_name": "Dr. Kim",
  "location": "Suite 200, 450 Medical Plaza"
}
Prompt excerpt
"Your appointment with {{doctor_name}} is on {{appointment_time}} at {{location}}."
"variables": {
  "days_remaining": "2",
  "plan_name": "Pro",
  "upgrade_url": "app.yourcompany.com/upgrade"
}
Prompt excerpt
"Your {{plan_name}} trial ends in {{days_remaining}} days. Visit {{upgrade_url}} to keep access."
"variables": {
  "order_number": "ORD-88231",
  "delivery_date": "tomorrow between 2 PM and 6 PM",
  "carrier": "FedEx"
}
Prompt excerpt
"Order {{order_number}} is out for delivery via {{carrier}}. Expected: {{delivery_date}}."
"context": "This customer has called support twice this week. Be extra patient and apologetic."
Prompt excerpt
"Additional context for this call: {{context}}"