@retell-ai/mcp-server 5.21.0 → 5.23.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -133,31 +133,32 @@ const EMBEDDED_METHODS = [
133
133
  },
134
134
  {
135
135
  name: 'list',
136
- endpoint: '/v2/list-calls',
136
+ endpoint: '/v3/list-calls',
137
137
  httpMethod: 'post',
138
138
  summary: '',
139
- description: 'Retrieve call details',
139
+ description: 'List calls with unified cursor pagination response.',
140
140
  stainlessPath: '(resource) call > (method) list',
141
141
  qualified: 'client.call.list',
142
142
  params: [
143
- "filter_criteria?: { agent_id?: string[]; batch_call_id?: string[]; call_id?: string[]; call_status?: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; call_successful?: boolean[]; call_type?: 'web_call' | 'phone_call'[]; direction?: 'inbound' | 'outbound'[]; disconnection_reason?: string[]; duration_ms?: { lower_threshold?: number; upper_threshold?: number; }; dynamic_variables?: object; e2e_latency_p50?: { lower_threshold?: number; upper_threshold?: number; }; end_timestamp?: { lower_threshold?: number; upper_threshold?: number; }; from_number?: string[]; in_voicemail?: boolean[]; metadata?: object; start_timestamp?: { lower_threshold?: number; upper_threshold?: number; }; to_number?: string[]; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; version?: number[]; };",
143
+ "filter_criteria?: { agent?: { agent_id: string; version?: number[]; }[]; batch_call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; call_status?: { op: 'in'; type: 'enum'; value: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; }; call_successful?: { op: 'eq'; type: 'boolean'; value: boolean; }; call_type?: { op: 'in'; type: 'enum'; value: 'web_call' | 'phone_call'[]; }; combined_cost?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; custom_analysis_data?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; custom_attributes?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; data_storage_setting?: { op: 'in'; type: 'enum'; value: 'everything' | 'everything_except_pii' | 'basic_attributes_only'[]; }; direction?: { op: 'in'; type: 'enum'; value: 'inbound' | 'outbound'[]; }; disconnection_reason?: { op: 'in'; type: 'enum'; value: string[]; }; duration_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; dynamic_variables?: { key: string; op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }[]; e2e_latency_p50?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; end_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; from_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; in_voicemail?: { op: 'eq'; type: 'boolean'; value: boolean; }; metadata?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; start_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; to_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; tool_calls?: { name: string; latency_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; success?: { op: 'eq'; type: 'boolean'; value: boolean; }; }[]; user_sentiment?: { op: 'in'; type: 'enum'; value: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; }; };",
144
144
  'limit?: number;',
145
145
  'pagination_key?: string;',
146
+ 'skip?: number;',
146
147
  "sort_order?: 'ascending' | 'descending';",
147
148
  ],
148
- response: 'object | object[]',
149
- markdown: "## list\n\n`client.call.list(filter_criteria?: { agent_id?: string[]; batch_call_id?: string[]; call_id?: string[]; call_status?: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; call_successful?: boolean[]; call_type?: 'web_call' | 'phone_call'[]; direction?: 'inbound' | 'outbound'[]; disconnection_reason?: string[]; duration_ms?: { lower_threshold?: number; upper_threshold?: number; }; dynamic_variables?: object; e2e_latency_p50?: { lower_threshold?: number; upper_threshold?: number; }; end_timestamp?: { lower_threshold?: number; upper_threshold?: number; }; from_number?: string[]; in_voicemail?: boolean[]; metadata?: object; start_timestamp?: { lower_threshold?: number; upper_threshold?: number; }; to_number?: string[]; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; version?: number[]; }, limit?: number, pagination_key?: string, sort_order?: 'ascending' | 'descending'): web_call_response | phone_call_response[]`\n\n**post** `/v2/list-calls`\n\nRetrieve call details\n\n### Parameters\n\n- `filter_criteria?: { agent_id?: string[]; batch_call_id?: string[]; call_id?: string[]; call_status?: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; call_successful?: boolean[]; call_type?: 'web_call' | 'phone_call'[]; direction?: 'inbound' | 'outbound'[]; disconnection_reason?: string[]; duration_ms?: { lower_threshold?: number; upper_threshold?: number; }; dynamic_variables?: object; e2e_latency_p50?: { lower_threshold?: number; upper_threshold?: number; }; end_timestamp?: { lower_threshold?: number; upper_threshold?: number; }; from_number?: string[]; in_voicemail?: boolean[]; metadata?: object; start_timestamp?: { lower_threshold?: number; upper_threshold?: number; }; to_number?: string[]; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; version?: number[]; }`\n Filter criteria for the calls to retrieve.\n - `agent_id?: string[]`\n Only retrieve calls that are made with specific agent(s).\n - `batch_call_id?: string[]`\n Only retrieve calls with specific batch call id(s).\n - `call_id?: string[]`\n Only retrieve calls with specific call id(s).\n - `call_status?: 'not_connected' | 'ongoing' | 'ended' | 'error'[]`\n Only retrieve calls with specific call status(es).\n - `call_successful?: boolean[]`\n Only retrieve calls with specific call successful(s).\n - `call_type?: 'web_call' | 'phone_call'[]`\n Only retrieve calls with specific call type(s).\n - `direction?: 'inbound' | 'outbound'[]`\n Only retrieve calls with specific direction(s).\n - `disconnection_reason?: string[]`\n Only retrieve calls with specific disconnection reason(s).\n - `duration_ms?: { lower_threshold?: number; upper_threshold?: number; }`\n Only retrieve calls with specific range of duration(s).\n - `dynamic_variables?: object`\n Filter by dynamic variables using dot notation (e.g., `dynamic_variables.name`).\nValues are matched exactly as strings.\n\n - `e2e_latency_p50?: { lower_threshold?: number; upper_threshold?: number; }`\n - `end_timestamp?: { lower_threshold?: number; upper_threshold?: number; }`\n Only retrieve calls with specific range of end timestamp(s).\n - `from_number?: string[]`\n Only retrieve calls with specific from number(s).\n - `in_voicemail?: boolean[]`\n Only retrieve calls that are in voicemail or not in voicemail.\n - `metadata?: object`\n Filter by metadata fields using dot notation (e.g., `metadata.customer_id`).\nValues are matched exactly as strings.\n\n - `start_timestamp?: { lower_threshold?: number; upper_threshold?: number; }`\n Only retrieve calls with specific range of start timestamp(s).\n - `to_number?: string[]`\n Only retrieve calls with specific to number(s).\n - `user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]`\n Only retrieve calls with specific user sentiment(s).\n - `version?: number[]`\n The version of the agent to use for the call.\n\n- `limit?: number`\n Limit the number of calls returned. Default 50, Max 1000. To retrieve more than 1000, use pagination_key to continue fetching the next page.\n\n- `pagination_key?: string`\n The pagination key to continue fetching the next page of calls. Pagination key is represented by a call id here, and it's exclusive (not included in the fetched calls). The last call id from the list calls is usually used as pagination key here. If not set, will start from the beginning.\n\n- `sort_order?: 'ascending' | 'descending'`\n The calls will be sorted by `start_timestamp`, whether to return the calls in ascending or descending order.\n\n### Returns\n\n- `{ access_token: string; agent_id: string; agent_version: number; call_id: string; call_status: 'registered' | 'not_connected' | 'ongoing' | 'ended' | 'error'; call_type: 'web_call'; agent_name?: string; call_analysis?: object; call_cost?: object; collected_dynamic_variables?: object; custom_sip_headers?: object; data_storage_setting?: 'everything' | 'everything_except_pii' | 'basic_attributes_only'; disconnection_reason?: string; duration_ms?: number; end_timestamp?: number; knowledge_base_retrieved_contents_url?: string; latency?: object; llm_token_usage?: object; metadata?: object; opt_in_signed_url?: boolean; public_log_url?: string; recording_multi_channel_url?: string; recording_url?: string; retell_llm_dynamic_variables?: object; scrubbed_recording_multi_channel_url?: string; scrubbed_recording_url?: string; scrubbed_transcript_with_tool_calls?: object | object | object | object | object[]; start_timestamp?: number; transcript?: string; transcript_object?: object[]; transcript_with_tool_calls?: object | object | object | object | object[]; transfer_destination?: string; transfer_end_timestamp?: number; } | { agent_id: string; agent_version: number; call_id: string; call_status: 'registered' | 'not_connected' | 'ongoing' | 'ended' | 'error'; call_type: 'phone_call'; direction: 'inbound' | 'outbound'; from_number: string; to_number: string; agent_name?: string; call_analysis?: object; call_cost?: object; collected_dynamic_variables?: object; custom_sip_headers?: object; data_storage_setting?: 'everything' | 'everything_except_pii' | 'basic_attributes_only'; disconnection_reason?: string; duration_ms?: number; end_timestamp?: number; knowledge_base_retrieved_contents_url?: string; latency?: object; llm_token_usage?: object; metadata?: object; opt_in_signed_url?: boolean; public_log_url?: string; recording_multi_channel_url?: string; recording_url?: string; retell_llm_dynamic_variables?: object; scrubbed_recording_multi_channel_url?: string; scrubbed_recording_url?: string; scrubbed_transcript_with_tool_calls?: object | object | object | object | object[]; start_timestamp?: number; telephony_identifier?: object; transcript?: string; transcript_object?: object[]; transcript_with_tool_calls?: object | object | object | object | object[]; transfer_destination?: string; transfer_end_timestamp?: number; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst callResponses = await client.call.list();\n\nconsole.log(callResponses);\n```",
149
+ response: '{ has_more?: boolean; items?: object | object[]; pagination_key?: string; }',
150
+ markdown: "## list\n\n`client.call.list(filter_criteria?: { agent?: { agent_id: string; version?: number[]; }[]; batch_call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; call_status?: { op: 'in'; type: 'enum'; value: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; }; call_successful?: { op: 'eq'; type: 'boolean'; value: boolean; }; call_type?: { op: 'in'; type: 'enum'; value: 'web_call' | 'phone_call'[]; }; combined_cost?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; custom_analysis_data?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; custom_attributes?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; data_storage_setting?: { op: 'in'; type: 'enum'; value: 'everything' | 'everything_except_pii' | 'basic_attributes_only'[]; }; direction?: { op: 'in'; type: 'enum'; value: 'inbound' | 'outbound'[]; }; disconnection_reason?: { op: 'in'; type: 'enum'; value: string[]; }; duration_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; dynamic_variables?: { key: string; op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }[]; e2e_latency_p50?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; end_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; from_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; in_voicemail?: { op: 'eq'; type: 'boolean'; value: boolean; }; metadata?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; start_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; to_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; tool_calls?: { name: string; latency_ms?: object | object; success?: object; }[]; user_sentiment?: { op: 'in'; type: 'enum'; value: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; }; }, limit?: number, pagination_key?: string, skip?: number, sort_order?: 'ascending' | 'descending'): { has_more?: boolean; items?: web_call_response | phone_call_response[]; pagination_key?: string; }`\n\n**post** `/v3/list-calls`\n\nList calls with unified cursor pagination response.\n\n### Parameters\n\n- `filter_criteria?: { agent?: { agent_id: string; version?: number[]; }[]; batch_call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; call_status?: { op: 'in'; type: 'enum'; value: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; }; call_successful?: { op: 'eq'; type: 'boolean'; value: boolean; }; call_type?: { op: 'in'; type: 'enum'; value: 'web_call' | 'phone_call'[]; }; combined_cost?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; custom_analysis_data?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; custom_attributes?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; data_storage_setting?: { op: 'in'; type: 'enum'; value: 'everything' | 'everything_except_pii' | 'basic_attributes_only'[]; }; direction?: { op: 'in'; type: 'enum'; value: 'inbound' | 'outbound'[]; }; disconnection_reason?: { op: 'in'; type: 'enum'; value: string[]; }; duration_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; dynamic_variables?: { key: string; op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }[]; e2e_latency_p50?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; end_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; from_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; in_voicemail?: { op: 'eq'; type: 'boolean'; value: boolean; }; metadata?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]; start_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; to_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }; tool_calls?: { name: string; latency_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; success?: { op: 'eq'; type: 'boolean'; value: boolean; }; }[]; user_sentiment?: { op: 'in'; type: 'enum'; value: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; }; }`\n Filter criteria for calls. All conditions are implicitly connected with AND.\n - `agent?: { agent_id: string; version?: number[]; }[]`\n Filter by agent(s). Agent filters are connected by OR.\n - `batch_call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }`\n Filter by batch call ID.\n - `call_id?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }`\n Filter by call ID.\n - `call_status?: { op: 'in'; type: 'enum'; value: 'not_connected' | 'ongoing' | 'ended' | 'error'[]; }`\n - `call_successful?: { op: 'eq'; type: 'boolean'; value: boolean; }`\n Filter by whether the call was successful.\n - `call_type?: { op: 'in'; type: 'enum'; value: 'web_call' | 'phone_call'[]; }`\n - `combined_cost?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }`\n Filter by combined cost of the call.\n - `custom_analysis_data?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]`\n Filter by custom analysis data fields.\n - `custom_attributes?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]`\n Filter by custom attributes fields.\n - `data_storage_setting?: { op: 'in'; type: 'enum'; value: 'everything' | 'everything_except_pii' | 'basic_attributes_only'[]; }`\n - `direction?: { op: 'in'; type: 'enum'; value: 'inbound' | 'outbound'[]; }`\n - `disconnection_reason?: { op: 'in'; type: 'enum'; value: string[]; }`\n - `duration_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }`\n Filter by call duration in milliseconds.\n - `dynamic_variables?: { key: string; op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }[]`\n Filter by dynamic variables.\n - `e2e_latency_p50?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }`\n Filter by end-to-end latency p50.\n - `end_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }`\n Filter by call end timestamp (epoch ms).\n - `from_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }`\n Filter by from number.\n - `in_voicemail?: { op: 'eq'; type: 'boolean'; value: boolean; }`\n Filter by whether the call is in voicemail.\n - `metadata?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; key?: string; } | { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; key?: string; } | { op: 'eq'; type: 'boolean'; value: boolean; key?: string; } | { op: 'bt'; type: 'range'; value: number[]; key?: string; } | { op: 'in'; type: 'enum'; value: string[]; key?: string; } | { op: 'pr' | 'np'; type: 'present'; key?: string; }[]`\n Filter by metadata fields.\n - `start_timestamp?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }`\n Filter by call start timestamp (epoch ms).\n - `to_number?: { op: 'eq' | 'ne' | 'sw' | 'ew' | 'co'; type: 'string'; value: string; }`\n Filter by to number.\n - `tool_calls?: { name: string; latency_ms?: { op: 'eq' | 'ne' | 'gt' | 'ge' | 'lt' | 'le'; type: 'number'; value: number; } | { op: 'bt'; type: 'range'; value: number[]; }; success?: { op: 'eq'; type: 'boolean'; value: boolean; }; }[]`\n Filter by tool call criteria. Tool call filters are connected by AND.\n - `user_sentiment?: { op: 'in'; type: 'enum'; value: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'[]; }`\n\n- `limit?: number`\n Maximum number of calls to return.\n\n- `pagination_key?: string`\n Opaque pagination cursor from a previous response.\n\n- `skip?: number`\n Number of records to skip for pagination.\n\n- `sort_order?: 'ascending' | 'descending'`\n Sort calls by `start_timestamp` in ascending or descending order.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { access_token: string; agent_id: string; agent_version: number; call_id: string; call_status: 'registered' | 'not_connected' | 'ongoing' | 'ended' | 'error'; call_type: 'web_call'; agent_name?: string; call_analysis?: object; call_cost?: object; collected_dynamic_variables?: object; custom_sip_headers?: object; data_storage_setting?: 'everything' | 'everything_except_pii' | 'basic_attributes_only'; disconnection_reason?: string; duration_ms?: number; end_timestamp?: number; knowledge_base_retrieved_contents_url?: string; latency?: object; llm_token_usage?: object; metadata?: object; opt_in_signed_url?: boolean; public_log_url?: string; recording_multi_channel_url?: string; recording_url?: string; retell_llm_dynamic_variables?: object; scrubbed_recording_multi_channel_url?: string; scrubbed_recording_url?: string; scrubbed_transcript_with_tool_calls?: object | object | object | object | object[]; start_timestamp?: number; transcript?: string; transcript_object?: object[]; transcript_with_tool_calls?: object | object | object | object | object[]; transfer_destination?: string; transfer_end_timestamp?: number; } | { agent_id: string; agent_version: number; call_id: string; call_status: 'registered' | 'not_connected' | 'ongoing' | 'ended' | 'error'; call_type: 'phone_call'; direction: 'inbound' | 'outbound'; from_number: string; to_number: string; agent_name?: string; call_analysis?: object; call_cost?: object; collected_dynamic_variables?: object; custom_sip_headers?: object; data_storage_setting?: 'everything' | 'everything_except_pii' | 'basic_attributes_only'; disconnection_reason?: string; duration_ms?: number; end_timestamp?: number; knowledge_base_retrieved_contents_url?: string; latency?: object; llm_token_usage?: object; metadata?: object; opt_in_signed_url?: boolean; public_log_url?: string; recording_multi_channel_url?: string; recording_url?: string; retell_llm_dynamic_variables?: object; scrubbed_recording_multi_channel_url?: string; scrubbed_recording_url?: string; scrubbed_transcript_with_tool_calls?: object | object | object | object | object[]; start_timestamp?: number; telephony_identifier?: object; transcript?: string; transcript_object?: object[]; transcript_with_tool_calls?: object | object | object | object | object[]; transfer_destination?: string; transfer_end_timestamp?: number; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { access_token: string; agent_id: string; agent_version: number; call_id: string; call_status: 'registered' | 'not_connected' | 'ongoing' | 'ended' | 'error'; call_type: 'web_call'; agent_name?: string; call_analysis?: { call_successful?: boolean; call_summary?: string; custom_analysis_data?: object; in_voicemail?: boolean; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'; }; call_cost?: { combined_cost: number; product_costs: { cost: number; product: string; is_transfer_leg_cost?: boolean; unit_price?: number; }[]; total_duration_seconds: number; total_duration_unit_price: number; }; collected_dynamic_variables?: object; custom_sip_headers?: object; data_storage_setting?: 'everything' | 'everything_except_pii' | 'basic_attributes_only'; disconnection_reason?: string; duration_ms?: number; end_timestamp?: number; knowledge_base_retrieved_contents_url?: string; latency?: { asr?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; e2e?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; knowledge_base?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; llm?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; llm_websocket_network_rtt?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; s2s?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; tts?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; }; llm_token_usage?: { average: number; num_requests: number; values: number[]; }; metadata?: object; opt_in_signed_url?: boolean; public_log_url?: string; recording_multi_channel_url?: string; recording_url?: string; retell_llm_dynamic_variables?: object; scrubbed_recording_multi_channel_url?: string; scrubbed_recording_url?: string; scrubbed_transcript_with_tool_calls?: { content: string; role: 'agent' | 'user' | 'transfer_target'; words: { end?: number; start?: number; word?: string; }[]; } | { arguments: string; name: string; role: 'tool_call_invocation'; tool_call_id: string; thought_signature?: string; } | { content: string; role: 'tool_call_result'; tool_call_id: string; successful?: boolean; } | { former_node_id: string; former_node_name: string; new_node_id: string; new_node_name: string; role: 'node_transition'; transition_type?: 'global' | 'global_go_back' | 'interrupt_go_back' | 'normal'; } | { digit: string; role: 'dtmf'; }[]; start_timestamp?: number; transcript?: string; transcript_object?: { content: string; role: 'agent' | 'user' | 'transfer_target'; words: { end?: number; start?: number; word?: string; }[]; }[]; transcript_with_tool_calls?: { content: string; role: 'agent' | 'user' | 'transfer_target'; words: { end?: number; start?: number; word?: string; }[]; } | { arguments: string; name: string; role: 'tool_call_invocation'; tool_call_id: string; thought_signature?: string; } | { content: string; role: 'tool_call_result'; tool_call_id: string; successful?: boolean; } | { former_node_id: string; former_node_name: string; new_node_id: string; new_node_name: string; role: 'node_transition'; transition_type?: 'global' | 'global_go_back' | 'interrupt_go_back' | 'normal'; } | { digit: string; role: 'dtmf'; }[]; transfer_destination?: string; transfer_end_timestamp?: number; } | { agent_id: string; agent_version: number; call_id: string; call_status: 'registered' | 'not_connected' | 'ongoing' | 'ended' | 'error'; call_type: 'phone_call'; direction: 'inbound' | 'outbound'; from_number: string; to_number: string; agent_name?: string; call_analysis?: { call_successful?: boolean; call_summary?: string; custom_analysis_data?: object; in_voicemail?: boolean; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'; }; call_cost?: { combined_cost: number; product_costs: { cost: number; product: string; is_transfer_leg_cost?: boolean; unit_price?: number; }[]; total_duration_seconds: number; total_duration_unit_price: number; }; collected_dynamic_variables?: object; custom_sip_headers?: object; data_storage_setting?: 'everything' | 'everything_except_pii' | 'basic_attributes_only'; disconnection_reason?: string; duration_ms?: number; end_timestamp?: number; knowledge_base_retrieved_contents_url?: string; latency?: { asr?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; e2e?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; knowledge_base?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; llm?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; llm_websocket_network_rtt?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; s2s?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; tts?: { max?: number; min?: number; num?: number; p50?: number; p90?: number; p95?: number; p99?: number; values?: number[]; }; }; llm_token_usage?: { average: number; num_requests: number; values: number[]; }; metadata?: object; opt_in_signed_url?: boolean; public_log_url?: string; recording_multi_channel_url?: string; recording_url?: string; retell_llm_dynamic_variables?: object; scrubbed_recording_multi_channel_url?: string; scrubbed_recording_url?: string; scrubbed_transcript_with_tool_calls?: { content: string; role: 'agent' | 'user' | 'transfer_target'; words: { end?: number; start?: number; word?: string; }[]; } | { arguments: string; name: string; role: 'tool_call_invocation'; tool_call_id: string; thought_signature?: string; } | { content: string; role: 'tool_call_result'; tool_call_id: string; successful?: boolean; } | { former_node_id: string; former_node_name: string; new_node_id: string; new_node_name: string; role: 'node_transition'; transition_type?: 'global' | 'global_go_back' | 'interrupt_go_back' | 'normal'; } | { digit: string; role: 'dtmf'; }[]; start_timestamp?: number; telephony_identifier?: { twilio_call_sid?: string; }; transcript?: string; transcript_object?: { content: string; role: 'agent' | 'user' | 'transfer_target'; words: { end?: number; start?: number; word?: string; }[]; }[]; transcript_with_tool_calls?: { content: string; role: 'agent' | 'user' | 'transfer_target'; words: { end?: number; start?: number; word?: string; }[]; } | { arguments: string; name: string; role: 'tool_call_invocation'; tool_call_id: string; thought_signature?: string; } | { content: string; role: 'tool_call_result'; tool_call_id: string; successful?: boolean; } | { former_node_id: string; former_node_name: string; new_node_id: string; new_node_name: string; role: 'node_transition'; transition_type?: 'global' | 'global_go_back' | 'interrupt_go_back' | 'normal'; } | { digit: string; role: 'dtmf'; }[]; transfer_destination?: string; transfer_end_timestamp?: number; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst calls = await client.call.list();\n\nconsole.log(calls);\n```",
150
151
  perLanguage: {
151
152
  typescript: {
152
153
  method: 'client.call.list',
153
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst callResponses = await client.call.list();\n\nconsole.log(callResponses);",
154
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst calls = await client.call.list();\n\nconsole.log(calls.has_more);",
154
155
  },
155
156
  python: {
156
157
  method: 'call.list',
157
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\ncall_responses = client.call.list()\nprint(call_responses)',
158
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\ncalls = client.call.list()\nprint(calls.has_more)',
158
159
  },
159
160
  http: {
160
- example: 'curl https://api.retellai.com/v2/list-calls \\\n -H \'Content-Type: application/json\' \\\n -H "Authorization: Bearer $RETELL_API_KEY" \\\n --max-time 300 \\\n -d \'{\n "filter_criteria": {\n "agent_id": [\n "agent_oBeDLoLOeuAbiuaMFXRtDOLriT12345"\n ],\n "call_id": [\n "call_5a82f0a43ea0977566b1104fcfc"\n ],\n "call_status": [\n "ended"\n ],\n "call_successful": [\n true\n ],\n "call_type": [\n "phone_call"\n ],\n "direction": [\n "inbound"\n ],\n "start_timestamp": {\n "lower_threshold": 1738475411000,\n "upper_threshold": 1738475421000\n },\n "user_sentiment": [\n "Positive"\n ]\n }\n }\'',
161
+ example: 'curl https://api.retellai.com/v3/list-calls \\\n -X POST \\\n -H "Authorization: Bearer $RETELL_API_KEY" \\\n --max-time 300',
161
162
  },
162
163
  },
163
164
  },
