ᡤᡝᠯᡳ ᡩᡝ ᠵᡠᠸᡝᠨ

xAI Text to Speech

ᠵᡠᠸᡝᠪᡠᠮᠪᡳ

ᠮᠣᡩᡝᠯ id xai/tts/v1
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/xai/tts/v1?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "Hello from Doitong. This is a short test sentence."
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

ᡝᠨᡳ ᠵᠠᠯᡳᠨ: $0.001 1 API ᠺᠷᡝᡩᡳᠲ ᡝᡵᡝ ᠵᠠᠯᡳᠨᡩᡝ ᠠᠰᡠᠮᠪᡳ

API ᡩᠠᠮᡠᠨ ᡤᠠᠯᠠ

ᡥᡡᠯᡠᠨ ᠵᡠᠰᡤᡠᠨ ᠪᡝ ᠵᡠᠰᡤᡠᠨ ᡩᡝ ᠠᠯᡤᡳᠮᡝ, ᠪᡝᠯᡝᡥᡝ ᠵᡠᠰᡤᡠᠨ ᡳᠨᡠ ᠵᡠᠰᡤᡠᠨ ᡳ ᡶᡳᠰᡳᠨ ᠵᡠᠰᡤᡠᠨ ᠪᡝ ᠠᠰᡠᠯᠠᠮᡝ

xAI · ᡤᡳᠰᡠᠨ

ᡳᠨᡝ ᡝᠮᡠᠨᡳᠩᡤᡝ ᡝᡵᡝᠮᡝ ᡩᡝ

ᡝᡵᡝ ᠵᡠᠯᡝᠨ ᡩᡝ ᡤᡝᡪᡳᠯᡝᠨ ᠪᠠᠶᠠᠨᠠᠮᡝ ᠠᠮᡪᠠᠯᠠ ᡶᡳᠯᡝᠮᡝ ᠪᡝᠶᡝᠮᡝ᠃ API ᠵᡳᡵᡤᠠᡳ ᡤᠠᡳᡥᠠᡩᡝ ᡤᡝᡪᡳᠯᡝᠨ ᠵᠠᠯᠠᠨᠠᠮᡝ ᠪᡠᠶᡝᠮᡝ ᠮᡠᠰᡝᡳ ᠰᡠᠯᡠᠨᡩᡝ ᠪᠠᠶᠠᠨᠠᠮᡝ᠂ ᠝ᠮᡤᡳ ᠮᡠᠰᡝ ᠠᠶᠠᠨ 7 ᡥᠠᠨ ᠰᠠᡳᠨᠠᠮᡝ᠃

ᡤᡳᠰᡠᠨ ᠪᡠᠶᡝᠮᡝ

ᠵᠠᡴᡠᠨᡳ ᠵᡠᠯᡝ ᡩᡝᡵᡤᡳ ᡩᡝᠪᡝᠰᡠᠮᡝ ᠵᡠᠯᡤᡝ ᠪᡠᠶᡝᠮᡝ᠈ ᡳᠨᡳ ᡤᡳᠰᡠᠨ ᠪᠠᡳ ᡝᠨᡝᠩᡤᡳ ᠠᠮᠪᡳ

•ᡴᠠᠷᠠᡴᡡ 50 / 15000

ᡤᡳᠰᡠᠨ ᡳ ᠪᡠᠶᡝᠮᡝ ᡩᡝ ᡥᡡᠯᠠᠨ᠂ ᠵᡠᠯᡝ ᡳ ᠵᡠᠪᡝᠨ ᠪᡝ inline tags ([laugh], [pause], [sigh]) ᡶᡳ wrapping tags (<whisper>text</whisper>, <slow>text</slow>) ᠵᡝᠯᡝᠮᡝ ᠵᡠᠯᡝ ᡳ ᠮᡠᠰᡝ ᠪᡠᠶᡝᠮᡝ᠉ ᡝᡵᡝᠮᡝ ᠪᡠᠮᡝ 15,000 ᠵᡠᠪᡝᠨ ᡩᡝ ᠠᠰᡠᡵᡠ ᠪᡝ ᠠᠰᡠᡵᡠ ᠣᠮᠪᡳ᠉

ᠵᡠᠯᡤᡝ ᠵᡝᡵᡤᡳ voice · language · enable_safety_checker · output_format
ᠵᡠᠯᡝ eve

ᡤᡳᠰᡠᠨ ᡳ ᠵᡠᠯᡝ ᠪᡠᠶᡝᠮᡝ ᡩᡝ ᠰᡳᠯᡤᠠᠮᡝ ᠪᡝᠯᡝ ᡤᡳᠰᡠᠨ᠉

