# SMS for AI > SMS API for AI Agents — Send SMS to 190+ countries from any AI agent. REST API + native MCP (Model Context Protocol) server. Pay-per-use credits, no monthly subscriptions. SMS for AI is a managed cloud service that lets AI agents, chatbots, and automation workflows send SMS messages worldwide. It provides a REST API and an MCP server (Model Context Protocol) compatible with Claude Desktop and any MCP-compatible framework. Pricing is purely pay-per-use: buy credit bundles via Stripe, spend them per SMS. No subscriptions, no lock-in. ## Key Facts - Service URL: https://smsforai.com - API base URL: https://smsforai.com/api/v1 - MCP endpoint: https://smsforai.com/api/mcp - Pricing model: Prepay credits (Stripe), pay per SMS. No monthly fee. - US SMS price: $0.01 per message - Coverage: 190+ countries - Authentication: Bearer token in the Authorization header (`Authorization: Bearer smsai_YourToken`) ## REST API Endpoints - `GET /api/v1` — API status and version (public, no auth) - `GET /api/v1/me` — Authenticated token + user info - `GET /api/v1/balance` — Current credit balance in USD - `GET /api/v1/countries` — List of all countries with per-SMS price in USD - `POST /api/v1/sms/send` — Send an SMS message - `GET /api/v1/sms` — List sent messages (paginated) - `GET /api/v1/sms/{id}` — Get a specific SMS by ID ### Send SMS Example ```http POST https://smsforai.com/api/v1/sms/send Authorization: Bearer smsai_YourToken Content-Type: application/json { "to": "+14155552671", "body": "Your verification code is 4821", "sender_id": "MYAPP" } ``` Response: ```json { "sms": { "id": 42, "status": "sent", "to": "+14155552671", "price_usd": 0.01 }, "balance": 9.99 } ``` ### Check Balance Example ```http GET https://smsforai.com/api/v1/balance Authorization: Bearer smsai_YourToken ``` Response: `{"credits_usd": 9.99}` ## MCP Integration (Claude Desktop and MCP-compatible agents) Add to `claude_desktop_config.json`: ```json { "mcpServers": { "smsforai": { "url": "https://smsforai.com/api/mcp", "headers": { "Authorization": "Bearer smsai_YourToken" } } } } ``` Available MCP tools after connecting: - `send_sms` — Send an SMS to any country with a custom sender ID - `get_balance` — Check current credit balance in real time - `list_sms` — View recent messages sent by the agent ## API Token Permissions Tokens can be scoped with specific permissions: - `sms:send` — Required to send SMS - `sms:read` — List and view SMS logs - `balance:read` — Check account balance Tokens also support: IP whitelist, per-minute rate limits, daily rate limits, USD spending cap, and optional expiry date. This makes them safe to embed in autonomous agents. ## Pricing Packages | Package | Credits | ≈ SMS (US) | |---------|----------|------------| | $10 | $10 USD | ~1,000 SMS | | $25 | $25 USD | ~2,500 SMS | | $50 | $50 USD | ~5,000 SMS | | $100 | $100 USD | ~10,000 SMS | Credits never expire. Payments via Stripe (card). Auto-recharge available. ## Use Cases - OTP and verification code delivery by AI agents - AI-powered customer support with SMS fallback channel - Telegram / Discord / WhatsApp bots with SMS notifications - LangChain, CrewAI, AutoGen, and AutoGPT agents with an SMS tool - Claude Desktop sending SMS as a native tool call - Automated alerts, reminders, and status updates via AI workflows - Multi-agent pipelines where one agent notifies users via SMS ## FAQ (Short Answers) **Q: What is SMS for AI?** A: A REST API and MCP server that lets AI agents send SMS globally, using prepaid credits. **Q: Does it support MCP?** A: Yes. The MCP endpoint at https://smsforai.com/api/mcp works with Claude Desktop and any MCP-compatible agent. **Q: Is there a free tier?** A: Yes. Sign up free (no credit card). Credits are added when you buy a package starting at $10. **Q: How is pricing calculated?** A: Credits are deducted per SMS at the destination-country rate. US = $0.01/SMS. Query /api/v1/countries for all rates. **Q: Can an agent manage its own tokens and balance?** A: Yes. Agents can check balance (/balance), list SMS history (/sms), and query pricing (/countries) autonomously. **Q: Is it secure to embed tokens in agents?** A: Yes, if you scope tokens with only the permissions needed and set spending caps / IP whitelists. ## Pages - [Home](https://smsforai.com/) - [API Documentation](https://smsforai.com/docs/api) - [Pricing](https://smsforai.com/pricing) - [Use Cases](https://smsforai.com/use-cases) - [FAQ](https://smsforai.com/faq) - [Sign Up Free](https://smsforai.com/register)