Speech to Text
Last updated November 24, 2026
Synchronous speech-to-text endpoint accepting multipart/form-data audio uploads and returning transcribed text and duration.
Unified synchronous Speech to Text endpoint routing by model (currently supporting DeepSeek ASR). Upload an audio file via multipart/form-data and receive transcribed text together with actual audio duration.
https://gateway.amux.ai/v1/tools/asrAuthorization
headerAuthorizationstringRequiredBearer <your Amux AI key> Amux AI API key created in the console.
Request
multipart/form-datamodelstringRequiredASR model canonical ID or alias (for example deepseek/deepseek-asr or deepseek-asr).
filestringRequiredAudio file to transcribe. Supports 16-bit PCM WAV (8 kHz–48 kHz) or Ogg Opus (max 8 MiB, max 120 seconds).
Response
200responseTranscription succeeded.
400responseInvalid multipart payload, audio file exceeds size or duration limits, or model does not support ASR.
402responseInsufficient workspace balance.
Protocol overview
- Upload formats and limits: Upload the audio in the
filefield usingmultipart/form-data. Supports 16-bit PCM WAV (8 kHz–48 kHz) and Ogg Opus up to 8 MiB and 120 seconds per request. - Audio direction check: Accepts only ASR models with
audioininput_modalities. Passing a TTS model returns400 invalid_request. - Synchronous, non-streaming:
stream: trueand real-time streaming transcription are not supported. - Billing: Settled from the returned
duration_ms, rounding partial seconds up (ceil(duration_ms / 1000)); failed requests incur no charge.
Error handling
Errors follow the standard OpenAI error schema. Non-multipart requests, files exceeding 8 MiB, unsupported audio formats, or model mismatches return 400 invalid_request. See Errors and retries.
curl https://gateway.amux.ai/v1/tools/asr \
-H "Authorization: Bearer $AMUX_API_KEY" \
-F "model=deepseek/deepseek-asr" \
-F "file=@/path/to/file.png"{
"request_id": "asr-0196a1b2c3d4",
"model": "deepseek/deepseek-asr",
"text": "Hello, welcome to Amux AI.",
"duration_ms": 2450
}