get_drive_file_download_url
Generate secure download URLs for Google Drive files, converting Google Docs, Sheets, and Slides to PDF, DOCX, XLSX, CSV, or PPTX formats for safe access.
Instructions
Gets a download URL for a Google Drive file. The file is prepared and made available via HTTP URL.
For Google native files (Docs, Sheets, Slides), exports to a useful format: • Google Docs → PDF (default) or DOCX if export_format='docx' • Google Sheets → XLSX (default) or CSV if export_format='csv' • Google Slides → PDF (default) or PPTX if export_format='pptx'
For other files, downloads the original file format.
Args: user_google_email: The user's Google email address. Required. file_id: The Google Drive file ID to get a download URL for. export_format: Optional export format for Google native files. Options: 'pdf', 'docx', 'xlsx', 'csv', 'pptx'. If not specified, uses sensible defaults (PDF for Docs/Slides, XLSX for Sheets).
Returns: str: Download URL and file metadata. The file is available at the URL for 1 hour.
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": {
"user_google_email": "<user_google_email>",
"file_id": "<file_id>"
},
"name": "get_drive_file_download_url"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| user_google_email | Yes | ||
| file_id | Yes | ||
| export_format | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |