GET
Get Media
Download media by storage path or by chat_id + message_id.
API endpoint
https://waclient.com/api/get_mediaExample:
curl -X GET \
'https://waclient.com/api/get_media' \
-G \
--data-urlencode 'path=6A4B02A1XXXX/media/1750000000000_image.jpg' \
--data-urlencode 'instance_id=6A4B02A1XXXX' \
--data-urlencode 'access_token=EMCUH3NQQK8YXXXX'Response
{
"status": "success",
"message": "Success",
"data": {
"path": "6A4B02A1XXXX/media/1750000000000_image.jpg",
"url": "https://storage.waclient.com/6A4B02A1XXXX/media/1750000000000_image.jpg",
"mime_type": "image/jpeg"
}
}| Parameter | Description |
|---|---|
| path | Relative storage path (instance_id/media/...) |
| chat_id | Alternative: download from a message (with message_id) (Optional) |
| message_id | Used with chat_id (Optional) |
| as_json | Return base64 JSON instead of binary (Optional) |
| instance_id | Your instance ID |
| access_token | Your access token |