Downloads the media of a received message. WhatsApp delivers encrypted media;
this endpoint decrypts it using the metadata that arrives in the webhook
(media_key, mimetype, direct_path or url, and the hashes).Set base64: true to receive the content embedded in the response, or use
async for large downloads in the background.
The required fields (media_key, mimetype, file_sha256 etc.) come in the
received message webhook payload — pass them straight through to this endpoint.
Official API (Cloud API)
On Official API connections, media is stored at Meta and identified by the
media_id, which arrives in the webhook in media_data.media_id. Send media_id and
mimetype instead of media_key, direct_path and hashes. The response is
always synchronous — async is not accepted on these connections.
With the Do not store media option enabled under My Account → Privacy, D-API
does not keep any of the account’s media: nothing goes to storage, Redis, queues or
the database. Received message webhooks carry only the metadata
(media_key, direct_path, hashes or media_id), with no media_url and no
base64, and the file is retrieved through this endpoint. On these accounts:
the response is always base64, even without base64: true;
async is rejected — download is synchronous only;
base64 media sends with async are also rejected; use synchronous
sending or a URL.
Enabling or disabling the option restarts the account’s unofficial connections,
which go offline for a few seconds.
Media type. Optional: when omitted, it is inferred from the mimetype.
Allowed value: "image"
file_enc_sha256
string
file_sha256
string
file_length
number
async
booleanstring
base64
boolean
Response
200
Successful response
{"docsConfig":{"theme":"mint","$schema":"https://mintlify.com/docs.json","name":"D-API","colors":{"primary":"#00B7CD","light":"#2DD4E0","dark":"#0E8FA3"},"logo":{"light":"https://mintcdn.com/d-api/dcX-Hd4-QsKLE866/logo/dapi-horizontal.png?fit=max\u0026auto=format\u0026n=dcX-Hd4-QsKLE866\u0026q=85\u0026s=449901bb5b53e11232d03fd1fa54a4c3","dark":"https://mintcdn.com/d-api/dcX-Hd4-QsKLE866/logo/dapi-horizontal.png?fit=max\u0026auto=format\u0026n=dcX-Hd4-QsKLE866\u0026q=85\u0026s=449901bb5b53e11232d03fd1fa54a4c3"},"favicon":"https://mintcdn.com/d-api/dcX-Hd4-QsKLE866/favicon.png?fit=max\u0026auto=format\u0026n=dcX-Hd4-QsKLE866\u0026q=85\u0026s=a2b2d31d3ad7ea89d6d82db7f17b2b07","navbar":{"links":[{"href":"https://wa.me/5551920018823?text=Ol%C3%A1%2C%20preciso%20de%20ajuda%20com%20a%20documenta%C3%A7%C3%A3o%20da%20D-API","label":"Suporte"}],"primary":{"type":"button","label":"Painel","href":"https://app.d-api.cloud"}},"footer":{"links":[{"header":"D-API","items":[{"label":"Painel","href":"https://app.d-api.cloud"},{"label":"Suporte","href":"https://wa.me/5551920018823?text=Ol%C3%A1%2C%20preciso%20de%20ajuda%20com%20a%20documenta%C3%A7%C3%A3o%20da%20D-API"}]}]},"contextual":{"options":["copy","view","chatgpt","claude","mcp","cursor","vscode"],"display":"header"},"styling":{"latex":false},"navigation":{"languages":[{"language":"pt-BR","default":true,"href":"whatsapp/introducao"},{"language":"en","footer":{"links":[{"header":"D-API","items":[{"label":"Dashboard","href":"https://app.d-api.cloud"},{"label":"Support","href":"https://wa.me/5551920018823?text=Hi%2C%20I%20need%20help%20with%20the%20D-API%20documentation"}]}]},"navbar":{"links":[{"href":"https://wa.me/5551920018823?text=Hi%2C%20I%20need%20help%20with%20the%20D-API%20documentation","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://app.d-api.cloud"}},"href":"en/whatsapp/introducao"}]}},"deployment":{"deploymentMetadataValue":{"subdomain":"d-api","hasAudioNarration":false,"actualSubdomain":"d-api","customDomains":["docs.d-api.cloud"],"gitSource":{"type":"github","owner":"joaoartur","repo":"docs","deployBranch":"main","contentDirectory":"","isPrivate":false,"mountPath":"","label":""},"entitlements":{},"buildId":"6af87e0a4fd4397144dfd711","clientVersion":"0.0.4177","searchFilterCounts":[{"language":"pt-BR","tag":"API Reference","count":140},{"language":"en","tag":"API Reference","count":140},{"language":"pt-BR","tag":"Sessões","count":27},{"language":"en","tag":"Sessions","count":27},{"language":"pt-BR","tag":"Ligações","count":17},{"language":"pt-BR","tag":"WhatsApp","count":17},{"language":"en","tag":"Calls","count":17},{"language":"en","tag":"WhatsApp","count":17},{"language":"pt-BR","tag":"Grupos","count":15},{"language":"pt-BR","tag":"Conversas","count":15},{"language":"en","tag":"Groups","count":15},{"language":"en","tag":"Chats","count":15},{"language":"pt-BR","tag":"Webhooks","count":14},{"language":"en","tag":"Webhooks","count":14},{"language":"pt-BR","tag":"API Oficial (Cloud API)","count":11},{"language":"pt-BR","tag":"Mensagens","count":11},{"language":"en","tag":"Official API (Cloud API)","count":11},{"language":"en","tag":"Messages","count":11},{"language":"pt-BR","tag":"Catálogo","count":9},{"language":"en","tag":"Catalog","count":9}]},"assistantConfig":{"enableAskAiButton":false,"enableStarterQuestions":false,"enableAskAiSearchBar":true},"basePath":"","hasChatPermissions":false,"hasWebMcpPermissions":false,"toggles":[{"name":"kill-isr","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"custom-rbac-roles","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":"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":"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":"editor-metadata","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},{"name":"starter-pricing","enabled":true,"variant":{"name":"control","enabled":true,"payload":{"type":"string","value":"control"},"feature_enabled":true},"impressionData":false},{"name":"llms-txt-v2","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false},{"name":"wildcard-email-auth","enabled":true,"variant":{"name":"disabled","enabled":false,"feature_enabled":true},"impressionData":false}],"googleFontsInlined":false},"customCss":[],"page":{"pagePath":"en/api-reference/endpoints/baixar-midia","slug":"/en/api-reference/endpoints/baixar-midia","pageMetadata":{"title":"Download media","description":"Download received media in a unified way.","openapi":"api-reference/openapi.en.json POST /api/v1/media/download","href":"/en/api-reference/endpoints/baixar-midia"},"description":{"compiledSource":"\"use strict\";\nconst {jsx: _jsx} = arguments[0];\nconst {useMDXComponents: _provideComponents} = arguments[0];\nfunction _createMdxContent(props) {\n const _components = {\n p: \"p\",\n ..._provideComponents(),\n ...props.components\n };\n return _jsx(_components.p, {\n children: \"Download received media in a unified way.\"\n });\n}\nfunction MDXContent(props = {}) {\n const {wrapper: MDXLayout} = {\n ..._provideComponents(),\n ...props.components\n };\n return MDXLayout ? _jsx(MDXLayout, {\n ...props,\n children: _jsx(_createMdxContent, {\n ...props\n })\n }) : _createMdxContent(props);\n}\nreturn {\n default: MDXContent\n};\n","frontmatter":{},"scope":{}},"pageType":"default","mdx":{"mdxSource":{"compiledSource":"\"use strict\";const{Fragment:_Fragment,jsx:_jsx,jsxs:_jsxs}=arguments[0];const{useMDXComponents:_provideComponents}=arguments[0];function _createMdxContent(props){const _components={code:`code`,li:`li`,p:`p`,pre:`pre`,span:`span`,strong:`strong`,ul:`ul`,..._provideComponents(),...props.components},{CodeBlock,Heading,Tip,Warning}=_components;if(!CodeBlock)_missingMdxReference(`CodeBlock`,true);if(!Heading)_missingMdxReference(`Heading`,true);if(!Tip)_missingMdxReference(`Tip`,true);if(!Warning)_missingMdxReference(`Warning`,true);return _jsxs(_Fragment,{children:[_jsxs(_components.p,{children:[`Downloads the media of a received message. WhatsApp delivers encrypted media;\nthis endpoint decrypts it using the metadata that arrives in the webhook\n(`,_jsx(_components.code,{children:`media_key`}),`, `,_jsx(_components.code,{children:`mimetype`}),`, `,_jsx(_components.code,{children:`direct_path`}),` or `,_jsx(_components.code,{children:`url`}),`, and the hashes).`]}),`\n`,_jsxs(_components.p,{children:[`Set `,_jsx(_components.code,{children:`base64: true`}),` to receive the content embedded in the response, or use\n`,_jsx(_components.code,{children:`async`}),` for large downloads in the background.`]}),`\n`,_jsx(Tip,{children:_jsxs(_components.p,{children:[`The required fields (`,_jsx(_components.code,{children:`media_key`}),`, `,_jsx(_components.code,{children:`mimetype`}),`, `,_jsx(_components.code,{children:`file_sha256`}),` etc.) come in the\nreceived message webhook payload — pass them straight through to this endpoint.`]})}),`\n`,_jsx(Heading,{level:`2`,id:`official-api-cloud-api`,children:`Official API (Cloud API)`}),`\n`,_jsxs(_components.p,{children:[`On Official API connections, media is stored at Meta and identified by the\n`,_jsx(_components.code,{children:`media_id`}),`, which arrives in the webhook in `,_jsx(_components.code,{children:`media_data.media_id`}),`. Send `,_jsx(_components.code,{children:`media_id`}),` and\n`,_jsx(_components.code,{children:`mimetype`}),` instead of `,_jsx(_components.code,{children:`media_key`}),`, `,_jsx(_components.code,{children:`direct_path`}),` and hashes. The response is\nalways synchronous — `,_jsx(_components.code,{children:`async`}),` is not accepted on these connections.`]}),`\n`,_jsx(CodeBlock,{filename:``,numberOfLines:`6`,language:`json`,children:_jsx(_components.pre,{className:`shiki shiki-themes github-light-default dark-plus`,style:{backgroundColor:`#ffffff`,\"--shiki-dark-bg\":`#0B0C0E`,color:`#1f2328`,\"--shiki-dark\":`#D4D4D4`},language:`json`,children:_jsxs(_components.code,{language:`json`,numberOfLines:`6`,children:[_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`{`})}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"sessionId\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"cloud-...\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"media_id\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"1234567890\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"mimetype\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0A3069`,\"--shiki-dark\":`#CE9178`},children:`\"image/jpeg\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`,`})]}),`\n`,_jsxs(_components.span,{className:`line`,children:[_jsx(_components.span,{style:{color:`#116329`,\"--shiki-dark\":`#9CDCFE`},children:` \"base64\"`}),_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`: `}),_jsx(_components.span,{style:{color:`#0550AE`,\"--shiki-dark\":`#569CD6`},children:`true`})]}),`\n`,_jsx(_components.span,{className:`line`,children:_jsx(_components.span,{style:{color:`#1F2328`,\"--shiki-dark\":`#D4D4D4`},children:`}`})}),`\n`]})})}),`\n`,_jsx(Heading,{level:`2`,id:`accounts-with-“do-not-store-media”`,children:`Accounts with “Do not store media”`}),`\n`,_jsxs(_components.p,{children:[`With the `,_jsx(_components.strong,{children:`Do not store media`}),` option enabled under `,_jsx(_components.strong,{children:`My Account → Privacy`}),`, D-API\ndoes not keep any of the account’s media: nothing goes to storage, Redis, queues or\nthe database. Received message webhooks carry only the metadata\n(`,_jsx(_components.code,{children:`media_key`}),`, `,_jsx(_components.code,{children:`direct_path`}),`, hashes or `,_jsx(_components.code,{children:`media_id`}),`), with no `,_jsx(_components.code,{children:`media_url`}),` and no\nbase64, and the file is retrieved through this endpoint. On these accounts:`]}),`\n`,_jsxs(_components.ul,{children:[`\n`,_jsxs(_components.li,{children:[`the response is always base64, even without `,_jsx(_components.code,{children:`base64: true`}),`;`]}),`\n`,_jsxs(_components.li,{children:[_jsx(_components.code,{children:`async`}),` is rejected — download is synchronous only;`]}),`\n`,_jsxs(_components.li,{children:[`base64 media sends with `,_jsx(_components.code,{children:`async`}),` are also rejected; use synchronous\nsending or a URL.`]}),`\n`]}),`\n`,_jsx(Warning,{children:_jsx(_components.p,{children:`Enabling or disabling the option restarts the account’s unofficial connections,\nwhich go offline for a few seconds.`})})]})}function MDXContent(props={}){const{wrapper:MDXLayout}={..._provideComponents(),...props.components};return MDXLayout?_jsx(MDXLayout,{...props,children:_jsx(_createMdxContent,{...props})}):_createMdxContent(props)}return{default:MDXContent};function _missingMdxReference(id,component){throw new Error(`Expected `+(component?`component`:`object`)+\" `\"+id+\"` to be defined: you likely forgot to import, pass, or provide it.\")}","frontmatter":{},"scope":{"config":{},"pageMetadata":{"title":"Download media","description":"Download received media in a unified way.","openapi":"api-reference/openapi.en.json POST /api/v1/media/download","href":"/en/api-reference/endpoints/baixar-midia"}}},"mdxSourceWithNoJs":null},"mdxExtracts":{"tableOfContents":[{"title":"Official API (Cloud API)","slug":"official-api-cloud-api","depth":2,"children":[]},{"title":"Accounts with “Do not store media”","slug":"accounts-with-“do-not-store-media”","depth":2,"children":[]}],"codeExamples":{}},"jsLinks":[],"openApiReferenceData":{"operation":{"parameters":[],"operationId":"postApiV1MediaDownload","tags":["Media"],"summary":"Download media (unified)","description":"Download received media in a unified way.","requestBody":"e6fe3a4d-1587-4f20-a927-5a6ea8f6bd95","responses":{"200":"cd87a454-733b-4d23-a2cc-6ca799be5fbc"},"method":"post","type":"path","servers":["30dcbd30-46ac-41fc-9f05-b51acbf83285"],"security":["29ca4a19-6992-4b98-8548-87d175ab2453"],"path":"/api/v1/media/download","baseUrlOptions":["https://api.d-api.cloud"],"title":"Download media (unified)","codeSamples":[],"requiredOnlyExamples":false,"requestExampleType":"generated","responseExampleType":"generated"},"dependencies":{"parameters":{},"requestBody":{"required":true,"content":{"application/json":{"schema":{"type":"object","properties":{"sessionId":{"minLength":1,"type":"string","isRequired":true,"uniqueKey":"sessionId","typeLabel":"string"},"mimetype":{"minLength":1,"type":"string","isRequired":true,"uniqueKey":"mimetype","typeLabel":"string"},"url":{"type":"string","uniqueKey":"url","typeLabel":"string"},"direct_path":{"type":"string","uniqueKey":"direct_path","typeLabel":"string"},"media_key":{"minLength":1,"type":"string","uniqueKey":"media_key","typeLabel":"string"},"media_id":{"minLength":1,"type":"string","uniqueKey":"media_id","typeLabel":"string"},"media_type":{"oneOf":[{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"image","uniqueKey":"media_type.oneOf.0","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"video","uniqueKey":"media_type.oneOf.1","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"audio","uniqueKey":"media_type.oneOf.2","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"document","uniqueKey":"media_type.oneOf.3","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"sticker","uniqueKey":"media_type.oneOf.4","typeLabel":"string"}],"uniqueKey":"media_type","typeLabel":"string"},"file_enc_sha256":{"type":"string","uniqueKey":"file_enc_sha256","typeLabel":"string"},"file_sha256":{"type":"string","uniqueKey":"file_sha256","typeLabel":"string"},"file_length":{"type":"number","uniqueKey":"file_length","typeLabel":"number"},"async":{"oneOf":[{"type":"boolean","uniqueKey":"async.oneOf.0","typeLabel":"boolean"},{"type":"string","uniqueKey":"async.oneOf.1","typeLabel":"string"}],"uniqueKey":"async","typeLabel":"boolean | string"},"base64":{"type":"boolean","uniqueKey":"base64","typeLabel":"boolean"}},"required":["sessionId","mimetype"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"sessionId":"\u003cstring>","mimetype":"\u003cstring>","url":"\u003cstring>","direct_path":"\u003cstring>","media_key":"\u003cstring>","media_id":"\u003cstring>","media_type":"image","file_enc_sha256":"\u003cstring>","file_sha256":"\u003cstring>","file_length":123,"async":true,"base64":true}}},"exampleType":"generated"},"multipart/form-data":{"schema":{"type":"object","properties":{"sessionId":{"minLength":1,"type":"string","isRequired":true,"uniqueKey":"sessionId","typeLabel":"string"},"mimetype":{"minLength":1,"type":"string","isRequired":true,"uniqueKey":"mimetype","typeLabel":"string"},"url":{"type":"string","uniqueKey":"url","typeLabel":"string"},"direct_path":{"type":"string","uniqueKey":"direct_path","typeLabel":"string"},"media_key":{"minLength":1,"type":"string","uniqueKey":"media_key","typeLabel":"string"},"media_id":{"minLength":1,"type":"string","uniqueKey":"media_id","typeLabel":"string"},"media_type":{"oneOf":[{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"image","uniqueKey":"media_type.oneOf.0","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"video","uniqueKey":"media_type.oneOf.1","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"audio","uniqueKey":"media_type.oneOf.2","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"document","uniqueKey":"media_type.oneOf.3","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"sticker","uniqueKey":"media_type.oneOf.4","typeLabel":"string"}],"uniqueKey":"media_type","typeLabel":"string"},"file_enc_sha256":{"type":"string","uniqueKey":"file_enc_sha256","typeLabel":"string"},"file_sha256":{"type":"string","uniqueKey":"file_sha256","typeLabel":"string"},"file_length":{"type":"number","uniqueKey":"file_length","typeLabel":"number"},"async":{"oneOf":[{"type":"boolean","uniqueKey":"async.oneOf.0","typeLabel":"boolean"},{"type":"string","uniqueKey":"async.oneOf.1","typeLabel":"string"}],"uniqueKey":"async","typeLabel":"boolean | string"},"base64":{"type":"boolean","uniqueKey":"base64","typeLabel":"boolean"}},"required":["sessionId","mimetype"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"sessionId":"\u003cstring>","mimetype":"\u003cstring>","url":"\u003cstring>","direct_path":"\u003cstring>","media_key":"\u003cstring>","media_id":"\u003cstring>","media_type":"image","file_enc_sha256":"\u003cstring>","file_sha256":"\u003cstring>","file_length":123,"async":true,"base64":true}}},"exampleType":"generated"},"text/plain":{"schema":{"type":"object","properties":{"sessionId":{"minLength":1,"type":"string","isRequired":true,"uniqueKey":"sessionId","typeLabel":"string"},"mimetype":{"minLength":1,"type":"string","isRequired":true,"uniqueKey":"mimetype","typeLabel":"string"},"url":{"type":"string","uniqueKey":"url","typeLabel":"string"},"direct_path":{"type":"string","uniqueKey":"direct_path","typeLabel":"string"},"media_key":{"minLength":1,"type":"string","uniqueKey":"media_key","typeLabel":"string"},"media_id":{"minLength":1,"type":"string","uniqueKey":"media_id","typeLabel":"string"},"media_type":{"oneOf":[{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"image","uniqueKey":"media_type.oneOf.0","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"video","uniqueKey":"media_type.oneOf.1","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"audio","uniqueKey":"media_type.oneOf.2","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"document","uniqueKey":"media_type.oneOf.3","typeLabel":"string"},{"type":"string","description":"Media type. Optional: when omitted, it is inferred from the mimetype.","const":"sticker","uniqueKey":"media_type.oneOf.4","typeLabel":"string"}],"uniqueKey":"media_type","typeLabel":"string"},"file_enc_sha256":{"type":"string","uniqueKey":"file_enc_sha256","typeLabel":"string"},"file_sha256":{"type":"string","uniqueKey":"file_sha256","typeLabel":"string"},"file_length":{"type":"number","uniqueKey":"file_length","typeLabel":"number"},"async":{"oneOf":[{"type":"boolean","uniqueKey":"async.oneOf.0","typeLabel":"boolean"},{"type":"string","uniqueKey":"async.oneOf.1","typeLabel":"string"}],"uniqueKey":"async","typeLabel":"boolean | string"},"base64":{"type":"boolean","uniqueKey":"base64","typeLabel":"boolean"}},"required":["sessionId","mimetype"],"additionalProperties":false,"uniqueKey":"","typeLabel":"object"},"examples":{"Example":{"title":"Example","value":{"sessionId":"\u003cstring>","mimetype":"\u003cstring>","url":"\u003cstring>","direct_path":"\u003cstring>","media_key":"\u003cstring>","media_id":"\u003cstring>","media_type":"image","file_enc_sha256":"\u003cstring>","file_sha256":"\u003cstring>","file_length":123,"async":true,"base64":true}}},"exampleType":"generated"}},"exampleType":"generated"},"responses":{"cd87a454-733b-4d23-a2cc-6ca799be5fbc":{"description":"Successful response","content":{"_mintlify/placeholder":{"schema":{"type":"object","description":""}}}}},"security":{"29ca4a19-6992-4b98-8548-87d175ab2453":{"ApiKeyAuth":{"type":"apiKey","in":"header","name":"Authorization","description":"API Key for authentication. Format: \u003cAPI_KEY>","scopes":[],"schemeName":"ApiKeyAuth"}}},"servers":{"30dcbd30-46ac-41fc-9f05-b51acbf83285":{"url":"https://api.d-api.cloud","description":"Production"}},"processedSecurityOptions":[{"schemes":[{"scheme":{"type":"apiKey","in":"header","name":"Authorization","description":"API Key for authentication. Format: \u003cAPI_KEY>","scopes":[],"schemeName":"ApiKeyAuth"},"schema":{"title":"Authorization","type":"string","description":"API Key for authentication. Format: \u003cAPI_KEY>","isRequired":true,"typeLabel":"string","deprecated":false},"schemeName":"ApiKeyAuth","name":"Authorization"}],"title":"ApiKeyAuth"}]},"originalFileLocation":"api-reference/openapi.en.json"},"subdomain":"d-api","siteName":"D-API","title":"Download media - D-API","navMaps":{"firstHrefInVersion":{},"firstHrefInLanguage":{"pt-BR":{"href":"/api-reference/endpoints/baixar-midia","matchLevel":1},"en":{"href":"/en/api-reference/endpoints/baixar-midia","matchLevel":0}}},"lastModified":"2026-10-31T01:05:58.055Z","originalFileLocation":"en/api-reference/endpoints/baixar-midia.mdx","locale":"en"},"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=\"description\" content=\"Download received media in a unified way.\">\u003cmeta data-mint-head name=\"application-name\" content=\"D-API\">\u003cmeta data-mint-head name=\"generator\" content=\"Mintlify\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_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=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon/apple-touch-icon.png\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon/favicon-16x16.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon/favicon-32x32.png\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon/favicon.ico\" media=\"(prefers-color-scheme: light)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"192x192\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon-dark/android-chrome-192x192.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"16x16\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon-dark/favicon-16x16.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"icon\" type=\"image/png\" sizes=\"32x32\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon-dark/favicon-32x32.png\" media=\"(prefers-color-scheme: dark)\">\u003clink data-mint-head rel=\"shortcut icon\" type=\"image/x-icon\" href=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon-dark/favicon.ico\" media=\"(prefers-color-scheme: dark)\">\u003cmeta data-mint-head property=\"og:title\" content=\"Download media - D-API\">\u003cmeta data-mint-head property=\"og:description\" content=\"Download received media in a unified way.\">\u003cmeta data-mint-head property=\"og:site_name\" content=\"D-API\">\u003cmeta data-mint-head property=\"og:url\" content=\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia\">\u003cmeta data-mint-head property=\"og:type\" content=\"website\">\u003cmeta data-mint-head property=\"og:image\" content=\"https://d-api.mintlify.site/_mintlify/api/og/v2?division=Media\u0026amp;title=Download+media\u0026amp;description=Download+received+media+in+a+unified+way.\u0026amp;theme=6bf39124e553ea1529d3e32e\u0026amp;signature=aca972b1aae09e5632eedb2474ab5b01b81df1caa6e8f8150065db26f72aedae\">\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=\"Download media - D-API\">\u003cmeta data-mint-head name=\"twitter:description\" content=\"Download received media in a unified way.\">\u003cmeta data-mint-head name=\"twitter:image\" content=\"https://d-api.mintlify.site/_mintlify/api/og/v2?division=Media\u0026amp;title=Download+media\u0026amp;description=Download+received+media+in+a+unified+way.\u0026amp;theme=6bf39124e553ea1529d3e32e\u0026amp;signature=aca972b1aae09e5632eedb2474ab5b01b81df1caa6e8f8150065db26f72aedae\">\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=\"/mintlify-assets/_mintlify/favicons/d-api/36SbMupri6RA-H0W/_generated/favicon/browserconfig.xml\">\u003cmeta data-mint-head name=\"apple-mobile-web-app-title\" content=\"D-API\">\u003cmeta data-mint-head name=\"msapplication-TileColor\" content=\"#00B7CD\">\u003clink data-mint-head rel=\"canonical\" href=\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia\">\u003clink data-mint-head rel=\"alternate\" type=\"application/xml\" href=\"/sitemap.xml\">\u003clink data-mint-head rel=\"alternate\" type=\"text/markdown\" href=\"/en/api-reference/endpoints/baixar-midia.md\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"en\" href=\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"pt-BR\" href=\"https://docs.d-api.cloud/api-reference/endpoints/baixar-midia\">\u003clink data-mint-head rel=\"alternate\" hreflang=\"x-default\" href=\"https://docs.d-api.cloud/api-reference/endpoints/baixar-midia\">\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@graph\":[{\"@type\":\"Organization\",\"@id\":\"https://docs.d-api.cloud/#organization\",\"name\":\"D-API\",\"url\":\"https://docs.d-api.cloud\",\"logo\":{\"@type\":\"ImageObject\",\"url\":\"https://mintcdn.com/d-api/dcX-Hd4-QsKLE866/logo/dapi-horizontal.png?fit=max\u0026auto=format\u0026n=dcX-Hd4-QsKLE866\u0026q=85\u0026s=449901bb5b53e11232d03fd1fa54a4c3\"}},{\"@type\":\"WebSite\",\"@id\":\"https://docs.d-api.cloud#website\",\"name\":\"D-API\",\"url\":\"https://docs.d-api.cloud\",\"publisher\":{\"@id\":\"https://docs.d-api.cloud/#organization\"}},{\"@type\":\"WebPage\",\"@id\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia#webpage\",\"url\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia\",\"name\":\"Download media\",\"description\":\"Download received media in a unified way.\",\"dateModified\":\"2026-10-31T01:05:58.055Z\",\"isPartOf\":{\"@id\":\"https://docs.d-api.cloud#website\"},\"breadcrumb\":{\"@id\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia#breadcrumb\"}},{\"@type\":\"BreadcrumbList\",\"@id\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"D-API\",\"item\":\"https://docs.d-api.cloud\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Download media\",\"item\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia\"}]},{\"@type\":[\"TechArticle\",\"APIReference\"],\"@id\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia#apireference\",\"headline\":\"Download media\",\"name\":\"Download media\",\"description\":\"Download received media in a unified way.\",\"url\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia\",\"mainEntityOfPage\":{\"@id\":\"https://docs.d-api.cloud/en/api-reference/endpoints/baixar-midia#webpage\"},\"dateModified\":\"2026-10-31T01:05:58.055Z\",\"publisher\":{\"@id\":\"https://docs.d-api.cloud/#organization\"},\"isPartOf\":{\"@id\":\"https://docs.d-api.cloud#website\"}}]}\u003c/script>\u003cscript data-mint-head type=\"application/ld+json\">{\"@context\":\"https://schema.org\",\"@type\":\"WebSite\",\"name\":\"D-API\",\"publisher\":{\"@type\":\"Organization\",\"name\":\"D-API\"},\"provider\":{\"@type\":\"Organization\",\"name\":\"Mintlify\",\"url\":\"https://mintlify.com\"}}\u003c/script>","agentPointerHref":"/en/api-reference/endpoints/baixar-midia.md","siteName":"D-API","nav":{"global":null,"languages":[{"language":"pt-BR","default":true,"pages":[{"title":"pt-BR","href":"/api-reference/endpoints/baixar-midia"}]},{"language":"en","footer":{"links":[{"header":"D-API","items":[{"label":"Dashboard","href":"https://app.d-api.cloud"},{"label":"Support","href":"https://wa.me/5551920018823?text=Hi%2C%20I%20need%20help%20with%20the%20D-API%20documentation"}]}]},"navbar":{"links":[{"href":"https://wa.me/5551920018823?text=Hi%2C%20I%20need%20help%20with%20the%20D-API%20documentation","label":"Support"}],"primary":{"type":"button","label":"Dashboard","href":"https://app.d-api.cloud"}},"tabs":[{"tab":"WhatsApp","pages":[{"title":"WhatsApp","href":"/en/whatsapp/introducao"}]},{"tab":"Official API","pages":[{"title":"Official API","href":"/en/api-oficial/saas"}]},{"tab":"SMS","pages":[{"title":"SMS","href":"/en/sms/webhooks/visao-geral"}]},{"tab":"IVR","pages":[{"title":"IVR","href":"/en/ura/ligacoes/stream"}]},{"tab":"API Reference","groups":[{"group":"Getting started","pages":[{"title":"Introduction","href":"/en/api-reference/introduction"},{"title":"Quickstart","href":"/en/api-reference/quickstart"},{"title":"Returns basic information about the API","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /","href":"/api-reference/home/returns-basic-information-about-the-api"},{"title":"Returns the API health status, including DB, RabbitMQ and Redis","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /health","href":"/api-reference/home/returns-the-api-health-status-including-db-rabbitmq-and-redis"}]},{"group":"Sessions","pages":[{"title":"Create a session","openapi":"api-reference/openapi.en.json POST /api/v1/sessions","href":"/en/api-reference/endpoints/criar-sessao"},{"title":"Connect via QR code","openapi":"api-reference/openapi.en.json GET /api/v1/sessions/{sessionId}/qr","href":"/en/api-reference/endpoints/conectar-qr"},{"title":"Generate migration code (OTP)","openapi":"api-reference/openapi.en.json POST /api/v1/sessions/{sessionId}/migration-otp","href":"/en/api-reference/endpoints/gerar-otp"},{"title":"List all sessions","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions","href":"/api-reference/sessions/list-all-sessions"},{"title":"Session data","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions/{sessionId}","href":"/api-reference/sessions/session-data"},{"title":"Delete a session","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json delete /api/v1/sessions/{sessionId}","href":"/api-reference/sessions/delete-a-session"},{"title":"Session logs","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions/{sessionId}/logs","href":"/api-reference/sessions/session-logs"},{"title":"Update session webhook","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/webhook","href":"/api-reference/sessions/update-session-webhook"},{"title":"Save RabbitMQ settings","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/rabbitmq-config","href":"/api-reference/sessions/save-rabbitmq-settings"},{"title":"Save Webhook settings","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/webhook-config","href":"/api-reference/sessions/save-webhook-settings"},{"title":"Update message filters","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/ignore-settings","href":"/api-reference/sessions/update-message-filters"},{"title":"Update call settings","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/call-settings","href":"/api-reference/sessions/update-call-settings"},{"title":"Update automatic mark as read","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/mark-previous-as-read-settings","href":"/api-reference/sessions/update-automatic-mark-as-read"},{"title":"Update Brazil country code usage","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/assume-br-country-code-settings","href":"/api-reference/sessions/update-brazil-country-code-usage"},{"title":"Update message storage","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/disable-message-storage-settings","href":"/api-reference/sessions/update-message-storage"},{"title":"Update call receiving","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/receive-calls-settings","href":"/api-reference/sessions/update-call-receiving"},{"title":"Update command delivery mode","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/command-mode","href":"/api-reference/sessions/update-command-delivery-mode"},{"title":"Reconnect a session with pod restart","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions/{sessionId}/connect","href":"/api-reference/sessions/reconnect-a-session-with-pod-restart"},{"title":"Disconnect a session","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/disconnect","href":"/api-reference/sessions/disconnect-a-session"},{"title":"Passkey connect available?","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions/passkey/available","href":"/api-reference/sessions/passkey-connect-available?"},{"title":"Get a session's WebAuthn (passkey) challenge","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions/{sessionId}/auth/passkey","href":"/api-reference/sessions/get-a-sessions-webauthn-passkey-challenge"},{"title":"Submit a session's WebAuthn (passkey) signature","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/auth/passkey","href":"/api-reference/sessions/submit-a-sessions-webauthn-passkey-signature"},{"title":"Generate passkey fallback code (popup)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/auth/passkey/code","href":"/api-reference/sessions/generate-passkey-fallback-code-popup"},{"title":"Get a session's pairing code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/sessions/{sessionId}/pair-code","href":"/api-reference/sessions/get-a-sessions-pairing-code"},{"title":"Import migrated WhatsApp Web session","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sessions/{sessionId}/import-web-auth","href":"/api-reference/sessions/import-migrated-whatsapp-web-session"},{"title":"Get passkey challenge by code (popup fallback)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/session-passkey/{code}","href":"/api-reference/sessions/get-passkey-challenge-by-code-popup-fallback"},{"title":"Submit passkey signature by code (popup fallback)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/session-passkey/{code}","href":"/api-reference/sessions/submit-passkey-signature-by-code-popup-fallback"}]},{"group":"Migration","pages":[{"title":"Migrate WhatsApp Web session with single-use code","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/session-migration/migrate","href":"/api-reference/migration/migrate-whatsapp-web-session-with-single-use-code"}]},{"group":"Messages","pages":[{"title":"Send text message","openapi":"api-reference/openapi.en.json POST /api/v1/messages/send/text","href":"/en/api-reference/endpoints/enviar-texto"},{"title":"Send image","openapi":"api-reference/openapi.en.json POST /api/v1/messages/send/image","href":"/en/api-reference/endpoints/enviar-imagem"},{"title":"Send video message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/video","href":"/api-reference/messages/send-video-message"},{"title":"Send audio message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/audio","href":"/api-reference/messages/send-audio-message"},{"title":"Send document message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/document","href":"/api-reference/messages/send-document-message"},{"title":"Send sticker","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/sticker","href":"/api-reference/messages/send-sticker"},{"title":"Send location","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/location","href":"/api-reference/messages/send-location"},{"title":"Send contact","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/contact","href":"/api-reference/messages/send-contact"},{"title":"Send poll","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/poll","href":"/api-reference/messages/send-poll"},{"title":"Send reaction","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/reaction","href":"/api-reference/messages/send-reaction"},{"title":"Send album","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/messages/send/album","href":"/api-reference/messages/send-album"}]},{"group":"Interactive messages","pages":[{"title":"Send list message","openapi":"api-reference/openapi.en.json POST /api/v1/interactive/send/list","href":"/en/api-reference/endpoints/enviar-lista"},{"title":"Send carousel message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/interactive/send/carousel","href":"/api-reference/interactive-messages/send-carousel-message"},{"title":"Send template message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/interactive/send/template","href":"/api-reference/interactive-messages/send-template-message"},{"title":"Send NativeFlow message (mobile only)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/interactive/send/nativeflow","href":"/api-reference/interactive-messages/send-nativeflow-message-mobile-only"},{"title":"Send PIX button message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/interactive/send/pix","href":"/api-reference/interactive-messages/send-pix-button-message"}]},{"group":"Chats","pages":[{"title":"Edit message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json put /api/v1/messages/{messageId}","href":"/api-reference/chat/edit-message"},{"title":"List a session's chats","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/chats/","href":"/api-reference/chat/list-a-sessions-chats"},{"title":"Advanced chat search","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/search","href":"/api-reference/chat/advanced-chat-search"},{"title":"Advanced message search","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/messages/search","href":"/api-reference/chat/advanced-message-search"},{"title":"List a chat's messages (simplified)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/chats/{chatId}/messages","href":"/api-reference/chat/list-a-chats-messages-simplified"},{"title":"Send presence","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/presence","href":"/api-reference/chat/send-presence"},{"title":"Mark as read","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/read","href":"/api-reference/chat/mark-as-read"},{"title":"Archive chat","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/archive","href":"/api-reference/chat/archive-chat"},{"title":"Pin chat","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/pin","href":"/api-reference/chat/pin-chat"},{"title":"Mute chat","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/mute","href":"/api-reference/chat/mute-chat"},{"title":"Mark chat as unread","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/chats/mark-unread","href":"/api-reference/chat/mark-chat-as-unread"},{"title":"List archived chats","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/chats/archived","href":"/api-reference/chat/list-archived-chats"},{"title":"List pinned chats","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/chats/pinned","href":"/api-reference/chat/list-pinned-chats"},{"title":"Delete message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json delete /api/v1/chats/messages/{messageId}","href":"/api-reference/chat/delete-message"},{"title":"Get chat details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/chats/{chatId}","href":"/api-reference/chat/get-chat-details"}]},{"group":"Contacts","pages":[{"title":"Get blocklist","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/contacts/blocklist","href":"/api-reference/contacts/get-blocklist"},{"title":"Update blocklist","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/contacts/blocklist","href":"/api-reference/contacts/update-blocklist"},{"title":"Report contact","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/contacts/report","href":"/api-reference/contacts/report-contact"},{"title":"List contacts","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/contacts/","href":"/api-reference/contacts/list-contacts"},{"title":"Get contact info","openapi":"api-reference/openapi.en.json GET /api/v1/contacts/{phone}","href":"/en/api-reference/endpoints/obter-contato"},{"title":"Get user avatar","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/contacts/{phone}/avatar","href":"/api-reference/contacts/get-user-avatar"},{"title":"Check users","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/contacts/check","href":"/api-reference/contacts/check-users"},{"title":"Get user info","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/contacts/getuser","href":"/api-reference/contacts/get-user-info"}]},{"group":"Groups","pages":[{"title":"Create group","openapi":"api-reference/openapi.en.json POST /api/v1/groups/create","href":"/en/api-reference/endpoints/criar-grupo"},{"title":"List groups","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/groups/list","href":"/api-reference/groups/list-groups"},{"title":"Get group info","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/groups/{groupId}/info","href":"/api-reference/groups/get-group-info"},{"title":"Manage group participants","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/participants","href":"/api-reference/groups/manage-group-participants"},{"title":"Join group","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/join","href":"/api-reference/groups/join-group"},{"title":"Leave group","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/leave","href":"/api-reference/groups/leave-group"},{"title":"Link a group to a community","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/link","href":"/api-reference/groups/link-a-group-to-a-community"},{"title":"Get group invite","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/groups/{groupId}/invite","href":"/api-reference/groups/get-group-invite"},{"title":"Set group description","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json put /api/v1/groups/{groupId}/description","href":"/api-reference/groups/set-group-description"},{"title":"Set group name","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json put /api/v1/groups/{groupId}/name","href":"/api-reference/groups/set-group-name"},{"title":"Set group picture","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json put /api/v1/groups/{groupId}/profile-picture","href":"/api-reference/groups/set-group-picture"},{"title":"Set group privacy settings","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json put /api/v1/groups/{groupId}/settings","href":"/api-reference/groups/set-group-privacy-settings"},{"title":"Revoke group invite link","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/invite/revoke","href":"/api-reference/groups/revoke-group-invite-link"},{"title":"Approve group join requests","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/join-requests/approve","href":"/api-reference/groups/approve-group-join-requests"},{"title":"Reject group join requests","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/groups/{groupId}/join-requests/reject","href":"/api-reference/groups/reject-group-join-requests"}]},{"group":"Labels","pages":[{"title":"Sync labels","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/labels/sync","href":"/api-reference/labels/sync-labels"},{"title":"Create/edit label","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/labels/upsert","href":"/api-reference/labels/createedit-label"},{"title":"Attach label to chat","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/labels/attach","href":"/api-reference/labels/attach-label-to-chat"},{"title":"List labels","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/labels/list","href":"/api-reference/labels/list-labels"},{"title":"List contact labels","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/labels/contact-labels","href":"/api-reference/labels/list-contact-labels"}]},{"group":"Catalog","pages":[{"title":"List catalog products","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/list","href":"/api-reference/catalog/list-catalog-products"},{"title":"List catalog collections","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/collections/list","href":"/api-reference/catalog/list-catalog-collections"},{"title":"Get product by ID","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/product/get","href":"/api-reference/catalog/get-product-by-id"},{"title":"Create product","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/product/create","href":"/api-reference/catalog/create-product"},{"title":"Edit product","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/product/edit","href":"/api-reference/catalog/edit-product"},{"title":"Delete product","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/product/delete","href":"/api-reference/catalog/delete-product"},{"title":"Create collection","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/collection/create","href":"/api-reference/catalog/create-collection"},{"title":"Edit collection","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/collection/edit","href":"/api-reference/catalog/edit-collection"},{"title":"Delete collection","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/catalog/collection/delete","href":"/api-reference/catalog/delete-collection"}]},{"group":"Channels (Newsletters)","pages":[{"title":"List newsletters","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/newsletters/list","href":"/api-reference/newsletters/list-newsletters"},{"title":"Create newsletter","description":"Creates a new newsletter/channel. picture can be a URL or base64.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/newsletters/create","href":"/api-reference/newsletters/create-newsletter"}]},{"group":"Media","pages":[{"title":"Download media","openapi":"api-reference/openapi.en.json POST /api/v1/media/download","href":"/en/api-reference/endpoints/baixar-midia"}]},{"group":"History","pages":[{"title":"Sync history (bulk) via webhook in D-API format","description":"Resends the instance's stored history in bulk to the webhook (D-API messages.received format). Default webhook: the one configured on the session (per_event uses the message received event's webhook); you can override it with `webhookUrl` (required if the instance has no webhook). Includes media when the message has a media_url. Delivery to the webhook is capped by `delivery.maxRps` (default 100 req/s, maximum 500), shared by all of the account's syncs to the same destination.","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/history/sync","href":"/api-reference/history/sync-history-bulk-via-webhook-in-d-api-format"},{"title":"Instance history sync (D-API) status","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/history/sync/{sessionId}/status","href":"/api-reference/history/instance-history-sync-d-api-status"},{"title":"Request FULL HISTORY SYNC","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/history/full-sync","href":"/api-reference/history/request-full-history-sync"},{"title":"Request HISTORY SYNC ON DEMAND","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/history/on-demand","href":"/api-reference/history/request-history-sync-on-demand"}]},{"group":"Calls","pages":[{"title":"List recorded calls","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/calls/","href":"/api-reference/calls/list-recorded-calls"},{"title":"Get recorded call by id","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/calls/{callId}","href":"/api-reference/calls/get-recorded-call-by-id"},{"title":"Create WhatsApp call link","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/create-link","href":"/api-reference/calls/create-whatsapp-call-link"},{"title":"Send scheduled call message","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/send-event","href":"/api-reference/calls/send-scheduled-call-message"},{"title":"Place voice call","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/place","href":"/api-reference/calls/place-voice-call"},{"title":"Place live (stream) voice call","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/stream","href":"/api-reference/calls/place-live-stream-voice-call"},{"title":"Accept incoming call","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/accept","href":"/api-reference/calls/accept-incoming-call"},{"title":"Reject incoming call","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/reject","href":"/api-reference/calls/reject-incoming-call"},{"title":"End active voice call","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/end","href":"/api-reference/calls/end-active-voice-call"},{"title":"Mute or unmute call audio","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/mute","href":"/api-reference/calls/mute-or-unmute-call-audio"},{"title":"Get call state","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/calls/state","href":"/api-reference/calls/get-call-state"}]},{"group":"Async commands","pages":[{"title":"Get async command","openapi":"api-reference/openapi.en.json GET /api/v1/commands/{commandId}","href":"/en/api-reference/endpoints/consultar-comando"},{"title":"Ordered async sending (sequential)","href":"/en/api-reference/endpoints/envio-sequencial"}]},{"group":"Voice agents","pages":[{"title":"Get call details","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/voice-agent-calls/{callId}","href":"/api-reference/voice-agents/get-call-details"},{"title":"Call transcript (paginated)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/voice-agent-calls/{callId}/turns","href":"/api-reference/voice-agents/call-transcript-paginated"},{"title":"Trigger an agent call (public trigger URL)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/hooks/va/{token}","href":"/api-reference/voice-agents-—-triggers/trigger-an-agent-call-public-trigger-url"}]},{"group":"IVR calls","pages":[{"title":"Dispatch bulk IVR calls (audio or IVR flow)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/voice/bulk","href":"/api-reference/ivr-calls/dispatch-bulk-ivr-calls-audio-or-ivr-flow"},{"title":"Dispatch an IVR call (audio or IVR flow)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/voice/call","href":"/api-reference/ivr-calls/dispatch-an-ivr-call-audio-or-ivr-flow"},{"title":"Start a live IVR call (Smart Caller ID, 30/6 billing)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/voice/live/start","href":"/api-reference/ivr-calls/start-a-live-ivr-call-smart-caller-id-306-billing"}]},{"group":"SMS","pages":[{"title":"Send an SMS","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sms/send","href":"/api-reference/sms/send-an-sms"},{"title":"Send bulk SMS (same message to multiple numbers)","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json post /api/v1/sms/bulk","href":"/api-reference/sms/send-bulk-sms-same-message-to-multiple-numbers"}]},{"group":"Account","pages":[{"title":"Get account limits","deprecated":null,"version":null,"openapi":"/api-reference/openapi.en.json get /api/v1/limits/{sessionId}","href":"/api-reference/account/get-account-limits"}]},{"group":"Official API (Cloud API)","pages":[{"group":"Connection","pages":[{"title":"Create connection manually","openapi":"api-reference/openapi.en.json POST /api/v1/connections/cloud-api/manual","href":"/en/api-reference/cloud-api/criar-conexao-manual"},{"title":"Get connection","openapi":"api-reference/openapi.en.json GET /api/v1/connections/cloud-api/{id}","href":"/en/api-reference/cloud-api/obter-conexao"},{"title":"Update connection","openapi":"api-reference/openapi.en.json PATCH /api/v1/connections/cloud-api/{id}","href":"/en/api-reference/cloud-api/atualizar-conexao"},{"title":"Get Meta access token","openapi":"api-reference/openapi.en.json GET /api/v1/connections/cloud-api/{id}/access-token","href":"/en/api-reference/cloud-api/obter-access-token"}]},{"group":"Routing","pages":[{"title":"Get partners and routing","openapi":"api-reference/openapi.en.json GET /api/v1/connections/cloud-api/{id}/routing","href":"/en/api-reference/cloud-api/ver-roteamento"},{"title":"Take, pass or release a conversation","openapi":"api-reference/openapi.en.json POST /api/v1/connections/cloud-api/{id}/thread-control","href":"/en/api-reference/cloud-api/controlar-conversa"}]},{"group":"Templates","pages":[{"title":"List approved templates","openapi":"api-reference/openapi.en.json GET /api/v1/connections/cloud-api/{id}/templates","href":"/en/api-reference/cloud-api/listar-templates"},{"title":"List all templates","openapi":"api-reference/openapi.en.json GET /api/v1/connections/cloud-api/{id}/templates/all","href":"/en/api-reference/cloud-api/listar-templates-todos"},{"title":"Create template","openapi":"api-reference/openapi.en.json POST /api/v1/connections/cloud-api/{id}/templates","href":"/en/api-reference/cloud-api/criar-template"},{"title":"Delete template","openapi":"api-reference/openapi.en.json DELETE /api/v1/connections/cloud-api/{id}/templates/{name}","href":"/en/api-reference/cloud-api/excluir-template"},{"title":"Send template","openapi":"api-reference/openapi.en.json POST /api/v1/messages/send/template","href":"/en/api-reference/cloud-api/enviar-template"}]}]}]}]}]},"basePath":"","title":"Download media - D-API","deploymentId":"dpl_HhUetB7eHHDAmK9T1Teip38TgFx9","buildId":"dpl_HhUetB7eHHDAmK9T1Teip38TgFx9","dynamics":["c2aa737661","2b790eda92","b0f84f53ff","a9bb46feb3"],"chunks":["OpenApiReferenceProvider-jJHA3WSo.js","utils-DbZn3Mjn.js","cloneDeep-CnBnaSyy.js","_Uint8Array-CMQtTgBR.js","isObject-FP1Yky1u.js","utils-Bl2DvzOJ.js","addUniqueKeysToSchema-BwOLo9p1.js","snippetPresets-BBiPpKa-.js","style-to-object-BY3JEAdk.js","v4-DIgz8zy6.js","conditional-requirements-CFM0id0Q.js","ApiExamples-C0px4Tml.js","isEqual-zAyttAAO.js","usePlaygroundInputsStore-Dell6dGw.js","shallow-0VKqkSqN.js","getApiPlaygroundDisplay-CP_ctPEB.js","CodeSnippet-5L35ic0s.js","CodeSnippets-DOXbNhJw.js","Page-DRLI_2Ue.js","getPastedJson-VhzT9m2P.js","icon-CD8_AtCO.js","MethodPill-DGgOMftG.js","DuplicateIcon-DZ6A_EtN.js","createIcon-DUl4oM5f.js","DynamicMarkdown-BGHukeRM.js","SectionHeading-ChrEUs8u.js","axios-vUo_bRtp.js","Markdown-Dj-na-_-.js","dist-C5gjFYHe.js","lib-DuNMoZ05.js","lib-B8HbPgcC.js","katex-YMM-FMeD.js","html-void-elements-mCSPHezU.js","marked.esm-CZWythHk.js","AssistantPageLink-DEBW87tT.js"]}