> For a complete page index, fetch https://docs.synthflow.ai/llms.txt. For full documentation content, fetch https://docs.synthflow.ai/llms-full.txt.

# Multi-Agent System

> Learn how to use the Multi-Agent System and Trigger Subflow node to build one agent with multiple specialized conversation flows.

The **Multi-Agent System** lets you split a [Flow Designer](/flow-designer) agent into a main flow and several sub-agents, each a complete flow focused on one task. All of them share the agent's phone number, configuration, and analytics, so you keep one agent instead of maintaining several.

The main flow hands off to a sub-agent with a [Trigger Subflow](/flow-designer-nodes#trigger-subflow) node. When the sub-agent finishes, the call returns to the main flow and continues from the node after the trigger. Because any point in the main flow can trigger the same sub-agent, logic like pricing answers lives in one place instead of being repeated across branches.

## Create a sub-agent

Create a sub-agent for each self-contained task, such as pricing questions, technical support, appointment scheduling, or FAQs. Build each one like any other flow, with its own [Conversation](/flow-designer-nodes#conversation), [Branch](/flow-designer-nodes#branch), and [Message](/flow-designer-nodes#message) nodes.

Sub-agents inherit the main flow's [Global Settings](/flow-designer-nodes#global-settings), so personality and objection handling stay consistent across the whole call.

## Hand off with Trigger Subflow

1. In the main flow, click the plus icon and select **Trigger Subflow**.
2. Choose the sub-agent to run.
3. Add the nodes that should run after the sub-agent returns.

When the main flow reaches the trigger, it saves its position and the sub-agent takes over. When the sub-agent reaches its end, control returns to the trigger and the main flow continues with the next node. The caller hears one continuous conversation.

```mermaid
flowchart TD
    A["Conversation<br />What can I help with?"] -->|It is a pricing question| C["Trigger Subflow<br />Pricing Questions"]
    A -->|Not a pricing question| D["Continue main flow"]
    C --> E["Message<br />Anything else?"]
```

Use Trigger Subflow when you want to come back after the detour. To move to another node in the same flow without returning, use [Jump To](/flow-designer-nodes#jump-to) instead.

## Share variables between flows

Variables move in both directions automatically. A sub-agent can use anything the main flow already collected, such as `{user_name}`, and any variable a sub-agent sets, such as `{issue_resolved}`, is available to the main flow after it returns. That lets you follow a trigger with a [Branch](/flow-designer-nodes#branch) on the sub-agent's result.

The [variable drawer](/variables) lists the variables from the main flow and every sub-agent, so you can check what is available at any node.

## FAQ

#### How many sub-agents can I have in one agent?

There is no hard limit. If an agent grows to many unrelated sub-agents, consider splitting it into separate agents.

#### Can a sub-agent trigger another sub-agent?

Yes. Keep nesting to two levels at most, because deeper chains are hard to debug and maintain.

#### Do I need to publish sub-agents separately?

No. Sub-agents are [published](/version-control#publishing-a-flow-designer-agent) together with the main flow.

#### What's the difference between Trigger Subflow and Jump To?

Trigger Subflow runs a separate sub-agent and returns automatically. Jump To moves to a node in the same flow and does not return.