{
  "markdown": "# @textbee/mcp\n\n[![npm version](https://img.shields.io/npm/v/%40textbee%2Fmcp)](https://www.npmjs.com/package/@textbee/mcp)\n[![CI](https://github.com/textbee/textbee-mcp/actions/workflows/ci.yaml/badge.svg)](https://github.com/textbee/textbee-mcp/actions/workflows/ci.yaml)\n[![license](https://img.shields.io/npm/l/%40textbee%2Fmcp)](./LICENSE)\n\nMCP server for [textbee.dev](https://textbee.dev), the open source SMS gateway that turns an Android phone into an SMS API. Gives Claude Desktop, Claude Code, Cursor, and any MCP client the ability to send and read SMS through your own phone and your own number.\n\nThree tools, no per-message markup, works with self-hosted textbee instances.\n\n## Setup\n\nYou need a textbee account with a paired Android device and an API key from the [dashboard](https://app.textbee.dev/dashboard). The key has full account access; treat it like a password.\n\n### Claude Code\n\n```bash\nclaude mcp add textbee -s user -e TEXTBEE_API_KEY=your-key -- npx -y @textbee/mcp\n```\n\n### Claude Desktop\n\nAdd to `claude_desktop_config.json` (macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`):\n\n```json\n{\n  \"mcpServers\": {\n    \"textbee\": {\n      \"command\": \"npx\",\n      \"args\": [\"-y\", \"@textbee/mcp\"],\n      \"env\": { \"TEXTBEE_API_KEY\": \"your-key\" }\n    }\n  }\n}\n```\n\n### Cursor\n\nThe same object in `~/.cursor/mcp.json`.\n\n### Slow first start\n\n`npx` downloads the package on first run. If your client times out waiting, install globally once and point the config at the binary:\n\n```bash\nnpm install -g @textbee/mcp\n```\n\n```json\n{ \"mcpServers\": { \"textbee\": { \"command\": \"textbee-mcp\", \"env\": { \"TEXTBEE_API_KEY\": \"your-key\" } } } }\n```\n\n## Tools\n\n### send_sms\n\nSend an SMS to one or more recipients (E.164 format, for example `+15550100123`). The sending phone is chosen automatically: your default device, otherwise the enabled device with the most recent heartbeat. Optional `device_id`, `sim_subscription_id`, and `scheduled_at`. Returns an `sms_batch_id` for delivery checks when the account uses the SMS queue.\n\n### get_messages\n\nRead messages across every device on the account. Defaults to received messages, newest first. Filter by `direction` (`received`, `sent`, `all`), free-text `search`, `sms_batch_id` (per-recipient delivery status of a send), `device_ids`, and a `from`/`to` time window. Supports cursor pagination for polling without duplicates or gaps.\n\n### list_devices\n\nThe phones on the account: ids, enabled state, which one sends by default, last check-in, and message counts.\n\n## Self-hosted textbee\n\nPoint the server at your own instance:\n\n```json\n\"env\": {\n  \"TEXTBEE_API_KEY\": \"your-key\",\n  \"TEXTBEE_BASE_URL\": \"https://sms.example.com\"\n}\n```\n\nThe `/api/v1` suffix is optional and added automatically. Subpath deployments like `https://example.com/textbee` work too. An invalid URL is an error rather than a silent fallback, so a typo never sends your key to the public API.\n\n## Environment variables\n\n| Variable | Required | Default | Purpose |\n|---|---|---|---|\n| `TEXTBEE_API_KEY` | yes | none | API key from the textbee dashboard |\n| `TEXTBEE_BASE_URL` | no | `https://api.textbee.dev` | Your instance's URL when self-hosting |\n| `TEXTBEE_TIMEOUT_MS` | no | `30000` | Per-request timeout in milliseconds |\n\n## Notes\n\n- Your key stays on your machine: this server talks only to the textbee API at the base URL above.\n- Sends count against your textbee plan quota, and the plan's rate limits apply server-side.\n- All diagnostics go to stderr; stdout is reserved for the MCP protocol.\n\n## Using it as a library\n\nThe package also exports its tool definitions for embedding in another MCP host (this is how the hosted remote endpoint reuses them):\n\n```js\nimport { createTextbeeMcpServer, staticCredentials, loadConfig } from '@textbee/mcp'\n\nconst server = createTextbeeMcpServer({\n  credentials: staticCredentials(loadConfig(process.env)),\n})\n```\n\nCredentials are resolved per tool call, so a multi-tenant host can inject a different key per request. See `credentialsFromAuthInfoExtra`.\n\n## License\n\nMIT. Part of the [textbee](https://github.com/textbee/textbee) project.\n",
  "bytes": 4132,
  "sha": "93f76c5914c5050a3286de7c9319e3e0e7f192239e10320841e0e7c426290fe5",
  "repo_slug": "textbee/textbee-mcp",
  "fonte": "repo",
  "truncated": false,
  "api": "https://agentalog.com/api/listings/mcp_io_github_textbee_mcp_093737d4/readme"
}