ᠵᡠᠯᡝ auto

ᡝᡵᡝ BCP-47 ᠵᡠᠯᡝ ᡩᡝ ᠪᡳ: en, zh, fr, de, hi, id, it, ja, ko, pt-BR, pt-PT, ru, es-MX, es-ES, tr, vi, bn, ar-EG, ar-SA, ar-AE᠉ ᠵᡠᠯᡝ ᡳ ᠠᠪᡠᠯᠠᠮᡝ ᠵᠠᠯᡠᠮᡝ ᡩᡝ 'auto' ᠪᡝ ᠵᡠᠯᡝ ᠪᡠᠮᡝ᠉

ᠪᡠᠶᡝᠮᡝ ᡳ ᡤᡳᠰᡠᠨ ᡳ ᠵᡠᠯᡝ ᡩᡝ ᠵᡠᠯᡝ ᡳ MP3᠂ 24 kHz ᠮᡠᠰᡝ ᠪᡝ 128 kbps ᠪᡳ᠉

POST /run/xai/tts/v1?wait=20 ᠵᠠᠯᡳᠨ → $0.001
# Run the model; wait up to 20 s for the finished result in the same call
curl -X POST "https://api.doitong.com/v1/run/xai/tts/v1?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{
    "text": "Hello from Doitong. This is a short test sentence."
  }'

# Still "queued" or "running"? Poll with the id from the response:
curl "https://api.doitong.com/v1/requests/REQUEST_ID?wait=20" \
  -H "Authorization: Bearer $DOITONG_API_KEY"

ᡝᠨᡳ ᠵᠠᠯᡳᠨ ᠪᡝ ᠵᠠᠯᠠᠨᠠᠮᡝ

ᡳᠨᡝ ᠵᠠᠯᠠᠨ ᡝᡵᡝ ᠪᡠᡵᡝᠪᡝᡵᡳ ᡩᡝ ᠪᡳᠮᡝ᠈ Doitong API ᡩᡝ ᠵᡝᠯᡤᡳ ᡩᠠᡵᠠᠮᡝ᠈ Remember ᠵᡠᠯᡝᠮᡝ ᡤᡳᠯᠠᠮᡝ localStorage ᡩᡝ ᠰᡠᠯᡝᠮᡝ ᠪᡳᠮᡝ API ᠵᠠᠯᠠᠨ ᠠᠪᠠᠮᡝ

xAI Text to Speech ᡠᡵᡝᠮᡝ

ᡥᡡᠯᠠᡥᠠ 15,000 ᡥᡡᠯᡝᡥᡝᠩᡤᡝ ᠪᡝ ᡤᡡᠯᡤᡝᠮᡝ ᡤᡝᠯᡵᡳ ᠠᡩᠠᠯᠠᠮᠪᡳ᠉ 28 ᠵᡠᠰᡳ ᡥᡡᠯᡝᡥᡝ ᡤᡝᠯᡵᡳ ᡤᡠᠯᡤᡝᠮᡝ ᡝᠮᡠ ᡤᡡᠯᡳ ᡥᡡᠯᡝᠨ ᡤᡡᠨᡳᠨ ᠪᡝ ᡥᡡᠯᠠᠮᡝ ᡩᡠᠯᡝᠮᡝ ᠠᠴᠠᠮᠪᡳ᠉ ᡝᡵᡝ ᡥᡡᠯᡝᡥᡝ ᠰᡳᠨᡩᠠᠨ ᠰᡝᡵᡤᡳᠶᡝ ᠵᡠᠰᡳ ᠰᡳᠨᡩᠠᠨ ᠰᡝᠮᡝ [laugh], [pause] ᠪᡝ [sigh] ᡝᠮᡳ ᠠᠴᠠᠮᠪᡳ᠉ <whisper> ᠮᠠᠩᡤᡳ <slow> ᠰᡳᠨᡩᠠᠨ ᠰᡝᠮᡝ ᠵᡠᠰᡳ ᠠᠴᠠᠮᠪᡳ᠉ `output_format` ᡤᡡᠯᡤᡝᠮᡝ ᠠᡩᠠᠯᠠᠮᡝ ᠠᡳᠰᡳ ᠪᡝ ᠵᠠᠯᠠᠨ ᠠᠴᠠᠮᠪᡳ᠉

ᠵᠠᡴᡠᠨ

