Creating and Managing Scripts

You can create a script by posting text to the script endpoint (see here)

As every script needs to be located within an organisation, a project and a module you can either explicitly define them or they will be defaulted for you.

Scripts can not be changed and to update them you will need to create a new version.

You can get an overview of all your scripts by listing them (see here) and can retrieve scripts by script ID (see here)

import apiaudio

apiaudio.api_key = "<<apiKey>>"

# Create a new script and print the script created
script = apiaudio.Script().create(
    scriptText="<<sectionName::hello>> Hello world"

Random Script

Do not know what to write for script text?

User the random text functionality to get a script text from one of our many different categories

scriptText = apiaudio.Script.get_random_text(category="BibleVerse")
await Script.getRandomText(category?: string)

Categories currently available: "BibleVerse", "FunFact", "InspirationalQuote", "Joke", "MovieSynopsis", "Poem", "PhilosophicalQuestion", "Recipe", "TriviaQuestion".

Do's and Dont's

Creating synthetic speech that is expressive and engaging is not a trivial task. offers guardrails and even frontend components that make it easy for you to build something for your users that make it easy to create audio and does not come in the way of their creativity.

Nonetheless, here are some tips on how to create a script that will end up sounding great in the end.

Did this page help you?