Issue with Vapi Tools section
# support
t
Hi Everyone, I'm having issues with Tools sections of the ai agents. I have set up a tool that sends a request n8n to receive some data . the request is sent successfully but the response sent back doesnt show in vapi even though i'm certain a response is sent. the response is sent back in following way : [ { "results": [ { "toolCallId": "", "result": { "exists": true, "first_name": "", "last_name": "", "address": "", "unit_number": "" } } ] } ] I would apperciate some help. Thank you 🙂
v
Suggestion: Make sure your response includes the correct
toolCallId
from the incoming Vapi request. Here’s an example of the correct response format:
Copy code
json
{
  "results": [
    {
      "toolCallId": "REPLACE_WITH_ACTUAL_ID",
      "result": {
        "exists": true,
        "first_name": "",
        "last_name": "",
        "address": "",
        "unit_number": ""
      }
    }
  ]
}
Replace
"REPLACE_WITH_ACTUAL_ID"
with the actual
toolCallId
from the request payload. This should allow Vapi to match and display the response correctly. Source: - [Custom Tools Vapi Documentation](https://docs.vapi.ai/tools/custom-tools)
t
@Vapi Support Bot I include this already in my code as seen in the logs in provided
v
If you're already including the correct
toolCallId
in your response, double-check that the value is not empty and matches exactly what Vapi sends in the incoming request payload. For example:
Copy code
json
{
  "results": [
    {
      "toolCallId": "actual_tool_call_id_from_request",
      "result": { "exists": true, "first_name": "", "last_name": "", "address": "", "unit_number": "" }
    }
  ]
}
If the
toolCallId
is empty or mismatched, Vapi will not display the response. Make sure to extract and return the exact value from the incoming request.
[See the official documentation for reference.](https://docs.vapi.ai/tools/custom-tools) Source: - [Custom Tools Vapi Documentation](https://docs.vapi.ai/tools/custom-tools)
5 Views