> ## Documentation Index
> Fetch the complete documentation index at: https://www.vobiz.ai/docs/llms.txt
> Use this file to discover all available pages before exploring further.

# What Is a Call Flow? Design, Automation & Examples

> A call flow is the step-by-step path a phone call takes through your system — from answer to resolution. How to design call flows, automate them with XML, common patterns (IVR, transfer, voicemail, AI routing), and how to build one on Vobiz.

*November 2026 · Vobiz Team*

**A call flow is the blueprint for how a phone call moves through your system — which message plays first, what options the caller hears, how their response routes the call, and what happens if no one's available.** Good call flows reduce transfers, eliminate wait time, and resolve calls faster. Poor call flows frustrate callers with long menus, dead ends, and confusing options.

> [!NOTE]
>
> **Key takeaways**
>
> * A call flow maps every step from call answer to resolution — greeting, routing, options, transfer, voicemail
> * Call flow automation removes the need for a human to manually route each call
> * On Vobiz, call flows are defined in VobizXML returned by your server in response to webhooks
> * Common patterns: IVR menu → agent transfer, time-based routing, AI agent first layer, voicemail fallback
> * Well-designed call flows measure first-call resolution (FCR), handle time, and abandonment rate

## Anatomy of a Call Flow

Every call flow — however simple or complex — has the same basic structure:

```
1. ENTRY POINT
   Call arrives on your number
         ↓
2. ANSWER
   Pre-answer message / queue position / ringback
         ↓
3. GREETING
   "Thank you for calling [Company]. How can we help you today?"
         ↓
4. ROUTING LOGIC
   DTMF menu / voice / time-of-day / caller ID / queue availability
         ↓
5. DESTINATION
   Agent transfer / AI agent / voicemail / self-service / external number
         ↓
6. COMPLETION
   Call ends / callback scheduled / CRM logged
```

Each step is a decision point your system makes in real time. The sophistication comes from how many conditions you can evaluate at each step.

## Types of Call Flows

### Inbound Call Flow

The most common type — a caller dials your number and the flow handles them:

```
Caller dials → Greeting → IVR menu → Route to department/agent → 
  Agent available? Yes → Connect
  Agent unavailable? → Queue → Timeout → Voicemail / Callback offer
```

### Outbound Call Flow

Your system initiates the call — alerts, reminders, campaigns:

```
System dials contact → AMD (human or machine?) →
  Human: AI agent intro → Qualify/inform → Log outcome
  Machine: Drop voicemail → Hang up
```

### After-Hours Call Flow

Time-based routing sends calls to different destinations outside business hours:

```
Call arrives →
  Is it 9am–6pm Monday–Friday? →
    Yes: Route to agent queue
    No: "Our office is closed. Hours are [X]. Press 1 to leave a voicemail, Press 2 for emergency support."
```

### AI-First Call Flow

The AI agent handles the call first; human agents receive only escalations:

```
Call arrives → AI voice agent → 
  Resolved by AI? → Log, end call
  Needs human? → Transfer to specialist with context summary
```

## Designing a Call Flow: Principles

**Keep menus to 4 options or fewer**: Beyond 4 choices, callers start to forget the first options. If you need more, use sub-menus ("For billing, press 2. For account changes, press 3. For technical support, press 4.").

**Put the most common options first**: Analyse your call distribution. If 60% of callers want billing support, that should be option 1. Don't bury high-volume options at the end.

**Always offer a way out**: Every menu should offer a path to reach a human — even if it means waiting in a queue. Callers who feel trapped abandon or redial, increasing your handle time.

**Match language to callers**: For India-based businesses, offer Hindi and regional language options early. A caller who hears their native language immediately feels better served.

**Test the fail paths**: What happens when no agent answers? When the caller presses an invalid key? When the call drops mid-IVR? Every edge case needs a defined outcome.

## Building Call Flows on Vobiz with XML

Vobiz call flows are defined in XML returned by your server. When a call arrives, Vobiz sends a webhook to your `answerUrl` and executes whatever XML your server returns.

**Simple IVR call flow:**

```xml theme={null}
<?xml version="1.0" encoding="UTF-8"?>
<Response>
  <Gather action="/menu-response" method="POST" timeout="5" numDigits="1">
    <Speak>
      Welcome to Acme Corp. Press 1 for Sales. Press 2 for Support. Press 3 for Billing.
    </Speak>
  </Gather>
  <!-- Fallback if no input received -->
  <Redirect>/no-input</Redirect>
</Response>
```

**Menu response handler** (your server logic, Python):

```python theme={null}
from fastapi import FastAPI, Form
from fastapi.responses import Response

app = FastAPI()

@app.post("/menu-response")
async def menu_response(Digits: str = Form(...)):
    if Digits == "1":
        xml = """<?xml version="1.0" encoding="UTF-8"?>
<Response>
  <Dial><Number>+919876500001</Number></Dial>
</Response>"""
    elif Digits == "2":
        xml = """<?xml version="1.0" encoding="UTF-8"?>
<Response>
  <Dial><Number>+919876500002</Number></Dial>
</Response>"""
    elif Digits == "3":
        xml = """<?xml version="1.0" encoding="UTF-8"?>
<Response>
  <Speak>Connecting you to billing.</Speak>
  <Dial><Number>+919876500003</Number></Dial>
</Response>"""
    else:
        xml = """<?xml version="1.0" encoding="UTF-8"?>
<Response>
  <Redirect>/answer</Redirect>
</Response>"""
    return Response(content=xml, media_type="application/xml")
```

**Time-based routing:**

