models

Google: Gemini 3.1 Flash TTS Preview

Markdown · JSON

Google: Gemini 3.1 Flash TTS Preview

Google Gemini 3.1 Flash TTS Preview converts written scripts into expressive spoken audio. Natural-language direction, speaker Audio Profiles, Director’s Notes and inline audio tags shape pace, tone and accent. It supports native dialogue and more than 70 languages, using the 3.1 prompt and audio format.

About the model

This description covers the model’s capabilities. Available in Ailoot inputs, outputs and options are listed for the selected method below.

Google Gemini 3.1 Flash TTS Preview is the text-to-speech edition of the Gemini 3.1 Flash Audio family. It accepts text and produces spoken audio with prompt-directed expression. Google describes this generation as an improvement in speech naturalness, controllability and multilingual performance, with native multi-speaker dialogue and more than 70 languages. A practical use is a short narrated lesson, a character exchange or a spoken passage whose delivery matters as much as its wording.

Prepare a finished script and a performance brief. This generation uses natural-language instructions within the text input to guide vocal style, pace and delivery. Google’s release introduces scene direction to establish a situation, speaker Audio Profiles to define characters, and Director’s Notes to guide pace, tone and accent. Keep those parts identifiable when preparing the prompt so the intended words and the performance instructions can be reviewed independently. An economical brief is easier to revise than several competing descriptions of the same voice.

For example, an original rehearsal brief can describe a calm narrator explaining a museum exhibit, with measured phrasing and a warmer tone on the final sentence. The accompanying script should contain the exhibit’s actual names and the precise wording that needs to be voiced. For a dialogue, give the characters distinct profiles and a clear sequence of turns. Use the scene context to explain whether one speaker is reassuring the other, asking a genuine question or responding with restrained surprise. The generated artifact to assess is the audible performance of that script.

Inline audio tags add local control inside the text, allowing a speaker’s expression to change within a sentence rather than relying entirely on the opening direction. Google describes tags as controlling vocal style, pace and delivery. Use them where the performance needs a particular shift and keep the rest of the wording natural to speak. The useful distinction in this edition is between the high-level character or scene brief and the local change in delivery. A short neutral passage can establish the baseline voice before the script adds more emotional direction.

For multilingual work, supply the final-language script and state the desired accent and speaking style in the brief. Google’s announcement documents support across more than 70 languages. As practical editorial preparation, give recurring names one consistent spelling, expand ambiguous abbreviations when one reading is required and check numbers in the spoken result. A language label alone does not settle how a brand name or borrowed term should sound. Compare the passages containing those terms with the intended reading before accepting a long narration.

The exact Gemini API model page lists an input limit of 8,192 tokens and an output limit of 16,384 tokens for this preview model. DeepMind’s native TTS model card separately lists text input up to 16K tokens and audio output of 32K tokens; those model-card figures are distinct from the Gemini API serving limits. Count the performance directions as part of the prepared input as well as the script. The output allowance is expressed in audio tokens, so it does not guarantee a particular recording duration. Organize a long lesson or story into coherent sections, retain the same character brief and listen to the joins. For scripted dialogue, check attribution and turn order in addition to the spoken words and emotional delivery.

Google’s migration documentation identifies the 3.1 default output as headerless raw PCM with the audio/l16 type. The audio bytes need the appropriate playback or container information when preparing an editable recording; adding a WAV filename alone does not create a WAV header. Check the actual returned format before importing the result. Google also states that audio generated by Gemini 3.1 Flash TTS carries an imperceptible SynthID watermark. The watermark concerns identification of generated audio and does not replace a transcript, speaker labels or a listening review.

The 3.1 preparation style differs materially from 3.8. Gemini 3.8 moves sustained directions and speaker identity into structured speech metadata, uses angle-bracket point-event tags and changes completed-request defaults to WAV. Preserve a 3.1 prompt as a 3.1 prompt rather than mixing in that newer request structure. Google’s supported-model table lists single- and multi-speaker synthesis for 3.1, while its designed-voice and voice-replication controls belong to the 3.8 entries. The separate Flash Live edition handles interactive audio input; this TTS edition serves prepared text-to-audio production.

Review the recording against the written script for omitted or repeated words, names, timing of turns and the intended emotional changes. If one sentence needs a different emphasis, revise that local direction and inspect the affected transition. This workflow makes the performance brief useful: it records what should remain stable about the speaker and what should change in that passage, while the script preserves the content the audience needs to hear.

Ailoot Ultra · Speech POST /v1/audio/speech google/gemini-3.1-flash-tts-preview

google/gemini-3.1-flash-tts-preview

Google /google/gemini-3.1-flash-tts-preview

Overview

Google Gemini 3.1 Flash TTS Preview converts written scripts into expressive spoken audio. Natural-language direction, speaker Audio Profiles, Director’s Notes and inline audio tags shape pace, tone and accent. It supports native dialogue and more than 70 languages, using the 3.1 prompt and audio format.

Accepted inputs
Text
Results
Audio

Available in Ailoot · inputs & methods

