download_file
Download an attached file from a chat message to local disk and receive its saved path. Safely stores under downloads folder, sanitizing filenames and avoiding duplicates.
Instructions
Download the file attached to one message to local disk and return its path.
Saves under this project's downloads/ folder by default; dest_dir selects a
subdirectory within that downloads/ folder (relative paths, .., and absolute
paths that resolve outside it are rejected). The filename is sanitized and
de-duplicated against existing files in the target directory.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| chat | Yes | ||
| dest_dir | No | ||
| message_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||