This project is a fork of abhaybabbar/retellai-mcp-server, originally licensed under the MIT License. This fork is independently maintained and extended under the same license.
This is a Model Context Protocol (MCP) server implementation for RetellAI, allowing AI assistants to interact with RetellAI's voice services. Based on the RetellAI API.
The RetellAI MCP server provides tools for:
- Call Management: Create and manage phone calls and web calls
- Agent Management: Create and manage voice agents with different LLM configurations
- Phone Number Management: Provision and configure phone numbers
- Voice Management: Access and use different voice options
- Test Case Definitions: Create and manage simulation test cases for voice agents (undocumented API)
- Open
Claude Desktopand pressCMD + ,to go toSettings. - Click on the
Developertab. - Click on the
Edit Configbutton. - This will open the
claude_desktop_config.jsonfile in your file explorer. - Get your Retell API key from the Retell dashboard (https://dashboard.retellai.com/apiKey).
- Add the following to your
claude_desktop_config.jsonfile. See here for more details. - Restart the Claude Desktop after editing the config file.
{
"mcpServers": {
"retellai-mcp-server": {
"command": "npx",
"args": ["-y", "@robraux/retellai-mcp-server"],
"env": {
"RETELL_API_KEY": "<your_retellai_token>",
// Optional: Only needed for Test Case Definition tools (undocumented API)
"RETELL_UNDOCUMENTED_BEARER_TOKEN": "<your_bearer_token>",
"RETELL_UNDOCUMENTED_ORG_ID": "<your_workspace_org_id>"
}
}
}
}The RetellAI MCP server uses a two-tier authentication system:
RETELL_API_KEY: Your RetellAI API key for all documented APIs- Get this from: RetellAI Dashboard > API Key
- Required for: All 31 documented tools (calls, agents, phone numbers, voices, LLMs, knowledge bases)
RETELL_UNDOCUMENTED_BEARER_TOKEN: Bearer token for undocumented APIsRETELL_UNDOCUMENTED_ORG_ID: Your workspace/organization ID- Required for: Only the 4 Test Case Definition tools (simulation testing)
- These are completely optional - the server works perfectly without them
If you want to use the Test Case Definition tools, you can find these values using your browser's Developer Tools:
- Open Browser DevTools: Press F12 or right-click and select "Inspect"
- Go to Network Tab: Click the "Network" tab in DevTools
- Login to RetellAI: Navigate to your specific workspace in the RetellAI Dashboard
- Monitor Network Requests: Look for API requests to
api.retellai.com - Find Headers: Look for requests that include both:
Authorization: Bearer <token>(this is yourRETELL_UNDOCUMENTED_BEARER_TOKEN)Orgid: org_<id>(this is yourRETELL_UNDOCUMENTED_ORG_ID)
Note: The Org ID is your Workspace ID and follows the format org_XXXXXXXXXXXXXXXXXXXXXXXX
- List all the numbers I have in retellai
- List all the agents I have
- Tell me more about pizza delivery agent
- Creating agent and calling example:
- Create an agent that calls my local pizza shop, make sure to keep the conversation short and to the point.
- Order a margeritta pizza
- Payment will be done by cash on delivery
- Send it to
- The agent should pretend to be me. My name is <your_name>
- Make an outbound call to my local pizza shop at <phone_number>, using the usa number
-
Install dependencies:
npm i
-
Create a
.envfile with your RetellAI API key:RETELL_API_KEY=your_api_key_here -
Run the server:
node src/retell/index.js
list_calls: Lists all Retell callscreate_phone_call: Creates a new phone callcreate_web_call: Creates a new web callget_call: Gets details of a specific callupdate_call: Updates call metadata and variablesdelete_call: Deletes a specific callcreate_batch_call: Creates batch call campaigns
list_agents: Lists all Retell agentscreate_agent: Creates a new Retell agentget_agent: Gets a Retell agent by IDupdate_agent: Updates an existing Retell agentdelete_agent: Deletes a Retell agentget_agent_versions: Gets all versions of a Retell agentpublish_agent: Publishes agent versions
list_phone_numbers: Lists all Retell phone numberscreate_phone_number: Creates a new phone numberget_phone_number: Gets details of a specific phone numberupdate_phone_number: Updates a phone numberdelete_phone_number: Deletes a phone numberimport_phone_number: Imports external phone numbers
list_voices: Lists all available Retell voicesget_voice: Gets details of a specific voice
list_retell_llms: Lists all LLM configurationscreate_retell_llm: Creates new LLM setupsget_retell_llm: Retrieves LLM configurationupdate_retell_llm: Updates LLM settingsdelete_retell_llm: Removes LLM configurations
list_knowledge_bases: Lists all knowledge basescreate_knowledge_base: Creates new knowledge basesget_knowledge_base: Retrieves knowledge base detailsupdate_knowledge_base: Updates knowledge base propertiesdelete_knowledge_base: Removes knowledge basescreate_knowledge_base_document: Adds documents to knowledge bases
list_test_case_definitions: Lists test case definitions for a specific Retell LLMcreate_test_case_definition: Creates new test case definitions for simulation testingupdate_test_case_definition: Updates existing test case definitions (full replacement)delete_test_case_definition: Deletes test case definitions by ID
Note: These tools access undocumented RetellAI APIs using direct HTTP calls via the SDK's underlying APIClient. They enable simulation testing of voice agents with support for 9 LLM models including GPT-4o, Claude-3.5-Sonnet, and Gemini-2.0-Flash.