Ailoot Ultra · Speech POST /v1/audio/speech
Input types
text
Output types
audio
FieldTypeRequirementValues & limitsDefault
FieldmodelTypestringRequirementRequiredValues & limits
google/gemini-3.1-flash-tts-preview
Default—
FieldinputTypestringRequirementRequiredValues & limits
Minimum length: 1
Default—
FieldvoiceTypestringRequirementRequiredValues & limits
Zephyr, Puck, Charon, Kore, Fenrir, Leda, Orus, Aoede, Callirrhoe, Autonoe, Enceladus, Iapetus, Umbriel, Algieba, Despina, Erinome, Algenib, Rasalgethi, Laomedeia, Achernar, Alnilam, Schedar, Gacrux, Pulcherrima, Achird, Zubenelgenubi, Vindemiatrix, Sadachbia, Sadaltager, Sulafat
Minimum length: 1
Default—
Fieldresponse_formatTypestringRequirementOptionalValues & limits
mp3, pcm
Defaultpcm
FieldproviderTypeobjectRequirementOptionalValues & limitsDefault—
Method parameters and lifecycle
ParameterContract
Parametercontent_typeContractapplication/json
ParameterrequiredContractmodel, input, voice
Parametermaterial_typesContracttext

Lifecycle: synchronous_result_then_owned_library

GET /v1/media/tasks/{task_id} · actual returned task_id or media library record

GET /v1/media/assets/{asset_id}/content

GET /v1/media/assets

GET /v1/media/assets/{asset_id}

Pricing

Tariff references do not add request options. Supported parameters are listed for the selected method.

Fast mode
Not specified When fast mode is selected
Flex mode
Not specified When flex mode is selected
Maximum reasoning effort
Not specified When maximum reasoning effort uses the default adjustment

Ailoot rates

Prices by configuration

Match each charge to the conditions shown. Use one rate for each set of alternative configurations.

ConfigurationRate scheduleBilling unitCharge
ConfigurationBase token ratesRate scheduleBase rateBilling unit—Charge
Input · Input tokens — / 1K tokens
Output · Output tokens — / 1K tokens
Input · Cache read — / 1K tokens
Input · Cache write — / 1K tokens
Input · Cache write, 1 hour — / 1K tokens
Configurationinput tokenRate schedule—Billing unit/ 1K tokensCharge
Input · input token $0.002 / 1K tokens
Configurationoutput tokenRate schedule—Billing unit/ 1K tokensCharge
Output · output token $0.04 / 1K tokens

Ailoot reserves an estimated amount before a request. After the result, it settles the final charge from measured usage. Streaming settlement uses the final usage record. How reservation and settlement work →

Example requests

Ailoot Ultra · Speech

Use actual input and retain the complete result
set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
: "${AILOOT_INPUT_TEXT:?Set the actual documented input value}"
export AILOOT_INPUT_TEXT
python3 - <<'PY_REQUEST'
import json,os
from pathlib import Path
request={'model': 'google/gemini-3.1-flash-tts-preview', 'input': '${ACTUAL_INPUT_TEXT}', 'voice': 'Orus', 'response_format': 'pcm'}
request['input']=os.environ['AILOOT_INPUT_TEXT']
Path('request.json').write_text(json.dumps(request,ensure_ascii=False),encoding='utf-8')
PY_REQUEST
curl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/audio/speech \
  -H "Authorization: Bearer $AILOOT_API_KEY" -H 'Content-Type: application/json' \
  --data-binary @request.json -D response-headers.txt -o response.bin
# Retain the complete response and headers, every actual output, original returned identifiers and all usage fields. Recover the original operation without submitting creation again.

Receive and save results

Ailoot Ultra · Speech

Complete binary audio or original audio_url response, headers and every owned asset.

  • GET /v1/media/tasks/{task_id}
  • GET /v1/media/assets/{asset_id}/content
  • GET /v1/media/assets
  • GET /v1/media/assets/{asset_id}
Other content reads
Read existing owned assets
set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
curl --fail-with-body --silent --show-error https://api.ailoot.ai/v1/media/assets \
  -H "Authorization: Bearer $AILOOT_API_KEY" -o owned-assets.json
# Preserve every returned asset and follow its exact signed content URL. Do not construct a signed token.
Keep all completed results

Keep every complete returned response, file and content part.

Retain the complete response and headers, every actual output, original returned identifiers and all usage fields. Recover the original operation without submitting creation again.

If the original response needs checking

Keep the returned X-Client-Request-ID for reconciliation. Read only actual returned task_id/asset_id values or the owned media library; never build a task URL from the operation ID and never resubmit creation.

Aliases

Model aliases

Ailoot Ultra google/gemini-3.1-flash-tts-preview

Method path aliases

Use the method paths shown above.

Related caller IDs

google/gemini-3.1-flash-tts-preview

FAQ · Google: Gemini 3.1 Flash TTS Preview
What inputs and results are available?

POST /v1/audio/speech · google/gemini-3.1-flash-tts-preview: text → audio

Which fields does the request use?

POST /v1/audio/speech · google/gemini-3.1-flash-tts-preview: model, input, voice, response_format, provider

More details

Connect Ailoot to Claude Code, OpenCode, Hermes or your own app.

The company and its project portfolio

The company and its project portfolio: millions of customers; monthly sales in the billions.

Buy tokens at a discount.

Subscription discounts for regular use. Promo codes offer up to 50% off token purchases.

Subscription
Choose a discounted plan for your regular requests.
Promo code: up to 50% off
Enter your code at checkout. The price updates to reflect the current promotion.
Spending in your history
The model, tokens and amount are recorded for each request.

Choose a subscription · View model prices

Connect the API to a product you sell.

Use Ailoot in SaaS, apps and bots under its official service offer and licence agreement. Request a reseller licence for resale.

Commercial application
Add text, image, video and audio generation to paid features in your service.
Reseller licence
Send a description of your project and how you provide access. Request written terms for use and resale.
Documents on the website
The service offer, licence agreement and data processing policy are available before you connect.

Request a reseller licence · Service offer and licence agreement