Audio bytes, between 80 ms and 20 minutes and at most 256 MB. Set the part's Content-Type to the format: audio/wav, audio/pcm (raw 16-bit PCM), audio/aac, audio/mpeg (MP3), audio/mp4 (M4A), audio/ogg (Ogg/Opus), audio/flac, or audio/webm.
Transcription and rewrite configuration. Optional; when omitted, the audio is transcribed with defaults, including the default rewrite. Only the fields below are accepted. An unknown field is rejected with a 400.
Show child attributes
Response
Transcription completed. The rewrite is best-effort: a failed rewrite still returns 200 with the transcription, llm_response set to null, and llm_error set. Fall back to text in that case, and never treat a non-nullllm_error as a failed request.
Set when the rewrite failed, and null on success. The transcription is still returned in text. timeout: the rewrite ran past its deadline. error: the model returned nothing usable, or an unexpected failure. truncated: the output hit max_tokens before finishing. prompt_not_found: your account has no saved prompt with the name in llm.aai_prompt. context_exceeded: the input is too long for the model's context window. unsupported_param: the model doesn't support a parameter that was sent. rate_limited: LLM Gateway returned 429. invalid_request: LLM Gateway rejected the request with any other 4xx. upstream_error: LLM Gateway returned a 5xx or another non-2xx error.
The transcription portion of request_time_ms, in milliseconds.
Was this page helpful?
{"docsConfig":{"theme":"aspen","$schema":"https://mintlify.com/docs.json","name":"AssemblyAI","description":"AssemblyAI provides production-ready Voice AI models for speech-to-text, speaker detection, sentiment analysis, and more. Build with pre-recorded or streaming audio using REST APIs and WebSockets.","colors":{"primary":"#614fd2","light":"#887bdd","dark":"#614fd2"},"logo":{"light":"https://mintcdn.com/assemblyai-fff14a6f/vMuNaI_PbWUbVeV0/assets/assemblyai-lockup-primary.svg?fit=max\u0026auto=format\u0026n=vMuNaI_PbWUbVeV0\u0026q=85\u0026s=808d2a677e2536423045d44b3f330ac2","dark":"https://mintcdn.com/assemblyai-fff14a6f/vMuNaI_PbWUbVeV0/assets/assemblyai-lockup-secondary.svg?fit=max\u0026auto=format\u0026n=vMuNaI_PbWUbVeV0\u0026q=85\u0026s=065ec1618693f8650241242ec62ed0ad","href":"https://www.assemblyai.com"},"favicon":"https://mintcdn.com/assemblyai-fff14a6f/6OQYF4QMRVQRoCb1/assets/favicon.png?fit=max\u0026auto=format\u0026n=6OQYF4QMRVQRoCb1\u0026q=85\u0026s=74b6b6a7321938bd113d4a271e06068d","api":{"openapi":["openapi.yaml","api-reference/specs/llm-gateway.yaml","api-reference/specs/streaming-token.yaml"],"asyncapi":["api-reference/specs/streaming.yaml","api-reference/specs/streaming-tts.yaml"]},"background":{"color":{"light":"#fdfcf8","dark":"#1d1b16"}},"navbar":{"links":[{"href":"https://www.assemblyai.com/playground","label":"Playground"},{"href":"https://www.assemblyai.com/changelog","label":"Changelog"}],"primary":{"type":"button","label":"Sign In","href":"https://www.assemblyai.com/dashboard/login"}},"footer":{"socials":{"x":"https://x.com/AssemblyAI","github":"https://github.com/AssemblyAI","linkedin":"https://www.linkedin.com/company/assemblyai"},"links":[{"header":"Legal","items":[{"label":"Terms of Service","href":"https://www.assemblyai.com/legal/terms-of-service"},{"label":"Privacy Policy","href":"https://www.assemblyai.com/legal/privacy-policy"},{"label":"Trust Center","href":"https://app.vanta.com/assemblyai/trust/7n80syl8zln1bn1qm3x8eg"},{"label":"Subprocessors","href":"https://app.vanta.com/assemblyai/trust/7n80syl8zln1bn1qm3x8eg/subprocessors"}]}]},"seo":{"metatags":{"canonical":"https://www.assemblyai.com/docs"}},"fonts":{"heading":{"family":"GT Standard","weight":600,"source":"https://www.assemblyai.com/_aai/fonts/rebrand/GT-Standard-M-Semibold.woff2","format":"woff2"},"body":{"family":"GT Standard","weight":400,"source":"https://www.assemblyai.com/_aai/fonts/rebrand/GT-Standard-M-Regular.woff2","format":"woff2"}},"icons":{"library":"fontawesome"},"banner":{"content":"**New** AssemblyAI-TTS-1: Text-to-speech for voice agents. [Learn more](https://www.assemblyai.com/docs/tts/getting-started/quickstart)","dismissible":true},"contextual":{"options":["copy","view","chatgpt","claude"],"display":"header"},"styling":{"latex":true},"navigation":{"pages":[]}},"deployment":{"deploymentMetadataValue":{"subdomain":"assemblyai-fff14a6f","hasAudioNarration":false,"actualSubdomain":"assemblyai-fff14a6f","customDomains":["assemblyai.com"],"gitSource":{"type":"github","owner":"assemblyai","repo":"assemblyai-docs","deployBranch":"master","contentDirectory":"","isPrivate":true,"mountPath":"","label":""},"chroma":{"liveDeploymentHistoryId":"6aeccb38184351b562255256","collectionId":"b8508a41-1b7f-4c95-9e7e-f8654882a006","schemaVersion":"v3","latestBuiltDeploymentHistoryId":"6aeccb38184351b562255256"},"feedback":{"thumbs":true,"agentFeedback":true},"entitlements":{"AI_CHAT":{"status":"ENABLED"},"REMOVE_BRANDING":{"status":"ENABLED"},"CONTEXTUAL_FEEDBACK":{"status":"ENABLED"},"CODE_SNIPPET_FEEDBACK":{"status":"ENABLED"},"WEB_MCP":{"status":"ENABLED"},"NARRATION":{"status":"ENABLED"}},"buildId":"6aeccb38184351b562255256","clientVersion":"0.0.4071","searchFilterCounts":[{"language":"default","tag":"Overview","count":115},{"language":"default","tag":"FAQ","count":94},{"language":"default","tag":"Pre-recorded STT","count":69},{"language":"default","tag":"Guides","count":59},{"language":"default","tag":"Real-time STT","count":50},{"language":"default","tag":"Tutorials","count":48},{"language":"default","tag":"Pre-recorded audio","count":47},{"language":"default","tag":"LLM Gateway","count":44},{"language":"default","tag":"Features","count":37},{"language":"default","tag":"API reference","count":35}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableContextualStarterQuestions":false,"enableAskAiSearchBar":true,"attachments":{"status":"DISABLED"}},"basePath":"/docs","hasChatPermissions":true,"hasWebMcpPermissions":true,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-mintlify-slack","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"agent-integrations-settings","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"rbac-expansion","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-pr-grouping","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-prefix","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"analytics-v7","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"user-flows-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"no-publish-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-onboarding","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving-live","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"stripTemperatureMiddleware","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"support-platform-pylon-zendesk","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"snapshot-serving","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"instant-rollback","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications-server","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"granular-notifications","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automations-fable","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fixed-ai-action-pricing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"automation-resolve-merge-conflict","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"scoped-publishing","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"mintql","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"page-level-analytics","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"editor-version-history-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"billing-page-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"full-page-search","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workspace-projects","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"assistant-v5","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"fork-pr-previews","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"revalidation-jwt","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"vite-origin","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-sso-scim","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"hobby-abuse-scan","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"dashboard-inbox","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-signup","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-dual-write","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"workos-enabled","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"approve-review-flow","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"sso-setup-deadline-banner","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"turbopuffer-serve","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"live-agents","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[{"filePath":"style.css","content":"@font-face{font-family:\"GT Standard\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/GT-Standard-M-Regular.woff2\")\n format(\"woff2\"),\n url(\"https://www.assemblyai.com/docs/assets/GT-Standard-M-Regular.woff2\")\n format(\"woff2\"),\n url(\"/assets/GT-Standard-M-Regular.woff2\") format(\"woff2\");font-weight:400;font-style:normal;font-display:swap}@font-face{font-family:\"GT Standard\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/GT-Standard-M-Medium.woff2\")\n format(\"woff2\"),\n url(\"https://www.assemblyai.com/docs/assets/GT-Standard-M-Medium.woff2\")\n format(\"woff2\"),\n url(\"/assets/GT-Standard-M-Medium.woff2\") format(\"woff2\");font-weight:500;font-style:normal;font-display:swap}@font-face{font-family:\"GT Standard\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/GT-Standard-M-Semibold.woff2\")\n format(\"woff2\"),\n url(\"https://www.assemblyai.com/docs/assets/GT-Standard-M-Semibold.woff2\")\n format(\"woff2\"),\n url(\"/assets/GT-Standard-M-Semibold.woff2\") format(\"woff2\");font-weight:600;font-style:normal;font-display:swap}@font-face{font-family:\"Modern Gothic Mono\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/ModernGothicMono-Light.woff2\")\n format(\"woff2\");font-weight:300;font-style:normal;font-display:swap}@font-face{font-family:\"Modern Gothic Mono\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/ModernGothicMono-Regular.woff2\")\n format(\"woff2\");font-weight:400;font-style:normal;font-display:swap}@font-face{font-family:\"Modern Gothic Mono\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/ModernGothicMono-Medium.woff2\")\n format(\"woff2\");font-weight:500;font-style:normal;font-display:swap}@font-face{font-family:\"Modern Gothic Mono\";src:url(\"https://www.assemblyai.com/_aai/fonts/rebrand/ModernGothicMono-Italic.woff2\")\n format(\"woff2\");font-weight:400;font-style:italic;font-display:swap}html:root{--font-family-body-custom: \"GT Standard\", -apple-system, BlinkMacSystemFont,\n \"Segoe UI\", sans-serif;--font-family-headings-custom: \"GT Standard\", -apple-system, BlinkMacSystemFont,\n \"Segoe UI\", sans-serif}code,kbd,samp,pre,pre code,pre code span{font-family:\"Modern Gothic Mono\", \"JetBrains Mono\", ui-monospace, SFMono-Regular,\n Menlo, Consolas, monospace!important}html{overflow-y:scroll;scrollbar-gutter:stable}pre,pre code,pre code span{font-size:0.75rem!important;line-height:1.5!important}:not(pre)>code{font-size:0.75rem!important;line-height:inherit!important}[data-nav-tag=\"WSS\"]{color:#614fd2!important;background-color:rgba(136, 123, 221, 0.14)!important;font-size:0.55rem!important}:is(.dark) [data-nav-tag=\"WSS\"]{color:#887bdd!important}div:has(>.nav-tag-pill>[data-nav-tag=\"WSS\"]){order:-1}.nav-tag-pill:has(>[data-nav-tag=\"WSS\"]){width:2.375rem;justify-content:flex-start}.ws-endpoint{display:flex;align-items:center;gap:0.625rem;margin:1rem 0 1.75rem;padding:0.5rem 0.75rem;border:1px solid rgba(0, 0, 0, 0.08);border-radius:0.5rem;background:rgba(0, 0, 0, 0.02);font-size:0.875rem;overflow-x:auto}:is(.dark) .ws-endpoint{border-color:rgba(255, 255, 255, 0.1);background:rgba(255, 255, 255, 0.03)}.ws-endpoint-badge{flex:none;font-weight:700;font-size:0.75rem;letter-spacing:0.02em;color:#614fd2;background:rgba(136, 123, 221, 0.14);padding:0.1875rem 0.5rem;border-radius:0.375rem}:is(.dark) .ws-endpoint-badge{color:#887bdd}.ws-endpoint-url{font-family:ui-monospace, SFMono-Regular, \"SF Mono\", Menlo, Consolas, monospace;white-space:nowrap}#assistant-entry,:is(.dark) #assistant-entry{background-color:#614fd2!important;filter:none!important}#assistant-entry:hover,:is(.dark) #assistant-entry:hover{background-color:#614fd2!important;opacity:0.9;filter:none!important}#assistant-entry span,#assistant-entry svg,:is(.dark) #assistant-entry span,:is(.dark) #assistant-entry svg{color:#ffffff!important}.callout strong{font-weight:700}*{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;-o-font-smoothing:antialiased}.katex-display{overflow-x:visible!important;overflow-y:visible!important}.katex-display>.katex{display:flex!important;justify-content:center;width:100%!important;overflow-x:visible!important;overflow-y:visible!important}.katex-display>.katex>.katex-html{display:inline-block!important;width:auto!important;max-width:100%;overflow-x:visible!important;overflow-y:visible!important}.card-logo-icon{display:block;width:1.5rem!important;height:1.5rem!important;min-width:1.5rem;max-width:1.5rem;max-height:1.5rem;margin:0!important;object-fit:contain;object-position:center;vertical-align:middle}.card-logo-icon-livekit{transform:scale(0.9)}.card-logo-icon-pipecat{transform:scale(1.12)}.card-logo-icon-livekit,.card-logo-icon-pipecat,.card-logo-icon-vercel{color:#614fd2}:is(.dark) .card-logo-icon-livekit,:is(.dark) .card-logo-icon-pipecat,:is(.dark) .card-logo-icon-vercel{color:#887bdd}.recommended-pill{background:#614fd2;color:#fff;padding:2px 8px;border-radius:9999px;font-size:0.7rem;font-weight:600;margin-left:6px;vertical-align:middle;white-space:nowrap}:is(.dark) .recommended-pill{background:#614fd2}.preview-pill{background:#b45309;color:#fff;padding:2px 8px;border-radius:9999px;font-size:0.7rem;font-weight:600;margin-left:6px;vertical-align:middle;white-space:nowrap}:is(.dark) .preview-pill{background:#b45309}table code{white-space:nowrap}"}],"page":{"pagePath":"api-reference/dictation-api/transcribe","slug":"/api-reference/dictation-api/transcribe","pageMetadata":{"title":"Transcribe recorded audio","og.description":"Send a finished recording of up to 20 minutes, including compressed formats, to the Dictation API and receive send-ready cleaned-up text alongside the verbatim transcript.","openapi":"specs/dictation.yaml POST /v1/transcribe","description":null,"href":"/api-reference/dictation-api/transcribe"},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){return _jsx(_Fragment,{})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Transcribe recorded audio","og.description":"Send a finished recording of up to 20 minutes, including compressed formats, to the Dictation API and receive send-ready cleaned-up text alongside the verbatim transcript.","openapi":"specs/dictation.yaml POST /v1/transcribe","description":null,"href":"/api-reference/dictation-api/transcribe"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[],"codeExamples":{}},"jsLinks":["/docs/_mintlify/custom/assemblyai-fff14a6f/83628fb7cd91f870/rudderstack.js","/docs/_mintlify/custom/assemblyai-fff14a6f/700d2574de973df9/chat-widget.js"],"openApiReferenceData":{"operation":{"summary":"Transcribe recorded audio","description":"Send a complete recording and receive text ready to send, together with\nthe verbatim transcript. Audio must be between 80 ms and 20 minutes,\nand at most 256 MB.\n\nThis endpoint takes audio you already hold in full. The server reads\nthe whole body before it starts transcribing, so the `config` part can\ncome before or after `audio`, and can be left out to use the defaults.\nBesides WAV and raw PCM, it accepts compressed audio: AAC, MP3, M4A,\nOgg/Opus, FLAC, and WebM.\n\nFor audio that is still being recorded, use\n[`/v1/transcribe/live`](/api-reference/dictation-api/transcribe-live)\ninstead. It uploads while the user speaks and accepts up to 120 seconds\nof WAV or raw PCM. The SDKs use `/v1/transcribe/live`, so this endpoint\nis called over HTTP.\n\nThis endpoint is also served at `/transcribe`, without the version\nprefix.\n","operationId":"transcribeDictationRecording","requestBody":"d7308e81-49e1-4f97-b1d0-7518c8590299","x-codeSamples":[{"lang":"bash","label":"cURL","source":"curl -X POST https://dictation.assemblyai.com/v1/transcribe \\\n -H 'Authorization: \u003cYOUR_API_KEY>' \\\n -F 'audio=@recording.mp3;type=audio/mpeg'\n"},{"lang":"python","label":"Python","source":"import requests\n\nwith open(\"recording.mp3\", \"rb\") as f:\n audio = f.read()\n\nresponse = requests.post(\n \"https://dictation.assemblyai.com/v1/transcribe\",\n headers={\"Authorization\": \"\u003cYOUR_API_KEY>\"},\n files={\n \"audio\": (\"recording.mp3\", audio, \"audio/mpeg\"),\n # Optional; omit for the defaults.\n \"config\": (None, '{\"language_codes\": [\"en\"]}', \"application/json\"),\n },\n timeout=90,\n)\nresponse.raise_for_status()\nresult = response.json()\n\nprint(result[\"text\"]) # verbatim transcript\nprint(result[\"llm_response\"]) # default cleanup rewrite\n"},{"lang":"javascript","label":"JavaScript","source":"import { readFileSync } from \"fs\";\n\nconst audio = readFileSync(\"recording.mp3\");\nconst form = new FormData();\nform.append(\"audio\", new Blob([audio], { type: \"audio/mpeg\" }), \"recording.mp3\");\n\nconst response = await fetch(\n \"https://dictation.assemblyai.com/v1/transcribe\",\n {\n method: \"POST\",\n headers: { Authorization: \"\u003cYOUR_API_KEY>\" },\n body: form,\n }\n);\n\nif (!response.ok) {\n const error = await response.json();\n throw new Error(error.error || error.detail);\n}\n\nconst result = await response.json();\nconsole.log(result.text); // verbatim transcript\nconsole.log(result.llm_response); // default cleanup rewrite\n"}],"responses":{"200":"00fbd8ca-22f0-4426-9b11-eb98bdf0c5ff","400":"2d049933-8ce6-4f69-81d3-738366d8fdd2","401":"87b26ebb-7c45-4502-9f87-0014fcd1beac","413":"750a7a9c-b055-41e1-8033-cfa92f61231a","415":"13bb09a3-c1f5-4404-8321-83e342f40c6f","429":"b8656954-af2c-4e58-baaf-45ea727ccb72","502":"d354b8be-8692-49e0-8c56-e694c4ce9c33","503":"0c25d365-3145-4bca-b67b-090b23e4f254","504":"5c502b55-29ab-47f5-a549-0e94f7dc3710"},"method":"post","type":"path","servers":["bbf7fccd-3497-4629-90f1-de490605b2a2","98399c60-3ea0-4c90-a4ca-3015649752b9","3d9b9ae9-2104-4bdc-aa5b-88ce10c192bb"],"security":["1bafb6dd-2b24-4649-93b0-195dd3bed246"],"path":"/v1/transcribe","baseUrlOptions":["https://dictation.assemblyai.com","https://dictation.us.assemblyai.com","https://dictation.eu.assemblyai.com"],"title":"Transcribe recorded audio","codeSamples":[{"label":"cURL","lang":"bash","source":"curl -X POST https://dictation.assemblyai.com/v1/transcribe \\\n -H 'Authorization: \u003cYOUR_API_KEY>' \\\n -F 'audio=@recording.mp3;type=audio/mpeg'\n"},{"label":"Python","lang":"python","source":"import requests\n\nwith open(\"recording.mp3\", \"rb\") as f:\n audio = f.read()\n\nresponse = requests.post(\n \"https://dictation.assemblyai.com/v1/transcribe\",\n headers={\"Authorization\": \"\u003cYOUR_API_KEY>\"},\n files={\n \"audio\": (\"recording.mp3\", audio, \"audio/mpeg\"),\n # Optional; omit for the defaults.\n \"config\": (None, '{\"language_codes\": [\"en\"]}', \"application/json\"),\n },\n timeout=90,\n)\nresponse.raise_for_status()\nresult = response.json()\n\nprint(result[\"text\"]) # verbatim transcript\nprint(result[\"llm_response\"]) # default cleanup rewrite\n"},{"label":"JavaScript","lang":"javascript","source":"import { readFileSync } from \"fs\";\n\nconst audio = readFileSync(\"recording.mp3\");\nconst form = new FormData();\nform.append(\"audio\", new Blob([audio], { type: \"audio/mpeg\" }), \"recording.mp3\");\n\nconst response = await fetch(\n \"https://dictation.assemblyai.com/v1/transcribe\",\n {\n method: \"POST\",\n headers: { Authorization: \"\u003cYOUR_API_KEY>\" },\n body: form,\n }\n);\n\nif (!response.ok) {\n const error = await response.json();\n throw new Error(error.error || error.detail);\n}\n\nconst result = await response.json();\nconsole.log(result.text); // verbatim transcript\nconsole.log(result.llm_response); // default cleanup rewrite\n"}],"requiredOnlyExamples":false,"requestExampleType":"codeSamples","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"multipart/form-data":{"schema":{"type":"object","required":["audio"],"properties":{"audio":{"type":"string","format":"binary","description":"Audio bytes, between 80 ms and 20 minutes and at most 256 MB. Set the part's Content-Type to the format: `audio/wav`, `audio/pcm` (raw 16-bit PCM), `audio/aac`, `audio/mpeg` (MP3), `audio/mp4` (M4A), `audio/ogg` (Ogg/Opus), `audio/flac`, or `audio/webm`.","isRequired":true,"uniqueKey":"audio","typeLabel":"file"},"config":{"type":"object","additionalProperties":false,"description":"Transcription and rewrite configuration. Optional; when omitted, the audio is transcribed with defaults, including the default rewrite. Only the fields below are accepted. An unknown field is rejected with a `400`.","properties":{"sample_rate":{"type":"integer","description":"Source sample rate in Hz, for example `16000`. Required when `audio` is `audio/pcm`. Not needed for WAV or compressed formats, which carry it in the file.","uniqueKey":"config.sample_rate","typeLabel":"integer"},"channels":{"type":"integer","description":"Number of audio channels. Required when `audio` is `audio/pcm`. Not needed for WAV or compressed formats.","uniqueKey":"config.channels","typeLabel":"integer"},"language_codes":{"type":"array","items":{"type":"string","enum":["en","es","de","fr","it","pt","tr","nl","sv","no","da","fi","hi","vi","ar","he","ja","ur","zh","ko","ca","gl","ru","ro","et","fa","yue","af","mr","zu","xh","nn"],"uniqueKey":"config.language_codes.items.[INDEX]","typeLabel":"enum\u003cstring>"},"description":"Language or languages of the audio, as ISO language codes. A code outside this set is rejected with a `400`. When omitted, no language steering is applied.","uniqueKey":"config.language_codes","typeLabel":"enum\u003cstring>[]"},"stt_prompt":{"type":"string","maxLength":6000,"description":"Context for the transcription: a description of what the audio is about, such as \"A doctor dictating a patient visit note.\" It describes the situation rather than instructing the model, and is prepended to the base transcription prompt, which always applies. Also accepted as `prompt`; send one or the other, or the request is rejected with `400`.","uniqueKey":"config.stt_prompt","typeLabel":"string"},"keyterms_prompt":{"type":"array","maxItems":100,"items":{"type":"string","uniqueKey":"config.keyterms_prompt.items.[INDEX]","typeLabel":"string"},"description":"Terms to bias transcription toward, such as names or jargon. Maximum 100 terms and 8000 characters in total. The legacy names `keyterms` and `word_boost` are also accepted; send only one of the three, or the request is rejected with `400`.","uniqueKey":"config.keyterms_prompt","typeLabel":"string[]"},"llm_instruction":{"oneOf":[{"type":"string","description":"Plain-English description of the shape you want the text in, which replaces the default cleanup task. Describe only the transformation: rules about output format, refusing to answer the text, and handling clean input are enforced automatically. Omitting the field, or setting it to `null`, keeps the default cleanup task, which removes filler, resolves self-corrections, and applies punctuation and capitalization.","uniqueKey":"config.llm_instruction.oneOf.0","typeLabel":"string"},{"type":"null","description":"Plain-English description of the shape you want the text in, which replaces the default cleanup task. Describe only the transformation: rules about output format, refusing to answer the text, and handling clean input are enforced automatically. Omitting the field, or setting it to `null`, keeps the default cleanup task, which removes filler, resolves self-corrections, and applies punctuation and capitalization.","uniqueKey":"config.llm_instruction.oneOf.1","typeLabel":"null"}],"uniqueKey":"config.llm_instruction","typeLabel":"string | null"},"rewrite_mode":{"type":"string","enum":["fast","smart"],"default":"fast","description":"Model tier that runs the rewrite. `fast`, the default, has the lowest latency. `smart` follows detailed formatting instructions more reliably, but has higher latency. Any other value is rejected with `400`.","uniqueKey":"config.rewrite_mode","typeLabel":"enum\u003cstring>"},"llm":{"type":"object","description":"Your own LLM Gateway [chat completions request](/llm-gateway/chat-completions) for the rewrite, used instead of `llm_instruction`. Send `llm` or `llm_instruction`, not both, or the request is rejected with `400`. Put the transcript in the request in one of two ways: write `prompt` or `messages` with `{{turn}}` where the transcript goes, or set `aai_prompt` to a [saved prompt](/llm-gateway/saved-prompts) that contains `{{ text }}`. The model gets exactly the prompt you send, without the guardrails that apply to `llm_instruction`. Only the fields below are accepted. Field names are case-sensitive, and any other field, such as `fallbacks`, `tools`, `stream` or `transcript_id`, is rejected with `400`. If LLM Gateway rejects or fails the request, the response is still `200` and `llm_error` says why. See [Sending your own LLM request](/dictation/transcript-rewriting#sending-your-own-llm-request).","properties":{"model":{"type":"string","enum":["qwen3.5-4b-32k-fast","gemma-4-31b","gemini-3.5-flash-lite"],"description":"Model that runs the rewrite. In the EU region, use `qwen3.5-4b-32k-fast` or `gemini-3.5-flash-lite`. Any other model is rejected with `400`. Without `model`, `rewrite_mode` picks one.","uniqueKey":"config.llm.model","typeLabel":"enum\u003cstring>"},"messages":{"type":"array","items":{"type":"object","uniqueKey":"config.llm.messages.items.[INDEX]","typeLabel":"object"},"description":"Chat messages, as in an LLM Gateway chat completions request. Dictation renders each message as a Jinja2 template and fills `{{turn}}` with the transcript.","uniqueKey":"config.llm.messages","typeLabel":"object[]"},"prompt":{"type":"string","description":"A single prompt, as in an LLM Gateway chat completions request. Dictation renders it as a Jinja2 template and fills `{{turn}}` with the transcript.","uniqueKey":"config.llm.prompt","typeLabel":"string"},"temperature":{"type":"number","default":0,"description":"Sampling temperature. `0` unless you set it.","uniqueKey":"config.llm.temperature","typeLabel":"number"},"top_p":{"type":"number","description":"Nucleus sampling, as in LLM Gateway.","uniqueKey":"config.llm.top_p","typeLabel":"number"},"top_k":{"type":"integer","description":"Top-k sampling, as in LLM Gateway.","uniqueKey":"config.llm.top_k","typeLabel":"integer"},"max_tokens":{"type":"integer","maximum":8192,"description":"Maximum output tokens, at most 8192. If you leave it out, Dictation sizes it from the transcript, so a prompt that expands the text may need a larger value. A rewrite that runs out of tokens returns `llm_error: \"truncated\"`.","uniqueKey":"config.llm.max_tokens","typeLabel":"integer"},"max_completion_tokens":{"type":"integer","maximum":8192,"description":"Maximum completion tokens, at most 8192.","uniqueKey":"config.llm.max_completion_tokens","typeLabel":"integer"},"response_format":{"type":"object","description":"Response format, as in LLM Gateway.","uniqueKey":"config.llm.response_format","typeLabel":"object"},"reasoning_effort":{"type":"string","description":"Reasoning effort, as in LLM Gateway.","uniqueKey":"config.llm.reasoning_effort","typeLabel":"string"},"zero_data_retention":{"type":"boolean","description":"Dictation sets this to `true` on every LLM Gateway request, including ones that use `aai_prompt`, and you can't turn it off.","uniqueKey":"config.llm.zero_data_retention","typeLabel":"boolean"},"aai_prompt":{"type":"string","description":"Name of a [saved prompt](/llm-gateway/saved-prompts) in your account. Dictation passes the transcript as the `text` replacement, so put `{{ text }}` in the saved prompt. The model, `max_tokens` and every other setting come from the saved prompt, and the model and output limits above don't apply. Only `prompt_replacements` may accompany `aai_prompt`. Any other `llm` field, or `rewrite_mode`, is rejected with `400`.","uniqueKey":"config.llm.aai_prompt","typeLabel":"string"},"prompt_replacements":{"type":"object","additionalProperties":{"type":"string","uniqueKey":"config.llm.prompt_replacements.additionalProperties","typeLabel":"string"},"description":"Values for your own `{{ tag }}` placeholders in the saved prompt. Requires `aai_prompt`. Setting `text` or `transcript` is rejected with `400`: Dictation fills `text`, and LLM Gateway reserves `transcript`.","uniqueKey":"config.llm.prompt_replacements","typeLabel":"object"}},"uniqueKey":"config.llm","typeLabel":"object"}},"uniqueKey":"config","typeLabel":"object"}},"uniqueKey":"","typeLabel":"object"},"encoding":{"config":{"contentType":"application/json"},"audio":{"contentType":"audio/wav, audio/pcm, audio/aac, audio/mpeg, audio/mp4, audio/ogg, audio/flac, audio/webm"}},"examples":{"Example":{"title":"Example","value":{"audio":"\u003cstring>","config":{"sample_rate":123,"channels":123,"language_codes":[],"stt_prompt":"\u003cstring>","keyterms_prompt":["\u003cstring>"],"llm_instruction":"\u003cstring>","rewrite_mode":"fast","llm":{"messages":[{}],"prompt":"\u003cstring>","temperature":0,"top_p":123,"top_k":123,"max_tokens":123,"max_completion_tokens":123,"response_format":{},"reasoning_effort":"\u003cstring>","zero_data_retention":true,"aai_prompt":"\u003cstring>","prompt_replacements":{}}}}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"00fbd8ca-22f0-4426-9b11-eb98bdf0c5ff":{"description":"Transcription completed. The rewrite is best-effort: a failed rewrite still returns `200` with the transcription, `llm_response` set to `null`, and `llm_error` set. Fall back to `text` in that case, and never treat a non-`null` `llm_error` as a failed request.","content":{"application/json":{"schema":{"type":"object","required":["text","words","confidence","audio_duration_ms","session_id"],"properties":{"text":{"type":"string","description":"The verbatim transcript. Never altered by the LLM.","isRequired":true,"uniqueKey":"text","typeLabel":"string"},"words":{"type":"array","items":{"type":"object","required":["text","confidence"],"properties":{"text":{"type":"string","isRequired":true,"uniqueKey":"words.items.[INDEX].text","typeLabel":"string"},"confidence":{"type":"number","format":"float","isRequired":true,"uniqueKey":"words.items.[INDEX].confidence","typeLabel":"number\u003cfloat>"}},"uniqueKey":"words.items.[INDEX]","typeLabel":"object"},"description":"Per-word transcript objects.","isRequired":true,"uniqueKey":"words","typeLabel":"object[]"},"confidence":{"type":"number","format":"float","description":"Overall transcription confidence (0–1).","isRequired":true,"uniqueKey":"confidence","typeLabel":"number\u003cfloat>"},"audio_duration_ms":{"type":"number","description":"Duration of the submitted audio in milliseconds.","isRequired":true,"uniqueKey":"audio_duration_ms","typeLabel":"number"},"session_id":{"type":"string","format":"uuid","description":"Server-generated request identifier. Include it when reporting problems.","isRequired":true,"uniqueKey":"session_id","typeLabel":"string\u003cuuid>"},"llm_response":{"oneOf":[{"type":"string","description":"The rewritten text, or `null` when the rewrite failed. Fall back to `text` when it is `null`.","uniqueKey":"llm_response.oneOf.0","typeLabel":"string"},{"type":"null","description":"The rewritten text, or `null` when the rewrite failed. Fall back to `text` when it is `null`.","uniqueKey":"llm_response.oneOf.1","typeLabel":"null"}],"uniqueKey":"llm_response","typeLabel":"string | null"},"llm_error":{"oneOf":[{"type":"string","enum":["timeout","error","truncated","prompt_not_found","context_exceeded","unsupported_param","rate_limited","invalid_request","upstream_error"],"description":"Set when the rewrite failed, and `null` on success. The transcription is still returned in `text`. `timeout`: the rewrite ran past its deadline. `error`: the model returned nothing usable, or an unexpected failure. `truncated`: the output hit `max_tokens` before finishing. `prompt_not_found`: your account has no saved prompt with the name in `llm.aai_prompt`. `context_exceeded`: the input is too long for the model's context window. `unsupported_param`: the model doesn't support a parameter that was sent. `rate_limited`: LLM Gateway returned `429`. `invalid_request`: LLM Gateway rejected the request with any other `4xx`. `upstream_error`: LLM Gateway returned a `5xx` or another non-`2xx` error.","uniqueKey":"llm_error.oneOf.0","typeLabel":"enum\u003cstring>"},{"type":"null","enum":["timeout","error","truncated","prompt_not_found","context_exceeded","unsupported_param","rate_limited","invalid_request","upstream_error"],"description":"Set when the rewrite failed, and `null` on success. The transcription is still returned in `text`. `timeout`: the rewrite ran past its deadline. `error`: the model returned nothing usable, or an unexpected failure. `truncated`: the output hit `max_tokens` before finishing. `prompt_not_found`: your account has no saved prompt with the name in `llm.aai_prompt`. `context_exceeded`: the input is too long for the model's context window. `unsupported_param`: the model doesn't support a parameter that was sent. `rate_limited`: LLM Gateway returned `429`. `invalid_request`: LLM Gateway rejected the request with any other `4xx`. `upstream_error`: LLM Gateway returned a `5xx` or another non-`2xx` error.","uniqueKey":"llm_error.oneOf.1","typeLabel":"null"}],"uniqueKey":"llm_error","typeLabel":"enum\u003cstring> | null"},"request_time_ms":{"type":"number","format":"float","description":"Total server-side processing time in milliseconds.","uniqueKey":"request_time_ms","typeLabel":"number\u003cfloat>"},"auth_time_ms":{"type":"number","format":"float","description":"Time in milliseconds spent authenticating the request, included in `request_time_ms`.","uniqueKey":"auth_time_ms","typeLabel":"number\u003cfloat>"},"sync_time_ms":{"type":"number","format":"float","description":"The transcription portion of `request_time_ms`, in milliseconds.","uniqueKey":"sync_time_ms","typeLabel":"number\u003cfloat>"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"text":"\u003cstring>","words":[{"text":"\u003cstring>","confidence":123}],"confidence":123,"audio_duration_ms":123,"session_id":"3c90c3cc-0d44-4b50-8888-8dd25736052a","llm_response":"\u003cstring>","llm_error":"timeout","request_time_ms":123,"auth_time_ms":123,"sync_time_ms":123}}},"exampleType":"generated"}},"exampleType":"generated"},"2d049933-8ce6-4f69-81d3-738366d8fdd2":{"description":"A malformed request body, or a Dictation-specific `config` field that fails validation, uses the `error`/`error_code` shape: a missing or empty `audio` part, an `audio` part over 256 MB, or `config` that is not valid JSON. Audio shorter than 80 ms, audio that cannot be decoded, and a transcription `config` field that fails validation, including an unknown field, use the `status`/`title`/`detail` shape instead.","content":{"application/json":{"schema":{"oneOf":[{"type":"object","properties":{"error":{"type":"string","description":"Human-readable error description.","uniqueKey":"oneOf.0.error","typeLabel":"string"},"error_code":{"type":"string","description":"Machine-readable error code, such as `bad_request`, `audio_too_large`, `capacity_exceeded`, `upstream_error`, or `upstream_timeout`.","uniqueKey":"oneOf.0.error_code","typeLabel":"string"}},"uniqueKey":"oneOf.0","typeLabel":"object"},{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"oneOf.1.status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"oneOf.1.title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"oneOf.1.detail","typeLabel":"string"}},"uniqueKey":"oneOf.1","typeLabel":"object"}],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"\u003cstring>","error_code":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"87b26ebb-7c45-4502-9f87-0014fcd1beac":{"description":"Missing `Authorization` header, or an invalid API key.","content":{"application/json":{"schema":{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"detail","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"status":123,"title":"\u003cstring>","detail":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"750a7a9c-b055-41e1-8033-cfa92f61231a":{"description":"The audio is longer than 20 minutes (`title: \"Audio Too Large\"`).","content":{"application/json":{"schema":{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"detail","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"status":123,"title":"\u003cstring>","detail":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"13bb09a3-c1f5-4404-8321-83e342f40c6f":{"description":"The `audio` part's Content-Type is not a supported format.","content":{"application/json":{"schema":{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"detail","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"status":123,"title":"\u003cstring>","detail":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"b8656954-af2c-4e58-baaf-45ea727ccb72":{"description":"Rate limited. Back off and retry.","content":{"application/json":{"schema":{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"detail","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"status":123,"title":"\u003cstring>","detail":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"d354b8be-8692-49e0-8c56-e694c4ce9c33":{"description":"Transcription upstream unavailable (`error_code: \"upstream_error\"`). Retry once, then surface an error.","content":{"application/json":{"schema":{"type":"object","properties":{"error":{"type":"string","description":"Human-readable error description.","uniqueKey":"error","typeLabel":"string"},"error_code":{"type":"string","description":"Machine-readable error code, such as `bad_request`, `audio_too_large`, `capacity_exceeded`, `upstream_error`, or `upstream_timeout`.","uniqueKey":"error_code","typeLabel":"string"}},"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"\u003cstring>","error_code":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"0c25d365-3145-4bca-b67b-090b23e4f254":{"description":"Server at capacity. Back off and retry.","content":{"application/json":{"schema":{"oneOf":[{"type":"object","properties":{"error":{"type":"string","description":"Human-readable error description.","uniqueKey":"oneOf.0.error","typeLabel":"string"},"error_code":{"type":"string","description":"Machine-readable error code, such as `bad_request`, `audio_too_large`, `capacity_exceeded`, `upstream_error`, or `upstream_timeout`.","uniqueKey":"oneOf.0.error_code","typeLabel":"string"}},"uniqueKey":"oneOf.0","typeLabel":"object"},{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"oneOf.1.status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"oneOf.1.title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"oneOf.1.detail","typeLabel":"string"}},"uniqueKey":"oneOf.1","typeLabel":"object"}],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"\u003cstring>","error_code":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"},"5c502b55-29ab-47f5-a549-0e94f7dc3710":{"description":"Transcription timed out. Retry once, then surface an error.","content":{"application/json":{"schema":{"oneOf":[{"type":"object","properties":{"error":{"type":"string","description":"Human-readable error description.","uniqueKey":"oneOf.0.error","typeLabel":"string"},"error_code":{"type":"string","description":"Machine-readable error code, such as `bad_request`, `audio_too_large`, `capacity_exceeded`, `upstream_error`, or `upstream_timeout`.","uniqueKey":"oneOf.0.error_code","typeLabel":"string"}},"uniqueKey":"oneOf.0","typeLabel":"object"},{"type":"object","description":"The shape used by auth failures (`401`), rate limiting (`429`), and errors from the transcription step, including transcription `config` validation failures (`400`) and unsupported audio formats (`415`).","properties":{"status":{"type":"integer","uniqueKey":"oneOf.1.status","typeLabel":"integer"},"title":{"type":"string","uniqueKey":"oneOf.1.title","typeLabel":"string"},"detail":{"type":"string","description":"Human-readable error description.","uniqueKey":"oneOf.1.detail","typeLabel":"string"}},"uniqueKey":"oneOf.1","typeLabel":"object"}],"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"error":"\u003cstring>","error_code":"\u003cstring>"}}},"exampleType":"generated"}},"exampleType":"generated"}},"security":{"1bafb6dd-2b24-4649-93b0-195dd3bed246":{"ApiKey":{"type":"apiKey","in":"header","name":"Authorization","description":"Your AssemblyAI API key, sent as the raw key with no `Bearer` prefix. A missing header or an invalid key returns `401`.","scopes":[],"schemeName":"ApiKey"}}},"servers":{"bbf7fccd-3497-4629-90f1-de490605b2a2":{"url":"https://dictation.assemblyai.com","description":"Global (default — routes to nearest region)"},"98399c60-3ea0-4c90-a4ca-3015649752b9":{"url":"https://dictation.us.assemblyai.com","description":"US data residency (us-east-1, us-east-2, us-west-1, us-west-2)"},"3d9b9ae9-2104-4bdc-aa5b-88ce10c192bb":{"url":"https://dictation.eu.assemblyai.com","description":"EU data residency (eu-central-1, eu-north-1, eu-south-1, eu-south-2, eu-west-1, eu-west-3)"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"Authorization","description":"Your AssemblyAI API key, sent as the raw key with no `Bearer` prefix. A missing header or an invalid key returns `401`.","scopes":[],"schemeName":"ApiKey"},"schema":{"title":"Authorization","type":"string","description":"Your AssemblyAI API key, sent as the raw key with no `Bearer` prefix. A missing header or an invalid key returns `401`.","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKey","name":"Authorization"}],"title":"ApiKey"}]},"originalFileLocation":"api-reference/specs/dictation.yaml"},"subdomain":"assemblyai-fff14a6f","siteName":"AssemblyAI","title":"Transcribe recorded audio - AssemblyAI","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{}},"lastModified":"2026-11-04T18:06:31.832Z","originalFileLocation":"api-reference/dictation-api/transcribe.mdx"},"headHtml":"\u003cscript data-mint-head>(function(){var d=document.documentElement,p=null;if(!p){try{p=localStorage.getItem(\"isDarkMode\")}catch(e){}if(p==='true')p='dark';else if(p==='false')p='light';if(p!=='light'\u0026\u0026p!=='dark'\u0026\u0026p!=='system')p=\"system\"}var r=p==='system'?(matchMedia(\"(prefers-color-scheme: dark)\").matches?'dark':'light'):p;d.classList.remove(r==='dark'?'light':'dark');d.classList.add(r);d.setAttribute(\"data-theme-preference\",p)})();\u003c/script>\u003cmeta data-mint-head name=\"application-name\" content=\"AssemblyAI\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon/android-chrome-192x192.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"apple-touch-icon\" type=\"image/png\" sizes=\"180x180\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Transcribe recorded audio - AssemblyAI\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"AssemblyAI\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://assemblyai-fff14a6f.mintlify.app/_mintlify/api/og/v2?division=API+reference\u0026amp;title=Transcribe+recorded+audio\u0026amp;theme=de66a831debd161b892ce587\u0026amp;signature=7ce791b1be364ce800c42e9598230590a13a79d2b0d9c3a3657e271cde5b4cc3\">\u003cmeta data-mint-head property=\"og:image:width\" content=\"1200\">\u003cmeta data-mint-head property=\"og:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"twitter:card\" content=\"summary_large_image\">\u003cmeta data-mint-head name=\"twitter:title\" content=\"Transcribe recorded audio - AssemblyAI\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://assemblyai-fff14a6f.mintlify.app/_mintlify/api/og/v2?division=API+reference\u0026amp;title=Transcribe+recorded+audio\u0026amp;theme=de66a831debd161b892ce587\u0026amp;signature=7ce791b1be364ce800c42e9598230590a13a79d2b0d9c3a3657e271cde5b4cc3\">\u003cmeta data-mint-head name=\"twitter:image:width\" content=\"1200\">\u003cmeta data-mint-head name=\"twitter:image:height\" content=\"630\">\u003cmeta data-mint-head name=\"msapplication-config\" content=\"/docs/mintlify-assets/_mintlify/favicons/assemblyai-fff14a6f/IP3FX8MjuVkHah_W/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"AssemblyAI\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#614fd2\">\u003clink data-mint-head rel=\"canonical\" href=\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/docs/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/docs/api-reference/dictation-api/transcribe.md\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://www.assemblyai.com/#organization\",\"name\":\"AssemblyAI\",\"url\":\"https://www.assemblyai.com\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/assemblyai-fff14a6f/vMuNaI_PbWUbVeV0/assets/assemblyai-lockup-primary.svg?fit=max\u0026auto=format\u0026n=vMuNaI_PbWUbVeV0\u0026q=85\u0026s=808d2a677e2536423045d44b3f330ac2\"}},{\"@type\":\"WebSite\",\"@id\":\"https://www.assemblyai.com/docs#website\",\"name\":\"AssemblyAI\",\"url\":\"https://www.assemblyai.com/docs\",\"publisher\":{\"@id\":\"https://www.assemblyai.com/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe#webpage\",\"url\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe\",\"name\":\"Transcribe recorded audio\",\"dateModified\":\"2026-11-04T18:06:31.832Z\",\"isPartOf\":{\"@id\":\"https://www.assemblyai.com/docs#website\"},\"breadcrumb\":{\"@id\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"API reference\",\"item\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe-live\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Transcribe recorded audio\",\"item\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe#apireference\",\"headline\":\"Transcribe recorded audio\",\"name\":\"Transcribe recorded audio\",\"url\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe\",\"mainEntityOfPage\":{\"@id\":\"https://www.assemblyai.com/docs/api-reference/dictation-api/transcribe#webpage\"},\"dateModified\":\"2026-11-04T18:06:31.832Z\",\"publisher\":{\"@id\":\"https://www.assemblyai.com/#organization\"},\"isPartOf\":{\"@id\":\"https://www.assemblyai.com/docs#website\"}}]}\u003c/script>","siteName":"AssemblyAI","nav":{"global":null,"tabs":[{"tab":"Overview","pages":[{"title":"Overview","href":""}]},{"tab":"Pre-recorded STT","pages":[{"title":"Pre-recorded STT","href":"/pre-recorded-audio/getting-started/transcribe-an-audio-file"}]},{"tab":"Real-time STT","pages":[{"title":"Real-time STT","href":"/streaming/getting-started/transcribe-streaming-audio"}]},{"tab":"Sync STT","pages":[{"title":"Sync STT","href":"/sync-stt/getting-started/quickstart"}]},{"tab":"Dictation API","groups":[{"group":"Getting started","pages":[{"title":"Quickstart","href":"/dictation"},{"title":"Uploading while recording","href":"/dictation/uploading-while-recording"},{"title":"Examples","href":"/dictation/examples"}]},{"group":"Features","pages":[{"title":"Transcript rewriting","href":"/dictation/transcript-rewriting"},{"title":"Prompting and keyterms","href":"/dictation/prompting-and-keyterms"},{"title":"Language selection","href":"/dictation/language-selection"}]},{"group":"API reference","pages":[{"title":"Transcribe dictated audio","openapi":"specs/dictation.yaml POST /v1/transcribe/live","description":null,"href":"/api-reference/dictation-api/transcribe-live"},{"title":"Transcribe recorded audio","openapi":"specs/dictation.yaml POST /v1/transcribe","href":"/api-reference/dictation-api/transcribe"}]},{"group":"Advanced","pages":[{"title":"Audio requirements","description":"Duration, format, and sample-rate constraints for Dictation audio.","href":"/dictation/audio-requirements"},{"title":"Error handling","href":"/dictation/error-handling"},{"title":"Cloud endpoints \u0026 data residency","sidebarTitle":"Cloud endpoints \u0026 data residency","href":"/dictation/endpoints-and-data-zones"},{"title":"Connection pre-warming","sidebarTitle":"Connection pre-warming","href":"/dictation/connection-pre-warming"}]}]},{"tab":"Text to Speech","pages":[{"title":"Text to Speech","href":"/tts/getting-started/quickstart"}]},{"tab":"Voice Agent API","hidden":true,"pages":[{"title":"Voice Agent API","href":"/voice-agents/voice-agent-api"}]},{"tab":"Speech Understanding","pages":[{"title":"Speech Understanding","href":"/speech-understanding/getting-started"}]},{"tab":"Guardrails","pages":[{"title":"Guardrails","href":"/guardrails/getting-started"}]},{"tab":"LLM Gateway","pages":[{"title":"LLM Gateway","href":"/llm-gateway/quickstart"}]},{"tab":"FAQ","pages":[{"title":"FAQ","href":"/faq"}]}]},"basePath":"","title":"Transcribe recorded audio - AssemblyAI","buildId":"dpl_DQCMP4mismmBj3AFK7YZqNhrtLNq","deploymentId":"dpl_DQCMP4mismmBj3AFK7YZqNhrtLNq","dynamics":["10e4515597","c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["BannerMarkdown-Brp0mPUt.js","dist-Dpla8_R7.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","clsx-C_advUgl.js","html-void-elements-mCSPHezU.js","katex-YMM-FMeD.js","marked.esm-CZWythHk.js","OpenApiReferenceProvider-Dub5uFbX.js","utils-BAOmmv1r.js","cloneDeep-izs3Hzxb.js","_Uint8Array-BVIqJ90l.js","isObjectLike-C8vmzPEN.js","isArray-Dcu1dQ5t.js","utils-Cfvfuq3w.js","toString-BX-iyh8G.js","isSymbol-CSH9U2Gm.js","addUniqueKeysToSchema-Chp3aFWD.js","snippetPresets-mdHEOVGp.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","ApiExamples-BRlO2pcM.js","isEqual-BfaiBbcl.js","usePlaygroundInputsStore-CrgNI3V9.js","shallow-Dl286uHn.js","getApiPlaygroundDisplay-YPKheyKd.js","CodeSnippet-BdD-lURy.js","CodeSnippets-BSggiSf7.js","Page-DZmn3mFl.js","getPastedJson-bQHv51S7.js","icon-SCSCTtsH.js","MethodPill-GnU2wo5s.js","DuplicateIcon-BM7jzGa_.js","createIcon-atdRs-Wh.js","DynamicMarkdown-B95U9rYS.js","SectionHeading-CvCxtB39.js","axios-vUo_bRtp.js","Markdown-CBJtw_nx.js","AssistantPageLink-BoWSGi0C.js"]}