Frequently asked questions
What is a text-to-speech JavaScript library?
A text-to-speech JavaScript library is a code package that simplifies sending text to a TTS API and handling the returned audio. For Kuyaking API, you can use the official OpenAI SDKs by changing the base URL to https://api.kuyaking.info/v1. This allows you to generate audio files directly from your JavaScript applications without building custom HTTP clients.
Does this API support OpenAI SDKs?
Yes, the API endpoint shape matches the OpenAI speech endpoint. You can use the official OpenAI SDKs by setting the base URL to https://api.kuyaking.info/v1 and providing your Kuyaking API key. This ensures compatibility with existing codebases that already utilize OpenAI’s JavaScript or Python SDKs for audio generation tasks.
How many characters can I send in one request?
Each request supports a maximum of 4096 characters in the input field. If your lesson text exceeds this limit, you must split it into parts, generate audio for each part, and join the resulting files. This approach ensures compatibility with the API’s processing constraints while allowing for longer course content.
Can I use this API for commercial courses?
Yes, the API is designed for generating synthetic audio for commercial use, including online courses. Generated audio files carry an inaudible watermark marking them as synthetic. Input text is not used for training, and generated audio is not stored, making it suitable for embedding in LMS platforms or downloadable course materials.
Which voices are best for educational content?
Sage offers a calm, instructional tone. Luna provides a soft, storytelling voice. Aria is a warm, clear narrator. Milo is friendly and conversational, while Atlas provides a neutral, news-style delivery. All eight voices support 23 languages and can be adapted to your course’s specific style.
Does the API support streaming audio?
No, the API does not support streaming, WebSocket, or real-time partial audio. You send a POST request with JSON body and receive the complete audio file in the response. This synchronous model is reliable for no-code integrations where immediate streaming is not required, simplifying the integration process for LMS platforms.
How is the language detected if not specified?
If the language field is omitted, the API guesses the language from the script. Latin script text defaults to English. For non-English Latin-script text, you should explicitly set the language parameter. The API supports 23 languages, including Arabic, Chinese, French, German, Japanese, and Spanish, among others.
What happens if a synthesis request fails?
If synthesis fails, the charge is returned in full. You are not billed for failed requests. This ensures that you only pay for successfully generated audio files. Failed requests do not consume your character quota, allowing you to retry or adjust parameters without financial penalty.
Is there a limit to the number of API keys?
Yes, there is one active API key per account. You can issue a new key at any time, but the old key stops working immediately. This ensures security and simplifies key management for your LMS integrations, as you only need to manage a single active credential at any given time.
Can I use my own custom voice?
No, custom voice cloning is not offered. You can choose from eight preset voices based on licensed recordings from LibriTTS-R and LibriVox. These voices include female options like Aria and Nova, and male options like Felix and Milo. Each voice has a distinct tone suitable for different educational contexts.
How are spaces and punctuation counted?
Spaces and punctuation count as characters toward your usage limit. The price is $0.01 per 1,000 characters, including spaces and punctuation. This means every character in your input text, whether a letter, space, or comma, contributes to the total character count used for billing calculations.
What audio formats are available?
The API supports MP3, WAV, OPUS, FLAC, and PCM formats. You can specify the desired format in the response_format field of your request. This flexibility allows you to choose the best format for your LMS platform, balancing file size and quality based on your specific technical requirements.
Is there a free trial available?
Yes, signing in with Google provides $0.50 of credit, valid for 7 days, allowing about 50,000 characters. Accounts created with email and password start without trial credit. This allows you to test the API’s quality and integration before committing to a top-up via USDT on the TRON network.
How do I top up my balance?
Top up your balance using USDT on the TRON network (TRC-20). The minimum top-up is $5, and credits are automatically added within minutes after the transfer. There are no monthly plans, subscriptions, or invoices. Your balance does not expire, and you can top up as needed for your course production.
First request
curl
curl https://api.kuyaking.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.mp3How it works
The API accepts text and returns synthesized audio via a standard JSON endpoint. Send a POST request to the speech endpoint with your model, voice, and input text to receive an audio file.
Developers can use the official OpenAI SDKs by simply changing the base URL to https://api.kuyaking.info/v1. The request shape matches OpenAI’s speech endpoint, allowing seamless integration with existing codebases without custom parsers.
JSON API structure
Send a POST request to https://api.kuyaking.info/v1/audio/speech with a JSON body containing the model, input text, voice selection, and response format. The endpoint returns the audio file directly in the response.
OpenAI SDK compatibility
Use the official OpenAI SDKs for your preferred language. Set the base URL to https://api.kuyaking.info/v1 and provide your API key. The request structure is identical to OpenAI’s speech endpoint, ensuring easy migration.
No code required
Platforms like Make or Zapier can call the API directly using standard HTTP actions. Pass the text from your LMS into the JSON body and store the returned audio file in your course media library.
Voices for education
Kuyaking offers eight distinct voice presets engineered for clarity in educational content. Each voice is derived from licensed LibriTTS-R recordings, ensuring consistent, synthetic audio suitable for lessons and narrations without the variability of human performance.
Female presets
Aria provides a warm, clear narrator tone ideal for storytelling. Nova offers a bright, upbeat delivery for engaging content. Luna delivers a soft, storytelling voice for calm lessons. Sage presents a calm, instructional tone perfect for structured courses.
Male presets
Felix brings an energetic, promo-style voice for dynamic modules. Milo offers a friendly, conversational tone for interactive lessons. Atlas provides a neutral, news-style delivery for factual content. Orion uses a deep, documentary voice for serious topics.
Language support
The API supports 23 languages, including English, Spanish, German, French, Japanese, and Chinese. Any voice can speak any supported language. If the language parameter is omitted, the system guesses the language from the script, defaulting to English for Latin text.
- 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
Technical specs
The API enforces a rate limit of 60 requests per minute per key, with a lower threshold of 10 per minute until the first top-up. Requests are processed sequentially, so high load may introduce queue delays. Failed synthesis requests incur no charge.
Request limits
Each API key allows 60 requests per minute. Before the first top-up, the limit is 10 requests per minute. Requests are processed one after another, meaning under heavy load, synthesis may wait in a queue.
Audio formats
Supported output formats include mp3, wav, opus, flac, and pcm. These formats cover standard compatibility needs for most Learning Management Systems and audio players without requiring additional conversion steps.
Character counting
Billing is based on character count, including spaces and punctuation. The input text limit is 4096 characters per request. For longer lessons, split the text into chunks and join the resulting audio files.
Integration examples
The API accepts standard JSON payloads, allowing you to generate audio files directly within your existing LMS workflows. Because the endpoint mirrors the OpenAI speech structure, you can reuse familiar libraries and simply update the base URL to point to the Kuyaking cluster.
This compatibility reduces integration time for no-code platforms and custom scripts. You can trigger audio generation on demand when a lesson is published or when a student requests narration for a specific module.
Node.js snippet
Use the official OpenAI SDK with a custom base URL to send synthesis requests. The code below demonstrates a simple POST request to generate an MP3 file from a lesson transcript.
Ensure you pass your API key in the Authorization header. The response returns the audio file.
- Install
openaipackage and setbase_urltohttps://api.kuyaking.info/v1 - Set
modeltotts-1ortts-1-hd - Pass
voiceas a preset likenovaoratlas
Browser fetch example
You can call the API directly from a frontend script if you expose your key securely. This is useful for interactive course elements where students trigger audio playback instantly.
The fetch request sends the text and voice parameters. The response contains the audio blob, which you can then play using an HTML5 audio element.
- Use
fetchwithPOSTmethod - Set
Authorization: Bearer YOUR_KEY - Parse response as
blob()
cURL command
For quick testing or server-side scripts, cURL provides a straightforward way to verify the integration. This command sends a short text string and receives an MP3 file.
The output is saved to lesson.mp3. You can adjust the voice and model parameters to match your course's tone and quality requirements.
curl -X POST-H 'Authorization: Bearer YOUR_KEY'- `-d '{"model": "tts-1", "input": "Hello", "voice": "nova"}'`
Pricing model
Kuyaking API charges $0.01 per 1,000 characters, including spaces and punctuation. Failed requests are free, with the charge returned in full if synthesis fails. There are no monthly plans, seats, or minimum spends.
Per character cost
Each request counts characters in the input text. At $10 per million characters, long lesson narrations remain cost-effective. The rate applies uniformly regardless of voice or format selected.
Trial credit
Signing in with Google provides $0.50 in trial credit, valid for 7 days. This allows approximately 50,000 characters of generation. Accounts created with email and password start without this trial credit.
USDT top-up
Top-ups are processed via USDT on the TRON network (TRC-20). The minimum top-up amount is $5. Credits are added automatically within minutes of transfer confirmation. No cards, PayPal, or invoices are supported.
- Minimum top-up: $5
- Network: TRON (TRC-20)
- Processing time: Minutes

