Skip to main content
Glama
deshartman

Twilio Messaging MCP Server

by deshartman

Twilio 消息 MCP 服务器

一个 MCP(模型上下文协议)服务器,可通过 Twilio API 发送短信。

特征

  • 通过 Twilio 发送短信

  • 与 Claude Desktop 等 MCP 客户端集成

  • 无需环境变量的安全凭证处理

  • 使用 Twilio API 密钥来提高安全性

Related MCP server: Twilio MCP Server

安装

您可以通过 npx 直接使用此服务器:

npx twilio-messaging-mcp-server <accountSid> <apiKey> <apiSecret> <number>

或者全局安装:

npm install -g twilio-messaging-mcp-server
twilio-messaging-mcp-server <accountSid> <apiKey> <apiSecret> <number>

配置

服务器需要以下参数:

  • accountSid :您的 Twilio 帐户 SID(必须以“AC”开头,将被验证)

  • apiKey :您的 Twilio API 密钥(以“SK”开头)

  • apiSecret :您的 Twilio API 密钥

  • number :发送消息的 Twilio 电话号码(E.164 格式,例如 +1234567890)

安全说明

此服务器使用 API 密钥和机密信息(而非身份验证令牌)来提高安全性。此方法提供了更好的访问控制,并能够在需要时撤销凭证。有关更多信息,请参阅Twilio API 密钥文档。

与 Claude Desktop 一起使用

本地开发

对于本地开发(当软件包未发布到 npm 时),将以下内容添加到您的 Claude Desktop 配置文件(macOS 上的~/Library/Application Support/Claude/claude_desktop_config.json或 Windows 上的%APPDATA%\Claude\claude_desktop_config.json )中:

{
  "mcpServers": {
    "twilio-messaging": {
      "command": "node",
      "args": [
        "/PATHTONODE/twilio-messaging-mcp-server/build/index.js",
        "your_account_sid_here",
        "your_api_key_here",
        "your_api_secret_here",
        "+1234567890"
      ]
    }
  }
}

用您的实际 Twilio 凭证替换这些值:

  • 第一个参数:您的 Twilio 帐户 SID(以“AC”开头)

  • 第二个参数:您的 Twilio API 密钥(以“SK”开头)

  • 第三个参数:您的 Twilio API 密钥

  • 第四个参数:您的 Twilio 电话号码(E.164 格式)

您可以通过在项目目录中运行以下命令来获取绝对路径:

# On macOS/Linux
echo "$(pwd)/build/index.js"

# On Windows (PowerShell)
Write-Output "$((Get-Location).Path)\build\index.js"

发布到 npm 后

一旦包发布到 npm,您就可以使用以下配置:

{
  "mcpServers": {
    "twilio-messaging": {
      "command": "npx",
      "args": [
        "-y", 
        "twilio-messaging-mcp-server",
        "your_account_sid_here",
        "your_api_key_here",
        "your_api_secret_here",
        "+1234567890"
      ]
    }
  }
}

可用工具

发送短信

通过 Twilio 发送短信。

参数:

  • to :E.164 格式的目标电话号码(例如 +1234567890)

  • message :要发送的消息内容

Claude 中的用法示例:

Can you send an SMS to +1234567890 saying "Hello from MCP!"

发展

要构建项目:

npm install
npm run build

手动运行服务器

要手动启动服务器进行测试(在 Claude Desktop 之外):

# Run with actual credentials
node build/index.js "your_account_sid_here" "your_api_key_here" "your_api_secret" "+1234567890"

# Or use the npm script (which uses ts-node for development)
npm run dev -- "your_account_sid_here" "your_api_key_here" "your_api_secret" "+1234567890"

服务器将启动并等待 MCP 客户端连接。您应该看到如下输出:

[TwilioMessagingServer] Server started successfully

与 Claude Desktop 一起使用时,Claude 加载配置文件时服务器会自动启动。您无需手动启动它。

执照

麻省理工学院

Related MCP Connectors

  • The Mobile Text Alerts SMS MCP server enables your AI to send SMS messages & manage contacts

  • The Telnyx MCP server is an official implementation of the Model Context Protocol that enables AI clients (like Claude Desktop, Cursor, and OpenAI Agents) to interact with Telnyx's telephony, messaging, and AI assistant APIs. It provides comprehensive capabilities including making and managing phone calls, sending SMS/MMS messages, purchasing and configuring phone numbers, creating AI assistants with custom instructions, managing cloud storage buckets, scraping and embedding website content, and handling integration secrets. The server exists as both a local implementation and a remotely hosted version, allowing developers to integrate real-world communication infrastructure directly into AI applications.

  • Phone, SMS & email for AI agents — one remote MCP endpoint, OAuth login, zero install.

  • WhatsMCP connects Claude and other MCP-compatible AI agents directly to WhatsApp. Send and receive text, images, documents, and voice notes; manage groups (create, add/remove members, promote admins); look up contacts and profiles; follow channels; and read call and message history — all through a standard MCP interface. For voice use cases, WhatsMCP offers SIP-based calling plans (inbound-only, or full inbound/outbound) so AI voice agents can answer and place WhatsApp calls, plus low-latency WebSocket integrations with voice agent providers like ElevenLabs. Multiple WhatsApp accounts can be paired and managed per workspace, with webhook support for real-time inbound message delivery to your own infrastructure.

Related MCP Servers

  • A
    license
    C
    quality
    D
    maintenance
    A server that connects Claude AI to Twilio through the Model Context Protocol, enabling prompt-assisted management of Twilio accounts, phone numbers, and regulatory compliance.
    4
    2
    MIT
  • A
    license
    Not graded
    quality
    D
    maintenance
    A Model Context Protocol server that enables Claude and other AI assistants to send SMS and MMS messages using Twilio.
    22 npm
    15
    MIT
  • A
    license
    B
    quality
    D
    maintenance
    A Model Context Protocol (MCP) server that allows AI agents like Claude to interact with the Aligo SMS API to send text messages and retrieve related information.
    1
    1
    MIT
  • A
    license
    B
    quality
    D
    maintenance
    MCP server for sending SMS via the SMSPM API. Send transactional SMS from Claude Desktop, Cursor, Windsurf, Cline, or any MCP client.
    1
    29 npm
    MIT