Microsoft AI: MAI-Voice-2.1-Flash
Microsoft AI’s MAI-Voice-2.1-Flash generates expressive speech across 23 languages for interactive voice applications. It supports streaming, multiple speakers and sentence-level delivery control, with a curated voice library.
About the model
This description covers the model’s capabilities. Available in Ailoot inputs, outputs and options are listed for the selected method below.
MAI-Voice-2.1-Flash is Microsoft AI’s prompted text-to-speech model designed around responsive spoken interaction. Its manufacturer positions it for voice assistants, customer-support conversations and telephone menus. It generates natural, expressive speech across twenty-three languages, with control over tone and delivery. Flash is the version oriented towards live response; the separately named MAI-Voice-2.1 prioritises detailed expression and fidelity for longer content.
Text, speaker and language
The input is the transcript to be spoken, with a selected voice and optional expressive instructions in SSML. The managed voice catalogue distinguishes the speaker, locale and model version. Harper and Grant are examples of named speakers with language-specific entries. Use the intended target-language text and select its appropriate locale; a prepared English greeting and a Spanish explanation are separate spoken passages, each with its own wording.
The model card documents a consistent voice identity across supported languages and multiple speakers for dialogue. That can support an application which needs one recognisable narrator across localised prompts, or a short dialogue with distinct roles. Assign the lines to the intended speakers explicitly and keep those assignments stable. The audio is the spoken version of that script, rather than a new answer composed from an open question.
Tone and speaking style
Microsoft documents sentence- and turn-level control of emotion and delivery through SSML. The available styles depend on the selected voice. The managed catalogue includes task styles such as narrator, educational and customer_call_center, alongside expressive styles for particular speakers. For example, the US Harper entry includes joyful and relieved. Choose a style supported by the voice rather than assuming that every speaker accepts the same set.
A practical support line is: “I can help you find the right document. Tell me its title, or describe the topic.” Keep the request short enough for a listener to act on, and choose a calm or encouraging delivery appropriate to the interaction. For a learning activity, write the explanation and the next question as separate spoken units. Expressiveness serves the meaning when the script makes the shift in intent clear.
Streaming and audio delivery
The Flash model card specifically documents streaming output for live dialogue, including workflows that handle a listener speaking over a response. The application can play audio as it arrives and coordinate the interruption and next turn. This makes the timing of the spoken message part of the interaction rather than requiring every response to be prepared as a complete recording first.
The manufacturer lets the synthesis workflow specify its output format. Its published example produces a mono MP3 file at 24 kHz and 160 kbit/s. That is one documented output configuration, not a fixed native-format restriction. Choose an audio representation that the intended playback path accepts and keep the speaker and spoken wording available for reviewing the result.
Optional reference-voice mode
Microsoft’s custom-voice mode can match a consented speaker from a five- to sixty-second reference clip without fine-tuning. The model card recommends natural conversational delivery with moderate energy because the reference affects the generated performance. This mode has a separate manufacturer approval and recorded-consent process; preset library voices form a distinct preparation path.
For a reference intended to define a brand narrator, use a clean, representative passage and decide which delivery should carry into the new script. For preset speech, prepare the actual names, commands and target-language phrases the application will use. Listen to those passages in the selected voice and inspect the transition between turns. The useful result is expressive spoken interaction with an intentional speaker, clear text and audio suited to the listener’s playback environment.
Ailoot Ultra · Text to speech POST /v1/audio/speech microsoft/mai-voice-2.1-flash
microsoft/mai-voice-2.1-flashOverview
Microsoft AI’s MAI-Voice-2.1-Flash generates expressive speech across 23 languages for interactive voice applications. It supports streaming, multiple speakers and sentence-level delivery control, with a curated voice library.
- Accepted inputs
- Text
- Results
- Audio
Available in Ailoot · inputs & methods
Ailoot Ultra · Text to speech POST /v1/audio/speech
- Input types
text- Output types
audio- Output format
- mp3
| Field | Type | Requirement | Values & limits | Default |
|---|---|---|---|---|
Fieldmodel | Typestring | RequirementRequired | Values & limits microsoft/mai-voice-2.1-flash | Default— |
Fieldinput | Typestring | RequirementRequired | Values & limits Minimum length: 1 Unit: Unicode characters | Default— |
Fieldvoice | Typestring | RequirementRequired | Values & limits cs-CZ-Grant:MAI-Voice-2.1-Flash, cs-CZ-Harper:MAI-Voice-2.1-Flash, da-DK-Grant:MAI-Voice-2.1-Flash, da-DK-Harper:MAI-Voice-2.1-Flash, de-DE-Grant:MAI-Voice-2.1-Flash, de-DE-Harper:MAI-Voice-2.1-Flash, de-DE-Klaus:MAI-Voice-2.1-Flash, de-DE-Mia:MAI-Voice-2.1-Flash, en-AU-Isla:MAI-Voice-2.1-Flash, en-GB-Emily:MAI-Voice-2.1-Flash, en-GB-Harry:MAI-Voice-2.1-Flash, en-IN-Dhruv:MAI-Voice-2.1-Flash, en-IN-Priya:MAI-Voice-2.1-Flash, en-US-Ethan:MAI-Voice-2.1-Flash, en-US-Grant:MAI-Voice-2.1-Flash, en-US-Harper:MAI-Voice-2.1-Flash, en-US-Iris:MAI-Voice-2.1-Flash, en-US-Jasper:MAI-Voice-2.1-Flash, en-US-Olivia:MAI-Voice-2.1-Flash, en-US-Sage:MAI-Voice-2.1-Flash, es-ES-Marta:MAI-Voice-2.1-Flash, es-MX-Alejo:MAI-Voice-2.1-Flash, es-MX-Grant:MAI-Voice-2.1-Flash, es-MX-Harper:MAI-Voice-2.1-Flash, es-MX-Valeria:MAI-Voice-2.1-Flash, fi-FI-Grant:MAI-Voice-2.1-Flash, fi-FI-Harper:MAI-Voice-2.1-Flash, fr-FR-Grant:MAI-Voice-2.1-Flash, fr-FR-Harper:MAI-Voice-2.1-Flash, fr-FR-Marc:MAI-Voice-2.1-Flash, fr-FR-Soleil:MAI-Voice-2.1-Flash, hi-IN-Arjun:MAI-Voice-2.1-Flash, hi-IN-Dhruv:MAI-Voice-2.1-Flash, hi-IN-Grant:MAI-Voice-2.1-Flash, hi-IN-Harper:MAI-Voice-2.1-Flash, hi-IN-Kavya:MAI-Voice-2.1-Flash, hi-IN-Priya:MAI-Voice-2.1-Flash, hu-HU-Bence:MAI-Voice-2.1-Flash, hu-HU-Grant:MAI-Voice-2.1-Flash, hu-HU-Harper:MAI-Voice-2.1-Flash, hu-HU-Levente:MAI-Voice-2.1-Flash, hu-HU-Lilla:MAI-Voice-2.1-Flash, hu-HU-Reka:MAI-Voice-2.1-Flash, id-ID-Grant:MAI-Voice-2.1-Flash, id-ID-Harper:MAI-Voice-2.1-Flash, it-IT-Grant:MAI-Voice-2.1-Flash, it-IT-Harper:MAI-Voice-2.1-Flash, it-IT-Luca:MAI-Voice-2.1-Flash, it-IT-Rosa:MAI-Voice-2.1-Flash, ko-KR-Grant:MAI-Voice-2.1-Flash, ko-KR-Haena:MAI-Voice-2.1-Flash, ko-KR-Harper:MAI-Voice-2.1-Flash, ko-KR-Junho:MAI-Voice-2.1-Flash, nb-NO-Grant:MAI-Voice-2.1-Flash, nb-NO-Harper:MAI-Voice-2.1-Flash, nl-NL-Grant:MAI-Voice-2.1-Flash, nl-NL-Harper:MAI-Voice-2.1-Flash, nl-NL-Sander:MAI-Voice-2.1-Flash, pl-PL-Grant:MAI-Voice-2.1-Flash, pl-PL-Harper:MAI-Voice-2.1-Flash, pt-BR-Caio:MAI-Voice-2.1-Flash, pt-BR-Grant:MAI-Voice-2.1-Flash, pt-BR-Harper:MAI-Voice-2.1-Flash, pt-BR-Luana:MAI-Voice-2.1-Flash, pt-BR-Pedro:MAI-Voice-2.1-Flash, pt-BR-Rafael:MAI-Voice-2.1-Flash, pt-PT-Grant:MAI-Voice-2.1-Flash, pt-PT-Harper:MAI-Voice-2.1-Flash, pt-PT-Rui:MAI-Voice-2.1-Flash, ro-RO-Andrei:MAI-Voice-2.1-Flash, ro-RO-Elena:MAI-Voice-2.1-Flash, ro-RO-Grant:MAI-Voice-2.1-Flash, ro-RO-Harper:MAI-Voice-2.1-Flash, ro-RO-Ioana:MAI-Voice-2.1-Flash, ro-RO-Radu:MAI-Voice-2.1-Flash, ru-RU-Grant:MAI-Voice-2.1-Flash, ru-RU-Harper:MAI-Voice-2.1-Flash, ru-RU-Lev:MAI-Voice-2.1-Flash, ru-RU-Masha:MAI-Voice-2.1-Flash, sv-SE-Grant:MAI-Voice-2.1-Flash, sv-SE-Harper:MAI-Voice-2.1-Flash, th-TH-Grant:MAI-Voice-2.1-Flash, th-TH-Harper:MAI-Voice-2.1-Flash, th-TH-Krit:MAI-Voice-2.1-Flash, th-TH-Nattapong:MAI-Voice-2.1-Flash, tr-TR-Aydin:MAI-Voice-2.1-Flash, tr-TR-Elif:MAI-Voice-2.1-Flash, tr-TR-Grant:MAI-Voice-2.1-Flash, tr-TR-Harper:MAI-Voice-2.1-Flash, vi-VN-Grant:MAI-Voice-2.1-Flash, vi-VN-Harper:MAI-Voice-2.1-Flash, zh-CN-Bo:MAI-Voice-2.1-Flash, zh-CN-Grant:MAI-Voice-2.1-Flash, zh-CN-Harper:MAI-Voice-2.1-Flash, zh-CN-Lan:MAI-Voice-2.1-Flash, zh-CN-Mei:MAI-Voice-2.1-Flash, zh-CN-Wei:MAI-Voice-2.1-Flash | Default— |
Fieldresponse_format | Typestring | RequirementRequired | Values & limits mp3 | Default— |
Input material combinations
text_to_speech · Required: input
Method parameters and lifecycle
| Parameter | Contract |
|---|---|
Parametercontent_type | Contractapplication/json |
Parameterrequired | Contractmodel, input, voice, response_format |
Parametervoice_ids | Contractcs-CZ-Grant:MAI-Voice-2.1-Flash, cs-CZ-Harper:MAI-Voice-2.1-Flash, da-DK-Grant:MAI-Voice-2.1-Flash, da-DK-Harper:MAI-Voice-2.1-Flash, de-DE-Grant:MAI-Voice-2.1-Flash, de-DE-Harper:MAI-Voice-2.1-Flash, de-DE-Klaus:MAI-Voice-2.1-Flash, de-DE-Mia:MAI-Voice-2.1-Flash, en-AU-Isla:MAI-Voice-2.1-Flash, en-GB-Emily:MAI-Voice-2.1-Flash, en-GB-Harry:MAI-Voice-2.1-Flash, en-IN-Dhruv:MAI-Voice-2.1-Flash, en-IN-Priya:MAI-Voice-2.1-Flash, en-US-Ethan:MAI-Voice-2.1-Flash, en-US-Grant:MAI-Voice-2.1-Flash, en-US-Harper:MAI-Voice-2.1-Flash, en-US-Iris:MAI-Voice-2.1-Flash, en-US-Jasper:MAI-Voice-2.1-Flash, en-US-Olivia:MAI-Voice-2.1-Flash, en-US-Sage:MAI-Voice-2.1-Flash, es-ES-Marta:MAI-Voice-2.1-Flash, es-MX-Alejo:MAI-Voice-2.1-Flash, es-MX-Grant:MAI-Voice-2.1-Flash, es-MX-Harper:MAI-Voice-2.1-Flash, es-MX-Valeria:MAI-Voice-2.1-Flash, fi-FI-Grant:MAI-Voice-2.1-Flash, fi-FI-Harper:MAI-Voice-2.1-Flash, fr-FR-Grant:MAI-Voice-2.1-Flash, fr-FR-Harper:MAI-Voice-2.1-Flash, fr-FR-Marc:MAI-Voice-2.1-Flash, fr-FR-Soleil:MAI-Voice-2.1-Flash, hi-IN-Arjun:MAI-Voice-2.1-Flash, hi-IN-Dhruv:MAI-Voice-2.1-Flash, hi-IN-Grant:MAI-Voice-2.1-Flash, hi-IN-Harper:MAI-Voice-2.1-Flash, hi-IN-Kavya:MAI-Voice-2.1-Flash, hi-IN-Priya:MAI-Voice-2.1-Flash, hu-HU-Bence:MAI-Voice-2.1-Flash, hu-HU-Grant:MAI-Voice-2.1-Flash, hu-HU-Harper:MAI-Voice-2.1-Flash, hu-HU-Levente:MAI-Voice-2.1-Flash, hu-HU-Lilla:MAI-Voice-2.1-Flash, hu-HU-Reka:MAI-Voice-2.1-Flash, id-ID-Grant:MAI-Voice-2.1-Flash, id-ID-Harper:MAI-Voice-2.1-Flash, it-IT-Grant:MAI-Voice-2.1-Flash, it-IT-Harper:MAI-Voice-2.1-Flash, it-IT-Luca:MAI-Voice-2.1-Flash, it-IT-Rosa:MAI-Voice-2.1-Flash, ko-KR-Grant:MAI-Voice-2.1-Flash, ko-KR-Haena:MAI-Voice-2.1-Flash, ko-KR-Harper:MAI-Voice-2.1-Flash, ko-KR-Junho:MAI-Voice-2.1-Flash, nb-NO-Grant:MAI-Voice-2.1-Flash, nb-NO-Harper:MAI-Voice-2.1-Flash, nl-NL-Grant:MAI-Voice-2.1-Flash, nl-NL-Harper:MAI-Voice-2.1-Flash, nl-NL-Sander:MAI-Voice-2.1-Flash, pl-PL-Grant:MAI-Voice-2.1-Flash, pl-PL-Harper:MAI-Voice-2.1-Flash, pt-BR-Caio:MAI-Voice-2.1-Flash, pt-BR-Grant:MAI-Voice-2.1-Flash, pt-BR-Harper:MAI-Voice-2.1-Flash, pt-BR-Luana:MAI-Voice-2.1-Flash, pt-BR-Pedro:MAI-Voice-2.1-Flash, pt-BR-Rafael:MAI-Voice-2.1-Flash, pt-PT-Grant:MAI-Voice-2.1-Flash, pt-PT-Harper:MAI-Voice-2.1-Flash, pt-PT-Rui:MAI-Voice-2.1-Flash, ro-RO-Andrei:MAI-Voice-2.1-Flash, ro-RO-Elena:MAI-Voice-2.1-Flash, ro-RO-Grant:MAI-Voice-2.1-Flash, ro-RO-Harper:MAI-Voice-2.1-Flash, ro-RO-Ioana:MAI-Voice-2.1-Flash, ro-RO-Radu:MAI-Voice-2.1-Flash, ru-RU-Grant:MAI-Voice-2.1-Flash, ru-RU-Harper:MAI-Voice-2.1-Flash, ru-RU-Lev:MAI-Voice-2.1-Flash, ru-RU-Masha:MAI-Voice-2.1-Flash, sv-SE-Grant:MAI-Voice-2.1-Flash, sv-SE-Harper:MAI-Voice-2.1-Flash, th-TH-Grant:MAI-Voice-2.1-Flash, th-TH-Harper:MAI-Voice-2.1-Flash, th-TH-Krit:MAI-Voice-2.1-Flash, th-TH-Nattapong:MAI-Voice-2.1-Flash, tr-TR-Aydin:MAI-Voice-2.1-Flash, tr-TR-Elif:MAI-Voice-2.1-Flash, tr-TR-Grant:MAI-Voice-2.1-Flash, tr-TR-Harper:MAI-Voice-2.1-Flash, vi-VN-Grant:MAI-Voice-2.1-Flash, vi-VN-Harper:MAI-Voice-2.1-Flash, zh-CN-Bo:MAI-Voice-2.1-Flash, zh-CN-Grant:MAI-Voice-2.1-Flash, zh-CN-Harper:MAI-Voice-2.1-Flash, zh-CN-Lan:MAI-Voice-2.1-Flash, zh-CN-Mei:MAI-Voice-2.1-Flash, zh-CN-Wei:MAI-Voice-2.1-Flash |
Parameterresponse_format | Contractmp3 |
Parametermax_input_characters | Contractnull |
Parameterother_options | Contractfalse |
Parameterinput | Contractexact UTF-8 text; Unicode character count without normalization |
Parametermaterial_types | Contracttext |
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}
Select exact voice from this model profile.
Input characters and audio seconds are different meters.
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.
| Configuration | Rate schedule | Billable quantity | Billing unit | Charge |
|---|---|---|---|---|
| ConfigurationBase token rates | Rate scheduleBase rate | Billable quantity— | Billing 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 |
| ConfigurationUltra | Rate schedule— | Billable quantityEach Unicode code point counts as one character, including Han characters. | Billing unitper 1000 input character | Charge Input · input character $0.03 per 1000 input character |
Reference tariff details
Model-level reference schedules do not change method selection, quotes or charges. Active charges use the selected Ailoot method rates.
Microsoft AI: MAI-Voice-2.1-Flash
Prices by configuration
| Configuration | Billing conditions | Charge |
|---|---|---|
| ConfigurationMicrosoft AI: MAI-Voice-2.1-Flash · Default configuration | Billing conditionsDefault configuration | Charge Input · Input characters $0.00003 per input character |
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 · Text to speech
set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
: "${AILOOT_VOICE_ID:?Choose an accepted voice ID from this exact model profile}"
export AILOOT_VOICE_ID
python3 - <<'PY_REQUEST'
import json,os
from pathlib import Path
p=json.loads('{"model": "microsoft/mai-voice-2.1-flash", "input": "Good afternoon! This is a short voice take."}')
voice=os.environ["AILOOT_VOICE_ID"]
allowed=json.loads('["cs-CZ-Grant:MAI-Voice-2.1-Flash", "cs-CZ-Harper:MAI-Voice-2.1-Flash", "da-DK-Grant:MAI-Voice-2.1-Flash", "da-DK-Harper:MAI-Voice-2.1-Flash", "de-DE-Grant:MAI-Voice-2.1-Flash", "de-DE-Harper:MAI-Voice-2.1-Flash", "de-DE-Klaus:MAI-Voice-2.1-Flash", "de-DE-Mia:MAI-Voice-2.1-Flash", "en-AU-Isla:MAI-Voice-2.1-Flash", "en-GB-Emily:MAI-Voice-2.1-Flash", "en-GB-Harry:MAI-Voice-2.1-Flash", "en-IN-Dhruv:MAI-Voice-2.1-Flash", "en-IN-Priya:MAI-Voice-2.1-Flash", "en-US-Ethan:MAI-Voice-2.1-Flash", "en-US-Grant:MAI-Voice-2.1-Flash", "en-US-Harper:MAI-Voice-2.1-Flash", "en-US-Iris:MAI-Voice-2.1-Flash", "en-US-Jasper:MAI-Voice-2.1-Flash", "en-US-Olivia:MAI-Voice-2.1-Flash", "en-US-Sage:MAI-Voice-2.1-Flash", "es-ES-Marta:MAI-Voice-2.1-Flash", "es-MX-Alejo:MAI-Voice-2.1-Flash", "es-MX-Grant:MAI-Voice-2.1-Flash", "es-MX-Harper:MAI-Voice-2.1-Flash", "es-MX-Valeria:MAI-Voice-2.1-Flash", "fi-FI-Grant:MAI-Voice-2.1-Flash", "fi-FI-Harper:MAI-Voice-2.1-Flash", "fr-FR-Grant:MAI-Voice-2.1-Flash", "fr-FR-Harper:MAI-Voice-2.1-Flash", "fr-FR-Marc:MAI-Voice-2.1-Flash", "fr-FR-Soleil:MAI-Voice-2.1-Flash", "hi-IN-Arjun:MAI-Voice-2.1-Flash", "hi-IN-Dhruv:MAI-Voice-2.1-Flash", "hi-IN-Grant:MAI-Voice-2.1-Flash", "hi-IN-Harper:MAI-Voice-2.1-Flash", "hi-IN-Kavya:MAI-Voice-2.1-Flash", "hi-IN-Priya:MAI-Voice-2.1-Flash", "hu-HU-Bence:MAI-Voice-2.1-Flash", "hu-HU-Grant:MAI-Voice-2.1-Flash", "hu-HU-Harper:MAI-Voice-2.1-Flash", "hu-HU-Levente:MAI-Voice-2.1-Flash", "hu-HU-Lilla:MAI-Voice-2.1-Flash", "hu-HU-Reka:MAI-Voice-2.1-Flash", "id-ID-Grant:MAI-Voice-2.1-Flash", "id-ID-Harper:MAI-Voice-2.1-Flash", "it-IT-Grant:MAI-Voice-2.1-Flash", "it-IT-Harper:MAI-Voice-2.1-Flash", "it-IT-Luca:MAI-Voice-2.1-Flash", "it-IT-Rosa:MAI-Voice-2.1-Flash", "ko-KR-Grant:MAI-Voice-2.1-Flash", "ko-KR-Haena:MAI-Voice-2.1-Flash", "ko-KR-Harper:MAI-Voice-2.1-Flash", "ko-KR-Junho:MAI-Voice-2.1-Flash", "nb-NO-Grant:MAI-Voice-2.1-Flash", "nb-NO-Harper:MAI-Voice-2.1-Flash", "nl-NL-Grant:MAI-Voice-2.1-Flash", "nl-NL-Harper:MAI-Voice-2.1-Flash", "nl-NL-Sander:MAI-Voice-2.1-Flash", "pl-PL-Grant:MAI-Voice-2.1-Flash", "pl-PL-Harper:MAI-Voice-2.1-Flash", "pt-BR-Caio:MAI-Voice-2.1-Flash", "pt-BR-Grant:MAI-Voice-2.1-Flash", "pt-BR-Harper:MAI-Voice-2.1-Flash", "pt-BR-Luana:MAI-Voice-2.1-Flash", "pt-BR-Pedro:MAI-Voice-2.1-Flash", "pt-BR-Rafael:MAI-Voice-2.1-Flash", "pt-PT-Grant:MAI-Voice-2.1-Flash", "pt-PT-Harper:MAI-Voice-2.1-Flash", "pt-PT-Rui:MAI-Voice-2.1-Flash", "ro-RO-Andrei:MAI-Voice-2.1-Flash", "ro-RO-Elena:MAI-Voice-2.1-Flash", "ro-RO-Grant:MAI-Voice-2.1-Flash", "ro-RO-Harper:MAI-Voice-2.1-Flash", "ro-RO-Ioana:MAI-Voice-2.1-Flash", "ro-RO-Radu:MAI-Voice-2.1-Flash", "ru-RU-Grant:MAI-Voice-2.1-Flash", "ru-RU-Harper:MAI-Voice-2.1-Flash", "ru-RU-Lev:MAI-Voice-2.1-Flash", "ru-RU-Masha:MAI-Voice-2.1-Flash", "sv-SE-Grant:MAI-Voice-2.1-Flash", "sv-SE-Harper:MAI-Voice-2.1-Flash", "th-TH-Grant:MAI-Voice-2.1-Flash", "th-TH-Harper:MAI-Voice-2.1-Flash", "th-TH-Krit:MAI-Voice-2.1-Flash", "th-TH-Nattapong:MAI-Voice-2.1-Flash", "tr-TR-Aydin:MAI-Voice-2.1-Flash", "tr-TR-Elif:MAI-Voice-2.1-Flash", "tr-TR-Grant:MAI-Voice-2.1-Flash", "tr-TR-Harper:MAI-Voice-2.1-Flash", "vi-VN-Grant:MAI-Voice-2.1-Flash", "vi-VN-Harper:MAI-Voice-2.1-Flash", "zh-CN-Bo:MAI-Voice-2.1-Flash", "zh-CN-Grant:MAI-Voice-2.1-Flash", "zh-CN-Harper:MAI-Voice-2.1-Flash", "zh-CN-Lan:MAI-Voice-2.1-Flash", "zh-CN-Mei:MAI-Voice-2.1-Flash", "zh-CN-Wei:MAI-Voice-2.1-Flash"]')
if voice not in allowed: raise SystemExit("Choose an accepted voice ID from this exact model profile")
p["voice"]=voice
p["response_format"]="mp3"
Path("request.json").write_text(json.dumps(p,ensure_ascii=False))
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 speech.mp3
Receive and save results
Ailoot Ultra · Text to speech
mp3
GET /v1/media/tasks/{task_id}GET /v1/media/assets/{asset_id}/contentGET /v1/media/assetsGET /v1/media/assets/{asset_id}
Other content reads
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 media-assets.json
set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
: "${AILOOT_MEDIA_TASK_ID:?Set the actual ID returned by the response or media-library metadata}"
export AILOOT_MEDIA_TASK_ID
resource_id=$(python3 -c 'import os,urllib.parse;print(urllib.parse.quote(os.environ["AILOOT_MEDIA_TASK_ID"],safe=""))')
curl --fail-with-body --silent --show-error "https://api.ailoot.ai/v1/media/tasks/$resource_id" \
-H "Authorization: Bearer $AILOOT_API_KEY" -o media-task.json
python3 - <<'PY_RESULT'
import json
from pathlib import Path
print(json.dumps(json.loads(Path("media-task.json").read_text())))
PY_RESULT
set -eu
: "${AILOOT_API_KEY:?Set your Ailoot API key}"
: "${AILOOT_ASSET_ID:?Set the actual ID returned by the response or media-library metadata}"
export AILOOT_ASSET_ID
resource_id=$(python3 -c 'import os,urllib.parse;print(urllib.parse.quote(os.environ["AILOOT_ASSET_ID"],safe=""))')
curl --fail-with-body --silent --show-error "https://api.ailoot.ai/v1/media/assets/$resource_id" \
-H "Authorization: Bearer $AILOOT_API_KEY" -o media-asset.json
python3 - <<'PY_RESULT'
import json
from pathlib import Path
print(json.dumps(json.loads(Path("media-asset.json").read_text())))
PY_RESULT
Keep all completed results
Keep every complete returned response, file and content part.
Keep the complete binary result and headers. If JSON/multiple outputs are returned, retain every data item and fetch each actual signed asset URL.
If the original response needs checking
Retain original operation_id/X-Client-Request-ID for reconciliation without resubmission; no dedicated audio poll route.
Response fields
| Field | Type |
|---|---|
Fieldbinary audio | Typebytes |
Fieldresponse headers | Typeheaders |
Errors and next steps
| Response | Condition | Next step |
|---|---|---|
Response400 · invalid_request_error | ConditionInvalid required fields, material representation or parameter value | Next stepCorrect the indicated fields before a new creation request. |
Responseserver_error | ConditionThe returned response says the operation or result requires a check | Next stepKeep the original returned operation/task ID, request headers and response; continue supported reads of that original operation. Do not resubmit the creation request. |
Aliases
Model aliases
Ailoot Ultra microsoft/mai-voice-2.1-flash
Method path aliases
Use the method paths shown above.
Related caller IDs
FAQ · Microsoft AI: MAI-Voice-2.1-Flash
- What inputs and results are available?
POST /v1/audio/speech·microsoft/mai-voice-2.1-flash:text→audio- Which fields does the request use?
POST /v1/audio/speech·microsoft/mai-voice-2.1-flash:model,input,voice,response_format