Connect Cursor to WhatsApp and Telegram
Cursor reads remote MCP servers from an mcp.json file. DMWire needs three lines in it.
Add DMWire to mcp.json
Use ~/.cursor/mcp.json to have DMWire in every project, or .cursor/mcp.json in one project's folder.
~/.cursor/mcp.json
{
"mcpServers": {
"dmwire": {
"url": "https://mcp.dmwire.ai/mcp",
"headers": { "X-API-Key": "${env:DMWIRE_API_KEY}" }
}
}
}${env:DMWIRE_API_KEY} reads the key from your environment, so it never sits in a file you might commit (Cursor MCP docs). Set it in the shell Cursor starts from:
Terminal
export DMWIRE_API_KEY="paste your dmw_live_ key here"Restart Cursor and check that DMWire shows up in Cursor's MCP settings with its tools turned on.
Check the key outside Cursor
If Cursor shows an error, test the key directly. This is the call Cursor makes first, run for real:
Request
curl \
-X POST https://mcp.dmwire.ai/mcp \
-H "X-API-Key: $DMWIRE_API_KEY" \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc": "2.0", "id": 1, "method": "initialize", "params": {"protocolVersion": "2025-06-18", "capabilities": {}, "clientInfo": {"name": "my-agent", "version": "1.0"}}}'Response (HTTP 200, captured 2026-10-17)
{
"result": {
"protocolVersion": "2025-06-18",
"capabilities": {
"tools": {}
},
"serverInfo": {
"name": "dmwire",
"title": "DMWire",
"version": "1.0.0"
},
"instructions": "DMWire connects you, the agent, to the user's own WhatsApp and Telegram so you can read and answer their messages. DMWire runs no AI of its own: you are the brain, DMWire is the wire.\n\n1. Start with `list_accounts` to see what is connected.\n2. To connect WhatsApp, call `connect_whatsapp` and give the user the QR code, connect link or pairing code it returns to open on their phone; check `get_whatsapp_status` until it is connected. For Telegram, call `connect_telegram`, then `submit_telegram_code` with the code Telegram sends the user (and `submit_telegram_password` if they use two-step verification).\n3. To receive messages, call `wait_for_messages`. It waits until something arrives, then returns the messages and a cursor: call it again with that cursor to keep listening.\n4. To reply, call `send_message`.\n5. Free tier limits: 1 connected account, 50 sends a day, 10 new contacts a day. A freshly registered WhatsApp number cannot message new contacts during its first days. `get_usage` shows what is left today.\n6. Ask the user before you message anyone, and never send unsolicited messages: answer people who wrote first, or people the user asked you to contact.\n7. Request bodies go in the `body` argument."
},
"jsonrpc": "2.0",
"id": 1
}A missing header gives:
Request
curl \
-X POST https://mcp.dmwire.ai/mcp \
-H "Content-Type: application/json" \
-H "Accept: application/json, text/event-stream" \
-d '{"jsonrpc": "2.0", "id": 1, "method": "initialize", "params": {"protocolVersion": "2025-06-18", "capabilities": {}, "clientInfo": {"name": "my-agent", "version": "1.0"}}}'Response (HTTP 401, captured 2026-10-17)
{
"jsonrpc": "2.0",
"error": {
"code": -32001,
"message": "Missing DMWire API key. Send it in the X-API-Key request header (or Authorization: Bearer <key>). API keys in the URL query string are not accepted."
},
"id": null
}First prompt
Cursor chat (agent mode)
Use DMWire: list my connected accounts and today's usage.Then link an account, see Quickstart step 2.
Last checked against the live service on 2026-10-17.