Supported languages
The API supports 23 languages, ensuring that course content reaches a global audience. Voice selection is independent of language, allowing any preset to speak any supported tongue with consistent quality.
English and variants
English is the default for Latin-script text if no language code is provided. It supports standard pronunciation across all eight voice presets, from clear narration to conversational tones.
European languages
Support includes Arabic, Danish, Dutch, Finnish, French, German, Greek, Hebrew, Hindi, Italian, Malay, Norwegian, Polish, Portuguese, Russian, Spanish, Swahili, and Swedish. Set the language field for non-English Latin text to ensure correct pronunciation.
Asian languages
The API handles Chinese, Japanese, and Korean natively. Vietnamese, Indonesian, Thai, Ukrainian, Romanian, Czech, and Bengali are not supported. Characters are counted individually, so multi-byte scripts do not impact pricing disproportionately.
Data privacy
Your input text is used exclusively for the purpose of generating the requested audio file and is not repurposed for training other models. This ensures that your course content remains proprietary and does not contribute to our engine’s development.
Generated audio is delivered directly in the response and is not stored on our servers after delivery. Only request metadata required for billing is retained, keeping your data footprint minimal and transparent.
Input usage
Text sent to the API is processed solely to synthesize the audio response. We do not use your lesson scripts or quiz questions to improve our voice models or train future iterations of the TTS engine.
Audio storage
The synthesized audio file is returned immediately in the API response and is not persistently stored by our infrastructure. Once the file is downloaded by your LMS or user, it resides only in your own systems.
We do not retain copies of your generated audio files for any period after the response is delivered.
Metadata retention
We retain request metadata, including timestamp, character count, voice used, and status, strictly for billing and usage verification purposes. This data allows us to accurately calculate charges and troubleshoot any issues with your account.
This metadata is not used for training or marketing purposes.
Common use cases
TTS API converts course text into synthetic audio, enabling consistent narration across lessons without recording studios. Instructors generate clear audio files via JSON requests, maintaining uniform voice quality across modules.
Lesson narration
Generate audio for video lessons or text-heavy modules using presets like Aria or Felix. The API handles texts up to 4096 characters, allowing precise control over pacing and clarity for educational content.
- Consistent voice across multiple modules
- Support for 23 languages including English, Spanish, and German
- No voice cloning required for standard narration
Quiz audio
Convert multiple-choice questions or instructions into audio format for auditory learners. Use the API to generate distinct audio files for each question variant, ensuring accurate playback in LMS environments without manual recording.
- MP3 and WAV formats for broad compatibility
- Real-time pricing per character keeps costs predictable
Accessibility compliance
Provide audio alternatives for text content to meet accessibility standards. The synthetic speech is clear and neutral, suitable for screen readers or dedicated audio players, ensuring content is reachable for visually impaired students.
- Support for WCAG audio requirements
- Easy integration via standard HTTP requests
Getting started
Create an account on our site using your Google account or a simple email and password. This establishes your workspace and tracks your usage. No complex setup is required to begin.
Once registered, you will receive a unique API key. This key authenticates your requests to the TTS endpoint. You can manage or rotate this key at any time from your dashboard.
Create account
Sign up via Google or email/password on the site. Accounts are specific to this domain.
No credit card is needed to start. Your account is ready immediately upon verification.
- Google SSO or email login
- Instant account creation
Get API key
Navigate to the API key page to view your unique key. One active key is issued per account.
Rotate the key anytime from the dashboard. The old key stops working immediately upon rotation.
First synthesis
Send a POST request to the API endpoint with your key, text, and voice selection.
Receive the audio file in your chosen format. Failed requests are free, so you can test safely.
You receive about 50,000 characters of free credit for 7 days with Google login.
Listen to the 8 voices
Each sample below was generated by this API from the same sentence. Your text input is processed exclusively to create the audio file.
23 languages
Any voice speaks any of these languages.
