TransferCall Not working, fails to patch
# support
g
I get {"message":["voice.property tools should not exist"],"error":"Bad Request","statusCode":400} When trying to patch the Assistant with transfer call, what am I doing wrong, text file with JSON attached https://cdn.discordapp.com/attachments/1316434353257189427/1316434353827348631/transferCall.txt?ex=675b0888&is=6759b708&hm=67f37c544ed0a2ee5fdad55854b2db55f16cd1c87583f8fc329311b8d1aeb90e&
v
@Graham It seems like there might be an issue with the JSON structure you're using to patch the Assistant with the transfer call functionality. The error message indicates that there's an unexpected "voice.property" field present in your JSON request. To assist you better, I would need to see the actual JSON content you're trying to patch. Could you please provide the relevant section of the JSON file that includes the transfer call configuration? This will help me understand what might be causing the error and guide you on how to fix it.
You can continue this conversation by mentioning me in the message.
g
{ "id": "xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "orgId": "xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "name": "Person from Organization", "voice": { "model": "eleven_turbo_v2_5", "tools": [ { "type": "transferCall", "destinations": [ { "type": "number", "number": "+441234567890", "message": "I am forwarding your call to our office line, please hold on" }, { "type": "number", "number": "+441234567891", "message": "I am forwarding your call to my Human. Please stay on the line." }, { "type": "number", "number": "+441234567892", "message": "I am forwarding your call to the Science Department. Give me a second" } ], "function": { "name": "transferCall", "description": "Use this function to transfer the call. Only use it when following instructions that explicitly ask you to use the transferCall function. DO NOT call this function unless you are instructed to do so.", "parameters": { "type": "object", "properties": { "destination": { "type": "string", "enum": [ "+441234567890", "+441234567891", "+441234567892" ], "description": "The destination to transfer the call to." } }, "required": [ "destination" ] } }, "messages": [ { "type": "request-start", "content": "I am forwarding your call to Department A. Please stay on the line.", "conditions": [ { "param": "destination", "operator": "eq", "value": "+1111111111" } ] },
attached txt file has full JSON, i can send un-anonimised if needs be
@Vapi { "id": "xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "orgId": "xxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx", "name": "Person from Organization", "voice": { "model": "eleven_turbo_v2_5", "tools": [ { "type": "transferCall", "destinations": [ { "type": "number", "number": "+441234567890", "message": "I am forwarding your call to our office line, please hold on" }, { "type": "number", "number": "+441234567891", "message": "I am forwarding your call to my Human. Please stay on the line." }, { "type": "number", "number": "+441234567892", "message": "I am forwarding your call to the Science Department. Give me a second" } ], "function": { "name": "transferCall", "description": "Use this function to transfer the call. Only use it when following instructions that explicitly ask you to use the transferCall function. DO NOT call this function unless you are instructed to do so.", "parameters": { "type": "object", "properties": { "destination": { "type": "string", "enum": [ "+441234567890", "+441234567891", "+441234567892" ], "description": "The destination to transfer the call to." } }, "required": [ "destination" ] } }, "messages": [ { "type": "request-start", "content": "I am forwarding your call to Department A. Please stay on the line.", "conditions": [ { "param": "destination", "operator": "eq", "value": "+1111111111" } ] },
v
@Graham Based on the JSON snippet you've provided, it appears that the structure of your JSON is correct in terms of nesting and syntax. However, the error message you're receiving suggests that there might be an issue with the schema expected by the API. The error message
{"message":["voice.property tools should not exist"],"error":"Bad Request","statusCode":400}
indicates that the API does not expect a
tools
property within the
voice
object. This could mean that the API's expected schema for a PATCH request does not include a
tools
field at all, or that it should be structured differently. Here are a few steps you can take to resolve this issue: 1. **Check the API Documentation**: Ensure that you are following the correct schema as per the API documentation for patching an Assistant with a transfer call. There might be specific guidelines on how to structure the
transferCall
data. 2. **Validate JSON Schema**: If you have access to the JSON schema that the API expects, validate your JSON against that schema to ensure it matches the expected structure. 3. **Remove Unnecessary Fields**: If the
tools
field is not expected within the
voice
object, you may need to remove it and place the
transferCall
configuration in the correct location as per the API's requirements. 4. **Contact Support**: If you're unable to resolve the issue by checking the documentation or adjusting the JSON structure, it may be best to contact the API support team for guidance. If you can share the API documentation or the expected schema, I can provide more specific advice on how to adjust your JSON. Otherwise, please refer to the API documentation or reach out to the API support team for further assistance.
g
@Graham attached txt file has full JSON, i can send un-anonimised if needs be
s
@Graham the error message is self explanatory the LLM expects tools as on of it's property nnokkkk, whereas Voice Deson't/
If you require further help do let me know.
2 Views