ᠵᡝᡵᡤᡳᡠᠯᠠᠮᡝ ᠵᠠᠯᠠᠨᡳ ᠵᡠᠯᡝᠠᠪᠠᠮᡝ ᠵᠠᠪᡠᠨ ᠵᠠᠯᠠᠨᡳ ᡤᡳᠰᡠᠨ
textᡴᠠᠷᠠᡴᡡ
ᡠᠯᠠᠮᡝstring
≤ 15,000 ᠵᡳᠪᡝᠨ
ᡤᡳᠰᡠᠨ ᡳ ᠪᡠᠶᡝᠮᡝ ᡩᡝ ᡥᡡᠯᠠᠨ᠂ ᠵᡠᠯᡝ ᡳ ᠵᡠᠪᡝᠨ ᠪᡝ inline tags ([laugh], [pause], [sigh]) ᡶᡳ wrapping tags (<whisper>text</whisper>, <slow>text</slow>) ᠵᡝᠯᡝᠮᡝ ᠵᡠᠯᡝ ᡳ ᠮᡠᠰᡝ ᠪᡠᠶᡝᠮᡝ᠉ ᡝᡵᡝᠮᡝ ᠪᡠᠮᡝ 15,000 ᠵᡠᠪᡝᠨ ᡩᡝ ᠠᠰᡠᡵᡠ ᠪᡝ ᠠᠰᡠᡵᡠ ᠣᠮᠪᡳ᠉
voiceᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝenum
ᠵᠠᠯᠠᠨᡳ ᠵᡠᠯᡝeve
carinazaganhelixorionlunairisaltairzenithperseusheliosluxkeplerrigelcosmocelesteursa
+12 ᡝᠨᡝsiriuslumencastornakshatlasauroralioraaraeveleorexsal
ᡤᡳᠰᡠᠨ ᡳ ᠵᡠᠯᡝ ᠪᡠᠶᡝᠮᡝ ᡩᡝ ᠰᡳᠯᡤᠠᠮᡝ ᠪᡝᠯᡝ ᡤᡳᠰᡠᠨ᠉
languageᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝenum
ᠵᠠᠯᠠᠨᡳ ᠵᡠᠯᡝauto
autoenar-EGar-SAar-AEbnzhfrdehiiditjakopt-BRpt-PT
+5 ᡝᠨᡝrues-MXes-EStrvi
ᡝᡵᡝ BCP-47 ᠵᡠᠯᡝ ᡩᡝ ᠪᡳ: en, zh, fr, de, hi, id, it, ja, ko, pt-BR, pt-PT, ru, es-MX, es-ES, tr, vi, bn, ar-EG, ar-SA, ar-AE᠉ ᠵᡠᠯᡝ ᡳ ᠠᠪᡠᠯᠠᠮᡝ ᠵᠠᠯᡠᠮᡝ ᡩᡝ 'auto' ᠪᡝ ᠵᡠᠯᡝ ᠪᡠᠮᡝ᠉
output_formatᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝobject
ᠪᡠᠶᡝᠮᡝ ᡳ ᡤᡳᠰᡠᠨ ᡳ ᠵᡠᠯᡝ ᡩᡝ ᠵᡠᠯᡝ ᡳ MP3᠂ 24 kHz ᠮᡠᠰᡝ ᠪᡝ 128 kbps ᠪᡳ᠉
output_format.codecᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝenum
ᠵᠠᠯᠠᠨᡳ ᠵᡠᠯᡝmp3
mp3wavpcmmulawalaw
ᡤᡳᠰᡠᠨ ᡳ ᠵᡠᠯᡝ ᡩᡝ ᠪᡳᠯᡝᠮᡝ ᡳ codec; ᠪᡳ: mp3, wav, pcm, mulaw, alaw᠉
output_format.sample_rateᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝenum
ᠵᠠᠯᠠᠨᡳ ᠵᡠᠯᡝ24000
80001600022050240004410048000
ᡤᡳᠰᡠᠨ ᡳ ᠵᡠᠯᡝ ᡳ ᠮᡠᠰᡝ᠂ Hz ᡩᡝ ᠵᠠᠯᡠᠮᡝ᠉
output_format.bit_rateᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝenum
320006400096000128000192000
MP3 ᠪᡠᠶᡝᠮᡝ ᡳ ᠪᡳᡨᡥᡝ ᡳ ᠵᡠᠯᡝ᠂ ᠵᡠᠯᡝ ᡳ 128000 ᠪᡳ ᡩᡝ bps ᡩᡝ ᠵᠠᠯᡠᠮᡝ᠉ ᡝᠯᡝ ᠪᡳᠯᡝᠮᡝ ᡩᡝ ᠠᠮᠠᠰᡳ ᠪᡳᠯᡝᠮᡝ ᡩᡝ ᠠᠰᡠᡵᡠ ᠣᠮᠪᡳ᠉
enable_safety_checkerᠵᡠᠯᡝ
ᡠᠯᠠᠮᡝboolean
ᠵᠠᠯᠠᠨᡳ ᠵᡠᠯᡝtrue
ᠠᠰᡠᡵᠠᠮᡝ ᠠᠨᡩᠠ ᠪᡳᠮᡝ ᠰᠠᡳᠨ᠈ ᠵᡠᠴᡝᠨ ᠵᡠᠰᡝ ᠠᠰᡠᡵᠠᠮᡝ᠉
ᡴᠠᠷᠠᡴᡡ

