Tool Triggering Too Early – Need to Delay transfer...
# support
a
In our current setup, we’re using a tool called transfer_call that has a request_start message configured. However, the tool is being triggered before the assistant finishes delivering required dialogue — specifically, messages defined in task steps prior to the tool invocation (e.g., things like “Great, I will see if {{ agent_name }} is available…”). This results in the assistant interrupting itself mid-sentence when transitioning to the tool’s request_start message, which causes a disjointed user experience. What we’re trying to achieve: We want the assistant to first complete its response (any Say: line in the task instructions) and only after that proceed to trigger the tool. The ideal flow is: 1- AI completes all required verbal steps defined in the task. 2- Only after the full message is sent to the user, the transfer_call tool is triggered, and its request_start message begins. What I’d like to know: - Is there any flag, setting, or supported instruction pattern we can use to enforce this delay? - Can we explicitly instruct the model (via prompt or tool configuration) to never trigger a tool in the same generation as a Say: message? - Is there a best practice to control tool timing in cases where tools have their own internal spoken messages like request_start? Call example: - https://dashboard.vapi.ai/calls/ddc81b77-f0ef-479b-8509-4bd9400041a0 (just in Great. I will Let me check if an agent is available to assist you. Please hold while I look into this for you. the AI interrupts itself, and trigger request-start message) Let me know what options are available to achieve this sequencing (if any). Thanks in advance!
v
You can use the
ToolMessageStart.blocking=true
parameter to ensure your assistant completes its message before triggering the transfer_call tool. Here's how to implement it:
Copy code
json
{
  "tools": [
    {
      "type": "transferCall",
      "messages": [
        {
          "type": "request-start",
          "content": "Transferring the call now",
          "blocking": true
        }
      ]
      // other tool configuration
    }
  ]
}
This configuration ensures the assistant fully completes its current speech before executing the tool call. Source: - [Vapi Changelog](https://docs.vapi.ai/changelog/2025/2/4)
s
Is this on the dashboard or api
k
Configure the tool to wait for the response like, set "async": false or use "blocking": true, adjust speech configuration settings like waitSeconds, or add a Wait: step in the task sequence. This will allow the assistant to finish its speech before invoking the tool, preventing interruptions..