Frequently asked questions
What is text-to-speech for games?
It is a cloud API that converts text into audio files via a simple POST request. You send JSON input with your script and receive an audio file back. This eliminates the need for recording sessions, allowing indie devs to generate consistent voice lines for NPCs programmatically without hiring full voice casts or managing studio logistics.
How do NPC voice lines work with this API?
Send text up to 4096 characters via POST to /v1/audio/speech. The API returns an audio file in your chosen format. For longer dialogues, split the text into parts, generate each segment, and join the resulting audio files. This workflow fits directly into game engines for dynamic or static NPC speech.
Which voices are best for game characters?
Choose from eight presets based on licensed recordings. Female options include Aria (warm narrator), Nova (upbeat), Luna (storytelling), and Sage (instructional). Male options include Felix (energetic promo), Milo (conversational), Atlas (neutral news), and Orion (deep documentary). Select the tone that matches your character’s personality and role in the game world.
Can I generate voice lines in multiple languages?
Yes, the API supports 23 languages including English, Japanese, German, Spanish, and Hindi. Any voice can speak any supported language. If you do not set the language parameter, the system guesses from the script, defaulting to English for Latin text. Explicitly set the language for non-English Latin-script text to ensure accuracy.
How much does it cost to generate game audio?
Pricing is $10 per 1 million characters, or $0.01 per 1,000 characters. Spaces and punctuation count as characters. Failed requests are free, with charges returned in full. You can start with a $0.50 free trial valid for 7 days when signing in with Google, or top up via USDT on TRON.
Do I need to pay for each voice line separately?
Yes, each API request generates one audio file and consumes character credits accordingly. You pay for the total characters sent in each request. If synthesis fails, the charge is returned. There are no monthly plans or minimum spends; you only pay for the characters you process through the endpoint.
Is the API fast enough for real-time gameplay?
Generation is roughly real-time for long texts, processing about 25 characters per second. Short phrases take a few seconds. Requests are processed sequentially, so under load, a request may wait in a queue. It is suitable for pre-baked dialogue but may have latency for instant real-time interaction.
Can I adjust the speed of the voice lines?
Yes, you can set the speed parameter between 0.25 and 4.0. This allows you to speed up exposition or slow down dramatic moments. Adjusting speed affects the character count if it changes duration, but pricing remains based on the input text length sent in the request, not the output audio duration.
What audio formats are supported for games?
You can request audio in mp3, wav, opus, flac, or pcm formats. These are standard digital audio formats compatible with most game engines and middleware. Select the format that best fits your engine’s audio pipeline, balancing file size and quality for your specific platform requirements.
Are the voices licensed for commercial use?
The voices are based on licensed recordings from LibriTTS-R (CC BY 4.0) and public-domain audiobook readings from LibriVox. Each generated file carries an inaudible watermark marking it as synthetic speech. This setup supports commercial game development.
Do the voices sound robotic or synthetic?
The voices are based on licensed human recordings, providing natural intonation and tone. However, every generated file carries an inaudible watermark that marks it as synthetic speech. They offer consistent narration suitable for NPC dialogue.
How do I integrate the API into my game engine?
Use the official OpenAI SDKs by changing the base_url to https://api.89999.info/v1 and using your API key. Alternatively, send a standard POST request with JSON body containing model, input, voice, and format. The endpoint is https://api.89999.info/v1/audio/speech. This HTTP-based approach works with any engine that supports network requests and can handle the response.
What happens if a voice line generation fails?
If synthesis fails, the charge is returned in full. You are not billed for failed requests. This ensures you only pay for successfully generated audio files. You can retry the request with adjusted parameters, such as checking character limits or voice availability, without incurring additional costs for the failed attempt.
Can I use the API for dialogue trees?
Yes, you can generate voice lines for each branch of a dialogue tree by sending individual requests. Split longer dialogues into parts under 4096 characters and join the resulting audio files. This allows dynamic generation of NPC responses based on player choices, fitting seamlessly into narrative-driven game structures.
First request
curl
curl https://api.89999.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.mp3Voice Lines Without the Recording Studio
Traditional voice recording requires hiring actors, booking studios, and managing complex scheduling for every character line. NPC Audio Lab replaces this logistical burden with a direct API integration, delivering consistent audio files tailored for game engines.
Generate distinct voice lines for dozens of characters without coordinating human availability. The system handles the synthesis, ensuring every NPC speaks with the same reliable tone every time, removing the variability of live sessions.
Consistent Character Voices
Maintain vocal identity across all game updates. Whether you are generating short battle cries or long exposition, the selected voice preset remains identical, preserving character continuity without the risk of casting changes between recording sessions.
- Fixed voice presets ensure uniform tone across all content
- No variation between recording takes or different actors
- Ideal for RPGs with extensive dialogue trees
Instant Iteration
Adjust dialogue text and regenerate audio immediately. If a line feels off or a translation is needed, you can re-synthesize the clip in seconds. This allows for rapid prototyping of voice lines directly within your development workflow.
No Session Scheduling
Eliminate the need to book studio time or coordinate actor availability. Generate as many lines as your project requires on demand. This removes the bottleneck of waiting for a voice actor's schedule, accelerating your production timeline.
8 Distinct Voice Personalities
NPC Audio Lab provides eight distinct voice presets designed for consistent character identity. Each voice is derived from licensed LibriTTS-R recordings, ensuring a natural baseline for dialogue generation without the need for full voice casts.
These presets cover a range of tones, from warm narrators to deep documentary tones. By selecting specific voices, you can maintain character consistency across thousands of lines of dialogue, regardless of the language used.
Female Narrators: Aria, Nova
Aria offers a warm, clear narration style ideal for exposition or calm character interactions. Nova provides a bright, upbeat tone suitable for energetic or youthful roles.
Both voices are optimized for clarity, ensuring that dialogue remains intelligible even during fast-paced gameplay sequences.
- Aria: Warm, clear narrator
- Nova: Bright, upbeat energy
Male Heroes: Felix, Milo
Felix delivers an energetic, promo-style delivery perfect for action sequences or promotional in-game dialogue. Milo provides a friendly, conversational tone that works well for everyday character interactions.
These voices add personality without requiring additional voice direction for minor roles.
- Felix: Energetic, promo style
- Milo: Friendly, conversational
Neutral & Deep: Atlas, Orion
Atlas offers a neutral, news-style voice suitable for objective information or background characters. Orion provides a deep, documentary tone ideal for serious or atmospheric dialogue.
Both voices ensure that critical information is delivered with authority and clarity.
- Atlas: Neutral, news style
- Orion: Deep, documentary tone
Multi-Language Support for Global Games
Support your game’s global reach with voice lines in 23 languages, from Arabic and Japanese to Swahili and Turkish. Each of the eight voice presets speaks every supported language, ensuring consistent character identity across your entire cast regardless of the target market.
23 Supported Languages
Our API supports Arabic, Chinese, Danish, Dutch, English, Finnish, French, German, Greek, Hebrew, Hindi, Italian, Japanese, Korean, Malay, Norwegian, Polish, Portuguese, Russian, Spanish, Swahili, Swedish, and Turkish. This covers the majority of major gaming markets without requiring external localization voices.
Automatic Language Detection
By default, the system guesses the language from the text script. Latin script defaults to English, but non-English Latin text (like French or Spanish) is not detected automatically. This reduces configuration overhead for simple monolingual builds.
Manual Language Override
For mixed scripts or ambiguous text, explicitly set the language field using the ISO code. This ensures accurate pronunciation and prevents the engine from defaulting to English when generating localized dialogue lines.
- Arabic, Chinese, Danish, Dutch, English, Finnish, French, German, Greek, Hebrew, Hindi, Italian, Japanese, Korean, Malay, Norwegian, Polish, Portuguese, Russian, Spanish, Swahili, Swedish, Turkish
Technical Integration for Devs
Integration is straightforward because the API follows the same request shape as the OpenAI speech endpoint. Indie developers can reuse existing codebases by simply changing the base_url to https://api.89999.info/v1 and updating the authentication header.
This compatibility extends to the official OpenAI SDKs, allowing you to generate NPC dialogue by changing the base_url. The standard HTTP structure ensures that your game engine or backend service can handle responses predictably without custom parsing logic.
OpenAI SDK Compatibility ['The API mirrors the OpenAI speech endpoint structure. You can use the official OpenAI SDKs by pointing the base_url to https://api.89999.info/v1. This means your existing integration code likely requires only a configuration change to start generating voices.', 'Authentication uses a standard Bearer token. One active key per account ensures clean tracking of usage across your development and production environments.'] ['Uses identical JSON request shape to OpenAI', 'Works with official OpenAI SDKs', 'Simple base_url configuration change']
Standard HTTP Endpoints ['The core endpoint is POST https://api.89999.info/v1/audio/speech. You send a JSON body with the text, model, voice, and format parameters. The response returns the audio file directly, ready for playback in your game engine.', 'Additional endpoints like GET /v1/voices and GET /v1/models provide metadata about available voices and formats. This allows you to build dynamic UIs that list available characters and language options for players.'] ['POST /v1/audio/speech for generation', 'GET /v1/voices for metadata', 'GET /v1/models for model info']
Format Flexibility (MP3, WAV) ['Choose between MP3, WAV, OPUS, FLAC, or PCM based on your engine’s requirements. MP3 is ideal for reducing bandwidth in online multiplayer, while WAV offers uncompressed quality for local assets.', 'This flexibility ensures that your audio pipeline handles both high-fidelity cutscenes and efficient in-game dialogue. The API returns the file directly in the response, simplifying storage and caching strategies.'] ['MP3 for bandwidth efficiency', 'WAV for uncompressed quality', 'Supports OPUS, FLAC, and PCM']
Pricing Built for Indie Budgets
Voice synthesis costs scale directly with your dialogue volume. You pay $0.01 per 1,000 characters, ensuring you only fund the content you actually generate. Failed requests are free, so you never pay for empty audio files.
Pay Per Character
The API charges $10 per 1 million characters. This includes spaces and punctuation. You get a free trial credit of $0.50 (about 50,000 characters) when you sign in with Google, valid for 7 days.
- $0.01 per 1,000 characters
- Failed requests are free
- $0.50 trial credit for Google sign-ins
No Monthly Fees
There are no subscriptions, seats, or minimum spend requirements. Your balance does not expire, so you can generate lines whenever your development cycle demands it without worrying about recurring costs or wasted credits.
Crypto Top-Ups
Fund your account using USDT on the TRON network (TRC-20). The minimum top-up is $5, and credits are added automatically within minutes. We do not accept cards, PayPal, or issue invoices with VAT.
- USDT (TRC-20) only
- Minimum $5 top-up
- Automatic credit within minutes

