Skip to content

MCP server

@smsfabric/mcp-server lets an AI assistant such as Claude, Cursor or GitHub Copilot send SMS, verify phone numbers, look up contacts and run campaigns through your SMSFabric account. You ask in plain language; the assistant calls the server’s tools, and the server calls the SMSFabric API with your API key.

The Model Context Protocol is an open standard for connecting AI assistants to tools and data. An MCP server describes a set of tools (a name, a description and an input schema for each), and an MCP client, the assistant’s app, decides when to call them.

The SMSFabric server runs on your machine as a local process. The client starts it and talks to it over standard input and output (stdio). It needs Node.js 20 or newer and makes outbound HTTPS requests to https://api.smsfabric.com only.

The server has 16 tools. Full inputs and examples are in Tools.

Area Tools Example prompt
Messages send_sms, list_messages, get_message “Text +201001234567 that the order shipped, then tell me when it is delivered.”
Verify send_verification, check_verification “Send a verification code to +201001234567.”
Phones list_devices “Which gateway phones are offline or low on battery?”
Contacts find_contacts, add_contact “Find Mona’s number and add her colleague Sara with the tag vip.”
Campaigns list_campaigns, get_campaign, create_campaign, estimate_campaign, start_campaign, pause_campaign, resume_campaign, cancel_campaign “Draft a campaign to the vip tag with 20% off this weekend and tell me how long it would take.”

The server cannot manage API keys, webhooks, team members, settings or the blacklist. Those stay in the portal and the API.

An assistant acts on your behalf, so the server limits what it can do in four layers:

  1. The API key’s scopes. The server can only do what its key allows. A key with messages:read and devices:read can look but never send. See Security for a key per use case.
  2. Test keys. With an sf_test_ key, messages and campaigns go to the built-in virtual device and never reach a real phone. Start there.
  3. Tool annotations. Read-only tools are marked readOnlyHint. start_campaign and cancel_campaign are marked destructiveHint, and their descriptions tell the assistant to confirm with you first. Clients use these hints to decide when to ask for your approval.
  4. Your client’s approval prompt. Claude Desktop, Claude Code, Cursor and VS Code ask before they run a tool unless you allow it permanently. Keep approval on for every tool that sends.

The server never sees verification codes: SMSFabric generates them and only the recipient gets them. The assistant has to ask the person to read the code back.