text-to-speech

Generate speech audio from text using HeyGen's Starfish TTS model. Use when: (1) Generating standalone speech audio files from text, (2) Converting text to speech with voice selection, speed, and pitch control, (3) Creating audio for voiceovers, narration, or podcasts, (4) Working with HeyGen's /v1/

By calesthio · 759 installs

npx skills add calesthio/openmontage --skill text-to-speech

Source repository · Upstream listing

Text to Speech (HeyGen Starfish) Generate speech audio files from text using HeyGen's in house Starfish TTS model. This skill is for standalone audio generation — separate from video creation. Authentication All requests require the X Api Key header. Set the HEYGEN API KEY environment variable. Tool Selection If HeyGen MCP tools are available ( mcp heygen ), prefer them over direct HTTP API calls. Task MCP Tool Fallback (Direct API) List TTS voices mcp heygen list audio voices GET /v1/audio/voices Generate speech audio mcp heygen text to speech POST /v1/audio/text to speech Default Workflow 1. List voices with mcp heygen list audio voices (or GET /v1/audio/voices ) 2. Pick a voice matching desired language, gender, and features 3. Call mcp heygen text to speech (or POST /v1/audio/text to speech ) with text and voice id 4. Use the returned audio url to download or play the audio List TTS Voices Retrieve voices compatible with the Starfish TTS model. Note: This uses GET /v1/audio/voices — a different endpoint from the video voices API ( GET /v2/voices ). Not all video voices support Starfish TTS. curl TypeScript Python Response Format Generate Speech Audio Convert text to speech audio using a specified voice. Endpoint POST https://api.heygen.com/v1/audio/text to speech Request Fields Field Type Req Description : : text string Y Text content to convert to speech voice id string Y Voice ID from GET /v1/audio/voices speed number Speech speed, 0.5 1.5 (default: 1) pitch integer Voice pitch, 50 to 50 (default: 0) locale string Accent/locale for multilingual voices (e.g., en US , pt BR ) elevenlabs settings object Advanced settings for ElevenLabs voices ElevenLabs Settings (optional) Field Type Description model string Model selection ( eleven v3 , eleven turbo v2 5 , etc.) similarity boost number Voice similarity, 0.0 1.0 stability number Output consistency, 0.0 1.0 style number Style intensity, 0.0 1.0 curl TypeScript Python Response Format Usage Examples Basic TTS With Speed Adjustment With Locale for Multilingual Voices Find a Voice and Generate Audio Pauses with Break Tags Use SSML style break tags in your text for pauses: Rules: Use seconds with s suffix: <break time="1.5s"/ Must have spaces before and after the tag Self closing tag format Expressive Voice Direction For narration, create a short voice performance plan before generating audio: narrator persona and emotional intent pacing profile energy curve across the script where pauses should land words or phrases that need emphasis Use concrete cues, not generic instructions. "Warm but decisive; pause before the contrast; slow down on the final sentence" is useful. "Sound natural" is not. When the selected voice supports pauses, put the most important pauses directly in the text with break tags. Generate a sample from the most performance heavy section first, and do not batch generate the rest if the sample sounds flat, rushed, or ignores the intended breaks. Best Practices 1. Use GET /v1/audio/voices to find compatible voices — not all voices from GET /v2/voices support Starfish TTS 2. Check support locale before setting a locale — only multilingual voices support locale selection 3. Keep speed between 0.8 1.2 for natural sounding output 4. Preview voices using the preview audio url before generating (may be null for some voices) 5. Use word timestamps in the response for caption syncing or timed text overlays 6. Use SSML break tags in your text for pauses: word <break time="1s"/ word