Send Media
send_mediaUpload a file from a public URL and send it as a message to a chat or direct message. Supports image, video, audio, and file types.
Instructions
Upload a file (image/video/audio/file) from a URL and send it as a message. The tool handles the full two-step upload process automatically: 1) get MAX upload URL, 2) upload file, 3) send message with attachment. Provide either chat_id or user_id.
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_url": "<file_url>",
"type": "<type>"
},
"name": "send_media"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chat_id | No | Group chat or channel ID | |
| user_id | No | User ID for direct message | |
| file_url | Yes | Public URL of the file to upload and send | |
| type | Yes | Type of media: image, video, audio, or file | |
| text | No | Optional text caption for the media | |
| format | No | Text formatting for caption |