About
Speechify Simba 3.0 turns text or SSML into natural speech. It is Speechify's default model and officially supports English plus German (de-DE), Spanish (es-ES, es-MX), French (fr-FR), Italian (it-IT) and Brazilian Portuguese (pt-BR). Infron serves it through the OpenAI-compatible POST /v1/audio/speech endpoint with mp3, wav, aac, pcm or ogg output and optional streaming. A request takes up to 2,000 spoken characters (20,000 when streaming) and is billed per spoken character; SSML tags are not counted.
1. Calling the API
Setup your API Key
To begin using Infron, create an account and generate your API Key.
export INFRON_KEY="YOUR_API_KEY"
Submit a request
Send JSON to POST https://llm.onerouter.pro/v1/audio/speech with your Infron API key. The request and response follow the OpenAI speech API, so the OpenAI SDKs work with the base URL https://llm.onerouter.pro/v1. The examples use the Speechify voice geffen_32. Replace YOUR_API_KEY with your key.
curl
curl https://llm.onerouter.pro/v1/audio/speech \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "speechify/simba-3.0/text-to-audio",
"voice": "geffen_32",
"input": "Hello! Welcome to Infron.",
"response_format": "mp3"
}' \
--output speech.mp3
Python (OpenAI SDK)
from openai import OpenAI
client = OpenAI(
base_url="https://llm.onerouter.pro/v1",
api_key="YOUR_API_KEY",
)
with client.audio.speech.with_streaming_response.create(
model="speechify/simba-3.0/text-to-audio",
voice="geffen_32",
input="Hello! Welcome to Infron.",
response_format="mp3",
) as response:
response.stream_to_file("speech.mp3")
TypeScript (OpenAI SDK)
import fs from "node:fs";
import OpenAI from "openai";
const client = new OpenAI({
baseURL: "https://llm.onerouter.pro/v1",
apiKey: "YOUR_API_KEY",
});
const response = await client.audio.speech.create({
model: "speechify/simba-3.0/text-to-audio",
voice: "geffen_32",
input: "Hello! Welcome to Infron.",
response_format: "mp3",
});
fs.writeFileSync("speech.mp3", Buffer.from(await response.arrayBuffer()));
Response
A successful request returns HTTP 200 with the audio file as the body, not JSON. Content-Type follows response_format: audio/mpeg for mp3, audio/wav for wav, audio/aac for aac, audio/pcm for pcm, audio/ogg for ogg. The examples above save it as speech.mp3.
Streaming
Add "stream_format": "sse" to receive Server-Sent Events while the audio is generated. Each speech.audio.delta event carries the next base64 chunk of the audio in response_format; decode the chunks and append them in order. The stream ends with a speech.audio.done event that reports usage. Infron streams from Speechify's timestamped stream; the word timestamps are not forwarded.
curl https://llm.onerouter.pro/v1/audio/speech \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR_API_KEY" \
-d '{
"model": "speechify/simba-3.0/text-to-audio",
"voice": "geffen_32",
"input": "Hello! Welcome to Infron.",
"response_format": "mp3",
"stream_format": "sse"
}' \
--no-buffer
data: {"type":"speech.audio.delta","audio":"<base64 audio chunk>"}
data: {"type":"speech.audio.delta","audio":"<base64 audio chunk>"}
data: {"type":"speech.audio.done","usage":{"input_tokens":25,"output_tokens":0,"total_tokens":25}}
In this example input_tokens is the billable character count of the input.
Routing and usage
This model is served by speechify (Speechify). Billing uses Speechify's billable character count: spoken characters only, without SSML tags and leading or trailing whitespace. The audio response carries no usage; with streaming, speech.audio.done reports the billable count as usage.input_tokens.
Errors
Parameters this model does not accept are rejected with HTTP 400 before the request is sent to Speechify, and nothing is charged. error.message explains the problem and ends with the request ID:
{
"error": {
"message": "voice is required (Speechify voice_id) (request id: 20261111221810441285700pZnPkvCJ)",
"type": "infron_ai_error",
"param": "",
"code": "invalid_request_error"
}
}
Errors reported by Speechify, such as an unknown voice ID, are returned with Speechify's message. If a stream fails after it has started, an error event is sent instead of speech.audio.done.
2. Schema
Input
| Parameter | Type | Required | Default | Range | Description |
|---|---|---|---|---|---|
model | string | Yes | -- | speechify/simba-3.0/text-to-audio | Model ID. |
input | string | Yes | -- | Up to 2,000 spoken characters and 20,000 characters including markup; with stream_format=sse, up to 20,000 spoken and 32,000 in total | Plain text or SSML wrapped in <speak>. SSML supports <break>, <prosody> (rate, pitch, volume) and <sub alias>; emphasis and emotion tags are accepted but not applied by Simba 3.x. |
voice | string | Yes | -- | -- | Speechify voice ID (sent as voice_id), for example geffen_32. Voice IDs come from Speechify's voice catalog (see Sources). |
response_format | string | No | mp3 | mp3, wav, aac, pcm, ogg | Audio format. Streaming supports mp3, aac, pcm and ogg (no wav). |
language | string | No | -- | BCP-47, e.g. en-US | Language of the input. When omitted, Speechify uses the voice's locale. |
text_normalization | boolean | No | true (false when streaming) | true, false | Expand numbers, dates and similar into words. Sent as options.text_normalization. |
stream_format | string | No | audio | audio, sse | sse streams Server-Sent Events (see Streaming). |
Speechify fields
These fields are not part of the OpenAI speech API. Put them at the top level of the JSON body; with the OpenAI Python SDK pass them in extra_body.
| Parameter | Type | Required | Default | Range | Description |
|---|---|---|---|---|---|
options | object | No | -- | -- | Speechify options: loudness_normalization (boolean, default false, normalizes to -14 LUFS) and text_normalization (boolean). |
output_format | string | No | -- | pcm_8000 to pcm_48000, mp3_22050_32 to mp3_24000_192, wav_24000, wav_48000, ulaw_8000, ogg_24000, aac_24000 | Speechify output format (codec, sample rate, bitrate). Takes precedence over response_format; wav_* is not available when streaming. |
pronunciations | array | No | -- | Up to 200 entries | Pronunciation overrides: each entry has text plus exactly one of ipa or alias, and optional case_sensitive. Simba 3.0 has no pronunciation languages, so Speechify rejects a non-empty list. |
Unsupported fields
| Field | Behavior |
|---|---|
speed | Rejected with 400 unless it is 1. Use SSML <prosody rate> in the input. |
instructions | Rejected with 400. Use SSML in the input. |
sample_rate, bit_rate | Ignored. Choose a sample rate and bitrate with output_format. |
| Other fields | Not forwarded to Speechify. |
Output
| Parameter | Type | Range | Description |
|---|---|---|---|
| Response body | binary | mp3, wav, aac, pcm, ogg | The audio file in response_format (without stream_format=sse). |
Content-Type header | string | audio/mpeg, audio/wav, audio/aac, audio/pcm, audio/ogg | MIME type of the audio. |
type | string | speech.audio.delta, speech.audio.done, error | Streaming event type. |
audio | string | Base64 | Next chunk of the audio (speech.audio.delta). |
usage.input_tokens | integer | Non-negative | Billable count of the input (speech.audio.done). |
usage.output_tokens | integer | 0 | Always 0 for this model. |
usage.total_tokens | integer | Non-negative | Sum of input and output. |
error | object | -- | message, type and code of a failure (error event). |
3. Detailed Pricing
| Model | Endpoint | Billing unit | Price |
|---|---|---|---|
| Speechify: Simba 3.0 | speechify | Per 1M characters | $10.00 |
Prices are in USD. Billing uses Speechify's billable character count: spoken characters only, without SSML tags and leading or trailing whitespace.
Sources: Create speech, Stream with timestamps, Models, Voices, Pricing.