Noah Johnson
09/09/2025, 4:25 PMassistant-ended-call rather than silence-timed-out or something else that indicates why the assistant ended the call. Trying to figure out a way around this.Noah Johnson
09/09/2025, 4:53 PMChiranjeet Mishra
09/11/2025, 2:52 PMcustomer.speech.timeout hook to handle periods of silence:
typescript
import { VapiClient } from "@vapi-ai/server-sdk";
const client = new VapiClient({ token: process.env.VAPI_API_KEY });
await client.assistants.create({
name: "Support Assistant",
hooks: [
{
on: "customer.speech.timeout",
options: {
timeoutSeconds: 10,
triggerMaxCount: 3,
triggerResetMode: "onUserSpeech"
},
do: [
{
type: "say",
exact: [
"Are you still there?",
"Can I help you with anything else?",
"I'm here whenever you're ready to continue."
]
}
],
name: "idle_message_check"
}
]
});
2. **Timeout and Triggering**:
- `timeoutSeconds`: Set this to how long you want to wait before triggering an idle message. Can be between 1-1000 seconds.
- `triggerMaxCount`: Maximum times the hook triggers per call.
- `triggerResetMode`: Choose whether the trigger count resets when the user speaks (onUserSpeech) or never.
3. **Best Practices**:
- Use concise and encouraging messages.
- For support calls, a timeout of 10-20 seconds is recommended.
These settings help re-engage users who might be distracted or experiencing audio delays, effectively reducing call abandonment during silent periods. Adjusting the timeout and trigger settings based on your scenario can further optimize user engagement.Noah Johnson
09/16/2025, 3:09 PMNoah Johnson
09/17/2025, 5:37 PMNoah Johnson
09/23/2025, 12:06 AMChiranjeet Mishra
09/23/2025, 3:10 PMendedReason field
However, note that most call ending should be handled through the assistant's actions or configurations rather than directly setting the end reason, as these are typically result codes rather than input parameters.Noah Johnson
09/23/2025, 8:14 PMasssitant-ended-call even when using the { "type": "tool", "tool": { "type": "endCall" } } tool. Shouldn't that show assistant-ended-call-with-hangup-task ?Noah Johnson
09/23/2025, 8:15 PMChiranjeet Mishra
09/25/2025, 7:09 PMNoah Johnson
09/30/2025, 5:23 PMNoah Johnson
10/08/2025, 6:19 PMNoah Johnson
10/27/2025, 3:11 PMChiranjeet Mishra
11/03/2025, 8:53 PMNoah Johnson
12/19/2025, 6:25 PM