```python theme={null}
from datetime import datetime
import pytz

@app.post("/answer")
async def answer():
    ist = pytz.timezone('Asia/Kolkata')
    now = datetime.now(ist)
    hour = now.hour
    weekday = now.weekday()  # 0=Monday, 6=Sunday
    
    if weekday < 5 and 9 <= hour < 18:  # Weekdays 9am-6pm
        xml = open_hours_xml()
    else:
        xml = after_hours_xml()
    
    return Response(content=xml, media_type="application/xml")
```

## Common Call Flow Patterns

### Pattern 1: IVR → Agent Transfer

```
Greeting → Menu → Department selection → Dial agent → 
  Agent answers → Live call
  Agent busy → Queue wait music → Timeout → Voicemail
```

Best for: Medium businesses with multiple departments, 9–6 operations.

### Pattern 2: AI First Layer

```
Greeting → AI voice agent handles call →
  AI resolves: Log, end call
  AI escalates: Transfer + summary to agent
```

Best for: High-volume businesses where 60%+ of calls are routine (order status, FAQs, appointment booking).

### Pattern 3: Callback Flow

```
Call arrives → "All agents busy. Wait time: 8 minutes."
  Press 1 to hold → Queue
  Press 2 for callback → Collect confirmation → Hang up → 
    Agent free → System dials customer back
```

Best for: Contact centres where wait times spike and abandonment rates are high.

### Pattern 4: Outbound Appointment Reminder

```
System dials patient → 
  "This is a reminder for your appointment on [date] at [time]."
  Press 1 to confirm → Log confirmed
  Press 2 to reschedule → Transfer to booking agent
  Press 3 to cancel → Log cancellation, free slot
  No response → Hang up, flag for follow-up
```

Best for: Healthcare, service businesses, any scheduled appointment workflow.

### Pattern 5: Payment Reminder

```
System dials customer →
  "You have an outstanding balance of ₹[amount] due on [date]."
  Press 1 to pay now → Transfer to payment agent
  Press 2 to request extension → Collect callback number → Log
  Press 3 to dispute → Transfer to billing team
  No response → Log unanswered
```

Best for: Fintech, NBFC, collections workflows.

## Measuring Call Flow Performance

| Metric | What it measures | Target |
| - | - | - |
| **First Call Resolution (FCR)** | % of calls resolved without callback | > 70% |
| **IVR Completion Rate** | % of callers who navigate the IVR fully | > 60% |
| **IVR Abandonment Rate** | % who hang up during IVR | \< 20% |
| **Average Handle Time (AHT)** | Total call time including hold | Varies by business |
| **Queue Abandonment** | % who hang up while waiting | \< 10% |
| **Transfer Rate** | % of calls transferred to another queue | \< 15% |

Review CDR data from Vobiz to calculate these. High IVR abandonment usually means the menu is too long or options are unclear. High transfer rate means routing is misconfigured.

## Call Flow Automation with the Vobiz API

For fully programmatic call flows, use the Vobiz REST API alongside XML:

**Trigger an outbound call:**

```bash theme={null}
curl -X POST https://api.vobiz.ai/v1/calls \
  -H "X-Auth-Token: YOUR_AUTH_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "from": "+911400000001",
    "to": "+919876543210",
    "answerUrl": "https://your-server.com/answer",
    "machineDetection": "Enable"
  }'
```

**Update a live call mid-flow:**

```bash theme={null}
curl -X POST https://api.vobiz.ai/v1/calls/{callUuid} \
  -H "X-Auth-Token: YOUR_AUTH_TOKEN" \
  -d '{"action": "redirect", "redirectUrl": "https://your-server.com/new-flow"}'
```

This lets you dynamically change a call's flow while it's in progress — useful for event-driven routing (agent becomes available, escalation trigger fires, real-time data changes).

## Call Flow for AI Voice Agents

Modern call flows increasingly use AI agents rather than rigid IVR menus. Instead of "Press 1 for Sales", the caller says "I want to know about pricing" and the AI routes based on intent:

```xml theme={null}
<?xml version="1.0" encoding="UTF-8"?>
<Response>
  <Stream url="wss://your-ai-agent.com/audio" bidirectional="true">
    <Parameter name="systemPrompt" value="You are a helpful receptionist..." />
  </Stream>
</Response>
```

The AI agent reads intent, asks clarifying questions, routes appropriately, and handles conversation naturally — no rigid menu required. The telephony infrastructure (Vobiz) is identical; only the routing logic changes from DTMF to conversational AI.

For detailed setup guides:

* [AI voice agent guide](https://www.vobiz.ai/docs/solutions/ai-voice-agent.md)
* [Cloud IVR guide](https://www.vobiz.ai/docs/solutions/cloud-ivr.md)
* [Build an AI receptionist](https://www.vobiz.ai/docs/blogs/what-is-an-ai-receptionist.md)

## Next Steps

* [Explore VobizXML verbs](https://www.vobiz.ai/docs/xml/overview/how-it-works.md) — the building blocks of every call flow
* [Try the XML builder tool](https://www.vobiz.ai/docs/xml-builder.md) — visual call flow editor with live XML output
* [Run the IVR example](https://www.vobiz.ai/docs/examples/vobiz-ivr-xml-python.md) — working Python + FastAPI server
* [Read the Cloud IVR guide](https://www.vobiz.ai/docs/solutions/cloud-ivr.md) — full IVR setup walkthrough
* [Connect an AI agent](https://www.vobiz.ai/docs/integrations/retellai-dashboard.md) for conversational routing


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.