hxssxn_21
12/22/2024, 9:30 AMAI Evy
12/22/2024, 9:30 AMAI Evy
12/22/2024, 9:30 AMAI Evy
12/22/2024, 9:30 AMjavascript
{
"type": "object",
"properties": {
"city": {
"type": "string",
"description": "The city of the weather"
}
},
"required": [
"city"
]
}
For arrays, you can structure it like this:
{
"type": "object",
"properties": {
"availabilities": {
"type": "array",
"description": "A list of time slots where the hcp is available",
"items": {
"type": "string"
}
}
},
"required": [
"availabilities"
]
}
[(2)]()
A few key points:
- The schema must include "type": "object" at the top level [(1)]()
- Properties should define the expected data types and descriptions
- You can specify which fields are required
If you're having trouble saving the function, it's likely due to invalid parameters. It's recommended to start with one of the examples and modify accordingly.AI Evy
12/22/2024, 9:30 AMhxssxn_21
12/22/2024, 9:31 AMAI Evy
12/22/2024, 9:31 AMAI Evy
12/22/2024, 9:31 AMAI Evy
12/22/2024, 9:31 AMjavascript
{
"name": "{{callerName}}",
"phone": "{{callerPhone}}",
"email": "{{callerEmail}}",
"reason": "{{callReason}}"
}
[(1)]()
Important notes:
- Don't include fields like $schema and title in your JSON - they are not needed by Retell
- The JSON structure should match the parameters you defined in your JSON schema
- The payload that Retell sends will contain the call info under the call object and your defined properties under argsAI Evy
12/22/2024, 9:31 AM