aivini
11/06/2025, 10:51 AMhttps://api-channel-voice-${process.env.projectId}.europe-southwest1.run.app/api/synthesize,
credentialId: process.env.VAPI_CUSTOM_VOICE_CREDENTIAL_ID,
headers: {
'x-cache-id': sessionData.idCache,
'x-session-id': sessionData.sessionId
},
timeoutSeconds: 12
},
cachingEnabled: false,
chunkPlan: {
enabled: true
},
fallbackPlan: {
voices: [
{
"provider": "11labs",
"voiceId": "21m00Tcm4TlvDq8ikWAM"
}
]
}
};
finalAssistant.firstMessageMode = "assistant-speaks-first-with-model-generated-message";
finalAssistant.hooks = [
{
on: "customer.speech.timeout",
options: {
timeoutSeconds: 12, // dispara el idle a los 6s de silencio del usuario
triggerMaxCount: 3, // hasta 3 veces durante la llamada
triggerResetMode: "onUserSpeech"
},
do: [{
type: "say",
exact: ["¿Sigues ahí?", "¿Puedo ayudarte con algo más?"]
}]
}
];
}
https://cdn.discordapp.com/attachments/1435944637830271116/1435944638136451072/image.png?ex=69467fa8&is=69452e28&hm=744b6540d01cb0232bfd9326eb622fc9a07a20d641df090b9955272f48c42d28&Chiranjeet Mishra
11/10/2025, 12:52 AMhttps://api-channel-voice-441671391645.europe-southwest1.run.app/api/synthesize
failed to return audio. The logs show:
- The customer.speech.timeout hook fired correctly.
- Vapi attempted the say action.
- Speech synthesis failed (“Couldn't Generate Speech / Couldn't Get Speech”).
- Because the synthesis never succeeded, the say request could not be completed.
Shortly after, the call ended and Twilio’s WebSocket closed, which is why you see messages about not being able to send bytes — these are consequences, not causes.
---
✅ Root Cause
The failure came directly from your custom voice service. Possible reasons:
- The endpoint timed out (12-second timeout is set)
- The service was down or unreachable
- The response format wasn’t valid audio
- Credentials/headers failed
- The server returned an error status
---
✅ Fallback Not Used
Your fallback plan (ElevenLabs voice) should have been triggered, but the logs don’t show any fallback attempt, meaning the failure likely happened before the fallback mechanism was invoked.
---
✅ Next Steps
You’ll want to:
1. Check your custom TTS endpoint logs for errors at the timestamp around 2025-11-06T10:45:03.841Z.
2. Confirm the endpoint responds quickly enough (<12 seconds).
3. Test manually (e.g., curl) that the endpoint can synthesize the idle-message text.
4. Consider reducing complexity inside the custom TTS or increasing timeout temporarily.aivini
11/10/2025, 11:46 AMaivini
11/12/2025, 9:33 AMaivini
11/27/2025, 5:23 PMChiranjeet Mishra
12/19/2025, 12:34 AMidle messages as it is for say messages