send_media
Send an image, video, document, or audio file (via public URL or base64) with an optional caption to a WhatsApp chat or group.
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": {
"toNumber": "<toNumber>",
"type": "<type>"
},
"name": "send_media"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Public HTTP/HTTPS URL of the media file to send | |
| type | Yes | Media type: 'image', 'video', 'document', or 'audio' | |
| base64 | No | Base64 encoded media data (with or without data URL prefix) | |
| caption | No | Optional caption text for the media | |
| filename | No | Filename for the media. Auto-generated from MIME type if not provided | |
| mimeType | No | Media MIME type (e.g., 'image/jpeg', 'video/mp4', 'application/pdf'). Auto-detected from data URL if not provided | |
| toNumber | Yes | Recipient's WhatsApp ID |