Text-to-Speech API for Audiobooks and Narration

By TextReader Hub editorial team · Updated 2026-11-19

Welcome to the TextReader Hub documentation, designed specifically for self-publishers and audiobook creators who want to turn manuscripts into listenable audio without hiring voice actors. This page provides all the technical details you need to integrate our cloud TTS API into your workflow, covering everything from API keys to long-text handling.

We focus on simplicity for no-code users and developers alike. You will find clear examples for generating natural-sounding narration in 23 languages, including German, using standard tools like cURL or the OpenAI SDK. Let’s get your first audio file generated.

Text-to-Speech API for Audiobooks and Narration

Frequently asked questions

What is the base URL for the API?

The base URL is https://api.44bd.info/v1. You send POST requests to https://api.44bd.info/v1/audio/speech. This endpoint accepts JSON bodies with your text, voice selection, and format preferences. It follows the same request shape as the OpenAI speech endpoint, making integration straightforward for existing developers.

Do I need the OpenAI SDK?

No, you do not need the OpenAI SDK, though it works with a base_url change. You can use plain HTTP requests or any standard library. However, the official OpenAI SDKs work perfectly if you change the base_url to https://api.44bd.info/v1 and provide your site’s key. This allows easy migration for users familiar with that ecosystem.

How do I set the language?

You can optionally set the language using an ISO code in the request body. If you omit this field, the system guesses the language from the script, defaulting to English for Latin text. For non-English Latin-script text, always set the language parameter to ensure accurate synthesis.

Can I change the speed of the voice?

Yes, you can adjust the speed between 0.25 and 4.0. This allows you to slow down narration for clarity or speed up content for quick reviews. The speed parameter accepts decimal values, giving you precise control over the pacing of your generated audiobooks and audio projects.

What is the maximum text length?

The maximum text length is 4096 characters per request. For longer manuscripts, split your text into parts of up to 4096 characters. Generate each part separately and join the resulting audio files. This ensures optimal processing and avoids hitting the character limit during a single synthesis call.

How do I handle errors?

If synthesis fails, the charge is returned in full. Failed requests do not cost you any credit. You should check the response status and retry if necessary. Since requests are processed sequentially, under load a request may wait in a queue, so implement appropriate retry logic for robustness.

Is there a WebSocket for streaming?

No, there is no WebSocket for streaming or real-time partial audio. The API returns the complete audio file in the response. You must wait for the full generation to complete before receiving the audio data. This synchronous approach simplifies integration for standard audiobook and narration workflows.

Do I need to install an SDK?

No, you do not need to install an SDK. You can use plain HTTP requests with any programming language that supports JSON. While the OpenAI SDK works with a base_url change, it is not required. This flexibility allows you to integrate the API into any environment easily.

How do I rotate my API key?

You can issue a new key at any time from your account dashboard. When you generate a new key, the old one stops working immediately. This ensures that only your current key is active, providing security without downtime. You can manage your keys directly on the /get-api-key/ page.

What formats are supported?

We support mp3, wav, opus, flac, and pcm formats. You can specify the desired format in the response_format field of your request. This allows you to choose the best balance between file size and quality for your specific use case, whether it is web playback or archival storage.

How does rate limiting work?

You are limited to 60 requests per minute per key. Before your first top-up, the limit is 10 requests per minute. This ensures fair usage across all users. If you exceed the limit, your requests may be delayed or rejected until the window resets, so monitor your usage closely.

Can I use custom voices?

No, custom voice cloning is not offered. You can choose from eight preset voices: aria, nova, luna, sage, felix, milo, atlas, and orion. These voices are based on licensed recordings and public-domain audiobook readings. You cannot upload your own voice or design custom tones for your specific projects.

Is the API RESTful?

Yes, the API is RESTful. It uses standard HTTP methods, primarily POST for speech generation and GET for retrieving voices and models. It follows standard conventions for request and response formats, making it easy to integrate with existing tools and libraries that support RESTful API interactions.

How do I get my key?

Sign up on the /get-api-key/ page using Google or email. Once registered, your account page displays your API key, balance, and usage statistics. You can copy the key and start making requests immediately. If you use email, you start without trial credit, unlike Google sign-ups.

First request

curl

curl https://api.44bd.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.mp3

Python (openai)

from openai import OpenAI

