retell_get_llm
Retrieve a specific LLM configuration from Retell AI's voice and chat agent platform to manage conversation flows and agent settings.
Instructions
Retrieve a Retell LLM configuration.
Input Schema
TableJSON Schema
| Name | Required | Description | Default |
|---|---|---|---|
| llm_id | Yes | The LLM configuration ID |
Implementation Reference
- src/index.ts:1203-1204 (handler)The handler logic in the executeTool switch statement that performs a GET request to the Retell API for retrieving the specified LLM configuration.case "retell_get_llm": return retellRequest(`/get-retell-llm/${args.llm_id}`, "GET");
- src/index.ts:743-752 (schema)The input schema defining the required llm_id parameter for the retell_get_llm tool.inputSchema: { type: "object", properties: { llm_id: { type: "string", description: "The LLM configuration ID" } }, required: ["llm_id"] }
- src/index.ts:740-752 (registration)The tool registration entry in the tools array, including name, description, and schema, used by the MCP ListTools handler.{ name: "retell_get_llm", description: "Retrieve a Retell LLM configuration.", inputSchema: { type: "object", properties: { llm_id: { type: "string", description: "The LLM configuration ID" } }, required: ["llm_id"] }
- src/index.ts:23-57 (helper)The core helper function that makes authenticated HTTP requests to the Retell AI API, used by all Retell tools including retell_get_llm.async function retellRequest( endpoint: string, method: string = "GET", body?: Record<string, unknown> ): Promise<unknown> { const apiKey = getApiKey(); const headers: Record<string, string> = { "Authorization": `Bearer ${apiKey}`, "Content-Type": "application/json", }; const options: RequestInit = { method, headers, }; if (body && method !== "GET") { options.body = JSON.stringify(body); } const response = await fetch(`${RETELL_API_BASE}${endpoint}`, options); if (!response.ok) { const errorText = await response.text(); throw new Error(`Retell API error (${response.status}): ${errorText}`); } // Handle 204 No Content if (response.status === 204) { return { success: true }; } return response.json(); }
- src/index.ts:1283-1285 (registration)MCP server registration for listing tools, which returns the tools array containing retell_get_llm.server.setRequestHandler(ListToolsRequestSchema, async () => { return { tools }; });