Frequently asked questions
How do I get my API key?
Sign up on the /get-api-key/ page using Google or an email and password. Your account is specific to this site. Once registered, you receive a Bearer token starting with 'tts-' to authenticate your requests. You can issue a new key at any time, which immediately invalidates the previous one.
Can I use the OpenAI SDK with your API?
Yes. Our endpoint matches the OpenAI speech endpoint shape. Simply change the SDK's base_url to https://api.play66mb.com/v1 and use your Civichord API key. This allows you to use official OpenAI SDKs without needing a custom client library or complex configuration adjustments.
What is the maximum text length per request?
Each request supports up to 4096 characters of input text. For longer documents, split your text into chunks of this size and join the resulting audio files. Spaces and punctuation count toward this character limit, so plan your splits accordingly to ensure complete sentences.
How do I set the voice language?
Send the optional 'language' field with an ISO code in your JSON body. If omitted, the system guesses the language, defaulting to English for Latin script. Explicitly setting the language is recommended for non-English text to ensure accurate synthesis across our 23 supported languages.
What happens if I exceed the rate limit?
You are limited to 60 requests per minute per key (10 per minute before the first top-up). Requests are processed sequentially, so exceeding limits may cause delays as your request waits in the queue. Failed requests are free.
Can I change my API key?
Yes, you can issue a new API key at any time from your account dashboard. When you generate a new key, the old one stops working immediately. This ensures secure access management for your government team or NGO without needing to wait for manual approval.
How do I handle audio streaming?
We do not offer streaming, WebSocket, or real-time partial audio. The API is synchronous: you send text and receive the complete audio file in the response. For long texts, you must split the input, generate each part, and join the files on your end.
Is the API synchronous or asynchronous?
The API is synchronous. You send a POST request and wait for the complete audio file in the response. Requests are processed one after another, so under load, your request may wait in a queue. This ensures you receive the full file before proceeding.
Do I need to install a specific SDK?
No. You can use the official OpenAI SDKs by adjusting the base_url, or use plain HTTP requests. We do not provide a proprietary SDK, mobile SDK, or WordPress plugin. Standard HTTP libraries in any language are sufficient to integrate our text-to-speech capabilities into your workflow.
How do I detect errors in the response?
Check the HTTP status code and response body for error details. Failed synthesis requests are free, meaning the charge is returned in full. You can also monitor your usage dashboard for any anomalies. Ensure your input text is within the 4096-character limit to avoid errors.
Can I use the same key for multiple projects?
Yes, one active key per account can be used across multiple projects. The rate limit of 60 requests per minute applies to the key itself, shared across all uses. You can monitor your usage and characters left directly from the account dashboard to manage load.
How do I calculate character count accurately?
Count every character, including spaces and punctuation. The price is $0.01 per 1,000 characters. Ensure your text does not exceed 4096 characters per request. Accurate counting helps you manage your budget effectively, especially when processing large documents for public announcements or accessible content.
Is the API available 24/7?
We do not provide an SLA or uptime guarantee. The API is generally available, but requests may queue under load. For critical government services, consider implementing retry logic in your integration to handle potential delays or temporary unavailability without disrupting your workflow significantly.
How do I test my integration?
Sign up to receive $0.50 in trial credit, valid for 7 days. Use the provided curl example on the /get-api-key/ page to send a test request. This allows you to verify voice selection, language settings, and audio format outputs before committing to larger document processing tasks.
First request
curl
curl https://api.play66mb.com/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.play66mb.com/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.play66mb.com/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
The API key is the sole credential for authenticating your requests. Generate yours on the /get-api-key/ page by signing in with Google or creating an email account. Each account holds one active key at a time, which appears alongside your balance and usage statistics.
API Key Generation
Keys are created instantly upon account setup. Use the key displayed in your dashboard for all API calls. If you lose access or suspect a breach, you can generate a new key immediately.
Bearer Token Format
Include your key in the Authorization header using the Bearer scheme. The format is Authorization: Bearer tts-your-api-key-here. Ensure no extra spaces or characters are included in the token string.
Key Rotation
You may issue a new key at any time via the dashboard. When a new key is generated, the previous one stops working immediately. This ensures tight control over access for large government teams without waiting for expiration periods.
Base URL
All API requests are directed to https://api.play66mb.com/v1. This base URL serves as the foundation for both the speech synthesis endpoint and the metadata endpoints that list available voices and models. Using a consistent base ensures your government or NGO applications can easily switch between standard HTTP calls and our compatible SDK wrappers.
Endpoint Structure
The primary endpoint for generating audio is POST https://api.play66mb.com/v1/audio/speech. This endpoint accepts JSON payloads containing your text, chosen voice, and desired output format. For management tasks, such as retrieving the list of 23 supported languages and 8 voice presets, use GET https://api.play66mb.com/v1/voices.
OpenAI SDK Compatibility
Our endpoint structure mirrors the OpenAI speech API, allowing you to use the official OpenAI SDKs with minimal configuration. Simply update the base_url to https://api.play66mb.com/v1 and provide your Civichord API key. This compatibility lets government teams leverage existing codebases and familiar developer workflows without learning a new proprietary protocol.
Versioning
The API version is embedded directly in the base URL path (/v1/). Currently, we support version 1 of the speech endpoint. By including the version in the path, we ensure clear separation between different API iterations. If we introduce breaking changes in future versions, they will be accessible via new path segments (e.g., /v2/).
Request Parameters
The API accepts text input up to 4,096 characters per request. For longer documents, split the text into chunks and join the resulting audio files. Spaces and punctuation count toward this limit.
Use "tts-1" for standard quality or "tts-1-hd" for enhanced clarity. Both engines use the same pricing and voice presets.
Model Selection
Select "tts-1" for standard generation or "tts-1-hd" for higher fidelity. Both models share identical pricing and voice options, allowing you to switch without changing your integration logic.
- tts-1: Standard quality, real-time speed
- tts-1-hd: Enhanced clarity, same price
Input Text Limits
Each request supports a maximum of 4,096 characters. Longer texts must be split into smaller segments. The API does not handle chunking automatically; your application should join the resulting audio files.
Voice Selection
Choose from eight presets tailored for clear public communication. Voices include female options like Aria and Nova, and male options like Felix and Atlas. Any voice can speak any of the 23 supported languages.
- Aria: Warm, clear narrator
- Nova: Bright, upbeat
- Felix: Energetic, promo
- Atlas: Neutral, news
Response Formats
The API returns audio files in five standard formats, allowing you to choose the best balance between file size and compatibility for your government or NGO distribution channels. Each request must specify the desired format via the response_format parameter.
MP3 Output
MP3 is one of the available formats and offers the best compression for web delivery and mobile apps. It is ideal for public announcement systems where bandwidth might be limited, ensuring fast loading times for digital signage or online accessibility portals.
WAV Output
WAV provides uncompressed audio. Use this format when you need pristine quality for archival purposes or integration with legacy broadcasting equipment that does not support compressed codecs. Files will be larger, so plan your storage accordingly.
Opus and FLAC Options
Opus offers superior compression for voice, making it excellent for low-bandwidth mobile data connections in field operations. FLAC provides lossless compression, retaining all audio data, suitable for high-quality internal archives.
Speed Control
The API accepts a speed parameter ranging from 0.25 to 4.0, allowing government teams to precisely adjust the playback rate of generated audio files. This feature ensures that public announcements, emergency alerts, or accessible content for visually impaired citizens are delivered at a comfortable, understandable pace.
Speed Range
Values below 1.0 slow the speech, while values above 1.0 accelerate it. The default speed is 1.0. You can fine-tune this for different dialects or accessibility needs within the 23 supported languages.
Adjusting Pace
Include the speed field in your JSON request body alongside model, input, and voice. For example, set speed: 0.8 for slower, clearer announcements in community settings, or speed: 1.2 for quick status updates.
Impact on Quality
Extreme speeds may slightly alter natural intonation but remain intelligible. Requests are processed sequentially, so under load a request may wait in a queue.