@@ -378,26 +379,32 @@ const EMBEDDED_METHODS = [
378
379
  },
379
380
  {
380
381
  name: 'list',
381
- endpoint: '/list-chat',
382
- httpMethod: 'get',
382
+ endpoint: '/v3/list-chats',
383
+ httpMethod: 'post',
383
384
  summary: '',
384
- description: 'List all chats',
385
+ description: 'List chats with unified cursor pagination response.',
385
386
  stainlessPath: '(resource) chat > (method) list',
386
387
  qualified: 'client.chat.list',
387
- params: ['limit?: number;', 'pagination_key?: string;', "sort_order?: 'ascending' | 'descending';"],
388
- response: "{ agent_id: string; chat_id: string; chat_status: 'ongoing' | 'ended' | 'error'; chat_analysis?: object; chat_cost?: object; chat_type?: 'api_chat' | 'sms_chat'; collected_dynamic_variables?: object; custom_attributes?: object; end_timestamp?: number; message_with_tool_calls?: object | object | object | object | object[]; metadata?: object; retell_llm_dynamic_variables?: object; start_timestamp?: number; transcript?: string; version?: number; }[]",
389
- markdown: "## list\n\n`client.chat.list(limit?: number, pagination_key?: string, sort_order?: 'ascending' | 'descending'): object[]`\n\n**get** `/list-chat`\n\nList all chats\n\n### Parameters\n\n- `limit?: number`\n Limit the number of chats returned. Default 50, Max 1000. To retrieve more than 1000, use pagination_key to continue fetching the next page.\n\n- `pagination_key?: string`\n The pagination key to continue fetching the next page of chats. Pagination key is represented by a chat id here, and it's exclusive (not included in the fetched chats). The last chat id from the list chats is usually used as pagination key here. If not set, will start from the beginning.\n\n- `sort_order?: 'ascending' | 'descending'`\n The chats will be sorted by `start_timestamp`, whether to return the chats in ascending or descending order.\n\n### Returns\n\n- `{ agent_id: string; chat_id: string; chat_status: 'ongoing' | 'ended' | 'error'; chat_analysis?: { chat_successful?: boolean; chat_summary?: string; custom_analysis_data?: object; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'; }; chat_cost?: { combined_cost?: number; product_costs?: object[]; }; chat_type?: 'api_chat' | 'sms_chat'; collected_dynamic_variables?: object; custom_attributes?: object; end_timestamp?: number; message_with_tool_calls?: { content: string; role: 'agent' | 'user'; created_timestamp?: number; message_id?: string; } | { arguments: string; name: string; role: 'tool_call_invocation'; tool_call_id: string; created_timestamp?: number; message_id?: string; thought_signature?: string; } | { content: string; role: 'tool_call_result'; tool_call_id: string; created_timestamp?: number; message_id?: string; successful?: boolean; } | { role: 'node_transition'; created_timestamp?: number; former_node_id?: string; former_node_name?: string; message_id?: string; new_node_id?: string; new_node_name?: string; transition_type?: 'global' | 'global_go_back' | 'interrupt_go_back' | 'normal'; } | { role: 'state_transition'; created_timestamp?: number; former_state_name?: string; message_id?: string; new_state_name?: string; }[]; metadata?: object; retell_llm_dynamic_variables?: object; start_timestamp?: number; transcript?: string; version?: number; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst chatResponses = await client.chat.list();\n\nconsole.log(chatResponses);\n```",
388
+ params: [
389
+ 'filter_criteria?: object;',
390
+ 'limit?: number;',
391
+ 'pagination_key?: string;',
392
+ 'skip?: number;',
393
+ "sort_order?: 'ascending' | 'descending';",
394
+ ],
395
+ response: "{ has_more?: boolean; items?: { agent_id: string; chat_id: string; chat_status: 'ongoing' | 'ended' | 'error'; chat_analysis?: object; chat_cost?: object; chat_type?: 'api_chat' | 'sms_chat'; collected_dynamic_variables?: object; custom_attributes?: object; end_timestamp?: number; message_with_tool_calls?: object | object | object | object | object[]; metadata?: object; retell_llm_dynamic_variables?: object; start_timestamp?: number; transcript?: string; version?: number; }[]; pagination_key?: string; }",
396
+ markdown: "## list\n\n`client.chat.list(filter_criteria?: object, limit?: number, pagination_key?: string, skip?: number, sort_order?: 'ascending' | 'descending'): { has_more?: boolean; items?: chat_response[]; pagination_key?: string; }`\n\n**post** `/v3/list-chats`\n\nList chats with unified cursor pagination response.\n\n### Parameters\n\n- `filter_criteria?: object`\n Filter criteria for chats to retrieve.\n\n- `limit?: number`\n Maximum number of chats to return.\n\n- `pagination_key?: string`\n Opaque pagination cursor from a previous response.\n\n- `skip?: number`\n Number of records to skip for pagination.\n\n- `sort_order?: 'ascending' | 'descending'`\n Sort chats by `start_timestamp` in ascending or descending order.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { agent_id: string; chat_id: string; chat_status: 'ongoing' | 'ended' | 'error'; chat_analysis?: object; chat_cost?: object; chat_type?: 'api_chat' | 'sms_chat'; collected_dynamic_variables?: object; custom_attributes?: object; end_timestamp?: number; message_with_tool_calls?: object | object | object | object | object[]; metadata?: object; retell_llm_dynamic_variables?: object; start_timestamp?: number; transcript?: string; version?: number; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { agent_id: string; chat_id: string; chat_status: 'ongoing' | 'ended' | 'error'; chat_analysis?: { chat_successful?: boolean; chat_summary?: string; custom_analysis_data?: object; user_sentiment?: 'Negative' | 'Positive' | 'Neutral' | 'Unknown'; }; chat_cost?: { combined_cost?: number; product_costs?: { cost: number; product: string; is_transfer_leg_cost?: boolean; unit_price?: number; }[]; }; chat_type?: 'api_chat' | 'sms_chat'; collected_dynamic_variables?: object; custom_attributes?: object; end_timestamp?: number; message_with_tool_calls?: { content: string; role: 'agent' | 'user'; created_timestamp?: number; message_id?: string; } | { arguments: string; name: string; role: 'tool_call_invocation'; tool_call_id: string; created_timestamp?: number; message_id?: string; thought_signature?: string; } | { content: string; role: 'tool_call_result'; tool_call_id: string; created_timestamp?: number; message_id?: string; successful?: boolean; } | { role: 'node_transition'; created_timestamp?: number; former_node_id?: string; former_node_name?: string; message_id?: string; new_node_id?: string; new_node_name?: string; transition_type?: 'global' | 'global_go_back' | 'interrupt_go_back' | 'normal'; } | { role: 'state_transition'; created_timestamp?: number; former_state_name?: string; message_id?: string; new_state_name?: string; }[]; metadata?: object; retell_llm_dynamic_variables?: object; start_timestamp?: number; transcript?: string; version?: number; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst chats = await client.chat.list();\n\nconsole.log(chats);\n```",
390
397
  perLanguage: {
391
398
  typescript: {
392
399
  method: 'client.chat.list',
393
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst chatResponses = await client.chat.list();\n\nconsole.log(chatResponses);",
400
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst chats = await client.chat.list();\n\nconsole.log(chats.has_more);",
394
401
  },
395
402
  python: {
396
403
  method: 'chat.list',
397
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nchat_responses = client.chat.list()\nprint(chat_responses)',
404
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nchats = client.chat.list()\nprint(chats.has_more)',
398
405
  },
399
406
  http: {
400
- example: 'curl https://api.retellai.com/list-chat \\\n -H "Authorization: Bearer $RETELL_API_KEY" \\\n --max-time 300',
407
+ example: 'curl https://api.retellai.com/v3/list-chats \\\n -X POST \\\n -H "Authorization: Bearer $RETELL_API_KEY" \\\n --max-time 300',
401
408
  },
402
409
  },
403
410
  },
