Save an attachment
save_attachmentExtract a photo, voice message, or document from a WhatsApp export and save it to a folder under the chat's own filename, returning the saved path.
Instructions
Copy one file out of the export (a photo, a voice message .opus, a document) into a folder, by the name the chat uses for it. Returns the saved path.
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": {
"path": "<path>",
"name": "<name>",
"output_dir": "<output_dir>"
},
"name": "save_attachment"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| name | Yes | File name as listed by list_attachments | |
| path | Yes | Path to the WhatsApp export: the .zip from Export chat, or the .txt | |
| output_dir | Yes | Folder to save into; created if missing |