Skip to main content

Pathways

Pathways are the conversation flows that guide how your agents interact with users. They define the logic, branching, and actions that occur during a conversation.

What Are Pathways?

A Pathway is a visual or code-defined flow that determines:
  • What questions the agent asks
  • How it responds to user input
  • When to take actions (book appointment, transfer call)
  • When to escalate to a human
Start

Greeting

Identify Intent → Appointment? → Collect Details → Book → Confirm
                → Question? → Search KB → Answer
                → Transfer? → Route Call
                → Other → Fallback

Pathway Components

Nodes

Nodes are the building blocks of pathways:
Node TypeDescription
StartEntry point of the conversation
MessageAgent speaks or sends text
ListenWaits for user input
ConditionBranches based on logic
ActionTriggers external action
TransferRoutes to human or another agent
EndTerminates the conversation

Conditions

Conditions control conversation branching:
// Intent-based
if (intent === "book_appointment") {
  goto("collect_appointment_details");
}

// Keyword-based
if (userInput.includes("emergency")) {
  goto("escalate_to_human");
}

// Data-based
if (customer.hasAppointment) {
  goto("existing_appointment_flow");
}

Actions

Actions trigger external operations:
  • API Call — Send data to external systems
  • Book Appointment — Create calendar entries
  • Send SMS — Dispatch text messages
  • Update CRM — Modify customer records
  • Transfer Call — Route to human agents

Creating Pathways

Visual Builder

The visual builder provides a drag-and-drop interface:
1

Open Pathway Editor

Navigate to your Crew and select Pathways
2

Add Start Node

Every pathway begins with a Start node
3

Build Flow

Drag nodes onto the canvas and connect them
4

Configure Nodes

Set messages, conditions, and actions for each node
5

Test

Use the simulator to test your pathway

Code Definition

For complex logic, define pathways in code:
{
  "id": "appointment_booking",
  "name": "Appointment Booking Flow",
  "nodes": [
    {
      "id": "start",
      "type": "start",
      "next": "greeting"
    },
    {
      "id": "greeting",
      "type": "message",
      "content": "Hi, I can help you schedule an appointment. What day works best for you?",
      "next": "collect_date"
    },
    {
      "id": "collect_date",
      "type": "listen",
      "variable": "appointment_date",
      "next": "collect_time"
    },
    {
      "id": "collect_time",
      "type": "message",
      "content": "Great, and what time would you prefer?",
      "next": "listen_time"
    }
  ]
}

Common Patterns

Intent Classification

Route conversations based on user intent:
Listen → Classify Intent

    ┌─────────┼─────────┐
    ↓         ↓         ↓
Schedule  Question  Transfer

Information Collection

Gather required data before taking action:
Ask Name → Store → Ask Phone → Store → Ask Email → Store → Confirm All

Escalation Flow

Gracefully hand off to humans:
Detect Escalation Trigger

Check Agent Availability

    Available? ─→ Warm Transfer

    Unavailable → Collect Callback Info → Promise Follow-up

FAQ Handling

Search and respond from knowledge base:
User Question → Search KB → Found? → Deliver Answer

                           Not Found → Apologize → Offer Transfer

Variables and Context

Pathways maintain conversation context:
// Set variables
context.customerName = "John";
context.appointmentDate = "2024-01-15";

// Use in messages
"Great, {{customerName}}, I've booked you for {{appointmentDate}}."

Built-in Variables

VariableDescription
caller_numberPhone number of the caller
call_durationHow long the call has lasted
current_timeCurrent timestamp
agent_nameName of the active agent
transfer_countNumber of transfers in this call

Testing Pathways

Simulator

Test pathways without making real calls:
  1. Open the Pathway Editor
  2. Click Simulate
  3. Type responses as if you were the user
  4. Verify the agent follows expected paths

Staging Environment

Deploy pathways to a staging Crew before production:
Development → Test → Staging → Validate → Production

Best Practices

Design the ideal conversation first, then add error handling.
Avoid deeply nested pathways. If a branch is complex, create a sub-pathway.
Users should always be able to reach a human or end the call.
Add catch-all nodes for unrecognized input.
Simulate real scenarios, including edge cases and mistakes.

Pathway Limits

PlanPathwaysNodes per Pathway
Starter550
Professional25200
EnterpriseUnlimitedUnlimited

Next Steps