@@ -432,6 +439,30 @@ const EMBEDDED_METHODS = [
432
439
  },
433
440
  },
434
441
  },
442
+ {
443
+ name: 'delete',
444
+ endpoint: '/delete-chat/{chat_id}',
445
+ httpMethod: 'delete',
446
+ summary: '',
447
+ description: 'Delete an existing chat',
448
+ stainlessPath: '(resource) chat > (method) delete',
449
+ qualified: 'client.chat.delete',
450
+ params: ['chat_id: string;'],
451
+ markdown: "## delete\n\n`client.chat.delete(chat_id: string): void`\n\n**delete** `/delete-chat/{chat_id}`\n\nDelete an existing chat\n\n### Parameters\n\n- `chat_id: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nawait client.chat.delete('16b980523634a6dc504898cda492e939')\n```",
452
+ perLanguage: {
453
+ typescript: {
454
+ method: 'client.chat.delete',
455
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nawait client.chat.delete('16b980523634a6dc504898cda492e939');",
456
+ },
457
+ python: {
458
+ method: 'chat.delete',
459
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nclient.chat.delete(\n "16b980523634a6dc504898cda492e939",\n)',
460
+ },
461
+ http: {
462
+ example: 'curl https://api.retellai.com/delete-chat/$CHAT_ID \\\n -X DELETE \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
463
+ },
464
+ },
465
+ },
435
466
  {
436
467
  name: 'create',
437
468
  endpoint: '/create-phone-number',
@@ -536,25 +567,26 @@ const EMBEDDED_METHODS = [
536
567
  },
537
568
  {
538
569
  name: 'list',
539
- endpoint: '/list-phone-numbers',
570
+ endpoint: '/v2/list-phone-numbers',
540
571
  httpMethod: 'get',
541
572
  summary: '',
542
- description: 'List all phone numbers',
573
+ description: 'List phone numbers with pagination',
543
574
  stainlessPath: '(resource) phone_number > (method) list',
544
575
  qualified: 'client.phoneNumber.list',
545
- response: "{ last_modification_timestamp: number; phone_number: string; phone_number_type: 'retell-twilio' | 'retell-telnyx' | 'custom'; allowed_inbound_country_list?: string[]; allowed_outbound_country_list?: string[]; area_code?: number; fallback_number?: string; inbound_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; inbound_sms_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; inbound_sms_webhook_url?: string; inbound_webhook_url?: string; nickname?: string; outbound_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; outbound_sms_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; phone_number_pretty?: string; sip_outbound_trunk_config?: { auth_username?: string; termination_uri?: string; transport?: string; }; }[]",
546
- markdown: "## list\n\n`client.phoneNumber.list(): object[]`\n\n**get** `/list-phone-numbers`\n\nList all phone numbers\n\n### Returns\n\n- `{ last_modification_timestamp: number; phone_number: string; phone_number_type: 'retell-twilio' | 'retell-telnyx' | 'custom'; allowed_inbound_country_list?: string[]; allowed_outbound_country_list?: string[]; area_code?: number; fallback_number?: string; inbound_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; inbound_sms_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; inbound_sms_webhook_url?: string; inbound_webhook_url?: string; nickname?: string; outbound_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; outbound_sms_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; phone_number_pretty?: string; sip_outbound_trunk_config?: { auth_username?: string; termination_uri?: string; transport?: string; }; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst phoneNumberResponses = await client.phoneNumber.list();\n\nconsole.log(phoneNumberResponses);\n```",
576
+ params: ['limit?: number;', 'pagination_key?: string;', "sort_order?: 'ascending' | 'descending';"],
577
+ response: "{ has_more?: boolean; items?: { last_modification_timestamp: number; phone_number: string; phone_number_type: 'retell-twilio' | 'retell-telnyx' | 'custom'; allowed_inbound_country_list?: string[]; allowed_outbound_country_list?: string[]; area_code?: number; fallback_number?: string; inbound_agents?: object[]; inbound_sms_agents?: object[]; inbound_sms_webhook_url?: string; inbound_webhook_url?: string; nickname?: string; outbound_agents?: object[]; outbound_sms_agents?: object[]; phone_number_pretty?: string; sip_outbound_trunk_config?: object; }[]; pagination_key?: string; }",
578
+ markdown: "## list\n\n`client.phoneNumber.list(limit?: number, pagination_key?: string, sort_order?: 'ascending' | 'descending'): { has_more?: boolean; items?: phone_number_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-phone-numbers`\n\nList phone numbers with pagination\n\n### Parameters\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n- `sort_order?: 'ascending' | 'descending'`\n Sort order for results.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { last_modification_timestamp: number; phone_number: string; phone_number_type: 'retell-twilio' | 'retell-telnyx' | 'custom'; allowed_inbound_country_list?: string[]; allowed_outbound_country_list?: string[]; area_code?: number; fallback_number?: string; inbound_agents?: object[]; inbound_sms_agents?: object[]; inbound_sms_webhook_url?: string; inbound_webhook_url?: string; nickname?: string; outbound_agents?: object[]; outbound_sms_agents?: object[]; phone_number_pretty?: string; sip_outbound_trunk_config?: object; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { last_modification_timestamp: number; phone_number: string; phone_number_type: 'retell-twilio' | 'retell-telnyx' | 'custom'; allowed_inbound_country_list?: string[]; allowed_outbound_country_list?: string[]; area_code?: number; fallback_number?: string; inbound_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; inbound_sms_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; inbound_sms_webhook_url?: string; inbound_webhook_url?: string; nickname?: string; outbound_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; outbound_sms_agents?: { agent_id: string; weight: number; agent_version?: number | string; }[]; phone_number_pretty?: string; sip_outbound_trunk_config?: { auth_username?: string; termination_uri?: string; transport?: string; }; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst phoneNumbers = await client.phoneNumber.list();\n\nconsole.log(phoneNumbers);\n```",
547
579
  perLanguage: {
548
580
  typescript: {
549
581
  method: 'client.phoneNumber.list',
550
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst phoneNumberResponses = await client.phoneNumber.list();\n\nconsole.log(phoneNumberResponses);",
582
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst phoneNumbers = await client.phoneNumber.list();\n\nconsole.log(phoneNumbers.has_more);",
551
583
  },
552
584
  python: {
553
585
  method: 'phone_number.list',
554
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nphone_number_responses = client.phone_number.list()\nprint(phone_number_responses)',
586
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nphone_numbers = client.phone_number.list()\nprint(phone_numbers.has_more)',
555
587
  },
556
588
  http: {
557
- example: 'curl https://api.retellai.com/list-phone-numbers \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
589
+ example: 'curl https://api.retellai.com/v2/list-phone-numbers \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
558
590
  },
559
591
  },
560
592
  },
@@ -870,6 +902,30 @@ const EMBEDDED_METHODS = [
870
902
  },
871
903
  },
