POST /v1/audio/speech request shape. Moving an existing OpenAI TTS integration takes three changes: the base URL, the API key, and the model name. The same three settings fill in the “OpenAI-compatible TTS” option of any app or plugin.
Boson preset
For an app that stores presets:
429 insufficient_quota.
Use the OpenAI SDK
Change the base URL and the key. Theaudio.speech.create call is unchanged.
What maps and what differs
extra_body in Python or as extra properties in TypeScript.
stream in extra_body:
Errors an OpenAI client does not expect
The error body has the OpenAI shape, so existing handlers run. Two cases differ:429is not always a rate limit.error.typeisinsufficient_quotawhen the account has no credit, and retrying cannot help. Onlyrate_limit_erroris transient. See Common error types.400 invalid_field_valuenames a field you may not have set on purpose: a two-letterlanguage, a tag that is not on the Tags list, or a voice name carried over from OpenAI. Showerror.messageto the user.
Checklist for a Boson preset
- Base URL
https://api.boson.ai/v1, Bearer key, modelhiggs-tts-3. voiceas free text, defaulting todefault, so users can paste avoice_<id>. For per-character voices, create one custom voice per character once and cache the IDs rather than sendingref_audioon every request.- Do not send
languageunless the user set it explicitly, and then as ISO 639-3. response_formatwavormp3;pcmplusstream: truefor streaming.- Drop or hide
speedandinstructions. If you offer a delivery dropdown, build it from the Tags page and send the tag ininput. - Surface
error.messageon400and429.