MCP server
@dialgem/mcp: let Claude, Cursor and other AI assistants manage your voice agents, calls and phone numbers, with spending tools off by default.
@dialgem/mcp is a Model Context Protocol server for Dialgem. It lets an AI assistant such as Claude Desktop, Claude Code or Cursor look at and manage your voice agents, calls and phone numbers. It is built on the TypeScript SDK, so it reaches only what the SDK can.
It needs Node 20 or later and runs on your own machine over standard input and output. It does not run on Dialgem's servers.
Set it up
Create an API key, then add the server to your assistant's configuration.
Claude Desktop, Cursor and most clients:
{
"mcpServers": {
"dialgem": {
"command": "npx",
"args": ["-y", "@dialgem/mcp"],
"env": { "DIALGEM_API_KEY": "zk_..." }
}
}
}Claude Code:
claude mcp add dialgem -e DIALGEM_API_KEY=zk_... -- npx -y @dialgem/mcpThe key is read from DIALGEM_API_KEY only, never from a file. Give it a scoped key with only what you want the assistant to do. The whoami tool shows the key's scopes, and a call outside them is refused by the API.
Tools
Tools come in three tiers, and what the assistant can see depends on how you start the server.
| Tier | Tools | Available |
|---|---|---|
| Read | whoami, list_agents, get_agent, list_voices, list_calls, get_call, list_phone_numbers, search_phone_numbers, list_contacts | Always |
| Write | create_agent, update_agent, delete_agent, publish_agent_version, chat_with_agent, stop_call, assign_phone_number | Unless you pass --read-only |
| Spend | start_phone_call, buy_phone_number | Only if you pass --allow-spend |
delete_agent and stop_call are marked destructive, so assistants that ask for confirmation will ask before running them. chat_with_agent sends a text message to an agent and returns its reply, which tests a prompt without a phone call. See Text chat.
Safety options
Add the flag to args, or set the environment variable in env.
| Flag | Environment variable | Effect |
|---|---|---|
--read-only | DIALGEM_MCP_READ_ONLY=1 | Only the read tools are offered. Nothing can change. |
--allow-spend | DIALGEM_MCP_ALLOW_SPEND=1 | Also offers the two tools that place a call or buy a number. |
--allow-spend is off by default on purpose. Those two tools ring a real person or charge your account, and an assistant can be steered into using them by text it reads, such as a transcript or a prompt someone else wrote. Turn it on only when you are watching, and consider a key with narrow scopes.
For a read-only view of your account, use:
"args": ["-y", "@dialgem/mcp", "--read-only"]Troubleshooting
- The server exits at start: it prints
no API keywhenDIALGEM_API_KEYis missing from the server'senvblock. - A tool is missing: write tools are hidden by
--read-only, and the two spend tools are hidden unless--allow-spendis set. - A tool returns a permission error: the key lacks the scope for it.
Source
The code is at github.com/DialgemAI/dialgem-mcp under the Apache-2.0 license. For a terminal instead of an assistant, see the command-line tool.