tool call response formatting not working - n8n
# support
m
Everything we try with the tool call response - even the simplest responses in the proper structure- are not getting picked up by vapi using n8n. What is the exact proper JSON response, it seems to break no matter what we send
v
The exact JSON response Vapi expects from your n8n webhook is:
Copy code
json
{
  "results": [
    {
      "toolCallId": "call_123",
      "result": "Your response as single-line string"
    }
  ]
}
Tips: - Always return HTTP 200, even for errors. - Ensure
toolCallId
matches the incoming request exactly, and keep the
result
value on a single line (no
\n
line breaks). For more details, see the [Custom Tools Troubleshooting documentation](https://docs.vapi.ai/tools/custom-tools-troubleshooting). Source: - [Custom Tools Troubleshooting documentation](https://docs.vapi.ai/tools/custom-tools-troubleshooting)
m
we have sent that and VAPI is not picking this up.
@Vapi Support Bot We sent exactly this and it is not working
v
Thank you for confirming you used the documented JSON format. Could you please check your Vapi dashboard's Call Logs or Webhook Logs and share any error messages or status codes you see for these tool calls? This will help pinpoint whether the issue is with the response format, HTTP status, or something else. For reference, common issues include not returning HTTP 200, toolCallId mismatches, or line breaks in the result ([see troubleshooting guide](https://docs.vapi.ai/tools/custom-tools-troubleshooting)). Source: - [Custom Tools Troubleshooting documentation](https://docs.vapi.ai/tools/custom-tools-troubleshooting)
c
Could you please share the affected call IDs?
m
019cdceb-872b-766e-b02a-1b1912e681fc
this marcoss guy is spaming here too
I am not getting a tool call result in the webhook responses.
019cdceb-872b-766e-b02a-1b1912e681fc
c
Hey Michael, We traced the issue - your n8n webhook is returning HTTP 200, but the JSON structure doesn't match what Vapi expects, which is why you're seeing "No result returned" immediately after. Here's the exact format Vapi requires: { "results": [
Copy code
{

  "toolCallId": "<exact ID from message.toolCalls\[0\].id>",

  "result": "your result as a string"

}
] } Two things to double-check in your n8n workflow: 1. The response must have a top-level
results
array - not
result
, not a bare object 2. The
toolCallId
must exactly match the ID sent in the incoming request (
message.toolCalls[0].id
) 3. The
result
value must be a string The most common n8n mistake is either missing the
results
wrapper or n8n double-wrapping the response in an extra array. Make sure your Respond to Webhook node is returning the structure above verbatim. Let us know if it's still not working after that and share a call ID - happy to dig further! Best, Vapi Support