Skip to main content

Overview

Generate natural-sounding speech from text using the CAMB.AI SDK. This tutorial covers installation, generating your first audio, choosing a model, and listing voices.

Listen to an Example

Prerequisites

1

Create an account

Sign up at CAMB.AI Studio if you havenโ€™t already.
2

Get your API key

Go to Settings โ†’ API Keys in Studio and copy your key. See Authentication for details.
3

Install the SDK

Skip this step if youโ€™re using the direct API.
4

Set your API key to use in your code


Code


MARS Instruct Delivery Control

Use mars-instruct when you want fine-grained control over tone and delivery. You can combine embedded expressive tags in text with user_instructions for broader style guidance.

Listing Voices

List available voices to find the right one for your use case:

Parameters

Required

Optional


mars-instruct supports embedded emotion tags, SSML-style breaks, and user_instructions for fine-grained control. See Emotional Voice Control for examples.

Next Steps

Emotional Voice Control

Add emotional expression and dramatic pacing with mars-instruct.

TTS with Accents

Generate speech in 140+ language accents with the same voice.

Voice Cloning

Clone a voice from reference audio and generate speech with it.

MARS 8 Models

Compare model variants in detail.
Last modified on June 17, 2026