Ask an agent from AI tools with an MCP trigger
The MCP trigger is a beta feature. Ask Willow to turn it on for your organization.
An MCP trigger gives a background agent its own MCP URL. People add the URL to Cursor, Claude or any other AI tool as an MCP server, sign in with Willow, and ask the agent from their chat. The agent works in the background and sends its answer back when it's done, so the AI tool doesn't have to keep the request open while the agent works.
Add the trigger
- Open the agent and go to Triggers.
- Select Add trigger, then MCP.
- Fill in the settings below and select Save trigger.
An agent has one MCP trigger. The option only shows for agents on a platform that supports agent conversations, the same platforms that support Email. See Platforms reference.
| Setting | What it does |
|---|---|
| Mode | The mode every call runs under. Shown when your organization uses modes. |
| What it does | What AI tools are told the agent does, so they know when to ask it. Empty uses the agent's description. |
| Conversations | Follow-ups continue the conversation lets a caller pass the conversation_id of an earlier answer to keep talking in the same conversation. Every call starts a new conversation ignores it. |
| Time limit (minutes) | A call fails if the agent hasn't answered by then. Default 30, at most 1440. |
Share the URL
After you save, the MCP block on Triggers shows two URLs:
- The agent's URL,
https://<your-org>.withwillow.ai/mcp/agents/<agent-id>, asks this agent only. - The all-agents URL,
https://<your-org>.withwillow.ai/mcp/agents, lists every agent with an MCP trigger that the signed-in person may call. Their AI tool picks the agent by name in each call.
Select the copy button next to a URL and share it. When someone adds it to their AI tool, they sign in with their Willow account.
Who may call the agent
The agent's Access decides who may call it, the same way it decides who may email it. With no Access set, any member of your organization may call the agent. A personal agent answers its owner only.
The agent runs as the person who called it, so tools set to act on behalf of the triggering user run with that person's connection.
What the caller sees
The agent's MCP server has two tools:
| Tool | What it does |
|---|---|
send_message | Sends a message to the agent. On the all-agents URL it also takes agent, the agent to ask. |
get_agent_reply | Gets the answer to an earlier call by its run_id. |
AI tools that support MCP tasks get the answer when the agent finishes. Other AI tools wait up to 45 seconds; if the agent is still working, they get a run_id and use get_agent_reply to collect the answer later.
The agent answers with its reply_to_caller tool, which Willow adds to every agent with an MCP trigger. It can also send short progress updates while it works. If the agent finishes without calling it, Willow sends back the agent's last message instead, on Claude and AWS AgentCore agents.
Every call shows in Logs as a call to the agents MCP server, with the agent and the person who called it.
Troubleshooting
| Problem | What to check |
|---|---|
| The URL answers "not found" | The trigger is paused, the agent is inactive, or the person isn't allowed by the agent's Access. |
| An agent is missing from the all-agents URL | The agent has no enabled MCP trigger, or its Access doesn't include the person. |
| The call fails with "The agent didn't answer in time" | The agent didn't reply within the trigger's time limit. Raise Time limit, or check the agent's session in Sessions. See Troubleshoot an agent. |