AI 智能體需要致電時,如何透過 MCP 將通話交由真人處理
When your AI agent needs to make a phone call: a pattern for handing calls to a human over MCP
Wesley提出一套透過 MCP 將 AI 智能體的電話任務交由真人處理的流程,涵蓋任務結構化、撥號前驗證及按問題 ID 回傳答案。流程採用非同步安排,讓智能體在通話期間處理其他工作,並可在通話排隊時更新或取消。
Disclosure up front: I run TaskBullet, and the last section describes our MCP server. Everything above it applies no matter which tool you use.
Agents are getting good at research, email and forms, but a lot of real-world work still ends at a phone number. The dentist that only books by phone, the supplier with no online stock check, the county office that answers questions only by voice. That's where most agent workflows quietly stop and hand the job back to a person.
Here is a simple pattern for when an agent needs a call made.
1. Treat the call as a structured job, not a chat
Don't ask the agent to "call and find out about pricing." Have it produce a small spec:
- the phone number and who it belongs to
- the goal of the call in one sentence
- a short list of questions, each with an id (q1, q2, q3)
- what to do if the person can't answer (leave a callback number, ask who can, etc.)
Ids matter. They let answers come back matched to questions, so the agent can drop them straight into its next step without re-parsing a transcript.
2. Validate before you dial
Have a check step before anything costs money or reaches a real person: is the number in a supported region, are the questions answerable on a call, is anything in the spec sensitive or something the caller shouldn't promise. Catching a bad spec here is much cheaper than a wasted call.
3. Let a person make the call
Voice bots are fine for simple, predictable calls. For anything where the other side goes off-script (hold queues, transfers, "let me check with my manager"), a human caller usually handles it better. The agent doesn't need to know who dialed; it just needs the result in a predictable shape.
4. Return structured answers plus notes
What comes back should be:
- an answer for each question id (or "unanswered" with a reason)
- short wrap-up notes for anything that didn't fit a question
- the transcript or summary if you want it for audit
Now the agent can keep going: update the CRM, compare quotes, or schedule the follow-up.
5. Make it async
Calls take minutes, not milliseconds. Use a place / poll (or webhook) / fetch-result flow and let the agent work on other things in between. Allow updates and cancels while the call is queued.
How we do it
TaskBullet's MCP server (npx -y @taskbullet/mcp-server, v0.2.0) exposes this exact flow as tools: validate_call, place_call, get_call, update_call, cancel_call and get_transcript. Your agent supplies the questions; a real TaskBullet assistant makes the call and returns answers matched by question id plus wrap-up notes. US and Canada numbers. Pricing is $2.50 for the first minute (minimum), then $1 per additional minute. The same MCP connection also has a delegate_task tool for other jobs an agent can't finish on its own.
Docs: https://taskbullet.com/docs/agent-api.md
Hub: https://taskbullet.com/hub
If you've built your own version of this pattern, I'd like to hear how you handled hold queues and voicemail.
來源:DEV Community · dev.to