Workflow Optimization
Game dialogue often exceeds the 4096-character limit per request. Splitting long scripts into smaller chunks and joining the resulting audio files ensures seamless narration without truncation or quality loss.
Adjusting the speed parameter between 0.25 and 4.0 allows you to match voice lines to animation timings or player reaction speeds, optimizing the pacing of in-game conversations.
Split Long Dialogues
Break your script into segments of up to 4096 characters. The API processes each part individually, and you can concatenate the returned audio files to create a continuous voice line.
This approach handles complex quests or extensive lore dumps without hitting request limits, keeping your asset pipeline smooth.
- Max 4096 characters per request
- Concatenate returned audio files
- Handles long quests and lore
Speed Adjustment
Use the speed parameter to fine-tune delivery. Faster speeds suit rapid-fire dialogue or comedic timing, while slower rates enhance dramatic pauses or instructional cues.
Values range from 0.25 to 4.0, giving you precise control over the rhythm of NPC interactions.
- Range: 0.25 to 4.0
- Optimize animation sync
- Control narrative pacing
Format Selection
Choose the output format that fits your engine’s requirements. MP3 offers small file sizes for quick downloads, while WAV provides lossless quality for high-fidelity sound design.
Other supported formats include OPUS, FLAC, and PCM for specific integration needs.
- MP3 for small size
- WAV for lossless quality
- Supports OPUS, FLAC, PCM
Why Choose API Voice Lines?
Generating voice lines via API removes the bottleneck of studio scheduling. You can produce unique character interactions, ensuring consistent audio quality across your entire game without managing recording sessions or external contractors.
The pay-per-character model aligns costs directly with content volume. With no monthly fees or minimum spend, you only pay for the audio you actually use, making it viable for both small prototypes and large-scale releases.
Scalable Content
API generation allows for infinite dialogue expansion. Instead of limiting your script to the number of actors you can afford, you can populate your world with distinct voices for every NPC, from background crowd members to major quest givers.
- Generate unique voice lines
- Support for 23 languages without additional casting
- Consistent voice identity across all generated audio
Cost Efficiency
At $0.01 per 1,000 characters, audio production scales linearly with your text. Failed requests are free, so you only pay for successful synthesis. This eliminates the risk of overpaying for unused studio time or unused voice sessions.
- $0.01 per 1,000 characters
- No monthly subscription fees
- No minimum spend requirements
Creative Control
You retain full control over tone and pacing. Adjust the speed between 0.25x and 4.0x to match the emotion of the scene, and choose from eight distinct voice presets to define each character’s personality without needing voice directors.
- Adjustable speed (0.25–4.0x)
- 8 distinct voice personalities
- Direct format selection (MP3, WAV, etc.)
Data and Licensing
The voice models powering NPC Audio Lab are derived from LibriTTS-R, a dataset licensed under CC BY 4.0. This foundation ensures that the synthesized voices, based on licensed recordings, maintain a consistent quality suitable for commercial game development.
Your input text is used exclusively for the immediate synthesis of the audio file and is not retained for model training. This means your unique dialogue scripts remain private and do not contribute to the public dataset used to train the engine.
LibriVox Licensed Voices
Each of the eight preset voices (Aria, Nova, Luna, Sage, Felix, Milo, Atlas, Orion) is based on recordings from the LibriVox project. These sources provide a diverse range of vocal characteristics, from warm narrators to deep documentary tones, all grounded in established public-domain or CC-licensed source material.
No Training Data Usage
Input text is processed to generate your audio and is not stored or used to improve the underlying model. Only request metadata (time, character count, status) is kept for billing purposes. Your game’s dialogue remains distinct and does not influence future voice generations for other customers.
Synthetic Watermarks
Every audio file generated by the API contains an inaudible digital watermark. This mark identifies the output as synthetic speech, providing a clear distinction between AI-generated lines and traditional voice-acted performances for your players and licensors.
Get Started Today
Start generating NPC dialogue immediately with a $0.50 free trial credit, valid for 7 days after signing in via Google. This gives you roughly 50,000 characters to test voice consistency and integration without financial commitment.
Access clear documentation at /docs/ to see curl examples and SDK configuration. Support is available via email for any technical questions regarding API usage or billing.
Free Trial Credit
New accounts created with Google authentication receive $0.50 in trial credit, valid for 7 days. This allows approximately 50,000 characters of generation, enough to prototype multiple character voices and test integration workflows before spending.
Simple Documentation
The /docs/ page provides ready-to-use curl examples and explains how to configure the OpenAI SDK by changing the base URL. The request structure mirrors standard speech endpoints, making integration straightforward for indie developers familiar with common TTS patterns.
Email Support
For technical questions or billing issues, support is available via email. There is no phone number or live chat, ensuring focused assistance for API-related concerns.
Listen to the 8 voices
Each sample below was generated by this API from the same sentence. This ensures consistent voice delivery across extended conversations without hitting request limits.
23 languages
Any voice speaks any of these languages.