Error Handling
When a request fails, the API returns an error code and the charge is returned in full. This ensures you are never billed for audio that was not successfully generated. Common issues include invalid model names or exceeding the 4096 character input limit.
Common Error Codes
Use standard HTTP status codes to diagnose issues. A 400 error indicates invalid parameters, such as an unsupported voice or format. A 401 error means your API key is missing or invalid. A 500 error suggests a temporary server issue, which you can retry.
- 400 Bad Request: Invalid input parameters.
- 401 Unauthorized: Invalid or expired API key.
- 500 Internal Server Error: Temporary service issue.
Rate Limit Errors
You are limited to 60 requests per minute per key. If you exceed this, you receive a 429 Too Many Requests error. New accounts start with a 10 requests per minute limit until the first top-up is processed.
- Standard limit: 60 requests/minute.
- New account limit: 10 requests/minute.
- Limit resets every 60 seconds.
Retry Logic
Implement exponential backoff for 429 and 500 errors. Since requests are processed sequentially, long texts may queue behind other users. Retry after a short delay to avoid overwhelming the queue during peak usage.
- Use exponential backoff for retries.
- Retry on 429 and 500 errors.
- Wait briefly to respect queue order.
Rate Limits
The API enforces a strict rate limit of 60 requests per minute per key, ensuring stable performance for large government teams. Before your first top-up, this limit is lower at 10 requests per minute, which is suitable for initial testing but may require pacing during bulk audio generation projects.
Requests Per Minute
Each API key is capped at 60 requests per minute. This limit applies across all concurrent connections from your account. If you exceed this threshold, the API will reject further requests until the window resets.
- Standard limit: 60 requests/minute.
- Pre-top-up limit: 10 requests/minute.
- Limit is per key, not per IP.
Queue Behavior
Requests are processed sequentially. Under heavy load, your synthesis job may wait in a queue before processing begins. Longer texts take more time to generate, roughly real-time speed, so plan your submission schedule accordingly to avoid delays in your announcement pipeline.
Burst Limits
There is no separate hard burst limit beyond the per-minute cap. However, sudden spikes in traffic may cause temporary throttling if the server is already busy processing previous requests. For consistent throughput, space out your API calls evenly rather than sending them all at once.
Example Code
Integrate public announcement systems quickly with these ready-to-use snippets. Use the provided curl command for immediate testing or embed the Python and JavaScript examples directly into your internal tools for automated document-to-audio workflows.
Ensure your API key is correctly formatted as a Bearer token in the Authorization header. These examples demonstrate the standard request structure compatible with the OpenAI SDK or raw HTTP clients.
Curl Example
Send a simple synthesis request to generate MP3 audio from text. Replace YOUR_API_KEY with your actual key from the dashboard.
Python OpenAI SDK
Use the official OpenAI Python library by pointing it to our base URL. This allows you to handle audio bytes directly in your Python scripts for backend processing.
JavaScript Example
Integrate TTS into web dashboards or notification systems using the fetch API. The example shows how to handle the audio stream response for immediate playback or download.
Listen to the 8 voices
Each sample below was generated by this API from the same sentence. Each account has one active key, which can be regenerated at any time.
23 languages
Any voice speaks any of these languages.
