# Synthesize speech (query params) GET /v1/a/adapters/tts/{engine} Select code sample ``` const url = 'https://example.com/v1/a/adapters/tts/polly?format=mp3&fallback=true'; const options = {method: 'GET', headers: {Authorization: 'Bearer '}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ``` curl --request GET \ --url 'https://example.com/v1/a/adapters/tts/polly?format=mp3&fallback=true' \ --header 'Authorization: Bearer ' ``` - /v1/a/adapters/tts/{engine} Synthesizes speech from the query parameters and streams the audio. Either `text` or `text_b64` is required. ## Permission This operation needs the permission [`tts:synthesize:manage`](https://docs.aiva.apifonica.com/concepts/roles-and-permissions/#tts-synthesize-manage). ## Authorizations - **[bearerAuth](https://docs.aiva.apifonica.com/api/account/#bearerauth)** ## Parameters ### Path Parameters **engine** required string Allowed values: polly azure gc ya\_v3 techmo elevenlabs alfanum voxtream kugel TTS engine selector. ### Query Parameters **voice** string Voice id. Short alias `v`. **language** string Language code. Short alias `l`. **text** string Plain text to synthesize. Required unless `text_b64` is set. **text\_b64** string Base64-encoded text. Required unless `text` is set. **speed** string Speech speed. Short alias `s`. **format** string default: mp3 Audio format. Short alias `f`. Defaults to `mp3`. **sampleRate** integer Sample rate in Hz. Short alias `sr`. **model** string Provider model. Short alias `m`. **fallback** boolean default: true Allow voice fallback. Short alias `fb`. Defaults to `true`. **v** string Short alias for `voice`. **l** string Short alias for `language`. **s** string Short alias for `speed`. **f** string Short alias for `format`. **sr** integer Short alias for `sampleRate`. **m** string Short alias for `model`. **fb** boolean Short alias for `fallback`. **advanced\_settings** Provider-specific free-form synthesis settings, supplied as dot-delimited nested query keys of the form `advanced_settings.
.=` (alias prefix `as`), e.g. `as.s.param1=100`. The keys are flattened into a nested object per section; the accepted sections and keys are provider-specific. object ***key*** additional properties any **skip\_uri\_length\_validation** boolean Skip the freeswitch URI length guard when `true`. ## Responses ### 200 Synthesized audio stream. Select media type string format: binary string format: binary #### Headers **X-Cache** string `1` on cache hit, `0` otherwise. **Content-Disposition** string ### 400 Error response. Media typeapplication/json object **code** required string **reason** required string **message** required string ##### Examplegenerated ``` { "code": "example", "reason": "example", "message": "example" } ``` ### 401 Unauthorized ### 403 Forbidden ### 429 Error response. Media typeapplication/json object **code** required string **reason** required string **message** required string ##### Examplegenerated ``` { "code": "example", "reason": "example", "message": "example" } ``` ### 502 Error response. Media typeapplication/json object **code** required string **reason** required string **message** required string ##### Examplegenerated ``` { "code": "example", "reason": "example", "message": "example" } ```