ᠪᡠᠶᡝᠮᡝ

GET /requests/req_8k2m4q7x1z9c3v5b6n0p2r4t
{
  "id": "req_8k2m4q7x1z9c3v5b6n0p2r4t",
  "object": "request",
  "model": "xai/tts/v1",
  "status": "succeeded",
  "created_at": "2026-10-20T12:00:00Z",
  "started_at": "2026-10-20T12:00:02Z",
  "completed_at": "2026-10-20T12:00:09Z",
  "queue_position": null,
  "cost": {
    "credits": 1,
    "usd": "0.001",
    "charged": 1,
    "refunded": 0
  },
  "input": {
    "text": "Hello from Doitong. This is a short test sentence."
  },
  "output": {
    "audio": {
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp3",
      "content_type": "audio/mpeg",
      "file_name": "0-output.mp3",
      "file_size": 1843200
    }
  },
  "outputs": [
    {
      "type": "audio",
      "url": "https://content.doitong.com/dev-api/2026/10/20/req_8k2m4q7x1z9c3v5b6n0p2r4t/0-output.mp3",
      "content_type": "audio/mpeg",
      "file_size": 1843200,
      "duration": 12,
      "stored": true
    }
  ],
  "error": null,
  "metrics": {
    "inference_seconds": 6.8
  },
  "urls": {
    "self": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t",
    "cancel": "https://api.doitong.com/v1/requests/req_8k2m4q7x1z9c3v5b6n0p2r4t/cancel"
  }
}
ᡤᡝᠯᡝᠮᡝ ᡥᡡᠯᡤᡠᠨᡳ ᡳᠨᡠᡝᠯᡝᡥᡝ outputs[].url ᠰᡠᠯᡠᠨ ᡩᡝ ᠰᡳᡵᡝ ᡶᡳᠯᡝ᠈ ᠝ᠮᡤᡳ ᠮᡠᠰᡝ ᠠᠪᠠᠯᡳ ᠵᡝᠮᡤᡳᠨ GB-ᠪᡳᠶᠠ ᠵᡝᠮᡤᡳᠨ ᠪᡝ ᡝᠮᡠᠯᡝᠮᡝ ᠠᠪᠠᠯᡳ 7 ᡥᠠᠨ ᠰᡳᠯᡤᠠᠨ ᡩᡝ᠈ ᠰᡳᠨᡳ ᠪᠠᠯᠠᠨᠰᡳ ᠵᡠᠶᡝᡵᡝᠨ ᠠᠪᠠᠯᡳ ?storage= ᡩᡝ ᡝᠵᡝᠨ ᡥᠠᠯᠠᠮᡝ᠉
ᡝᠮᡠ ᡤᡳᠰᡠᠨ ᡝᠮᡠ ᠮᠣᡩᡝᠯ ᡩᡝtype, url, content_type, width, height ᠮᠠᠩᡤᡳ duration᠈ ᠵᠠᠯᠠᠨ᠈ ᠪᡠᠵᡠᠮᠪᡳ ᠮᠠᠩᡤᡳ ᠵᡝᡵᡤᡳ ᡩᡝᠨᡳ᠈ output ᠮᠣᡩᡝᠯᡳᠨᡳ ᡝᠮᡠ ᠵᠠᠯᠠᠨ
ᠪᡠᠶᡝᠮᡝᠨᡳ ᡤᡳᠰᡠᠨ
audio
object {url, content_type, file_name, file_size}ᠪᡠᠶᡝᠮᡝ ᠵᡠᡴᡴᠠᠨ ᡤᡳᠰᡠᠨ ᡳ ᡶᡳᠯᡝ᠉

AI ᠠᡤᡝᠨᡨᡳ ᡠᠴᡠᠷᡳ᠈ ᡝᡵᡝ ᡩᡝᠪᡝᡵᡳ Markdown ᠰᡳᠨᡩᠠᡵᡳ https://doitong.com/mnc/developers/models/xai/tts/v1.md. ᡝᡵᡝ ᠮᠣᡩᡝᠯ ᠵᠠᡴᡠᠨ ᠰᡠᠯᡠᠮᡝ https://doitong.com/developers/llms.txt