Twilio SMS Server
БесплатноНе проверенEnables AI agents to send, receive, schedule, and manage SMS and MMS messages using the Twilio Programmable Messaging API. It provides comprehensive tools for h
Описание
Enables AI agents to send, receive, schedule, and manage SMS and MMS messages using the Twilio Programmable Messaging API. It provides comprehensive tools for handling bulk messaging, conversation threads, and real-time inbox monitoring through a secure, production-grade architecture.
README
Production-grade Model Context Protocol server for Twilio SMS.
Send, receive, schedule, redact, and inspect SMS/MMS conversations through any MCP-compatible client — VS Code Copilot, Codex CLI, Claude Desktop, and more.
Features
Tools (16)
| Tool | Description |
|---|---|
sms_send |
Send a single SMS or MMS |
sms_send_bulk |
Send the same message to up to 100 recipients with bounded concurrency |
sms_schedule |
Schedule a message for future delivery (requires Messaging Service) |
sms_cancel_scheduled |
Cancel a scheduled message |
sms_list_sent |
List outbound messages with optional filters |
sms_get_message |
Fetch one message by SID, enriched with delivery status |
sms_delete_message |
Delete a message record from Twilio |
sms_redact_message |
NEW — Redact message body for GDPR / privacy compliance |
sms_list_inbox |
List inbound webhook-captured messages |
sms_get_conversation |
Merge local inbox with Twilio history for a full thread |
sms_mark_read |
Mark inbox messages as read |
sms_list_numbers |
List Twilio phone numbers on the account |
sms_lookup_number |
Carrier and line-type intelligence lookup |
sms_format_number |
NEW — Validate any phone string and return E.164 + national format |
sms_usage_stats |
NEW — Daily SMS/MMS usage and cost analytics |
sms_account_info |
Account balance, status, and metadata |
Resources
| URI | Description |
|---|---|
twilio://account |
High-level account summary (SID, sender, version) |
Prompts
| Prompt | Description |
|---|---|
draft_sms |
AI-assisted SMS drafting given a recipient and topic |
summarize_conversation |
Summarize all messages exchanged with a number |
Production Hardening
- Retry with exponential backoff on transient Twilio API errors (429, 5xx, network failures)
- Webhook rate limiting — in-memory per-IP throttle (120 req/min)
- Structured logging — timestamped, leveled, consistent format on stderr
- Input validation — Pydantic v2 strict schemas with E.164, SID pattern enforcement
- Webhook signature verification — Twilio
RequestValidatoron all inbound hooks - Health and readiness endpoints —
/healthz,/readyzfor orchestrators - Docker multi-stage build with non-root user, health checks, persistent volume
py.typedmarker for downstream type-checker compatibility
Requirements
- Python 3.11+
- A Twilio account and a Twilio phone number
- For scheduled messages: a Twilio Messaging Service SID
- For inbound messages: a publicly reachable webhook URL
- Docker Desktop (optional, for container deployment)
Quick Start
cp env.example .env # fill in your Twilio credentials; for local runs set TWILIO_DB_PATH=inbox.db
pip install -e ".[dev]"
pytest # run the test suite
python -m twilio_sms_mcp.boot # start MCP + webhook server
Client Configuration
VS Code (GitHub Copilot / Copilot Chat)
Add to your VS Code settings.json or .vscode/mcp.json:
{
"mcp": {
"servers": {
"twilio-sms": {
"command": "python",
"args": ["-m", "twilio_sms_mcp.boot"],
"env": {
"TWILIO_ACCOUNT_SID": "ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"TWILIO_AUTH_TOKEN": "your_auth_token_here",
"TWILIO_FROM_NUMBER": "+12025551234"
}
}
}
}
}
Claude Desktop
Add to claude_desktop_config.json (macOS: ~/Library/Application Support/Claude/, Windows: %APPDATA%\Claude\):
{
"mcpServers": {
"twilio-sms": {
"command": "python",
"args": ["-m", "twilio_sms_mcp.boot"],
"env": {
"TWILIO_ACCOUNT_SID": "ACxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx",
"TWILIO_AUTH_TOKEN": "your_auth_token_here",
"TWILIO_FROM_NUMBER": "+12025551234"
}
}
}
}
Codex CLI
codex mcp add twilio-sms \
-- docker run --rm -i \
--env-file .env \
-p 8080:8080 \
-v twilio_sms_data:/data \
twilio-sms-mcp
Verify:
codex mcp get twilio-sms
codex mcp list
Docker
Build and run:
docker build -t twilio-sms-mcp .
docker run --rm -i \
--env-file .env \
-p 8080:8080 \
-v twilio_sms_data:/data \
twilio-sms-mcp
Or use Docker Compose:
docker compose up -d
Webhook Notes
- Configure Twilio to POST to
<your-host>/webhook/smsfor inbound messages. - Configure Twilio to POST to
<your-host>/webhook/statusfor delivery callbacks. - Set
TWILIO_PUBLIC_WEBHOOK_BASE_URLwhen behind a reverse proxy or ngrok. - Keep
TWILIO_VALIDATE_WEBHOOK_SIGNATURES=truein production.
Environment Variables
| Variable | Required | Default | Description |
|---|---|---|---|
TWILIO_ACCOUNT_SID |
Yes | — | Twilio Account SID (starts with AC) |
TWILIO_AUTH_TOKEN |
Yes | — | Twilio Auth Token |
TWILIO_FROM_NUMBER |
Yes | — | Default sender in E.164 format |
TWILIO_MESSAGING_SERVICE_SID |
No | — | Required for sms_schedule |
TWILIO_WEBHOOK_AUTH_TOKEN |
No | — | Override for webhook signature validation |
TWILIO_PUBLIC_WEBHOOK_BASE_URL |
No | — | Public URL for webhook signature validation |
TWILIO_VALIDATE_WEBHOOK_SIGNATURES |
No | true |
Disable only for local debugging |
TWILIO_BULK_SEND_CONCURRENCY |
No | 10 |
Max parallel sends for sms_send_bulk |
TWILIO_LOG_LEVEL |
No | INFO |
Logging verbosity |
TWILIO_DB_PATH |
No | inbox.db |
SQLite database location |
WEBHOOK_PORT |
No | 8080 |
Webhook HTTP server port |
TWILIO_API_RETRY_ATTEMPTS |
No | 3 |
Retry count for transient API errors |
TWILIO_API_RETRY_DELAY |
No | 1.0 |
Base delay in seconds between retries |
MCP_TRANSPORT |
No | stdio |
MCP transport: stdio, sse, or http |
MCP_HOST |
No | 0.0.0.0 |
Bind address for SSE/HTTP transport |
MCP_PORT |
No | 8000 |
Port for SSE/HTTP transport |
Testing
pip install -e ".[dev]"
pytest -v
Production Checklist
- Use HTTPS for webhook delivery
- Set
TWILIO_VALIDATE_WEBHOOK_SIGNATURES=true - Use a Messaging Service SID for sender pooling and scheduled messages
- Persist
/datavolume so inbox state survives restarts - Never commit
.env— it is excluded via.gitignoreand.dockerignore - Monitor
/healthzand/readyzfrom your orchestrator - Set
TWILIO_LOG_LEVEL=WARNINGin high-traffic environments
License
Установка Twilio SMS Server
У этого сервера нет опубликованного пакета — он собирается из исходников. Открой репозиторий и следуй инструкции в README.
▸ github.com/0x-Professor/Twilio-mcp-serverFAQ
Twilio SMS Server MCP бесплатный?
Да, Twilio SMS Server MCP бесплатный — установка в пару кликов через Unyly без оплаты.
Нужен ли API-ключ для Twilio SMS Server?
Нет, Twilio SMS Server работает без API-ключей и переменных окружения.
Twilio SMS Server — hosted или self-hosted?
Self-hosted: сервер запускается локально на твоей машине командой из раздела установки.
Как установить Twilio SMS Server в Claude Desktop, Claude Code или Cursor?
Открой Twilio SMS Server на unyly.org, выбери вкладку своего клиента (Claude Desktop, Claude Code, Cursor) и нажми Install — конфиг сгенерируется автоматически, без правки JSON.
Похожие MCP
Gmail
Read, send and search emails from Claude
автор: GoogleSlack
Send, search and summarize Slack messages
автор: SlackRunbear
No-code MCP client for team chat platforms, such as Slack, Microsoft Teams, and Discord.
Discord Server
A community discord server dedicated to MCP by [Frank Fiegel](https://github.com/punkpeye)
Klavis AI
Open Source MCP Infra. Hosted MCP servers and MCP clients on Slack and Discord.
Work90210/APIFold
Turn any REST API into a hosted MCP server. 18 free public servers (GitHub, Stripe, Slack, OpenAI, Notion, and more) — no setup required, bring your own API key
автор: Work90210arikusi/deepseek-mcp-server
MCP server for DeepSeek AI with chat, reasoning, multi-turn sessions, function calling, thinking mode, and cost tracking.
автор: arikusihashgraph-online/hashnet-mcp-js
MCP server for the Registry Broker. Discover, register, and chat with AI agents on the Hashgraph network.
автор: hashgraph-onlineprofullstack/mcp-server
A comprehensive MCP server aggregating 20+ tools including SEO optimization, document conversion, domain lookup, email validation, QR generation, weather data,
автор: profullstackWayStation-ai/mcp
Seamlessly and securely connect Claude Desktop and other MCP hosts to your favorite apps (Notion, Slack, Monday, Airtable, etc.). Takes less than 90 secs.
автор: waystation-aiCompare Twilio SMS Server with
Не уверен что выбрать?
Найди свой стек за 60 секунд
Автор?
Embed-бейдж для README
Похожее
Все в категории communication
