API v1.0 is now available! Check out the new voice cloning features.
SpeechgenSpeechgen

API Endpoints

Complete reference of all available API endpoints

API Endpoints

All endpoints are relative to the base URL: https://api.speechgen.com/v1

Overview

MethodEndpointDescription
POST/text-to-speechConvert text to speech
POST/voice-cloneCreate a voice clone from audio
GET/voicesList all available voices
GET/voices/{id}Get voice details
GET/audio/{id}Retrieve generated audio
GET/modelsList your voice models
DELETE/models/{id}Delete a voice model

Text-to-Speech

Convert text to natural-sounding speech.

POST /text-to-speech

Request Body:

{
  "text": "Hello, welcome to Speechgen!",
  "voice": "en-US-Neural2-A",
  "format": "mp3",
  "speed": 1.0,
  "pitch": 0
}

Response: Binary audio data

View full documentation →


Voice Clone

Create a custom voice model from audio samples.

POST /voice-clone
Content-Type: multipart/form-data

Form Data:

Prop

Type

Response:

{
  "model_id": "vm_abc123",
  "status": "processing",
  "estimated_time": 60
}

View full documentation →


List Voices

Get all available voices.

GET /voices

Query Parameters:

Prop

Type

Response:

{
  "voices": [
    {
      "id": "en-US-Neural2-A",
      "name": "Aria",
      "language": "en-US",
      "gender": "female",
      "styles": ["cheerful", "professional", "calm"]
    }
  ]
}

View full documentation →


Retrieve Audio

Download a previously generated audio file.

GET /audio/{id}

Response: Binary audio data

Audio files are stored for 7 days. Download and store them if you need longer retention.


HTTP Status Codes