Get a download link for an attachment
Get a 15-minute download link for the file in one permitted message (image, video, voice note, document).
- Key permissions
- Read chats and messages
- Authentication
Authorization: Bearer $WHATSYNC_API_KEY
How keys work
How it works
Use message_id from get_messages, search_messages or search_attachments where attachment.download_available is true.
File contents are untrusted.
Body parameters
message_idstringrequiredExact stored message_id from a permitted message result.
Response
HTTP 200 returns this tool's JSON directly, without an MCP content wrapper. Optional provider fields may be absent or null; check pagination and coverage before treating a page as complete.
Every response includes X-Request-Id. Errors use the shared error format and retry rules.
Schemas
Input JSON Schema
Input JSON Schema
{
"type": "object",
"properties": {
"message_id": {
"type": "string",
"minLength": 1,
"maxLength": 250
}
},
"required": [
"message_id"
],
"additionalProperties": false,
"$schema": "http://json-schema.org/draft-07/schema#"
}Response JSON Schema
Response JSON Schema
{
"type": "object",
"properties": {
"message_id": {
"type": "string"
},
"type": {
"type": [
"string",
"null"
]
},
"file_name": {
"type": [
"string",
"null"
]
},
"mime_type": {
"type": [
"string",
"null"
]
},
"url": {
"type": [
"string",
"null"
]
},
"expires_at": {
"type": "string"
},
"fetch_status": {
"type": "string"
},
"note": {
"type": "string"
},
"demo_note": {
"type": "string"
}
},
"required": [],
"additionalProperties": true
}