Discussions

Ask a Question
Back to all

Integrating Heygen interactive avatar (lip-sync) with Gemini TTS (gemini-2.5-flash-preview-native-audio-dialog) in TypeScript

Hello,

I’m building an interactive avatar using Heygen. I want to keep Heygen for the avatar video and lip-sync but use Google’s gemini-2.5-flash-preview-native-audio-dialog for text-to-speech**.

Questions:

  1. Can the avatar accept externally generated audio for lip-sync (instead of Heygen’s built-in voices)?
  2. If yes, what is the correct API/SDK entry point to stream or upload TTS audio so the avatar lip-syncs to it?
  3. Are there recommended audio formats, sample rates, or buffering requirements?

If anyone has implemented this with Gemini or another external TTS provider, guidance or example code would be very helpful.