https://retellai.com/?utm_source=discord&utm_medium=seo logo
whats the json format that retell expects when bat...
# ❓・ai-evy-support
s
@AI Evy whats the json format that retell expects when batch testing
a
Thanks for tagging me @shaurya51. I'll look through relevant sources and get back to you shortly.
​ To learn more, see the sources I considered: [[1] Create Batch Test](https://docs.retellai.com/api-references/create-batch-test) ​
### Answer To create a batch test via the API, the expected JSON format for the request body is: [(1) ]()
Copy code
json
{
  "response_engine": {
    "llm_id": "llm_id",
    "type": "retell-llm"
  },
  "test_case_definition_ids": ["string"]
}
Required fields: -
test_case_definition_ids
— an array of test case definition IDs to run (1–200 elements required) -
response_engine
— specifies the response engine to use (either
retell-llm
with an
llm_id
, or
conversation-flow
with a
conversation_flow_id
) Optional field: -
reserved_concurrency
— number of concurrency reserved for non-batch calls (integer, >= 0) The response returns a JSON object like:
Copy code
json
{
  "test_case_batch_job_id": "<string>",
  "status": "in_progress",
  "response_engine": {
    "type": "retell-llm",
    "llm_id": "<string>",
    "version": 0
  },
  "pass_count": 1,
  "fail_count": 1,
  "error_count": 1,
  "total_count": 1,
  "creation_timestamp": 123,
  "user_modified_timestamp": 123
}
For more details, see the [Create Batch Test]() documentation.
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
s
@AI Evy where do i find the llm id
a
Thanks for the follow-up, @shaurya51. I'll get back to you soon.
### Answer You can find the
llm_id
in a couple of ways: 1. From a Voice Agent's response engine: When you retrieve an agent, the
llm_id
is nested inside the
response_engine
object. [(1) ]()
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
  apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const agentResponse = await client.agent.retrieve('16b980523634a6dc504898cda492e939') ;
console.log(agentResponse.agent_id) ;
The response includes:
Copy code
json
"response_engine": {
  "type": "retell-llm",
  "llm_id": "llm_234sdertfsdsfsdf",
  "version": 0
}
2. Directly from the Retell LLM: If you already know your LLM ID, you can retrieve its details: [(2) ]()
Copy code
javascript
import Retell from 'retell-sdk';
const client = new Retell({
  apiKey: 'YOUR_RETELL_API_KEY',
}) ;
const llmResponse = await client.llm.retrieve('16b980523634a6dc504898cda492e939') ;
console.log(llmResponse.llm_id) ;
3. In the Retell Dashboard: The
llm_id
is also visible in your Retell dashboard when you view or create a Retell LLM Response Engine.
​ To learn more, see the sources I considered: [[1] Get Voice Agent](https://docs.retellai.com/api-references/get-agent) [[2] Get Retell LLM](https://docs.retellai.com/api-references/get-retell-llm) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.
s
@AI Evy can i set variables for example city_confirmed = city_raw in a transition
a
Thanks for the follow-up, @shaurya51. I'll get back to you soon.
### Answer Based on the available documentation, equation conditions in Conversation Flow transitions are designed for evaluating dynamic variables against values—not for assigning or setting variables. [(1) ]() Equation conditions support comparisons like:
Copy code
{{user_age}} > 18
{{user_location}} == "New York"
{{name}} exists
There is no documented syntax for assignment operations (like
city_confirmed = city_raw
) within transition conditions. To set or update dynamic variables during a conversation, you would typically need to: - Use a Function Node to call an external function that returns updated variable values - Pass dynamic variables at call initiation via
retell_llm_dynamic_variables
[(2) ]() If you need to "confirm" a variable value based on conversation context, consider using a function node that processes the logic and returns the confirmed value, which can then be used in subsequent nodes.
​ To learn more, see the sources I considered: [[1] Step 3: Add transition conditions](https://docs.retellai.com/build/conversation-flow/transition-condition) [[2] Dynamic Variables](https://docs.retellai.com/build/dynamic-variables) ​
Feel free to tag @AI Evy with additional questions. I also appreciate feedback, it helps me improve.