Tool Timeout
# support
j
Hi! I been working on a endpoint, to connect with our voice agents, the thing was this actionable takes 15-20s to execute, the three first time running work fine, then VAPI starts responding with timeout and big delays, there's a way to increase this limit? Thanks a lot https://cdn.discordapp.com/attachments/1389736225799143434/1389736226197864610/image.png?ex=6865b438&is=686462b8&hm=386c3489615373706ef07c0e3311afef22d55d117b0c7e7953b866ba061b74a5& https://cdn.discordapp.com/attachments/1389736225799143434/1389736227057434796/image.png?ex=6865b438&is=686462b8&hm=720a7ce7c026f4790f4191f0a3d0a6c80f0c7153c69a80e9d17ff9c38a018474&
c
Hi julian, To address the tool timeout issue you're experiencing, you can increase the timeout setting for your tool using the Vapi API. You'll need to adjust the
timeoutSeconds
value in your assistant's configuration. Here's an example of how you can set up an API request with a longer timeout:
Copy code
json
{
  "type": "apiRequest",
  "function": {
    "name": "api_request_tool"
  },
  "name": "yourToolName",
  "url": "https://yourapiendpoint.com/action",
  "method": "GET", // or POST depending on your API
  "timeoutSeconds": 45 // adjust this value as needed
}
If your endpoint generally takes 15-20 seconds to execute, starting with a
timeoutSeconds
value of 45 seconds should provide enough buffer to handle the occasional longer response time. For more details on configuring API requests, you can refer to the [Default Tools documentation](https://docs.vapi.ai/tools/default-tools). Additionally, ensure that your server is properly handling requests and able to respond within the configured timeout period to prevent errors.
4 Views