872
904
  },
905
+ {
906
+ name: 'publish',
907
+ endpoint: '/publish-agent-version/{agent_id}',
908
+ httpMethod: 'post',
909
+ summary: '',
910
+ description: 'Publish an existing draft version in place.',
911
+ stainlessPath: '(resource) agent > (method) publish',
912
+ qualified: 'client.agent.publish',
913
+ params: ['agent_id: string;', 'version: number;', 'version_description?: string;'],
914
+ markdown: "## publish\n\n`client.agent.publish(agent_id: string, version: number, version_description?: string): void`\n\n**post** `/publish-agent-version/{agent_id}`\n\nPublish an existing draft version in place.\n\n### Parameters\n\n- `agent_id: string`\n\n- `version: number`\n\n- `version_description?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nawait client.agent.publish('agent_xxx', { version: 15 })\n```",
915
+ perLanguage: {
916
+ typescript: {
917
+ method: 'client.agent.publish',
918
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nawait client.agent.publish('agent_xxx', { version: 15 });",
919
+ },
920
+ python: {
921
+ method: 'agent.publish',
922
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nclient.agent.publish(\n agent_id="agent_xxx",\n version=15,\n)',
923
+ },
924
+ http: {
925
+ example: 'curl https://api.retellai.com/publish-agent-version/$AGENT_ID \\\n -H \'Content-Type: application/json\' \\\n -H "Authorization: Bearer $RETELL_API_KEY" \\\n -d \'{\n "version": 15,\n "version_description": "Hotfix for transfer timeout"\n }\'',
926
+ },
927
+ },
928
+ },
873
929
  {
874
930
  name: 'get-versions',
875
931
  endpoint: '/get-agent-versions/{agent_id}',
@@ -1072,6 +1128,30 @@ const EMBEDDED_METHODS = [
1072
1128
  },
1073
1129
  },
1074
1130
  },
