Drive Download File
drive_download_fileSave Drive files to the server's disk: stored files are downloaded as-is, while Google Docs, Sheets, Slides and Drawings are exported to PDF, PNG or a chosen format.
Instructions
Save a Drive file to the server's disk: stored files such as PDFs or images are downloaded as they are, and Google Docs, Sheets, Slides and Drawings are exported (PDF by default, PNG for Drawings, or export_mime_type). Calendar event attachments are Drive files, so download them here by their file_id; to read text without saving a file use drive_read_file. Returns status 'ok', file_id, name, mode ('download' or 'export'), mime_type, export_mime_type, saved_to and bytes_written. It writes to the server's filesystem, so it works only when the server runs locally and is rejected with picker_required over remote MCP; Google limits exports to 10 MB.
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_id": "<file_id>",
"output_path": "<output_path>"
},
"name": "drive_download_file"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_id | Yes | Drive file ID: the id field of Drive and search_workspace results, or the long ID in a Drive, Docs, Sheets or Slides URL. | |
| overwrite | No | Replace a file already at output_path; when false the call fails if it exists. | |
| output_path | Yes | Destination file path on the machine running the server, e.g. '/tmp/report.pdf'; missing parent directories are created. Files over the server's MCP_MAX_DOWNLOAD_BYTES limit (250 MiB by default) fail. | |
| export_mime_type | No | Format a Google-native file is exported to, which must suit its type, e.g. 'application/pdf', 'text/plain' or 'application/vnd.openxmlformats-officedocument.wordprocessingml.document' for Docs, 'text/csv' (first sheet only) or 'application/vnd.openxmlformats-officedocument.spreadsheetml.sheet' for Sheets; drive_get_file lists the valid ones as export_formats. Omit for PDF (PNG for Drawings); ignored for stored files, which are saved as they are. | |
| acknowledge_abuse | No | Download a stored file even though Google flagged it as malware or abusive; Google allows this only for the file's owner or an organizer of its shared drive. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| mode | No | ||
| name | No | ||
| status | No | Machine-readable operation status. | |
| file_id | No | ||
| saved_to | No | ||
| mime_type | No | ||
| bytes_written | No | ||
| export_mime_type | No |