get_drive_file_tool
Retrieves the content of a Google Drive file from its URL or file ID, returning structured JSON for Docs/Sheets by default or raw Markdown/CSV when requested.
Instructions
Tool: Get the content of a Google Drive file from its URL
Args: url: The complete Google Drive URL or file ID Examples: - https://docs.google.com/document/d/FILE_ID/edit?usp=sharing - https://drive.google.com/file/d/FILE_ID/view - FILE_ID (direct ID also works) return_json: If True (default), convert Google Docs/Sheets to structured JSON. If False, return raw markdown/csv content.
Returns: String containing the file content (JSON format for Google Workspace files by default)
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": {
"url": "<url>"
},
"name": "get_drive_file_tool"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | ||
| return_json | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |