hasnain0794
09/05/2025, 11:16 AMAI Evy
09/05/2025, 11:16 AMAI Evy
09/05/2025, 11:17 AMagent_name when creating an agent [(1) ]() . The create agent API accepts an agent_name parameter:
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',
}) ;
**Listing all agents**: Yes, there's a list agents API that retrieves all agents under your account [(2) ]() :
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponses = await client.agent.list() ;
However, the current API doesn't appear to support filtering agents by name directly - you would need to filter the results client-side.
**Updating agent settings**: Yes, you can update existing agents without recreating them using the update agent API [(3) ]() :
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.update('16b980523634a6dc504898cda492e939', { agent_name: 'Jarvis' }) ;
This allows updating settings like agent_name, voice_id, webhook_url, and other configuration parameters .
**Soft-delete/deactivation**: The provided documentation doesn't show a soft-delete or deactivation feature for agents.
## Analytics & Reporting
**Call data retrieval**: You can retrieve call details using the list calls API [(4) ]() :AI Evy
09/05/2025, 11:17 AMjavascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const callResponses = await client.call.list() ;
The API supports filtering by agent_id and includes comprehensive call data like duration_ms, call_status, transcript, recording_url, call_analysis, and call_cost .
**Cost breakdown**: Yes, call cost information is included in the API response with detailed breakdowns . The response includes call_cost with product_costs, total_duration_seconds, and combined_cost .
For the remaining questions about outbound calls, batch processing, real-time webhooks, and specific analytics endpoints, I don't have sufficient information in the provided sources to give you complete answers.
**AI Evy
09/05/2025, 11:17 AMAI Evy
09/05/2025, 11:17 AMhasnain0794
09/05/2025, 11:18 AMAI Evy
09/05/2025, 11:18 AMAI Evy
09/05/2025, 11:19 AMtrigger_timestamp parameter [(1) ]() . You can also pass custom dynamic variables per task using retell_llm_dynamic_variables :
json
{
"from_number": "+14157774444",
"tasks": [
{
"to_number": "+12137774445",
"retell_llm_dynamic_variables": {
"customer_name": "John Doe"
}
}
],
"name": "First batch call",
"trigger_timestamp": 1735718400000
}
**Campaign tagging**: The API includes a name parameter for batch calls , which you could use to include campaign identifiers, though there's no dedicated campaign_id field shown in the documentation.
**Batch call management and status**: The documentation shows the creation endpoint but doesn't include information about pausing, resuming, canceling batch jobs, or retrieving per-lead status within a batch.
For the remaining questions about:
- Events & Webhooks (available events, webhook scope, payload contents, retry mechanisms)
- Scaling & Limits (concurrency limits, rate limits, sandbox mode)
- Additional API code examples for single calls and analytics
- SDK architecture (REST vs client libraries)
- Real-time monitoring recommendations
I don't have sufficient information in the provided sources to give you complete answers.
I'd recommend checking out these potentially useful sources: [Create Batch Call]()
Would you like me to try to answer generally based on my knowledge instead?AI Evy
09/05/2025, 11:19 AMAI Evy
09/05/2025, 11:19 AMhasnain0794
09/05/2025, 11:32 AMAI Evy
09/05/2025, 11:32 AMAI Evy
09/05/2025, 11:33 AMagent_name [(1) ]() . The create agent API accepts an agent_name parameter:
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) ;
The documentation describes agent_name as "The name of the agent. Only used for your own reference" , but doesn't specify character limits or restrictions.
**Agent metadata**: The create agent API doesn't show support for arbitrary metadata fields . However, agents do return an agent_id which you can use to map back to your system .
**Agent updates**: The documentation shows that agents can be updated, with the response including all configurable parameters like voice_id, voice_model, webhook_url, max_call_duration_ms, etc. . This suggests full update support for agent settings.
**Soft-delete/deactivation**: The available documentation doesn't show a soft-delete or deactivation flag for agents , [(2) ]() .
## Single Outbound Calls
For web calls, you can create them using:
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const webCallResponse = await client.call.createWebCall({ agent_id: 'oBeDLoLOeuAbiuaMFXRtDOLriTJ5tSxD' }) ;
console.log(webCallResponse.agent_id) ;AI Evy
09/05/2025, 11:33 AMcall_id, agent_id, call_status, and other fields , but the documentation doesn't show estimated cost in the creation response.
## Call Data and Analytics
**Retrieving call information**: You can list calls and filter by various criteria [(4) ]() :
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const callResponses = await client.call.list() ;
console.log(callResponses) ;
The list calls API supports filtering by agent_id and includes comprehensive data like duration_ms, call_status, transcript, call_analysis, and call_cost .
**Cost information**: Call responses include detailed cost breakdowns with call_cost containing product_costs, total_duration_seconds, and combined_cost .
For the remaining questions about:
- Character limits for agent names
- Phone call creation (vs web calls)
- Batch call APIs and their specific capabilities
- Webhook configurations and metadata propagation
- Scheduling and batch management features
I don't have sufficient information in the provided sources to give you complete answers.
Check out these potentially useful sources: [Create Agent]() , [Create Web Call]() , [List Calls]()
Would you like me to try to answer generally based on my knowledge instead?AI Evy
09/05/2025, 11:33 AMAI Evy
09/05/2025, 11:33 AMhasnain0794
09/05/2025, 11:33 AMAI Evy
09/05/2025, 11:33 AMAI Evy
09/05/2025, 11:34 AMcall_started - Triggered when a new call begins
- call_ended - Triggered when a call completes, transfers, or encounters an error
- call_analyzed - Triggered when call analysis is complete
Note that if a call doesn't connect (like dial failed) , the call_started webhook event will not be triggered .
**Webhook payload contents**: The webhook payload includes the event type and call object with fields like call_id, agent_id, call_type, from_number, to_number, direction, metadata, retell_llm_dynamic_variables, and more . Here's the sample payload structure:
json
{
"event": "call_ended",
"call": {
"call_type": "phone_call",
"from_number": "+12137771234",
"to_number": "+12137771235",
"direction": "inbound",
"call_id": "Jabr9TXYYJHfvl6Syypi88rdAHYHmcq6",
"agent_id": "oBeDLoLOeuAbiuaMFXRtDOLriTJ5tSxD",
"call_status": "registered",
"metadata": {},
"retell_llm_dynamic_variables": {
"customer_name": "John Doe"
},
"start_timestamp": 1714608475945,
"end_timestamp": 1714608491736,
"disconnection_reason": "user_hangup",
"transcript": "...",
"transcript_object": [ [Object], [Object], [Object], [Object] ],
"transcript_with_tool_calls": [ [Object], [Object], [Object], [Object] ],
"opt_out_sensitive_data_storage": false
}
}AI Evy
09/05/2025, 11:34 AMcall_analyzed webhook includes the full call data with the call_analysis object [(1) ]() . The webhook payload structure is:
json
{
"event_type": "call_analysis",
"call_analysis": {
// Analysis results object
}
}
[(3) ]()
For the remaining questions about:
- Batch-level throttling/concurrency settings
- HMAC webhook signing
- Detailed API filtering examples
- Aggregated metrics APIs
- Billing cost estimates
- Phone number management APIs
I don't have sufficient information in the provided sources to give you complete answers.
Check out these potentially useful sources: [Webhook Overview]() , [Consume the analysis data]()
Would you like me to try to answer generally based on my knowledge instead?AI Evy
09/05/2025, 11:34 AMAI Evy
09/05/2025, 11:34 AMhasnain0794
09/05/2025, 11:35 AMAI Evy
09/05/2025, 11:35 AMAI Evy
09/05/2025, 11:36 AMjavascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const concurrency = await client.concurrency.retrieve() ;
console.log(concurrency.base_concurrency) ;
The response includes current_concurrency, concurrency_limit, base_concurrency, purchased_concurrency, and other concurrency-related fields .
**Per-tenant concurrency controls**: Based on Discord discussions, you need to implement concurrency checks on your side [(2) ]() . The default concurrency limitation is 20 concurrent calls (both inbound and outbound) .
## Code Examples & SDK
**Node.js SDK setup**: The Node.js SDK requires Node.js version 18.10.0 or higher [(3) ]() :
npm i retell-sdk
**Python SDK setup**: The Python SDK requires Python 3.7 or higher :
pip install retell-sdk
**Creating an agent (Node.js) **:
javascript
import Retell from 'retell-sdk';
const client = new Retell({
apiKey: 'YOUR_RETELL_API_KEY',
}) ;
async function main() {
const params: Retell.AgentCreateParams = {
response_engine: {
llm_id: 'llm_234sdertfsdsfsdf',
type: 'retell-llm'
},
voice_id: '11labs-Adrian',
};
const agentResponse = await client.agent.create(params) ;
}
**Creating a web call**:AI Evy
09/05/2025, 11:36 AMjavascript
try {
const response = await retellClient.call.createPhoneCall({
from_number: '+14157774444',
to_number: '+12137774445',
}) ;
console.log('Call initiated:', response) ;
} catch (error) {
console.error('Error making call:', error) ;
}
**Python SDK configuration options**:
python
from retell import Retell
# Configure the default for all requests:
client = Retell(
# default is 2
max_retries=0,
)
# Or, configure per-request:
client.with_options(max_retries=5) .agent.create(
response_engine={
"llm_id": "llm_234sdertfsdsfsdf",
"type": "retell-llm",
},
voice_id="11labs-Adrian",
)
[(4) ]()
**SDK vs REST API**: The SDK offers several advantages over direct REST API usage [(3) ]() :
- Type safety with full TypeScript support
- Simplified authentication with built-in API key handling
- Error handling with structured error responses
- Reduced boilerplate for cleaner, more maintainable code
Both Node.js and Python SDKs support comprehensive error handling with specific error codes like BadRequestError, AuthenticationError, PermissionDeniedError, etc. [(4) ]()
For the remaining questions about:
- Specific API rate limits (requests/sec)
- Sandbox/test mode availability
- Phone number purchase APIs
- Batch call examples and status fetching
I don't have sufficient information in the provided sources to give you complete answers.
Check out these potentially useful sources: [SDKs]() , [Get Concurrency]()
Would you like me to try to answer generally based on my knowledge instead?AI Evy
09/05/2025, 11:36 AMAI Evy
09/05/2025, 11:36 AM