WhatsApp

Download WhatsApp media

Streams the binary for a WhatsApp attachment. This is the endpoint the url on a WhatsApp attachments[] entry points at, in both the message.received webhook and the List messages response.

This is an authenticated endpoint, not a public link. Send Authorization: Bearer <your API key> exactly as you would for any other call. Passing the URL straight to a browser, an LLM vision API, or a no-code "download file" step without the header returns 401. This is the most common integration mistake on this endpoint, and it differs from Instagram, Facebook and Telegram, whose attachments[].url is a direct CDN link that needs no header.

Fetch on receipt, not lazily. WhatsApp media lives in Meta's media store, not ours, and it is removed after a limited retention window (currently 7 days, and Meta has been dropping some inbound media sooner). Once Meta drops it the media is unrecoverable and this endpoint answers 400 permanently, so retrying will never succeed. Download and store the bytes when the webhook arrives.

Billing: Read (free unless it says otherwise) · Rate limit: 120/min

get/v1/messaging/whatsapp/media/{mediaId}

Request

  • Base URL: https://apihub.co.il
  • URL: https://apihub.co.il/v1/messaging/whatsapp/media/{mediaId}
  • Auth: HTTP bearer

Path parameters

mediaIdstring required

The media id from attachments[].payload.id.

Query parameters

accountIdstring required

The WhatsApp account that received the media.

Headers

Idempotency-Keystring

Replay-safe: the same execution is returned instead of charging twice

X-Tagstring

Group calls into one job (e.g. one video) — see GET /v1/usage?tag=…

Response

Completed

idstring

Execution id — stable across internal retries; use it with GET /v1/executions/{id}

status'pending' | 'processing' | 'completed' | 'partial' | 'failed' | 'cancelled' | 'timeout'
operationstring
tagstring nullable

Your X-Tag, if sent

created_atstring date-time
completed_atstring date-time nullable
outputobject

Operation result (see each operation). While a Studio render is processing: stage (queued · transcribing · downloading · preparing · cleaning_voice · mixing_audio · rendering · finishing), phase (the engine's: download · prepare · voice · audio · encode · qa · upload, or null), progress (a percent, 0–100) and progress_fraction (0–1), eta_seconds (seconds left, never below 0) and estimate_seconds

errorstring nullable

Changes

No recorded changes to this operation across all 2 revisions of this API.