client = OpenAI(base_url="https://api.44bd.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.44bd.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
ariafemale
novafemale
lunafemale
sagefemale
felixmale
milomale
atlasmale
orionmale
language
arالعربية
zh中文
daDansk
nlNederlands
enEnglish
fiSuomi
frFrançais
deDeutsch
elΕλληνικά
heעברית
hiहिन्दी
itItaliano
ja日本語
ko한국어
msBahasa Melayu
noNorsk
plPolski
ptPortuguês
ruРусский
esEspañol
swKiswahili
svSvenska
trTürkçe

Get Your API Key

Sound wave illustration for: Get Your API Key

Start by visiting the /get-api-key/ page to create your account. You can sign up instantly using your Google account or by entering an email and password. Once registered, you’ll see your unique API key, current balance, and a ready-to-use cURL example on the dashboard.

This page gives you immediate access to the tools needed for generating narration. Keep your key handy, as it authenticates every request you send to the API.

Google or Email Login

Google or Email Login

Choose Google for quick setup, which includes a $0.50 free trial valid for 7 days. Email registration is available but does not include trial credit. Accounts are specific to this site, ensuring your credits are tracked accurately.

  • Google login includes $0.50 trial credit
  • Email login requires manual top-up
  • 7-day trial validity period

Key Management

Key Management

Each account has one active API key starting with 'tts-'. You can issue a new key at any time via the dashboard. The old key stops working immediately when the new one is created, keeping your access secure.

  • One active key per account
  • Instant revocation on key refresh
  • Starts with 'tts-'

First Request with cURL

Sound wave illustration for: First Request with cURL

Generate your first audio file by sending a simple POST request. This section covers the basic JSON body, how the audio is returned, and how to handle common errors so you can start narrating your manuscript immediately.

The API accepts standard JSON inputs and returns binary audio data directly in the response body. You can test this quickly with cURL to verify your key works before integrating it into your publishing workflow.

Basic JSON Body

Send a POST request to https://api.44bd.info/v1/audio/speech with a JSON body containing your model, input text, voice preset, and response_format. Keep text under 4096 characters.

Include an optional speed parameter (0.25–4.0) and language code if needed. The system guesses language by default, but explicit codes ensure accuracy for non-English Latin scripts.

  • model: "tts-1" or "tts-1-hd"
  • input: Your manuscript text (max 4096 chars)
  • voice: e.g., "aria", "atlas"
  • response_format: "mp3", "wav", etc.

Audio Response

On success, the response contains the raw audio bytes corresponding to your chosen format. Save this output directly to a file for use in your audiobook project.

Failed requests return an error JSON object instead of audio, ensuring you know exactly why synthesis didn’t complete.

Error Handling

Handle HTTP 400 errors by checking your JSON syntax or voice ID. HTTP 429 indicates you’ve hit the 60 requests/minute limit or the initial 10 RPM cap.

HTTP 500 errors are rare server-side issues; retry after a brief pause. Failed synthesis charges are refunded automatically.

OpenAI SDK Integration

Sound wave illustration for: OpenAI SDK Integration

Connecting to our API is straightforward if you are already familiar with the OpenAI ecosystem. You do not need to rewrite your integration logic or switch to a completely different library. Simply point your existing client to our endpoint and authenticate with your TextReader Hub key.

Change Base URL

Update your SDK configuration to use https://api.44bd.info/v1 as the base URL. This ensures all requests are routed to our text-to-speech service while maintaining standard compatibility.

  • Base URL: https://api.44bd.info/v1

Use Official SDK

Leverage the official OpenAI SDK (e.g., openai Python or Node.js package). Install your preferred version and initialize the client with your API key. The library handles the HTTP details, leaving you to focus on your audiobook workflow.

Same Request Shape

The request structure mirrors the standard speech endpoint. Pass your text, chosen voice, and desired format exactly as you would for OpenAI. Our engine accepts tts-1 or tts-1-hd models, ensuring your code works seamlessly with our infrastructure.

Supported Formats

Sound wave illustration for: Supported Formats

Choose the audio format that best fits your audiobook distribution channel. Each format balances file size, quality, and compatibility differently, ensuring your narration sounds great whether it’s streamed on a mobile app or downloaded as a high-fidelity file.

MP3 Output

MP3 is the standard for web delivery and most audiobook platforms. It offers excellent compression with minimal quality loss, keeping file sizes small for faster uploads and downloads.

WAV Format

WAV provides uncompressed audio. Use this when you need the highest fidelity for professional mastering or archival purposes. Files are larger than MP3 but ensure no data is lost during transmission, preserving every nuance of the synthetic voice.

Opus, FLAC, PCM

Opus and FLAC are available formats. Opus is efficient for smaller file sizes, while FLAC provides lossless compression. PCM delivers raw, uncompressed audio data, ideal for immediate processing in digital audio workstations. Select these based on your specific editing pipeline needs.

Voice Selection

Sound wave illustration for: Voice Selection

Choosing the right voice is critical for maintaining listener engagement during long audiobook sessions. Our API offers eight distinct presets designed to suit various narration styles, from warm storytelling to crisp news delivery. Each voice is generated from licensed recordings, ensuring a natural and professional sound without the need for human actors.

Selecting the correct voice ID and language code ensures your text is synthesized accurately. You can mix voices across chapters or stick to one narrator for consistency. The system automatically detects language for Latin scripts, but specifying the ISO code guarantees precision for non-English content.

8 Preset Voices

We offer eight voices: Aria, Nova, Luna, and Sage (female); Felix, Milo, Atlas, and Orion (male). These cover a range of tones, from upbeat promos to deep documentaries. All voices support all 23 languages, allowing you to produce multilingual audiobooks with consistent quality.

None

  • Aria: Warm, clear narrator
  • Nova: Bright, upbeat
  • Luna: Soft, storytelling
  • Sage: Calm, instructional
  • Felix: Energetic, promo
  • Milo: Friendly, conversational
  • Atlas: Neutral, news
  • Orion: Deep, documentary

Voice IDs

Use the lowercase name as the voice parameter in your request (e.g., "voice": "aria"). The system maps these IDs to the corresponding audio engine. You can test different voices by generating short samples before committing to a full manuscript.

None

Language Codes

Pass an optional ISO language code (e.g., "language": "de" for German) to ensure correct pronunciation. If omitted, the system guesses the language based on the text script, defaulting to English for Latin characters. Explicitly setting the language prevents errors with mixed-language texts.

None

Voice Selection

Rate Limits

Sound wave illustration for: Rate Limits

Rate limits protect the shared inference engine during peak usage. Your API key allows 60 requests per minute once your account is active. This throughput is sufficient for most self-publishing workflows, from short samples to full chapter generation.

60 Requests Per Minute

After your initial trial period or first top-up, you get 60 requests per minute. This is enough to generate a significant amount of text. Use this limit to batch your manuscript chapters efficiently without waiting for manual processing.

  • Standard limit: 60 requests/minute per key
  • Applies to both tts-1 and tts-1-hd models

10 RPM Initial Limit

New accounts start with a stricter limit of 10 requests per minute. This prevents accidental bursts from draining your small trial balance. Top up with USDT to instantly increase your limit to the full 60 RPM.

Queue Processing

Requests are processed sequentially within your quota. If you hit the limit, new requests wait in a queue. Short phrases may take a few seconds, while longer texts take longer due to real-time generation speed. Be patient; no request is lost.

Error Codes

Sound wave illustration for: Error Codes

Errors in the TTS API are generally self-explanatory, but understanding common HTTP status codes helps you debug integration issues quickly. Most failures return clear messages indicating what went wrong, allowing you to adjust your requests without guessing.

400 Bad Request

This error occurs when the JSON body is malformed, the model name is invalid, or the input text exceeds the 4096-character limit. Check your request structure and ensure all required fields like input and voice are present and correctly formatted.

  • Invalid JSON structure
  • Unknown model or voice ID
  • Input text too long

429 Rate Limit

You hit the limit of 60 requests per minute per key. New accounts start with a 10 RPM limit until the first top-up. The API returns this status when you exceed the allowed quota, so pause briefly before retrying.

  • 60 RPM limit after top-up
  • 10 RPM initial limit
  • Retry after delay

500 Server Error

A generic server-side error indicating something went wrong during synthesis. These are rare, but if they persist, check the /v1/models endpoint to ensure the engine is healthy. Failed requests are free, so you can retry without charge.

  • Synthesis failure
  • Engine health check
  • Retry eligible

Long Text Handling

Sound wave illustration for: Long Text Handling

Manuscripts often exceed the 4096-character input limit. To handle longer texts, split your content into chunks of up to 4096 characters and send them as separate requests.

Each chunk generates a distinct audio file. These files must be joined sequentially to create a continuous narration file for your audiobook project.

4096 Char Limit

Every API request accepts a maximum of 4096 characters. Spaces and punctuation count toward this limit. Text exceeding this length must be divided before sending.

Split and Join

Split your manuscript into logical segments, such as paragraphs or scenes. Ensure each segment stays within the 4096-character boundary to avoid truncation.

  • Split at natural pause points to maintain audio continuity.
  • Track character counts to stay under the 4096 limit.

Audio Concatenation

Receive multiple audio files from your batch requests. Concatenate these files in order to produce a single, continuous narration track for your self-published audiobook.

Listen to the 8 voices

Each sample below was generated by this API from the same sentence. Special attention is paid to consonant clarity and vowel shapes, ensuring that complex words are understood without distortion.

Avatar of the voice aria
ariafemale
Avatar of the voice nova
novafemale
Avatar of the voice luna
lunafemale
Avatar of the voice sage
sagefemale
Avatar of the voice felix
felixmale
Avatar of the voice milo
milomale
Avatar of the voice atlas
atlasmale
Avatar of the voice orion
orionmale

23 languages

Any voice speaks any of these languages.

Sources and further reading

  1. Wikipedia
  2. Creative Commons Attribution 4.0
  3. openai-node on GitHub
  4. W3C WAI: making audio and video accessible
  5. curl documentation
  6. LibriTTS-R corpus (OpenSLR 141)
  7. Node.js documentation
  8. IETF RFC 7845: Ogg Opus
  9. Python documentation
  10. openai-python on GitHub
  11. TRON developer hub: TRC-20
  12. MDN: Web Speech API

More on this site