Frequently asked questions
How do I get an API key?
Visit https://123ap.info/get-api-key/ to sign up using Google or an email and password. Accounts are per site. The page displays your active key, balance, and usage. You can issue a new key at any time, which immediately invalidates the old one.
What is the base URL?
The API base URL is https://api.123ap.info/v1. You send POST requests to https://api.123ap.info/v1/audio/speech. Other endpoints include GET /v1/voices and GET /v1/models for retrieving available voices, languages, formats, and pricing information.
Can I use the OpenAI SDK?
Yes. The request shape matches the OpenAI speech endpoint. You can use the official OpenAI SDKs by changing the base_url to https://api.123ap.info/v1 and providing your site-specific key. This allows seamless integration into existing workflows without custom code.
What formats are supported?
Supported response formats are mp3, wav, opus, flac, and pcm. You specify the desired format in the request body using the response_format field. This allows you to choose the best balance between file size and quality for your specific application needs.
How do I set the speed?
Use the speed parameter in your request body. Valid values range from 0.25 to 4.0. This allows you to adjust the speaking rate of the generated audio. The default speed is typically 1.0, but you can customize it for IVR or narration.
What is the character limit?
Each request supports up to 4096 characters in the input field. For longer texts, split the content into parts of this size and join the resulting audio files. Spaces and punctuation count toward the character limit used for billing calculations.
What happens on rate limit?
The limit is 60 requests per minute per key, or 10 per minute before the first top-up. Requests are processed sequentially, so under load, a request may wait in a queue. Failed requests do not consume your rate limit allowance.
How do I authenticate?
Include an Authorization header with the value Bearer followed by your API key. You receive one active key per account. If you issue a new key, the old one stops working immediately. Ensure your key is kept secure in your application environment.
Is there a webhook for status?
No. The API is synchronous. You send a request and receive the audio file directly in the response. There are no webhooks for status updates or notifications. You must handle any retry logic or status checking within your own application code.
Can I request JSON format?
No. The API returns audio files directly. The response format is determined by the response_format field (mp3, wav, opus, flac, pcm). There is no JSON response body containing audio data; the audio binary is returned in the HTTP response body.
How do I handle errors?
Failed requests are free: if synthesis fails, the charge is returned in full. You should check the HTTP status code of the response. If synthesis fails, no characters are deducted from your balance. Implement standard error handling for network issues or invalid parameters.
Do I need to install dependencies?
No. You can use plain HTTP requests or the official OpenAI SDK. If using the SDK, you only need to install that library. No proprietary SDK is required. The API works with standard web technologies and programming languages that support HTTP requests.
Is the API RESTful?
Yes. It uses standard HTTP methods like POST for speech generation and GET for retrieving voices and models. Resources are identified by URLs, and responses are standard HTTP responses. It follows RESTful principles for simplicity and ease of integration into various systems.
Can I stream the audio?
No. There is no streaming or WebSocket support for real-time partial audio. The entire audio file is generated and returned in a single response. You must wait for the full file to be ready before processing or playing it in your application.
First request
curl
curl https://api.123ap.info/v1/audio/speech \
-H "Authorization: Bearer $TTS_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model":"tts-1","voice":"aria","input":"Hello from the API.","response_format":"mp3"}' \
--output hello.mp3Python (openai)
from openai import OpenAI
client = OpenAI(base_url="https://api.123ap.info/v1", api_key="tts-...")
with client.audio.speech.with_streaming_response.create(
model="tts-1", voice="nova", input="Hello from Python.", response_format="mp3"
) as response:
response.stream_to_file("hello.mp3")Node.js (openai)
import OpenAI from "openai";
import fs from "node:fs";
const client = new OpenAI({ baseURL: "https://api.123ap.info/v1", apiKey: process.env.TTS_API_KEY });
const res = await client.audio.speech.create({ model: "tts-1", voice: "milo", input: "Hello from Node.js." });
fs.writeFileSync("hello.mp3", Buffer.from(await res.arrayBuffer()));| voice | |
|---|---|
aria | female |
nova | female |
luna | female |
sage | female |
felix | male |
milo | male |
atlas | male |
orion | male |
| language | |
|---|---|
ar | العربية |
zh | 中文 |
da | Dansk |
nl | Nederlands |
en | English |
fi | Suomi |
fr | Français |
de | Deutsch |
el | Ελληνικά |
he | עברית |
hi | हिन्दी |
it | Italiano |
ja | 日本語 |
ko | 한국어 |
ms | Bahasa Melayu |
no | Norsk |
pl | Polski |
pt | Português |
ru | Русский |
es | Español |
sw | Kiswahili |
sv | Svenska |
tr | Türkçe |
Authentication
Access the VoxPilot API by including your unique API key in the Authorization header of every request. Use the format Bearer tts-<your_key>. This key is generated when you create your account on /get-api-key/ and is required for all endpoints, including voice listing and model details.
Use Bearer token in header
Include the header Authorization: Bearer tts-... in your HTTP requests. The system validates this token against your account before processing any text-to-speech job. Ensure the key is sent exactly as generated, without extra spaces or quotes.
- Header name: Authorization
- Value format: Bearer tts-your_key_here
- Case-sensitive
One active key per account
Each account holds a single active API key. If you share this key across multiple servers or team members, all requests are attributed to that one account. There is no concept of multiple simultaneous keys for a single account.
Regenerate key if needed
If your key is exposed or you wish to rotate credentials, you can generate a new key from the dashboard. The old key stops working immediately. Ensure your systems are updated to use the new key before revoking the old one.
Endpoints
The API exposes three core endpoints to manage speech synthesis and asset discovery. The primary endpoint handles audio generation, while the secondary endpoints provide metadata about available voices and model configurations.
POST /v1/audio/speech
Send text to this endpoint to receive synthesized audio. The request body must be JSON containing the text input, selected voice, and desired format. Responses return the audio file directly in the body, allowing immediate playback or storage by your call center infrastructure.
GET /v1/voices
Retrieve a list of all available voice presets, their associated languages, supported output formats, and pricing details. This endpoint helps you programmatically select the appropriate voice for specific IVR prompts or accessibility content without hardcoding identifiers.
GET /v1/models
Fetch details about the current text-to-speech models (tts-1 and tts-1-hd). Use this to verify model availability and ensure your integration aligns with the latest engine capabilities and pricing structures for your volume requirements.
Request parameters
To generate audio, your request must include the model, input, and voice parameters. The API accepts tts-1 or tts-1-hd for identical engine performance and pricing. You can send up to 4,096 characters per request, with excess text handled by splitting and joining audio files.
model: tts-1 or tts-1-hd
Both model options use the same underlying engine and incur the same charge of $0.01 per 1,000 characters. Choose tts-1-hd if you prefer slightly higher fidelity, though the audible difference is minimal for IVR prompts.
input: text up to 4096 characters
Pass your script text in the input field. The field supports up to 4,096 characters. If your prompt exceeds this limit, split the text into chunks, generate each part, and concatenate the resulting audio files.
- Spatial punctuation and spaces count toward the character limit.
voice: one of 8 presets
Select one of eight licensed voices from recordings in the LibriTTS-R dataset. Options include aria (warm narrator), nova (bright), luna (soft), sage (calm), felix (energetic), milo (friendly), atlas (neutral), and orion (deep).
Every generated file contains an inaudible watermark marking it as synthetic speech. Voices can speak any of the 23 supported languages, including English, Spanish, German, and Japanese.
Response format
The API returns synthesized audio directly in the response body, allowing seamless integration into call center workflows and accessibility pipelines. You can choose from five standard formats: mp3, wav, opus, flac, or pcm, depending on your downstream processing needs. Each file is generated with an inaudible watermark to identify it as synthetic speech.
mp3, wav, opus, flac, pcm
Select your preferred output format via the response_format parameter. MP3 is efficient for web delivery, while WAV and FLAC offer lossless quality for archival or high-fidelity IVR systems. OPUS provides excellent compression for VoIP, and PCM is ideal for raw audio processing.
Audio file in response body
The generated audio data is returned directly in the HTTP response body. No additional download steps are required. The payload contains the binary audio data corresponding to the requested format, enabling immediate playback or storage in your application.
Standard HTTP status codes
Successful requests return a 200 OK status with the audio data. Client errors (4xx) indicate issues like invalid parameters or authentication failures. A 500 Internal Server Error indicates a server-side problem. Failed synthesis requests are free, ensuring you are not charged for unsuccessful attempts.
- 200 OK: Audio data returned
- 400 Bad Request: Invalid parameters
- 401 Unauthorized: Invalid API key
- 500 Internal Server Error: Server-side problem
Speed and language
Control the pacing of your IVR prompts or audio content by adjusting the speed parameter between 0.25 and 4.0. This allows you to fine-tune delivery for accessibility needs or faster call-handling workflows without altering the underlying voice model.
The API supports 23 languages, including Arabic, Chinese, English, Hindi, Spanish, and others. You can specify the language using an optional ISO code to ensure accurate pronunciation, especially for non-English texts using Latin script.
Speed: 0.25 to 4.0
Set the speed value to adjust the generation rate. Values below 1.0 slow down the speech, while values above 1.0 increase it. This feature is useful for creating clearer audio for elderly users or speeding up repetitive informational prompts in call centers.
- Minimum speed: 0.25
- Maximum speed: 4.0
- Standard speed: 1.0
Language: optional ISO code
While the system can guess the language, providing an explicit language parameter ensures consistent quality. This is particularly important for mixed-language content or when the input text uses Latin characters but is not in English.
- Supported: Arabic, Chinese, Danish, Dutch, English, Finnish, French, German, Greek, Hebrew, Hindi, Italian, Japanese, Korean, Malay, Norwegian, Polish, Portuguese, Russian, Spanish, Swahili, Swedish, Turkish.
- Not supported: Vietnamese, Indonesian, Thai, Ukrainian, Romanian, Czech, Bengali.
Auto-detection for Latin script
If you do not specify a language, the API attempts to detect it from the script. Text in Latin script defaults to English. For accurate results in other Latin-based languages like French or German, always set the language parameter explicitly.

