Text to Speech
Convert text into natural-sounding speech with customizable voices and emotional delivery.
Try it out
Test the Text to Speech API directly in your browser with our interactive playground.
Overview
The Text to Speech API converts text into high-quality audio using advanced neural voice models. It supports multiple languages, voices, and emotional styles.
API Reference
Endpoint
POST https://api.tryvinci.com/vincitts
Headers
Name | Type | Description |
---|---|---|
X-User-ID | string | Required. Your user ID |
Request Parameters
Parameter | Type | Description |
---|---|---|
text | string | The text to convert to speech |
voice_id | string | The ID of the voice to use |
Response
{
url: string, // URL to the generated audio file
media_type: string, // "audio/wav"
user_id: string // The user ID used for the request
}
Code Examples
- Python
- JavaScript
import requests
url = "https://api.tryvinci.com/vincitts"
headers = {"X-User-ID": "your-user-id"}
data = {
"text": "Welcome to Vinci AI Studio!",
"voice_id": "voice_1"
}
response = requests.post(url, headers=headers, data=data)
result = response.json()
print(f"Audio URL: {result['url']}")
const response = await fetch('https://api.tryvinci.com/vincitts', {
method: 'POST',
headers: {
'X-User-ID': 'your-user-id',
'Content-Type': 'application/json',
},
body: JSON.stringify({
text: 'Welcome to Vinci AI Studio!',
voice_id: 'voice_1',
}),
});
const result = await response.json();
console.log(`Audio URL: ${result.url}`);
Voice Options
Available Voices
Choose from our library of pre-trained voices or use custom voice cloning.
Language Support
Supports 32+ languages with native-speaking voices.
Voice Customization
Control speech rate, pitch, and emotional style.
Best Practices
Text Formatting
Use punctuation to control pacing and intonation.
Audio Quality
Higher quality options available for professional use.
Performance
For real-time applications, use our optimized streaming endpoint with 75ms latency.