generate-audio
Generate speech, voice-changed audio, or music from a text prompt. Provide a chat UUID and prompt, then retrieve the completed audio URL from the response.
Instructions
Generate audio (TTS, voice change, music) via syntx.ai. Mirrors syntx.audio.generate and the SPA ai-audio.sendMessage flow. Posts to POST /api/v1/audio/generate?ai_name={ai_name}. Requires a target chat UUID (use create-chat first). The result includes generation metadata returned by the API; follow up with wait-for-response or get-messages to read the completed audio URL once the model finishes.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| prompt | Yes | Text prompt describing the audio to produce. | |
| ai_name | No | Audio provider name (e.g. "elevenlabs", "suno-music"). Use `list-models` with scope=audio to discover valid values. | elevenlabs |
| duration | No | Target duration in seconds (music/clip models). | |
| voice_id | No | Voice identifier for TTS models (e.g. ElevenLabs voice_id). | |
| chat_uuid | Yes | Target chat UUID (create one with create-chat). | |
| file_urls | No | Optional input file URLs (e.g. source audio for voice-change). Mirrors the SPA `attachments` argument translated to `file_urls`. | |
| model_type | No | Model identifier within the provider. | |
| sample_rate | No | Sample rate override in Hz (e.g. 22050, 44100). | |
| style_prompt | No | Provider-specific style/mood hint (e.g. "pop, sad, rainy night"). | |
| model_settings | No | Provider-specific settings merged into `body.settings` after the top-level fields above. Use for keys the top-level surface does not expose (e.g. suno wants `mode`, `is_instrumental`, `styles`, `title`, `negative_tags`, `source_clip_id`, `source_task_id`, `continue_at`). Merged AFTER the top-level fields, so values here override them. Only plain JSON values are allowed; arrays and nested objects are passed through verbatim. |