Rate limits
Predictable scaling is critical for call center IVR systems. Our API enforces strict rate limits to ensure consistent performance during high-volume traffic, preventing sudden drops in audio generation quality when your team is processing thousands of prompts.
Understanding these limits helps you design robust retry logic and manage queue depths effectively, ensuring your IVR remains responsive even during peak hours.
60 requests per minute per key
Once your account is active, you can send up to 60 requests per minute. This capacity is sufficient for most mid-sized call center operations generating standard IVR menus and notification prompts.
Each request processes text up to 4096 characters. If your scripts are longer, split them into chunks and join the resulting audio files sequentially.
- Limit: 60 RPM per API key
- Process: Sequential queue under load
- Scope: Per active key
10 requests per minute initially
New accounts start with a lower limit of 10 requests per minute. This allows you to verify integration stability before scaling up your production traffic.
You can upgrade this limit immediately by adding funds to your account.
- Initial limit: 10 RPM
- Trigger: First top-up
Limits increase after top-up
Upgrading your rate limit requires a top-up of at least $5.00 via USDT (TRC-20). The increase is automatic and takes effect within minutes of confirmation.
Balance does not expire, and limits remain stable as long as your account is in good standing. Failed requests are free.
- Minimum top-up: $5.00
- Currency: USDT (TRC-20) only
- Effective time: Within minutes
OpenAI SDK compatibility
The API accepts standard request bodies compatible with the official OpenAI TTS client, allowing teams to integrate quickly by changing the base_url. This compatibility leverages existing SDK knowledge for rapid deployment in call center workflows.
Use official OpenAI SDK
Import the standard OpenAI library for your language. The official SDK handles authentication and serialization automatically, reducing boilerplate code for your engineering team.
Change base_url to our endpoint
Configure the client to point to https://api.123ap.info/v1. This directs all requests to our infrastructure while maintaining the standard request structure.
Standard request shape
Send a POST request with model, input, and voice parameters. The response returns the audio file directly, ensuring seamless integration with existing audio processing pipelines.
- Supports
tts-1andtts-1-hdmodels - Accepts standard voice presets like 'aria' or 'atlas'
Error handling
API responses include standard HTTP status codes to indicate success or failure. A 4xx code signals a client-side error, such as an invalid request format or authentication issue, while a 5xx code indicates a server-side problem during synthesis.
Errors are returned as JSON objects containing a clear message describing the issue. Failed synthesis requests are free, ensuring you are not charged for audio that was not successfully generated.
4xx and 5xx status codes
Common 4xx errors include 401 Unauthorized (invalid API key) and 429 Too Many Requests (rate limit exceeded). A 400 Bad Request indicates malformed JSON or missing required fields like model or input. Server errors return 500 or 503 codes.
- 401: Invalid or expired API key
- 429: Rate limit exceeded (check your key's limit)
- 503: Service temporarily unavailable during high load
Error messages in JSON
All error responses follow a consistent JSON structure. This allows automated systems in call center workflows to parse the error reason programmatically and log the specific cause for debugging.
Retry logic recommendations
For transient 5xx errors, implement exponential backoff with jitter. For 429 rate limit errors, wait until the window resets (60 requests/minute). Since requests are processed sequentially, brief delays between bursts help maintain throughput without hitting limits.
Listen to the 8 voices
Each sample below was generated by this API from the same sentence. Users should implement retry logic in their applications to handle brief interruptions gracefully during peak usage periods.
23 languages
Any voice speaks any of these languages.
Sources and further reading
- Wikipedia
- W3C WAI: making audio and video accessible
- LibriVox public-domain audiobooks
- MDN: Web Speech API
- OpenAI API reference: create speech
- ISO 639 language codes
- IETF RFC 7845: Ogg Opus
- FFmpeg documentation
- LibriTTS-R corpus (OpenSLR 141)
- Python documentation
- openai-node on GitHub
- TRON developer hub: TRC-20
