upload_media
Upload media files to WhatsApp and receive a media ID for use in message sends. Supports images, videos, audio, documents, and stickers within their size limits.
Instructions
Upload a media file to WhatsApp. Returns a media ID that can be used in messages. Supported: image (5MB), video (16MB), audio (16MB), document (100MB), sticker (500KB).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"file_path": "<file_path>",
"mime_type": "<mime_type>",
"file_name": "<file_name>"
},
"name": "upload_media"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_name | Yes | File name with extension (e.g. "photo.jpg") | |
| file_path | Yes | Absolute path to the file to upload | |
| mime_type | Yes | MIME type of the file (e.g. "image/jpeg", "video/mp4", "application/pdf", "audio/ogg") |