zubeyrahmed
10/04/2025, 8:23 PMAI Evy
10/04/2025, 8:23 PMAI Evy
10/04/2025, 8:23 PMtype and description for each property. Based on the documentation, here's the required format:
json
"parameters": {
"type": "object",
"properties": {
"address": {
"type": "string",
"description": "",
"enum": ["omar"]
}
},
"required": [
"address"
]
}
Each property in the parameters object must have a type field (like "string", "number", etc.) and a description field (which can be an empty string if needed, but the field must be present) .AI Evy
10/04/2025, 8:23 PMAI Evy
10/04/2025, 8:23 PMzubeyrahmed
10/04/2025, 8:24 PMzubeyrahmed
10/04/2025, 8:24 PMAI Evy
10/04/2025, 8:24 PMAI Evy
10/04/2025, 8:24 PMtype and description in your function parameters for several key purposes:
## LLM Decision Making
The LLM uses the description to understand when and how to call your function [(1) ]() . The description helps the agent decide if a function is needed based on the conversation context .
## Parameter Extraction
When the LLM determines a function should be called, it uses the type and description to extract the correct information from the conversation and structure it properly .
## JSON Schema Validation
Retell follows the JSON schema format for function definitions [(2) ]() . The parameters must be defined using JSON schema format, where each property requires both type and description fields .
## Function Execution Process
Here's how Retell processes your function parameters [(1) ]() :
1. **Agent Decision**: The LLM uses your function description to determine when the function is needed
2. **Parameter Extraction**: The agent extracts required information using the parameter definitions
3. **Function Execution**: Retell calls your function with the extracted parameters
4. **Response Handling**: The function result is processed and incorporated into the conversation
## Technical Implementation
Function calling uses structured JSON to communicate between the LLM and your systems :
json
{
"function": "book_appointment",
"arguments": {
"date": "2024-03-15",
"time": "14:00",
"customer_name": "John Smith"
}
}AI Evy
10/04/2025, 8:24 PMAI Evy
10/04/2025, 8:24 PMzubeyrahmed
10/10/2025, 5:26 PMAI Evy
10/10/2025, 5:27 PMAI Evy
10/10/2025, 5:27 PM{{variable_name}} syntax [(2) ]() . Dynamic variables work in tool configurations, including custom function URLs and property descriptions .
For example, if you need to pass data to a GET endpoint, structure it like:
<https://your-endpoint.com/api/get_data?user_id=%7B%7Buser_id%7D%7D&session=%7B%7Bsession_id%7D%7D>
The response from your GET function will be processed the same way as other HTTP methods - it will be converted to a string (with the 15,000 character cap) and sent to the LLM for further processing [(1) ]() .
**AI Evy
10/10/2025, 5:27 PMAI Evy
10/10/2025, 5:27 PM