drive_download
Download non-Google-native Drive files such as PDF, XLSX, TXT, or images; text files return in 50,000-character windows, and binary files save to a local path.
Instructions
Download the content of a non-Google-native Drive file.
Uses user credentials. Works for uploaded files such as PDF, xlsx, txt or
images, up to 10 MB. Text files come back 50,000 characters at a time; a
note at the end gives the offset of the next window. Anything else is
saved to a local file, and the result gives its path; open that file to
read it.
For Google Docs, Sheets and Slides use docs_export instead.
Args: file_id: The Drive file id. offset: Character offset to start the text from. Ignored for binary files.
Returns:
The file content as text, or for binary files a JSON object
{path, name, mimeType, bytes} describing the saved file.
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>"
},
"name": "drive_download"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| offset | No | ||
| file_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |