#Can I trigger a tool at the end of a call?
1 messages · Page 1 of 1 (latest)
Yes, you can trigger a tool at the end of a call. For example, you can set up a client tool to send an end_call event to your server to handle the call termination. However, there are some considerations:
-
Timing of the Tool Call: If the tool call event is received before the final audio is sent, you might need to implement a slight delay (e.g., 1-2 seconds) before executing the
end_callevent. This ensures the final phrase, like "goodbye," is sent before the call ends. -
Built-in
end_callTool: ElevenLabs offers a built-inend_calltool, but it is currently only configurable through the web interface and not via the API. If you need this feature through the API, you can share your feedback for future updates. -
Custom Tools: If you're using a custom tool to end the call, ensure the setup aligns with your backend logic. Note that custom tools may sometimes result in unexpected behavior, such as repeated audio after the tool invocation.
If you'd like more details or assistance with your specific setup, feel free to provide additional information!
I want that the agen triggers the tool just before the call ends