Skip to main content
POST
/
voice_clones
JavaScript
import Telnyx from 'telnyx';

const client = new Telnyx({
  apiKey: process.env['TELNYX_API_KEY'], // This is the default and can be omitted
});

const voiceClone = await client.voiceClones.create({
  gender: 'male',
  language: 'en',
  name: 'clone-narrator',
  voice_design_id: '550e8400-e29b-41d4-a716-446655440000',
});

console.log(voiceClone.data);
{
  "data": {
    "record_type": "voice_clone",
    "id": "660f9511-f3ac-52e5-b827-557766551111",
    "source_voice_design_id": "550e8400-e29b-41d4-a716-446655440000",
    "source_voice_design_version": 1,
    "name": "clone-narrator",
    "language": "en",
    "gender": "male",
    "label": "Speak in a warm, friendly tone",
    "created_at": "2024-01-01T00:00:00Z",
    "updated_at": "2024-01-01T00:00:00Z"
  }
}

Authorizations

Authorization
string
header
required

Bearer authentication header of the form Bearer <token>, where <token> is your auth token.

Body

application/json

Request body for creating a voice clone from an existing voice design.

name
string
required

Name for the voice clone.

Required string length: 1 - 255
voice_design_id
string<uuid>
required

UUID of the source voice design to clone.

language
string
required

ISO 639-1 language code for the clone (e.g. en, fr, de).

gender
enum<string>
required

Gender of the voice clone.

Available options:
male,
female,
neutral

Response

Voice clone created successfully.

Response envelope for a single voice clone.

data
object

A voice clone object.