---
title: "Validate text-to-speech"
method: POST
path: "/v1/audio/speech/validate"
tags: ["audio"]
---

# Validate text-to-speech

`POST /v1/audio/speech/validate`

## Request

- Base URL: `https://api.beatra.ai` (the document declares no server; this is the origin it was published from)
- URL: `https://api.beatra.ai/v1/audio/speech/validate`
- Auth: none declared

## Headers

- `authorization` string, nullable

## Request body

- SpeechValidateRequest: Read-only speech check. No callback, signing key, metadata, or idempotency.
  - `voice` string, required: Opaque beatra voice_id (preset or cloned)
  - `input` string, required: Text to synthesize. It may contain speech markup such as {pause 0.5}, {laugh}, {pron 行 hang2} or {sub W3C 万维网联盟}; read the vocabulary and limits from the model card (beatra.models.list). Some models also accept inline emotion and performance markup, listed under script_markup on their card; other models skip it with a warning. Malformed markup is corrected or skipped with a markup_adjusted warning instead of failing the request. Each model has its own single-request limit (constraints.input_max_characters, and cjk_input_max_characters where present, on the model card); longer text is refused with a message that says how to split it.
  - `model` 'auto' | 'minimax-speech-2.8-hd' | 'minimax-speech-2.8-turbo' | 'doubao-seed-tts-3.0' | 'doubao-seed-tts-2.0' | 'elevenlabs-v4-turbo' | 'elevenlabs-v4': Model to check against (default auto)
  - `language` string, nullable: BCP-47 language hint
  - `format` 'mp3' | 'wav' | 'flac' | 'opus' | 'pcm': Audio format the create call would use
  - `sample_rate` 8000 | 16000 | 22050 | 24000 | 32000 | 44100, nullable: Sample rate in Hz for the chosen format
  - `speed` number: Speaking rate (0.5 to 2.0)
  - `volume` number: Volume (0 to 10)
  - `pitch` number: Normalized pitch (-1.0 to 1.0)
  - `emotion` 'happy' | 'sad' | 'angry' | 'fearful' | 'disgusted' | 'surprised' | 'calm' | 'fluent', nullable: Emotion preset for the whole request
  - `subtitle_enable` boolean: Whether the create call would request subtitles
  - `direction` string, nullable: Optional natural-language performance direction for the whole request, for example '像在耳边说悄悄话一样，轻声地说' or 'read it like breaking news'. Models and voices that follow it list direction under controls on their model card (with direction_max_characters); anywhere else it is ignored with an option_ignored warning. Effects vary with the voice and the text and are not a guarantee of intensity.
  - `previous_text` string, nullable: Optional text that comes right before this clip, for example the previous line of a dialogue or the previous paragraph, so separate calls keep a continuous tone. It is never spoken and never billed; any length is accepted and only its end is used (previous_text_tail_characters on the model card). Models and voices that do not use it ignore it with an option_ignored warning.
  - `next_text` string, nullable: Optional text that comes right after this clip, for example the next line of a dialogue or the next paragraph, so separate calls keep a continuous tone. It is never spoken and never billed; any length is accepted and only its start is used (next_text_head_characters on the model card). Models and voices that do not use it ignore it with an option_ignored warning.
  - `model_options` object, nullable: Expert provider options, same as the create call

## Response `200`

Validation report

- SpeechValidationReport
  - `valid` boolean, required: True when the request passes every preflight check
  - `warnings` TaskWarning[]: Non-blocking advisories: markup that was corrected or skipped (markup_adjusted), markup the model does not perform (markup_degraded), controls the model ignores (option_ignored), and voices scheduled for retirement (voice_retiring).
    - `code` string, required: e.g. option_clamped / auto_routed
    - `message` string, required
    - `field` string, nullable
  - `weighted_characters` integer, required: Weighted character count, the same quantity the create call bills on
  - `estimated_duration_seconds` number, nullable: Deterministic estimated audio duration in seconds factoring input, speed, and explicit pauses
  - `price_credits` string, required: Estimated credits for the create call
  - `execution` SpeechValidationExecution, required
    - `mode` string, nullable: Execution path the create call would take (sync or async)
  - `script_markup` SpeechScriptMarkup, nullable
    - `pause` SpeechMarkupPause, required
      - `syntax` string, required
      - `range` number[], required
      - `note` string, nullable
    - `tags` SpeechMarkupTag[], required
      - `token` string, required
      - `meaning` string, required
    - `pronunciation` SpeechMarkupPronunciation, required
      - `syntax` string, required
      - `readings` string, required
    - `escape` string, required
    - `alias` SpeechMarkupAlias, nullable
      - `syntax` string, required
      - `note` string, required
    - `inline_emotion` SpeechMarkupInlineEmotion, nullable
      - `syntax` string, required
      - `values` string[], required
      - `note` string, required
    - `performance` SpeechMarkupTag[]
      - `token` string, required
      - `meaning` string, required
  - `limitations` string[]: Capability limits declared by the resolved model

## Other responses

- `404`: Voice not found
- `422`: Invalid request or voice/model mismatch

## Changes

- **2026-12-01** `169708e3a8de`: 1 info
  - added the new `doubao-seed-tts-3.0` enum value to the request property `model`
- **2026-11-14** `c993a6dbff81`: 2 info
  - added the new optional request property `next_text`
  - added the optional property `estimated_duration_seconds` to the response with the `200` status
- **2026-11-11** `6e1e30efbbf0`: 1 info
  - the `subtitle_enable` request property default value changed from `false` to `true`
- **2026-11-06** `52094fd7dce4`: 2 info
  - added the optional property `script_markup/anyOf[subschema #1: SpeechScriptMarkup]/inline_emotion` to the response with the `200` status
  - added the optional property `script_markup/anyOf[subschema #1: SpeechScriptMarkup]/performance` to the response with the `200` status
- **2026-11-03** `b5bbac0bd580`: 2 info
  - added the new `elevenlabs-v4` enum value to the request property `model`
  - added the new `elevenlabs-v4-turbo` enum value to the request property `model`

[Operation history](https://skmtc.dev/beatra/apis/agent-service-api/changes/v1/audio/speech/validate/post.md)

---

[API](https://skmtc.dev/beatra/apis/agent-service-api.md) - [All operations](https://skmtc.dev/beatra/apis/agent-service-api/llms.txt) - [OpenAPI document](https://skmtc.dev/beatra/apis/agent-service-api/revisions/54a093c28eee?raw)
