Twilio MCP Server
Send SMS and WhatsApp messages and make voice calls through Twilio from workflows
The Twilio MCP server lets your workflows send SMS and WhatsApp messages, make voice calls with TwiML, check delivery and list WhatsApp templates. It provides 7 tools.
Setup
- Sign up at twilio.com and copy your Account SID and Auth Token from the Twilio Console.
- Go to Resources > MCP Servers > Add Server (OWNER or ADMIN).
- Choose Twilio (SMS / WhatsApp / Calls).
- Give it a Name and fill in:
| Field | Required | Description |
|---|---|---|
| Account SID | Yes | Starts with AC |
| Auth Token | Yes | Your Twilio Auth Token |
| From Number | No | Default sender, a Twilio number in E.164 format (e.g., +14155551234) |
- Under Available in workspaces, pick the workspaces, then click Add Server.
Phone numbers are always E.164: a leading +, the country code, no spaces or dashes. The sender must be a number your Twilio account owns - the configured From Number or a per-call from.
Business SMS to US numbers requires A2P 10DLC registration in Twilio; without it, messages are not delivered.
WhatsApp: templates outside the 24-hour window
WhatsApp decides by who wrote last:
- Within 24 hours after the recipient wrote to you,
send_whatsappcan send any text inbody. - Otherwise - which includes every notification your workflow starts on its own - free text is accepted by Twilio (you even get a message SID) but never delivered. You must send an approved Content Template:
content_sidpluscontent_variablesfor its placeholders.
So for notifications:
- Create the template and submit it for approval in the Twilio Console (no tool can create or approve one).
- Call
list_content_templatesand pick a template whoseusableistrue. - Pass its
sidascontent_sidtosend_whatsapp.
The template's category sets the price: utility and authentication templates cost far less than marketing ones. media_url works only for free-form messages; a template carries its own media. For the full picture, see Twilio's WhatsApp documentation.
Tools
send_sms
Send an SMS message via Twilio.
| Parameter | Type | Required | Description |
|---|---|---|---|
to | string | Yes | Recipient phone number in E.164 format (e.g., +14155551234) |
body | string | Yes | SMS message body (max 1600 characters) |
from | string | No | Sender number. Defaults to the server's From Number. |
send_whatsapp
Send a WhatsApp message. Free-form body is delivered only inside an open 24-hour window; messages you start yourself need content_sid - an approved Content Template. The whatsapp: prefix is added to the numbers for you.
| Parameter | Type | Required | Description |
|---|---|---|---|
to | string | Yes | Recipient phone number in E.164 format (e.g., +14155551234) |
body | string | No | Free-form message body. Delivered only inside an open 24h window (recipient wrote recently). Provide either body or content_sid. |
content_sid | string | No | Twilio Content Template SID (HX…) of an approved template — required for business-initiated messages outside the 24h window. Provide either content_sid or body. |
content_variables | object | No | Template placeholder values keyed by name/index, e.g. {"1": "Denis", "2": "tomorrow 10:00"}. Only used with content_sid. |
from | string | No | WhatsApp sender number. Defaults to the server's From Number. |
media_url | string | No | URL of media to attach (image, PDF, etc.). Free-form mode only. |
list_content_templates
List the WhatsApp Content Templates of this Twilio account with their approval status, SID and placeholder names. Use it before send_whatsapp whenever the recipient has not written in the last 24 hours. Reads templates only; it cannot create or approve them.
| Parameter | Type | Required | Description |
|---|---|---|---|
name_contains | string | No | Case-insensitive substring filter on the template's friendly name. |
approved_only | boolean | No | Return only approved templates. Default false - unapproved ones are listed with usable: false, so you can tell "missing" from "not approved yet". |
page_size | number | No | Templates per page (1-100, default 50). |
make_call
Make a phone call via Twilio using TwiML for call instructions.
| Parameter | Type | Required | Description |
|---|---|---|---|
to | string | Yes | Recipient phone number in E.164 format. |
twiml | string | Yes | TwiML instructions for the call (e.g., '<Response><Say>Hello!</Say></Response>') |
from | string | No | Caller number. Defaults to the server's From Number. |
timeout | number | No | Seconds to wait for answer (default: 30, max: 600) |
get_message_status
Check the delivery status of a sent message by its SID. An undelivered message is a normal answer: status failed or undelivered with errorCode and errorMessage. An unknown SID fails the call.
| Parameter | Type | Required | Description |
|---|---|---|---|
message_sid | string | Yes | Message SID (returned from send_sms or send_whatsapp) |
list_messages
List recent messages (sent and received)
| Parameter | Type | Required | Description |
|---|---|---|---|
to | string | No | Filter by recipient number. |
from | string | No | Filter by sender number. |
limit | number | No | Max messages to return (default: 20, max: 100) |
get_account_info
Get Twilio account information and balance.
No parameters.
Errors and Delivery
- A request Twilio refuses (invalid number, bad credentials, a sender you do not own) fails the step with
Twilio error <code>: <message>. - A message Twilio accepted is not proof of delivery. Use
get_message_statuswith the returned SID: a message that could not be delivered comes back withstatusfailedorundeliveredand anerrorCode/errorMessage(for example30007). - An SMS body is plain text, up to 1600 characters. Longer texts are split by the carrier into segments that may arrive out of order.
Example Workflow
An alert routed by severity:
- Trigger - Webhook receives an alert from a monitoring system.
- Logic - Switch on
{{trigger.data.severity}}:critical-twilio:make_callwith TwiML such as<Response><Say>Critical alert on the payment service.</Say></Response>.high-twilio:send_smswith the alert text.medium-twilio:send_whatsappwith an approved template (content_sid) and the alert fields incontent_variables.