Files
google-mcp/gdrive/drive_tools.py
Yair Weinberger 12e2be0807 feat: Add support for file:// URLs in create_drive_file
Added ability to upload local files to Google Drive using file:// URL scheme
in the create_drive_file tool. This enables uploading files from /tmp and
other local paths without requiring HTTP/HTTPS hosting.

Changes:
- Added urllib.parse.urlparse and pathlib.Path imports
- Detect file:// URLs and read directly from local filesystem
- Validate file exists before attempting upload
- Updated docstring to reflect support for file://, http://, and https://
- Added error handling for unsupported URL schemes

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude <noreply@anthropic.com>
2025-11-09 17:12:26 +00:00

25 KiB