1131
+ {
1132
+ name: 'publish',
1133
+ endpoint: '/publish-agent-version/{agent_id}',
1134
+ httpMethod: 'post',
1135
+ summary: '',
1136
+ description: 'Publish an existing draft version in place.',
1137
+ stainlessPath: '(resource) chat_agent > (method) publish',
1138
+ qualified: 'client.chatAgent.publish',
1139
+ params: ['agent_id: string;', 'version: number;', 'version_description?: string;'],
1140
+ markdown: "## publish\n\n`client.chatAgent.publish(agent_id: string, version: number, version_description?: string): void`\n\n**post** `/publish-agent-version/{agent_id}`\n\nPublish an existing draft version in place.\n\n### Parameters\n\n- `agent_id: string`\n\n- `version: number`\n\n- `version_description?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nawait client.chatAgent.publish('agent_xxx', { version: 15 })\n```",
1141
+ perLanguage: {
1142
+ typescript: {
1143
+ method: 'client.chatAgent.publish',
1144
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nawait client.chatAgent.publish('agent_xxx', { version: 15 });",
1145
+ },
1146
+ python: {
1147
+ method: 'chat_agent.publish',
1148
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nclient.chat_agent.publish(\n agent_id="agent_xxx",\n version=15,\n)',
1149
+ },
1150
+ http: {
1151
+ example: 'curl https://api.retellai.com/publish-agent-version/$AGENT_ID \\\n -H \'Content-Type: application/json\' \\\n -H "Authorization: Bearer $RETELL_API_KEY" \\\n -d \'{\n "version": 15,\n "version_description": "Hotfix for transfer timeout"\n }\'',
1152
+ },
1153
+ },
1154
+ },
1075
1155
  {
1076
1156
  name: 'get-versions',
1077
1157
  endpoint: '/get-chat-agent-versions/{agent_id}',
@@ -1167,26 +1247,26 @@ const EMBEDDED_METHODS = [
1167
1247
  },
1168
1248
  {
1169
1249
  name: 'list',
1170
- endpoint: '/list-retell-llms',
1250
+ endpoint: '/v2/list-retell-llms',
1171
1251
  httpMethod: 'get',
1172
1252
  summary: '',
1173
- description: 'List all Retell LLM Response Engines that can be attached to an agent.',
1253
+ description: 'List Retell LLM Response Engines with pagination',
1174
1254
  stainlessPath: '(resource) llm > (method) list',
1175
1255
  qualified: 'client.llm.list',
1176
- params: ['limit?: number;', 'pagination_key?: string;', 'pagination_key_version?: number;'],
1177
- response: "{ last_modification_timestamp: number; llm_id: string; begin_after_user_silence_ms?: number; begin_message?: string; default_dynamic_variables?: object; general_prompt?: string; general_tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; is_published?: boolean; kb_config?: object; knowledge_base_ids?: string[]; mcps?: object[]; model?: string; model_high_priority?: boolean; model_temperature?: number; s2s_model?: 'gpt-realtime-1.5' | 'gpt-realtime' | 'gpt-realtime-mini'; start_speaker?: 'user' | 'agent'; starting_state?: string; states?: object[]; tool_call_strict_mode?: boolean; version?: number; }[]",
1178
- markdown: "## list\n\n`client.llm.list(limit?: number, pagination_key?: string, pagination_key_version?: number): object[]`\n\n**get** `/list-retell-llms`\n\nList all Retell LLM Response Engines that can be attached to an agent.\n\n### Parameters\n\n- `limit?: number`\n A limit on the number of objects to be returned. Limit can range between 1 and 1000, and the default is 1000.\n\n- `pagination_key?: string`\n The pagination key to continue fetching the next page of LLMs. Pagination key is represented by a llm id, pagination key and version pair is exclusive (not included in the fetched page). If not set, will start from the beginning.\n\n- `pagination_key_version?: number`\n Specifies the version of the llm associated with the pagination_key. When paginating, both the pagination_key and its version must be provided to ensure consistent ordering and to fetch the next page correctly.\n\n### Returns\n\n- `{ last_modification_timestamp: number; llm_id: string; begin_after_user_silence_ms?: number; begin_message?: string; default_dynamic_variables?: object; general_prompt?: string; general_tools?: { name: string; type: 'end_call'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; ignore_e164_validation?: boolean; speak_during_execution?: boolean; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; } | { agent_id: string; name: string; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; keep_current_language?: boolean; keep_current_voice?: boolean; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { name: string; type: 'press_digit'; delay_ms?: number; description?: string; } | { name: string; sms_content: object | object | object; type: 'send_sms'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { code: string; name: string; type: 'code'; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { description: string; name: string; type: 'extract_dynamic_variable'; variables: object | object | object | object[]; } | { name: string; type: 'bridge_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'cancel_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { description: string; name: string; type: 'mcp'; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; input_schema?: object; mcp_id?: string; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; }[]; is_published?: boolean; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; model?: string; model_high_priority?: boolean; model_temperature?: number; s2s_model?: 'gpt-realtime-1.5' | 'gpt-realtime' | 'gpt-realtime-mini'; start_speaker?: 'user' | 'agent'; starting_state?: string; states?: { name: string; edges?: object[]; state_prompt?: string; tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; }[]; tool_call_strict_mode?: boolean; version?: number; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst llmResponses = await client.llm.list();\n\nconsole.log(llmResponses);\n```",
1256
+ params: ['limit?: number;', 'pagination_key?: string;', "sort_order?: 'ascending' | 'descending';"],
1257
+ response: "{ has_more?: boolean; items?: { last_modification_timestamp: number; llm_id: string; begin_after_user_silence_ms?: number; begin_message?: string; default_dynamic_variables?: object; general_prompt?: string; general_tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; is_published?: boolean; kb_config?: object; knowledge_base_ids?: string[]; mcps?: object[]; model?: string; model_high_priority?: boolean; model_temperature?: number; s2s_model?: 'gpt-realtime-1.5' | 'gpt-realtime' | 'gpt-realtime-mini'; start_speaker?: 'user' | 'agent'; starting_state?: string; states?: object[]; tool_call_strict_mode?: boolean; version?: number; }[]; pagination_key?: string; }",
1258
+ markdown: "## list\n\n`client.llm.list(limit?: number, pagination_key?: string, sort_order?: 'ascending' | 'descending'): { has_more?: boolean; items?: llm_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-retell-llms`\n\nList Retell LLM Response Engines with pagination\n\n### Parameters\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n- `sort_order?: 'ascending' | 'descending'`\n Sort order for results.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { last_modification_timestamp: number; llm_id: string; begin_after_user_silence_ms?: number; begin_message?: string; default_dynamic_variables?: object; general_prompt?: string; general_tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; is_published?: boolean; kb_config?: object; knowledge_base_ids?: string[]; mcps?: object[]; model?: string; model_high_priority?: boolean; model_temperature?: number; s2s_model?: 'gpt-realtime-1.5' | 'gpt-realtime' | 'gpt-realtime-mini'; start_speaker?: 'user' | 'agent'; starting_state?: string; states?: object[]; tool_call_strict_mode?: boolean; version?: number; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { last_modification_timestamp: number; llm_id: string; begin_after_user_silence_ms?: number; begin_message?: string; default_dynamic_variables?: object; general_prompt?: string; general_tools?: { name: string; type: 'end_call'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; transfer_destination: { number: string; type: 'predefined'; extension?: string; } | { prompt: string; type: 'inferred'; }; transfer_option: { type: 'cold_transfer'; cold_transfer_mode?: 'sip_refer' | 'sip_invite'; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; } | { type: 'warm_transfer'; agent_detection_timeout_ms?: number; enable_bridge_audio_cue?: boolean; ivr_option?: object; on_hold_music?: 'none' | 'relaxing_sound' | 'uplifting_beats' | 'ringtone'; opt_out_human_detection?: boolean; private_handoff_option?: object | object; public_handoff_option?: object | object; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; } | { agentic_transfer_config: object; type: 'agentic_warm_transfer'; enable_bridge_audio_cue?: boolean; on_hold_music?: 'none' | 'relaxing_sound' | 'uplifting_beats' | 'ringtone'; public_handoff_option?: object | object; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; }; type: 'transfer_call'; custom_sip_headers?: object; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; ignore_e164_validation?: boolean; speak_during_execution?: boolean; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; } | { agent_id: string; name: string; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; keep_current_language?: boolean; keep_current_voice?: boolean; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { name: string; type: 'press_digit'; delay_ms?: number; description?: string; } | { name: string; sms_content: { content?: string; type?: 'predefined'; } | { prompt?: string; type?: 'inferred'; } | { template: 'info_collection'; type: 'template'; }; type: 'send_sms'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: { properties: object; type: 'object'; required?: string[]; }; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { code: string; name: string; type: 'code'; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { description: string; name: string; type: 'extract_dynamic_variable'; variables: { description: string; name: string; type: 'string'; conditional_prompt?: string; examples?: string[]; required?: boolean; } | { choices: string[]; description: string; name: string; type: 'enum'; conditional_prompt?: string; required?: boolean; } | { description: string; name: string; type: 'boolean'; conditional_prompt?: string; required?: boolean; } | { description: string; name: string; type: 'number'; conditional_prompt?: string; required?: boolean; }[]; } | { name: string; type: 'bridge_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'cancel_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { description: string; name: string; type: 'mcp'; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; input_schema?: object; mcp_id?: string; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; }[]; is_published?: boolean; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; model?: string; model_high_priority?: boolean; model_temperature?: number; s2s_model?: 'gpt-realtime-1.5' | 'gpt-realtime' | 'gpt-realtime-mini'; start_speaker?: 'user' | 'agent'; starting_state?: string; states?: { name: string; edges?: { description: string; destination_state_name: string; parameters?: object; }[]; state_prompt?: string; tools?: { name: string; type: 'end_call'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; ignore_e164_validation?: boolean; speak_during_execution?: boolean; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; } | { agent_id: string; name: string; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; keep_current_language?: boolean; keep_current_voice?: boolean; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { name: string; type: 'press_digit'; delay_ms?: number; description?: string; } | { name: string; sms_content: object | object | object; type: 'send_sms'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { code: string; name: string; type: 'code'; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { description: string; name: string; type: 'extract_dynamic_variable'; variables: object | object | object | object[]; } | { name: string; type: 'bridge_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'cancel_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { description: string; name: string; type: 'mcp'; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; input_schema?: object; mcp_id?: string; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; }[]; }[]; tool_call_strict_mode?: boolean; version?: number; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst llms = await client.llm.list();\n\nconsole.log(llms);\n```",
1179
1259
  perLanguage: {
1180
1260
  typescript: {
1181
1261
  method: 'client.llm.list',
1182
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst llmResponses = await client.llm.list();\n\nconsole.log(llmResponses);",
1262
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst llms = await client.llm.list();\n\nconsole.log(llms.has_more);",
1183
1263
  },
1184
1264
  python: {
1185
1265
  method: 'llm.list',
1186
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nllm_responses = client.llm.list()\nprint(llm_responses)',
1266
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nllms = client.llm.list()\nprint(llms.has_more)',
1187
1267
  },
1188
1268
  http: {
1189
- example: 'curl https://api.retellai.com/list-retell-llms \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
1269
+ example: 'curl https://api.retellai.com/v2/list-retell-llms \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
1190
1270
  },
1191
1271
  },
1192
1272
  },
@@ -1329,26 +1409,26 @@ const EMBEDDED_METHODS = [
1329
1409
  },
1330
1410
  {
1331
1411
  name: 'list',
1332
- endpoint: '/list-conversation-flows',
1412
+ endpoint: '/v2/list-conversation-flows',
1333
1413
  httpMethod: 'get',
1334
1414
  summary: '',
1335
- description: 'List all conversation flows that can be attached to an agent.',
1415
+ description: 'List conversation flows with pagination',
1336
1416
  stainlessPath: '(resource) conversation_flow > (method) list',
1337
1417
  qualified: 'client.conversationFlow.list',
1338
- params: ['limit?: number;', 'pagination_key?: string;', 'pagination_key_version?: number;'],
1339
- response: "{ conversation_flow_id: string; version: number; begin_after_user_silence_ms?: number; begin_tag_display_position?: object; components?: object[]; default_dynamic_variables?: object; global_prompt?: string; is_transfer_llm?: boolean; kb_config?: object; knowledge_base_ids?: string[]; mcps?: object[]; model_choice?: object; model_temperature?: number; nodes?: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; notes?: object[]; start_node_id?: string; start_speaker?: 'user' | 'agent'; tool_call_strict_mode?: boolean; tools?: object | object | object[]; }[]",
1340
- markdown: "## list\n\n`client.conversationFlow.list(limit?: number, pagination_key?: string, pagination_key_version?: number): object[]`\n\n**get** `/list-conversation-flows`\n\nList all conversation flows that can be attached to an agent.\n\n### Parameters\n\n- `limit?: number`\n Limit the number of conversation flows returned. Default 1000, Max 1000. To retrieve more than 1000, use pagination_key to continue fetching the next page.\n\n- `pagination_key?: string`\n The pagination key to continue fetching the next page of conversation flows. Pagination key is represented by a conversation flow id here, and it's exclusive (not included in the fetched conversation flows). The last conversation flow id from the list conversation flows is usually used as pagination key here. If not set, will start from the beginning.\n\n- `pagination_key_version?: number`\n Specifies the version of the conversation flow associated with the pagination_key. When paginating, both the pagination_key and its version must be provided to ensure consistent ordering and to fetch the next page correctly.\n\n### Returns\n\n- `{ conversation_flow_id: string; version: number; begin_after_user_silence_ms?: number; begin_tag_display_position?: { x?: number; y?: number; }; components?: { name: string; nodes: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; begin_tag_display_position?: object; mcps?: object[]; notes?: object[]; start_node_id?: string; tools?: object | object | object[]; }[]; default_dynamic_variables?: object; global_prompt?: string; is_transfer_llm?: boolean; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; model_temperature?: number; nodes?: { id: string; instruction: object | object; type: 'conversation'; allow_dtmf_interruption?: boolean; always_edge?: object; display_position?: object; edges?: object[]; finetune_conversation_examples?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; interruption_sensitivity?: number; kb_config?: object; knowledge_base_ids?: string[]; model_choice?: object; name?: string; responsiveness?: number; skip_response_edge?: object; voice_speed?: number; } | { id: string; instruction: object; type: 'subagent'; allow_dtmf_interruption?: boolean; always_edge?: object; display_position?: object; edges?: object[]; finetune_conversation_examples?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; interruption_sensitivity?: number; kb_config?: object; knowledge_base_ids?: string[]; model_choice?: object; name?: string; responsiveness?: number; skip_response_edge?: object; tool_ids?: string[]; tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; voice_speed?: number; } | { id: string; type: 'end'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; tool_id: string; tool_type: 'local' | 'shared'; type: 'function'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; code: string; type: 'code'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; response_variables?: object; speak_during_execution?: boolean; timeout_ms?: number; } | { id: string; edge: object; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; display_position?: object; global_node_setting?: object; ignore_e164_validation?: boolean; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; instruction: object; type: 'press_digit'; delay_ms?: number; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; else_edge: object; type: 'branch'; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; failed_edge: object; instruction: object | object | object; success_edge: object; type: 'sms'; display_position?: object; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; type: 'extract_dynamic_variables'; variables: object | object | object | object[]; display_position?: object; edges?: object[]; else_edge?: object; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; agent_id: string; edge: object; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; display_position?: object; global_node_setting?: object; instruction?: object | object; keep_current_language?: boolean; keep_current_voice?: boolean; model_choice?: object; name?: string; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { id: string; mcp_id: string; mcp_tool_name: string; type: 'mcp'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; response_variables?: object; speak_during_execution?: boolean; } | { id: string; component_id: string; component_type: 'local' | 'shared'; else_edge: object; type: 'component'; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; name?: string; } | { id: string; type: 'bridge_transfer'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; type: 'cancel_transfer'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; }[]; notes?: { id: string; content: string; display_position: object; size: object; }[]; start_node_id?: string; start_speaker?: 'user' | 'agent'; tool_call_strict_mode?: boolean; tools?: { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; tool_id?: string; }[]; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst conversationFlowResponses = await client.conversationFlow.list();\n\nconsole.log(conversationFlowResponses);\n```",
1418
+ params: ['limit?: number;', 'pagination_key?: string;', "sort_order?: 'ascending' | 'descending';"],
1419
+ response: "{ has_more?: boolean; items?: { conversation_flow_id: string; version: number; begin_after_user_silence_ms?: number; begin_tag_display_position?: object; components?: object[]; default_dynamic_variables?: object; global_prompt?: string; is_transfer_llm?: boolean; kb_config?: object; knowledge_base_ids?: string[]; mcps?: object[]; model_choice?: object; model_temperature?: number; nodes?: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; notes?: object[]; start_node_id?: string; start_speaker?: 'user' | 'agent'; tool_call_strict_mode?: boolean; tools?: object | object | object[]; }[]; pagination_key?: string; }",
1420
+ markdown: "## list\n\n`client.conversationFlow.list(limit?: number, pagination_key?: string, sort_order?: 'ascending' | 'descending'): { has_more?: boolean; items?: conversation_flow_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-conversation-flows`\n\nList conversation flows with pagination\n\n### Parameters\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n- `sort_order?: 'ascending' | 'descending'`\n Sort order for results.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { conversation_flow_id: string; version: number; begin_after_user_silence_ms?: number; begin_tag_display_position?: object; components?: object[]; default_dynamic_variables?: object; global_prompt?: string; is_transfer_llm?: boolean; kb_config?: object; knowledge_base_ids?: string[]; mcps?: object[]; model_choice?: object; model_temperature?: number; nodes?: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; notes?: object[]; start_node_id?: string; start_speaker?: 'user' | 'agent'; tool_call_strict_mode?: boolean; tools?: object | object | object[]; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { conversation_flow_id: string; version: number; begin_after_user_silence_ms?: number; begin_tag_display_position?: { x?: number; y?: number; }; components?: { name: string; nodes: { id: string; instruction: object | object; type: 'conversation'; allow_dtmf_interruption?: boolean; always_edge?: object; display_position?: object; edges?: object[]; finetune_conversation_examples?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; interruption_sensitivity?: number; kb_config?: object; knowledge_base_ids?: string[]; model_choice?: object; name?: string; responsiveness?: number; skip_response_edge?: object; voice_speed?: number; } | { id: string; instruction: object; type: 'subagent'; allow_dtmf_interruption?: boolean; always_edge?: object; display_position?: object; edges?: object[]; finetune_conversation_examples?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; interruption_sensitivity?: number; kb_config?: object; knowledge_base_ids?: string[]; model_choice?: object; name?: string; responsiveness?: number; skip_response_edge?: object; tool_ids?: string[]; tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; voice_speed?: number; } | { id: string; type: 'end'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; tool_id: string; tool_type: 'local' | 'shared'; type: 'function'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; code: string; type: 'code'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; response_variables?: object; speak_during_execution?: boolean; timeout_ms?: number; } | { id: string; edge: object; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; display_position?: object; global_node_setting?: object; ignore_e164_validation?: boolean; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; instruction: object; type: 'press_digit'; delay_ms?: number; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; else_edge: object; type: 'branch'; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; failed_edge: object; instruction: object | object | object; success_edge: object; type: 'sms'; display_position?: object; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; type: 'extract_dynamic_variables'; variables: object | object | object | object[]; display_position?: object; edges?: object[]; else_edge?: object; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; agent_id: string; edge: object; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; display_position?: object; global_node_setting?: object; instruction?: object | object; keep_current_language?: boolean; keep_current_voice?: boolean; model_choice?: object; name?: string; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { id: string; mcp_id: string; mcp_tool_name: string; type: 'mcp'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; response_variables?: object; speak_during_execution?: boolean; } | { id: string; component_id: string; component_type: 'local' | 'shared'; else_edge: object; type: 'component'; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; name?: string; } | { id: string; type: 'bridge_transfer'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; type: 'cancel_transfer'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; }[]; begin_tag_display_position?: { x?: number; y?: number; }; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; notes?: { id: string; content: string; display_position: object; size: object; }[]; start_node_id?: string; tools?: { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; tool_id?: string; }[]; }[]; default_dynamic_variables?: object; global_prompt?: string; is_transfer_llm?: boolean; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; model_temperature?: number; nodes?: { id: string; instruction: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; type: 'conversation'; allow_dtmf_interruption?: boolean; always_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_conversation_examples?: { id: string; transcript: object | object | object[]; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; interruption_sensitivity?: number; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; responsiveness?: number; skip_response_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; voice_speed?: number; } | { id: string; instruction: { text: string; type: 'prompt'; }; type: 'subagent'; allow_dtmf_interruption?: boolean; always_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_conversation_examples?: { id: string; transcript: object | object | object[]; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; interruption_sensitivity?: number; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; responsiveness?: number; skip_response_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; tool_ids?: string[]; tools?: { name: string; type: 'end_call'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; ignore_e164_validation?: boolean; speak_during_execution?: boolean; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; } | { agent_id: string; name: string; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; keep_current_language?: boolean; keep_current_voice?: boolean; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { name: string; type: 'press_digit'; delay_ms?: number; description?: string; } | { name: string; sms_content: object | object | object; type: 'send_sms'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { code: string; name: string; type: 'code'; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { description: string; name: string; type: 'extract_dynamic_variable'; variables: object | object | object | object[]; } | { name: string; type: 'bridge_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'cancel_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { description: string; name: string; type: 'mcp'; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; input_schema?: object; mcp_id?: string; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; }[]; voice_speed?: number; } | { id: string; type: 'end'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; tool_id: string; tool_type: 'local' | 'shared'; type: 'function'; wait_for_result: boolean; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; enable_typing_sound?: boolean; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; code: string; type: 'code'; wait_for_result: boolean; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; enable_typing_sound?: boolean; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; response_variables?: object; speak_during_execution?: boolean; timeout_ms?: number; } | { id: string; edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; transfer_destination: { number: string; type: 'predefined'; extension?: string; } | { prompt: string; type: 'inferred'; }; transfer_option: { type: 'cold_transfer'; cold_transfer_mode?: 'sip_refer' | 'sip_invite'; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; } | { type: 'warm_transfer'; agent_detection_timeout_ms?: number; enable_bridge_audio_cue?: boolean; ivr_option?: object; on_hold_music?: 'none' | 'relaxing_sound' | 'uplifting_beats' | 'ringtone'; opt_out_human_detection?: boolean; private_handoff_option?: object | object; public_handoff_option?: object | object; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; } | { agentic_transfer_config: object; type: 'agentic_warm_transfer'; enable_bridge_audio_cue?: boolean; on_hold_music?: 'none' | 'relaxing_sound' | 'uplifting_beats' | 'ringtone'; public_handoff_option?: object | object; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; }; type: 'transfer_call'; custom_sip_headers?: object; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; ignore_e164_validation?: boolean; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; instruction: { text: string; type: 'prompt'; }; type: 'press_digit'; delay_ms?: number; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; else_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; type: 'branch'; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; failed_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; instruction: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; } | { template: 'info_collection'; type: 'template'; }; success_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; type: 'sms'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; type: 'extract_dynamic_variables'; variables: { description: string; name: string; type: 'string'; conditional_prompt?: string; examples?: string[]; required?: boolean; } | { choices: string[]; description: string; name: string; type: 'enum'; conditional_prompt?: string; required?: boolean; } | { description: string; name: string; type: 'boolean'; conditional_prompt?: string; required?: boolean; } | { description: string; name: string; type: 'number'; conditional_prompt?: string; required?: boolean; }[]; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; agent_id: string; edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; keep_current_language?: boolean; keep_current_voice?: boolean; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { id: string; mcp_id: string; mcp_tool_name: string; type: 'mcp'; wait_for_result: boolean; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; enable_typing_sound?: boolean; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; response_variables?: object; speak_during_execution?: boolean; } | { id: string; component_id: string; component_type: 'local' | 'shared'; else_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; type: 'component'; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; name?: string; } | { id: string; type: 'bridge_transfer'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; type: 'cancel_transfer'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; }[]; notes?: { id: string; content: string; display_position: { x?: number; y?: number; }; size: { height?: number; width?: number; }; }[]; start_node_id?: string; start_speaker?: 'user' | 'agent'; tool_call_strict_mode?: boolean; tools?: { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: { properties: object; type: 'object'; required?: string[]; }; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; tool_id?: string; }[]; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst conversationFlows = await client.conversationFlow.list();\n\nconsole.log(conversationFlows);\n```",
1341
1421
  perLanguage: {
1342
1422
  typescript: {
1343
1423
  method: 'client.conversationFlow.list',
1344
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst conversationFlowResponses = await client.conversationFlow.list();\n\nconsole.log(conversationFlowResponses);",
1424
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst conversationFlows = await client.conversationFlow.list();\n\nconsole.log(conversationFlows.has_more);",
1345
1425
  },
1346
1426
  python: {
1347
1427
  method: 'conversation_flow.list',
1348
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nconversation_flow_responses = client.conversation_flow.list()\nprint(conversation_flow_responses)',
1428
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nconversation_flows = client.conversation_flow.list()\nprint(conversation_flows.has_more)',
1349
1429
  },
1350
1430
  http: {
1351
- example: 'curl https://api.retellai.com/list-conversation-flows \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
1431
+ example: 'curl https://api.retellai.com/v2/list-conversation-flows \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
1352
1432
  },
1353
1433
  },
1354
1434
  },
@@ -1481,25 +1561,26 @@ const EMBEDDED_METHODS = [
1481
1561
  },
1482
1562
  {
1483
1563
  name: 'list',
1484
- endpoint: '/list-conversation-flow-components',
1564
+ endpoint: '/v2/list-conversation-flow-components',
1485
1565
  httpMethod: 'get',
1486
1566
  summary: '',
1487
- description: 'List shared conversation flow components',
1567
+ description: 'List shared conversation flow components with pagination',
1488
1568
  stainlessPath: '(resource) conversation_flow_component > (method) list',
1489
1569
  qualified: 'client.conversationFlowComponent.list',
1490
- response: '{ conversation_flow_component_id: string; name: string; nodes: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; user_modified_timestamp: number; begin_tag_display_position?: object; linked_conversation_flow_ids?: string[]; mcps?: object[]; notes?: object[]; start_node_id?: string; tools?: object | object | object[]; }[]',
1491
- markdown: "## list\n\n`client.conversationFlowComponent.list(): object[]`\n\n**get** `/list-conversation-flow-components`\n\nList shared conversation flow components\n\n### Returns\n\n- `{ conversation_flow_component_id: string; name: string; nodes: { id: string; instruction: object | object; type: 'conversation'; allow_dtmf_interruption?: boolean; always_edge?: object; display_position?: object; edges?: object[]; finetune_conversation_examples?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; interruption_sensitivity?: number; kb_config?: object; knowledge_base_ids?: string[]; model_choice?: object; name?: string; responsiveness?: number; skip_response_edge?: object; voice_speed?: number; } | { id: string; instruction: object; type: 'subagent'; allow_dtmf_interruption?: boolean; always_edge?: object; display_position?: object; edges?: object[]; finetune_conversation_examples?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; interruption_sensitivity?: number; kb_config?: object; knowledge_base_ids?: string[]; model_choice?: object; name?: string; responsiveness?: number; skip_response_edge?: object; tool_ids?: string[]; tools?: object | object | object | object | object | object | object | object | object | object | object | object | object[]; voice_speed?: number; } | { id: string; type: 'end'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; tool_id: string; tool_type: 'local' | 'shared'; type: 'function'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; code: string; type: 'code'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; response_variables?: object; speak_during_execution?: boolean; timeout_ms?: number; } | { id: string; edge: object; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; display_position?: object; global_node_setting?: object; ignore_e164_validation?: boolean; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; instruction: object; type: 'press_digit'; delay_ms?: number; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; else_edge: object; type: 'branch'; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; failed_edge: object; instruction: object | object | object; success_edge: object; type: 'sms'; display_position?: object; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; type: 'extract_dynamic_variables'; variables: object | object | object | object[]; display_position?: object; edges?: object[]; else_edge?: object; finetune_transition_examples?: object[]; global_node_setting?: object; model_choice?: object; name?: string; } | { id: string; agent_id: string; edge: object; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; display_position?: object; global_node_setting?: object; instruction?: object | object; keep_current_language?: boolean; keep_current_voice?: boolean; model_choice?: object; name?: string; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { id: string; mcp_id: string; mcp_tool_name: string; type: 'mcp'; wait_for_result: boolean; display_position?: object; edges?: object[]; else_edge?: object; enable_typing_sound?: boolean; finetune_transition_examples?: object[]; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; response_variables?: object; speak_during_execution?: boolean; } | { id: string; component_id: string; component_type: 'local' | 'shared'; else_edge: object; type: 'component'; display_position?: object; edges?: object[]; finetune_transition_examples?: object[]; global_node_setting?: object; name?: string; } | { id: string; type: 'bridge_transfer'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; } | { id: string; type: 'cancel_transfer'; display_position?: object; global_node_setting?: object; instruction?: object | object; model_choice?: object; name?: string; speak_during_execution?: boolean; }[]; user_modified_timestamp: number; begin_tag_display_position?: { x?: number; y?: number; }; linked_conversation_flow_ids?: string[]; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; notes?: { id: string; content: string; display_position: object; size: object; }[]; start_node_id?: string; tools?: { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; tool_id?: string; }[]; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst conversationFlowComponentResponses = await client.conversationFlowComponent.list();\n\nconsole.log(conversationFlowComponentResponses);\n```",
1570
+ params: ['limit?: number;', 'pagination_key?: string;', "sort_order?: 'ascending' | 'descending';"],
1571
+ response: '{ has_more?: boolean; items?: { conversation_flow_component_id: string; name: string; nodes: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; user_modified_timestamp: number; begin_tag_display_position?: object; linked_conversation_flow_ids?: string[]; mcps?: object[]; notes?: object[]; start_node_id?: string; tools?: object | object | object[]; }[]; pagination_key?: string; }',
1572
+ markdown: "## list\n\n`client.conversationFlowComponent.list(limit?: number, pagination_key?: string, sort_order?: 'ascending' | 'descending'): { has_more?: boolean; items?: conversation_flow_component_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-conversation-flow-components`\n\nList shared conversation flow components with pagination\n\n### Parameters\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n- `sort_order?: 'ascending' | 'descending'`\n Sort order for results.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { conversation_flow_component_id: string; name: string; nodes: object | object | object | object | object | object | object | object | object | object | object | object | object | object | object[]; user_modified_timestamp: number; begin_tag_display_position?: object; linked_conversation_flow_ids?: string[]; mcps?: object[]; notes?: object[]; start_node_id?: string; tools?: object | object | object[]; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { conversation_flow_component_id: string; name: string; nodes: { id: string; instruction: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; type: 'conversation'; allow_dtmf_interruption?: boolean; always_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_conversation_examples?: { id: string; transcript: object | object | object[]; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; interruption_sensitivity?: number; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; responsiveness?: number; skip_response_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; voice_speed?: number; } | { id: string; instruction: { text: string; type: 'prompt'; }; type: 'subagent'; allow_dtmf_interruption?: boolean; always_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_conversation_examples?: { id: string; transcript: object | object | object[]; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; interruption_sensitivity?: number; kb_config?: { filter_score?: number; top_k?: number; }; knowledge_base_ids?: string[]; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; responsiveness?: number; skip_response_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; tool_ids?: string[]; tools?: { name: string; type: 'end_call'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; transfer_destination: object | object; transfer_option: object | object | object; type: 'transfer_call'; custom_sip_headers?: object; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; ignore_e164_validation?: boolean; speak_during_execution?: boolean; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; } | { agent_id: string; name: string; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; keep_current_language?: boolean; keep_current_voice?: boolean; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { name: string; type: 'press_digit'; delay_ms?: number; description?: string; } | { name: string; sms_content: object | object | object; type: 'send_sms'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: object; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { code: string; name: string; type: 'code'; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; } | { description: string; name: string; type: 'extract_dynamic_variable'; variables: object | object | object | object[]; } | { name: string; type: 'bridge_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { name: string; type: 'cancel_transfer'; description?: string; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; speak_during_execution?: boolean; } | { description: string; name: string; type: 'mcp'; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; input_schema?: object; mcp_id?: string; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; }[]; voice_speed?: number; } | { id: string; type: 'end'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; tool_id: string; tool_type: 'local' | 'shared'; type: 'function'; wait_for_result: boolean; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; enable_typing_sound?: boolean; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; code: string; type: 'code'; wait_for_result: boolean; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; enable_typing_sound?: boolean; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; response_variables?: object; speak_during_execution?: boolean; timeout_ms?: number; } | { id: string; edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; transfer_destination: { number: string; type: 'predefined'; extension?: string; } | { prompt: string; type: 'inferred'; }; transfer_option: { type: 'cold_transfer'; cold_transfer_mode?: 'sip_refer' | 'sip_invite'; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; } | { type: 'warm_transfer'; agent_detection_timeout_ms?: number; enable_bridge_audio_cue?: boolean; ivr_option?: object; on_hold_music?: 'none' | 'relaxing_sound' | 'uplifting_beats' | 'ringtone'; opt_out_human_detection?: boolean; private_handoff_option?: object | object; public_handoff_option?: object | object; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; } | { agentic_transfer_config: object; type: 'agentic_warm_transfer'; enable_bridge_audio_cue?: boolean; on_hold_music?: 'none' | 'relaxing_sound' | 'uplifting_beats' | 'ringtone'; public_handoff_option?: object | object; show_transferee_as_caller?: boolean; transfer_ring_duration_ms?: number; }; type: 'transfer_call'; custom_sip_headers?: object; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; ignore_e164_validation?: boolean; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; instruction: { text: string; type: 'prompt'; }; type: 'press_digit'; delay_ms?: number; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; else_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; type: 'branch'; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; failed_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; instruction: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; } | { template: 'info_collection'; type: 'template'; }; success_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; type: 'sms'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; type: 'extract_dynamic_variables'; variables: { description: string; name: string; type: 'string'; conditional_prompt?: string; examples?: string[]; required?: boolean; } | { choices: string[]; description: string; name: string; type: 'enum'; conditional_prompt?: string; required?: boolean; } | { description: string; name: string; type: 'boolean'; conditional_prompt?: string; required?: boolean; } | { description: string; name: string; type: 'number'; conditional_prompt?: string; required?: boolean; }[]; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; } | { id: string; agent_id: string; edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; post_call_analysis_setting: 'both_agents' | 'only_destination_agent'; type: 'agent_swap'; agent_version?: number | string; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; keep_current_language?: boolean; keep_current_voice?: boolean; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; webhook_setting?: 'both_agents' | 'only_destination_agent' | 'only_source_agent'; } | { id: string; mcp_id: string; mcp_tool_name: string; type: 'mcp'; wait_for_result: boolean; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; else_edge?: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; enable_typing_sound?: boolean; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; response_variables?: object; speak_during_execution?: boolean; } | { id: string; component_id: string; component_type: 'local' | 'shared'; else_edge: { id: string; transition_condition: object | object | object; destination_node_id?: string; }; type: 'component'; display_position?: { x?: number; y?: number; }; edges?: { id: string; transition_condition: object | object; destination_node_id?: string; }[]; finetune_transition_examples?: { id: string; transcript: object | object | object[]; destination_node_id?: string; }[]; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; name?: string; } | { id: string; type: 'bridge_transfer'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; } | { id: string; type: 'cancel_transfer'; display_position?: { x?: number; y?: number; }; global_node_setting?: { condition: string; cool_down?: number; go_back_conditions?: object[]; negative_finetune_examples?: object[]; positive_finetune_examples?: object[]; }; instruction?: { text: string; type: 'prompt'; } | { text: string; type: 'static_text'; }; model_choice?: { model: string; type: 'cascading'; high_priority?: boolean; }; name?: string; speak_during_execution?: boolean; }[]; user_modified_timestamp: number; begin_tag_display_position?: { x?: number; y?: number; }; linked_conversation_flow_ids?: string[]; mcps?: { name: string; url: string; headers?: object; query_params?: object; timeout_ms?: number; }[]; notes?: { id: string; content: string; display_position: { x?: number; y?: number; }; size: { height?: number; width?: number; }; }[]; start_node_id?: string; tools?: { name: string; type: 'custom'; url: string; args_at_root?: boolean; description?: string; enable_typing_sound?: boolean; execution_message_description?: string; execution_message_type?: 'prompt' | 'static_text'; headers?: object; method?: 'GET' | 'POST' | 'PUT' | 'PATCH' | 'DELETE'; parameters?: { properties: object; type: 'object'; required?: string[]; }; query_params?: object; response_variables?: object; speak_after_execution?: boolean; speak_during_execution?: boolean; timeout_ms?: number; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'check_availability_cal'; description?: string; timezone?: string; tool_id?: string; } | { cal_api_key: string; event_type_id: number | string; name: string; type: 'book_appointment_cal'; description?: string; timezone?: string; tool_id?: string; }[]; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst conversationFlowComponents = await client.conversationFlowComponent.list();\n\nconsole.log(conversationFlowComponents);\n```",
1492
1573
  perLanguage: {
1493
1574
  typescript: {
1494
1575
  method: 'client.conversationFlowComponent.list',
1495
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst conversationFlowComponentResponses = await client.conversationFlowComponent.list();\n\nconsole.log(conversationFlowComponentResponses);",
1576
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst conversationFlowComponents = await client.conversationFlowComponent.list();\n\nconsole.log(conversationFlowComponents.has_more);",
1496
1577
  },
1497
1578
  python: {
1498
1579
  method: 'conversation_flow_component.list',
1499
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nconversation_flow_component_responses = client.conversation_flow_component.list()\nprint(conversation_flow_component_responses)',
1580
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nconversation_flow_components = client.conversation_flow_component.list()\nprint(conversation_flow_components.has_more)',
1500
1581
  },
1501
1582
  http: {
1502
- example: 'curl https://api.retellai.com/list-conversation-flow-components \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
1583
+ example: 'curl https://api.retellai.com/v2/list-conversation-flow-components \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
1503
1584
  },
1504
1585
  },
1505
1586
  },
@@ -1999,30 +2080,32 @@ const EMBEDDED_METHODS = [
1999
2080
  },
2000
2081
  {
2001
2082
  name: 'list-test-case-definitions',
2002
- endpoint: '/list-test-case-definitions',
2083
+ endpoint: '/v2/list-test-case-definitions',
2003
2084
  httpMethod: 'get',
2004
2085
  summary: '',
2005
- description: 'List test case definitions for a response engine',
2086
+ description: 'List test case definitions with pagination',
2006
2087
  stainlessPath: '(resource) tests > (method) list-test-case-definitions',
2007
2088
  qualified: 'client.tests.listTestCaseDefinitions',
2008
2089
  params: [
2009
2090
  "type: 'retell-llm' | 'conversation-flow';",
2010
2091
  'conversation_flow_id?: string;',
2092
+ 'limit?: number;',
2011
2093
  'llm_id?: string;',
2094
+ 'pagination_key?: string;',
2012
2095
  ],
2013
- response: "{ creation_timestamp: number; dynamic_variables: object; llm_model: string; metrics: string[]; name: string; response_engine: { llm_id: string; type: 'retell-llm'; version?: number; } | { conversation_flow_id: string; type: 'conversation-flow'; version?: number; }; test_case_definition_id: string; tool_mocks: { input_match_rule: object | object; output: string; tool_name: string; result?: boolean; }[]; type: 'simulation'; user_modified_timestamp: number; user_prompt: string; }[]",
2014
- markdown: "## list-test-case-definitions\n\n`client.tests.listTestCaseDefinitions(type: 'retell-llm' | 'conversation-flow', conversation_flow_id?: string, llm_id?: string): object[]`\n\n**get** `/list-test-case-definitions`\n\nList test case definitions for a response engine\n\n### Parameters\n\n- `type: 'retell-llm' | 'conversation-flow'`\n Type of response engine\n\n- `conversation_flow_id?: string`\n Conversation flow ID (required when type is conversation-flow)\n\n- `llm_id?: string`\n LLM ID (required when type is retell-llm)\n\n### Returns\n\n- `{ creation_timestamp: number; dynamic_variables: object; llm_model: string; metrics: string[]; name: string; response_engine: { llm_id: string; type: 'retell-llm'; version?: number; } | { conversation_flow_id: string; type: 'conversation-flow'; version?: number; }; test_case_definition_id: string; tool_mocks: { input_match_rule: object | object; output: string; tool_name: string; result?: boolean; }[]; type: 'simulation'; user_modified_timestamp: number; user_prompt: string; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst testCaseDefinitionResponses = await client.tests.listTestCaseDefinitions({ type: 'retell-llm' });\n\nconsole.log(testCaseDefinitionResponses);\n```",
2096
+ response: "{ has_more?: boolean; items?: { creation_timestamp: number; dynamic_variables: object; llm_model: string; metrics: string[]; name: string; response_engine: object | object; test_case_definition_id: string; tool_mocks: object[]; type: 'simulation'; user_modified_timestamp: number; user_prompt: string; }[]; pagination_key?: string; }",
2097
+ markdown: "## list-test-case-definitions\n\n`client.tests.listTestCaseDefinitions(type: 'retell-llm' | 'conversation-flow', conversation_flow_id?: string, limit?: number, llm_id?: string, pagination_key?: string): { has_more?: boolean; items?: test_case_definition_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-test-case-definitions`\n\nList test case definitions with pagination\n\n### Parameters\n\n- `type: 'retell-llm' | 'conversation-flow'`\n Type of response engine\n\n- `conversation_flow_id?: string`\n Conversation flow ID (required when type is conversation-flow)\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `llm_id?: string`\n LLM ID (required when type is retell-llm)\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { creation_timestamp: number; dynamic_variables: object; llm_model: string; metrics: string[]; name: string; response_engine: object | object; test_case_definition_id: string; tool_mocks: object[]; type: 'simulation'; user_modified_timestamp: number; user_prompt: string; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { creation_timestamp: number; dynamic_variables: object; llm_model: string; metrics: string[]; name: string; response_engine: { llm_id: string; type: 'retell-llm'; version?: number; } | { conversation_flow_id: string; type: 'conversation-flow'; version?: number; }; test_case_definition_id: string; tool_mocks: { input_match_rule: { type: 'any'; } | { args: object; type: 'partial_match'; }; output: string; tool_name: string; result?: boolean; }[]; type: 'simulation'; user_modified_timestamp: number; user_prompt: string; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst response = await client.tests.listTestCaseDefinitions({ type: 'retell-llm' });\n\nconsole.log(response);\n```",
2015
2098
  perLanguage: {
2016
2099
  typescript: {
2017
2100
  method: 'client.tests.listTestCaseDefinitions',
2018
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst testCaseDefinitionResponses = await client.tests.listTestCaseDefinitions({\n type: 'retell-llm',\n});\n\nconsole.log(testCaseDefinitionResponses);",
2101
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst response = await client.tests.listTestCaseDefinitions({ type: 'retell-llm' });\n\nconsole.log(response.has_more);",
2019
2102
  },
2020
2103
  python: {
2021
2104
  method: 'tests.list_test_case_definitions',
2022
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\ntest_case_definition_responses = client.tests.list_test_case_definitions(\n type="retell-llm",\n)\nprint(test_case_definition_responses)',
2105
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nresponse = client.tests.list_test_case_definitions(\n type="retell-llm",\n)\nprint(response.has_more)',
2023
2106
  },
2024
2107
  http: {
2025
- example: 'curl https://api.retellai.com/list-test-case-definitions \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
2108
+ example: 'curl https://api.retellai.com/v2/list-test-case-definitions \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
2026
2109
  },
2027
2110
  },
2028
2111
  },
@@ -2139,31 +2222,33 @@ const EMBEDDED_METHODS = [
2139
2222
  },
2140
2223
  {
2141
2224
  name: 'list-batch-tests',
2142
- endpoint: '/list-batch-tests',
2225
+ endpoint: '/v2/list-batch-tests',
2143
2226
  httpMethod: 'get',
2144
2227
  summary: '',
2145
- description: 'List batch test jobs for a response engine',
2228
+ description: 'List batch test jobs with pagination',
2146
2229
  stainlessPath: '(resource) tests > (method) list-batch-tests',
2147
2230
  qualified: 'client.tests.listBatchTests',
2148
2231
  params: [
2149
2232
  "type: 'retell-llm' | 'conversation-flow';",
2150
2233
  'conversation_flow_id?: string;',
2234
+ 'limit?: number;',
2151
2235
  'llm_id?: string;',
2236
+ 'pagination_key?: string;',
2152
2237
  'version?: number;',
2153
2238
  ],
2154
- response: "{ creation_timestamp: number; error_count: number; fail_count: number; pass_count: number; response_engine: { llm_id: string; type: 'retell-llm'; version?: number; } | { llm_websocket_url: string; type: 'custom-llm'; } | { conversation_flow_id: string; type: 'conversation-flow'; version?: number; }; status: 'in_progress' | 'complete'; test_case_batch_job_id: string; total_count: number; user_modified_timestamp: number; }[]",
2155
- markdown: "## list-batch-tests\n\n`client.tests.listBatchTests(type: 'retell-llm' | 'conversation-flow', conversation_flow_id?: string, llm_id?: string, version?: number): object[]`\n\n**get** `/list-batch-tests`\n\nList batch test jobs for a response engine\n\n### Parameters\n\n- `type: 'retell-llm' | 'conversation-flow'`\n Type of response engine\n\n- `conversation_flow_id?: string`\n Conversation flow ID (required when type is conversation-flow)\n\n- `llm_id?: string`\n LLM ID (required when type is retell-llm)\n\n- `version?: number`\n Version of the response engine (defaults to latest)\n\n### Returns\n\n- `{ creation_timestamp: number; error_count: number; fail_count: number; pass_count: number; response_engine: { llm_id: string; type: 'retell-llm'; version?: number; } | { llm_websocket_url: string; type: 'custom-llm'; } | { conversation_flow_id: string; type: 'conversation-flow'; version?: number; }; status: 'in_progress' | 'complete'; test_case_batch_job_id: string; total_count: number; user_modified_timestamp: number; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst batchTestResponses = await client.tests.listBatchTests({ type: 'retell-llm' });\n\nconsole.log(batchTestResponses);\n```",
2239
+ response: "{ has_more?: boolean; items?: { creation_timestamp: number; error_count: number; fail_count: number; pass_count: number; response_engine: object | object | object; status: 'in_progress' | 'complete'; test_case_batch_job_id: string; total_count: number; user_modified_timestamp: number; }[]; pagination_key?: string; }",
2240
+ markdown: "## list-batch-tests\n\n`client.tests.listBatchTests(type: 'retell-llm' | 'conversation-flow', conversation_flow_id?: string, limit?: number, llm_id?: string, pagination_key?: string, version?: number): { has_more?: boolean; items?: batch_test_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-batch-tests`\n\nList batch test jobs with pagination\n\n### Parameters\n\n- `type: 'retell-llm' | 'conversation-flow'`\n Type of response engine\n\n- `conversation_flow_id?: string`\n Conversation flow ID (required when type is conversation-flow)\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `llm_id?: string`\n LLM ID (required when type is retell-llm)\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n- `version?: number`\n Version of the response engine (defaults to latest)\n\n### Returns\n\n- `{ has_more?: boolean; items?: { creation_timestamp: number; error_count: number; fail_count: number; pass_count: number; response_engine: object | object | object; status: 'in_progress' | 'complete'; test_case_batch_job_id: string; total_count: number; user_modified_timestamp: number; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { creation_timestamp: number; error_count: number; fail_count: number; pass_count: number; response_engine: { llm_id: string; type: 'retell-llm'; version?: number; } | { llm_websocket_url: string; type: 'custom-llm'; } | { conversation_flow_id: string; type: 'conversation-flow'; version?: number; }; status: 'in_progress' | 'complete'; test_case_batch_job_id: string; total_count: number; user_modified_timestamp: number; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst response = await client.tests.listBatchTests({ type: 'retell-llm' });\n\nconsole.log(response);\n```",
2156
2241
  perLanguage: {
2157
2242
  typescript: {
2158
2243
  method: 'client.tests.listBatchTests',
2159
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst batchTestResponses = await client.tests.listBatchTests({ type: 'retell-llm' });\n\nconsole.log(batchTestResponses);",
2244
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst response = await client.tests.listBatchTests({ type: 'retell-llm' });\n\nconsole.log(response.has_more);",
2160
2245
  },
2161
2246
  python: {
2162
2247
  method: 'tests.list_batch_tests',
2163
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nbatch_test_responses = client.tests.list_batch_tests(\n type="retell-llm",\n)\nprint(batch_test_responses)',
2248
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nresponse = client.tests.list_batch_tests(\n type="retell-llm",\n)\nprint(response.has_more)',
2164
2249
  },
2165
2250
  http: {
2166
- example: 'curl https://api.retellai.com/list-batch-tests \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
2251
+ example: 'curl https://api.retellai.com/v2/list-batch-tests \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
2167
2252
  },
2168
2253
  },
2169
2254
  },
@@ -2194,26 +2279,26 @@ const EMBEDDED_METHODS = [
2194
2279
  },
2195
2280
  {
2196
2281
  name: 'list-test-runs',
2197
- endpoint: '/list-test-runs/{test_case_batch_job_id}',
2282
+ endpoint: '/v2/list-test-runs/{test_case_batch_job_id}',
2198
2283
  httpMethod: 'get',
2199
2284
  summary: '',
2200
- description: 'List all test case jobs (test runs) for a batch test job',
2285
+ description: 'List test case jobs (test runs) for a batch test job with pagination',
2201
2286
  stainlessPath: '(resource) tests > (method) list-test-runs',
2202
2287
  qualified: 'client.tests.listTestRuns',
2203
- params: ['test_case_batch_job_id: string;'],
2204
- response: "{ creation_timestamp: number; status: 'in_progress' | 'pass' | 'fail' | 'error'; test_case_definition_id: string; test_case_definition_snapshot: object; test_case_job_id: string; user_modified_timestamp: number; result_explanation?: string; transcript_snapshot?: object; }[]",
2205
- markdown: "## list-test-runs\n\n`client.tests.listTestRuns(test_case_batch_job_id: string): object[]`\n\n**get** `/list-test-runs/{test_case_batch_job_id}`\n\nList all test case jobs (test runs) for a batch test job\n\n### Parameters\n\n- `test_case_batch_job_id: string`\n\n### Returns\n\n- `{ creation_timestamp: number; status: 'in_progress' | 'pass' | 'fail' | 'error'; test_case_definition_id: string; test_case_definition_snapshot: object; test_case_job_id: string; user_modified_timestamp: number; result_explanation?: string; transcript_snapshot?: object; }[]`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst testCaseJobResponses = await client.tests.listTestRuns('test_case_batch_job_id');\n\nconsole.log(testCaseJobResponses);\n```",
2288
+ params: ['test_case_batch_job_id: string;', 'limit?: number;', 'pagination_key?: string;'],
2289
+ response: "{ has_more?: boolean; items?: { creation_timestamp: number; status: 'in_progress' | 'pass' | 'fail' | 'error'; test_case_definition_id: string; test_case_definition_snapshot: test_case_definition_response; test_case_job_id: string; user_modified_timestamp: number; result_explanation?: string; transcript_snapshot?: object; }[]; pagination_key?: string; }",
2290
+ markdown: "## list-test-runs\n\n`client.tests.listTestRuns(test_case_batch_job_id: string, limit?: number, pagination_key?: string): { has_more?: boolean; items?: test_case_job_response[]; pagination_key?: string; }`\n\n**get** `/v2/list-test-runs/{test_case_batch_job_id}`\n\nList test case jobs (test runs) for a batch test job with pagination\n\n### Parameters\n\n- `test_case_batch_job_id: string`\n\n- `limit?: number`\n Maximum number of items to return.\n\n- `pagination_key?: string`\n Pagination key for fetching the next page.\n\n### Returns\n\n- `{ has_more?: boolean; items?: { creation_timestamp: number; status: 'in_progress' | 'pass' | 'fail' | 'error'; test_case_definition_id: string; test_case_definition_snapshot: test_case_definition_response; test_case_job_id: string; user_modified_timestamp: number; result_explanation?: string; transcript_snapshot?: object; }[]; pagination_key?: string; }`\n\n - `has_more?: boolean`\n - `items?: { creation_timestamp: number; status: 'in_progress' | 'pass' | 'fail' | 'error'; test_case_definition_id: string; test_case_definition_snapshot: { creation_timestamp: number; dynamic_variables: object; llm_model: string; metrics: string[]; name: string; response_engine: object | object; test_case_definition_id: string; tool_mocks: object[]; type: 'simulation'; user_modified_timestamp: number; user_prompt: string; }; test_case_job_id: string; user_modified_timestamp: number; result_explanation?: string; transcript_snapshot?: object; }[]`\n - `pagination_key?: string`\n\n### Example\n\n```typescript\nimport Retell from 'retell-sdk';\n\nconst client = new Retell();\n\nconst response = await client.tests.listTestRuns('test_case_batch_job_id');\n\nconsole.log(response);\n```",
2206
2291
  perLanguage: {
2207
2292
  typescript: {
2208
2293
  method: 'client.tests.listTestRuns',
2209
- example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst testCaseJobResponses = await client.tests.listTestRuns('test_case_batch_job_id');\n\nconsole.log(testCaseJobResponses);",
2294
+ example: "import Retell from 'retell-sdk';\n\nconst client = new Retell({\n apiKey: process.env['RETELL_API_KEY'], // This is the default and can be omitted\n});\n\nconst response = await client.tests.listTestRuns('test_case_batch_job_id');\n\nconsole.log(response.has_more);",
2210
2295
  },
2211
2296
  python: {
2212
2297
  method: 'tests.list_test_runs',
2213
- example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\ntest_case_job_responses = client.tests.list_test_runs(\n "test_case_batch_job_id",\n)\nprint(test_case_job_responses)',
2298
+ example: 'import os\nfrom retell import Retell\n\nclient = Retell(\n api_key=os.environ.get("RETELL_API_KEY"), # This is the default and can be omitted\n)\nresponse = client.tests.list_test_runs(\n test_case_batch_job_id="test_case_batch_job_id",\n)\nprint(response.has_more)',
2214
2299
  },
2215
2300
  http: {
2216
- example: 'curl https://api.retellai.com/list-test-runs/$TEST_CASE_BATCH_JOB_ID \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
2301
+ example: 'curl https://api.retellai.com/v2/list-test-runs/$TEST_CASE_BATCH_JOB_ID \\\n -H "Authorization: Bearer $RETELL_API_KEY"',
2217
2302
  },
2218
2303
  },
2219
2304
  },