Mrplutus007
12/15/2025, 12:13 PMAI Evy
12/15/2025, 12:13 PMAI Evy
12/15/2025, 12:13 PMjavascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const llmResponse = await client.llm.create() ;
console.log(llmResponse.llm_id) ;
Option 2: Retrieve existing LLM IDs
If you already have Retell LLMs created, you can list them to get the `llm_id`: [(2) ]()
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const llmResponses = await client.llm.list() ;
console.log(llmResponses) ;
Or retrieve a specific one if you know the ID: [(3) ]()
javascript
const llmResponse = await client.llm.retrieve('16b980523634a6dc504898cda492e939') ;
console.log(llmResponse.llm_id) ;
Connecting to an Agent
When creating a Voice Agent, you attach the llm_id via the response_engine field with type: "retell-llm" and the corresponding llm_id. [(4) ]()
If the ID suddenly stopped working without changes on your end, double-check that the LLM wasn't deleted or that you're using the correct workspace/API key.AI Evy
12/15/2025, 12:13 PMAI Evy
12/15/2025, 12:13 PMMrplutus007
12/15/2025, 12:14 PMMrplutus007
12/15/2025, 12:15 PMAI Evy
12/15/2025, 12:15 PMAI Evy
12/15/2025, 12:15 PMllm_id across multiple agents is supported. When you create a Voice Agent, you reference the LLM via the response_engine field: [(1) ]()
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.create({
response_engine: { llm_id: 'llm_234sdertfsdsfsdf', type: 'retell-llm' },
voice_id: '11labs-Adrian',
}) ;
console.log(agentResponse.agent_id) ;
If the llm_id suddenly can't be found:
1. Verify the LLM still exists — If deleted (via client.llm.delete()) , all agents referencing it would fail to find it. [(2) ]()
2. Check you're using the correct API key — Different API keys may belong to different workspaces, each with their own LLMs.
3. Confirm the llm_id string is correct — Copy it directly from the dashboard or API response to avoid typos.
I don't have additional documentation on specific error messages for missing llm_id references. If the LLM exists and the API key is correct, consider reaching out via [Contact Sales]() or checking the [Retell GitHub]() for further troubleshooting.
Would you like me to provide a general answer on debugging API key or workspace mismatches?AI Evy
12/15/2025, 12:15 PMAI Evy
12/15/2025, 12:15 PMMrplutus007
12/15/2025, 12:16 PMAI Evy
12/15/2025, 12:16 PMAI Evy
12/15/2025, 12:16 PMllm_id and agent_id are separate identifiers for different resources. [(1) ]()
- **`agent_id`**: Identifies the Voice Agent itself (e.g., "oBeDLoLOeuAbiuaMFXRtDOLriTJ5tSxD")
- **`llm_id`**: Identifies the Retell LLM Response Engine attached to that agent (e.g., "llm_234sdertfsdsfsdf")
When you create or view an agent, the llm_id is found inside the response_engine object:
json
"response_engine": {
"type": "retell-llm",
"llm_id": "llm_234sdertfsdsfsdf",
"version": 0
}
You can also retrieve all your Retell LLMs directly using: [(2) ]()
javascript
const llmResponses = await client.llm.list() ;
console.log(llmResponses) ;
So you need the llm_id from within the agent's response_engine field (or from the LLM list endpoint) , not the agent_id shown next to the agent.AI Evy
12/15/2025, 12:16 PMAI Evy
12/15/2025, 12:16 PM