get_drive_file_download_url
Download any Google Drive file to your local machine. Returns a local file path or temporary URL, and exports Docs, Sheets, and Slides to PDF, DOCX, XLSX, CSV, or PPTX.
Instructions
Downloads a Google Drive file and saves it to local disk.
In stdio mode, returns the local file path for direct access. In HTTP mode, returns a temporary download URL (valid for 1 hour).
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), PDF if export_format='pdf', 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 download. 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). For Sheets: supports 'csv', 'pdf', or 'xlsx' (default).
Returns: str: File metadata with either a local file path or download URL.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| file_id | Yes | ||
| export_format | No | ||
| user_google_email | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |