Skip to main content
This page documents the original speech endpoint. Start new integrations at the TTS quickstart: the current endpoint lives at /v1/audio/speech, uses model mira-tts, streams, and takes the same sk_live_ key as the rest of the API.

What /tts/v1 does now

The URL keeps working. POST /tts/v1/audio/speech is an alias for POST /v1/audio/speech — the same handler, the same audio — so a caller that only changes its key needs no other change:
  • Auth is your sk_live_ API key, the one you mint in the console under Developers. The old mira_ speech keys are retired; if you are still holding one, get an sk_live_ key from the quickstart.
  • model is mira-tts, and mira-tts-v51 is accepted as an alias, so an existing body keeps working unchanged.
  • Everything else follows the current endpoint — voices, pcm streaming, the 2,000-character ceiling, the response headers, the price, the wallet it debits, and the request log. One contract, documented in one place.
  • The options below that were unique to this endpoint — speech_ready, instructions, lexicon and numbers — are no longer applied. They are ignored, not rejected.
The rest of this page describes the original endpoint as it behaved, for callers reading old code.

The original endpoint

The speech endpoint is the voice from our agents, on its own. Send text, get a WAV back. It takes the same request shape as the OpenAI audio API, so any OpenAI SDK works by swapping base_url and the key. The engine speaks Hindi, English and the Hinglish in between, plus Gujarati in beta. Five more languages — Telugu, Tamil, Marathi, Kannada and Bengali — arrive over the next two months: see the language roadmap.

Calling the alias

The old body, the new key:
The response body is the audio: 48 kHz mono PCM16, wav by default. Ask for "response_format": "pcm" and it streams, which is what you want in a live pipeline — see the TTS quickstart.

Request

Read as history. On the alias, model, input, voice and response_format behave as the TTS quickstart documents — input goes up to 2,000 characters and pcm streams — and the four fields below that are ours alone are ignored.
model is a stable public name, not the build number. It always points at the current production voice, which we upgrade underneath you — so a clip you generate today may sound better than one from last month without your code changing.

The rewrite pass

The rewrite pass is not part of the current endpoint. speech_ready, instructions and lexicon are ignored and no X-Mira-Speech-Ready header is returned. Send text you are happy to hear read aloud.
Raw text is rarely speech-ready. 97% should be read as “ninety-seven percent”, a product name should not be transliterated, and a bare URL should not be spelled out character by character. By default we run your text through a rewrite that fixes exactly that, preserving meaning, before it reaches the engine. Every response carries a header naming what happened: fallback is a degradation, never an error: you still get audio and still get a 200. If you are debugging pronunciation and the header says fallback, the rewrite is not what shaped that clip.
Skip the rewrite

Listing models

The list names one model — the current one:
mira-tts-v51 is still accepted in a request body; it is no longer listed.

Errors

Errors use the same envelope as the rest of the API — see Errors.
404 Not Found
The alias returns the current endpoint’s codes instead — invalid_request, unauthorized, insufficient_balance, at_capacity, rate_limited, model_not_found, upstream_error. See When something fails.

Using an OpenAI SDK

The shape matches, so point the client at us and keep your code:
lexicon, numbers, instructions and speech_ready are ours, not OpenAI’s. SDKs that validate their request body may reject them — send those with a plain HTTP client, or use extra_body where your SDK supports it.