Local text-to-speech with 31 languages & 10 built-in voices
Server v{{ versions.server }} · supertonic3 v{{ versions.supertonic3 }}
OpenAI-compatible TTS API. Use any OpenAI TTS client by pointing it to this server.
/health
Health check endpoint for container orchestration and monitoring.
{
"status": "healthy",
"model_loaded": true,
"sample_rate": 44100
}
/v1/voices
List all available built-in voices.
{
"object": "list",
"data": [
{"id": "M1", "name": "M1", "object": "voice", "type": "builtin"},
{"id": "F1", "name": "F1", "object": "voice", "type": "builtin"}
]
}
/v1/audio/speech
Generate speech audio from text. OpenAI-compatible endpoint.
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
input |
string | ✓ | - | The text to generate speech from |
voice |
string | M1 |
Voice ID. See /v1/voices
|
|
model |
string | - | Ignored (for OpenAI compatibility) | |
response_format |
string | mp3 |
Audio format: mp3, opus,
aac, flac, wav,
pcm
|
|
stream |
boolean | false |
Enable streaming response | |
lang |
string | en |
Language code for pronunciation |
curl -X POST http://localhost:7860/v1/audio/speech \
-H "Content-Type: application/json" \
-d '{
"input": "Hello world!",
"voice": "M1",
"response_format": "mp3"
}' \
--output speech.mp3
from openai import OpenAI
client = OpenAI(
base_url="http://localhost:7860/v1",
api_key="not-needed"
)
response = client.audio.speech.create(
model="tts-1",
voice="M1",
input="Hello world!"
)
response.stream_to_file("output.mp3")
Audio file in the requested format (binary stream).
Content-Type: audio/mpeg,
audio/wav, audio/opus, etc.
{
"error": "Missing required field: input"
}
10 voices available: M1-M5 (male), F1-F5 (female)