Skip to Content

Google Drive

Google Drive
Arcade Optimized

Description: Enable agents to interact with Google Drive

Author: Arcade

Auth: User authorization

PyPI VersionLicensePython VersionsWheel StatusDownloads

The Google Drive MCP Server provides a set of tools for interacting with Google Drive, enabling users to efficiently manage and access their files. With this MCP Server, users can:

  • Retrieve the file and folder structure of their Google Drive
  • Search for specific files within Google Drive
  • Create, rename, and move files and folders
  • Download and upload files
  • Share files with other users
  • Generate a Google File Picker URL for user-driven file selection and authorization

Available Tools

Tool NameDescription
GoogleDrive.WhoAmIGet comprehensive user profile and Google Drive environment information.
GoogleDrive.GetFileTreeStructureGet the file/folder tree structure of the user's Google Drive.
GoogleDrive.GenerateGoogleFilePickerUrlGenerate a Google File Picker URL for user-driven file selection and authorization.
GoogleDrive.SearchFilesSearch for files in Google Drive.
GoogleDrive.CreateFolderCreate a new folder in Google Drive.
GoogleDrive.RenameFileRename a file or folder in Google Drive.
GoogleDrive.MoveFileMove a file or folder to a different folder.
GoogleDrive.DownloadFileDownload a file from Google Drive.
GoogleDrive.DownloadFileChunkDownload a specific byte range of a file (for large files).
GoogleDrive.UploadFileUpload a file to Google Drive from a URL.
GoogleDrive.ShareFileShare a file or folder with specific people.

If you need to perform an action that’s not listed here, you can get in touch with us to request a new tool, or create your own tools.

GoogleDrive.WhoAmI


Get comprehensive user profile and Google Drive environment information. This tool provides detailed information about the authenticated user including their name, email, profile picture, Google Drive storage information, and the shared drives (and their IDs) the user has access to.

Parameters

This tool does not take any parameters.


GoogleDrive.GetFileTreeStructure


Get the file/folder tree structure of the user’s Google Drive. This operation can be inefficient for large drives, so use with caution.

Parameters

  • include_shared_drives (boolean, optional): Whether to include shared drives in the file tree structure. Defaults to False.
  • restrict_to_shared_drive_id (string, optional): If provided, only include files from this shared drive in the file tree structure. Defaults to None, which will include files and folders from all drives.
  • include_organization_domain_documents (boolean, optional): Whether to include documents from the organization’s domain. This is applicable to admin users who have permissions to view organization-wide documents in a Google Workspace account. Defaults to False.
  • order_by (Enum OrderBy, optional): Sort order. Defaults to listing the most recently modified documents first.
  • limit (integer, optional): The number of files and folders to list. Defaults to None, which will list all files and folders.

GoogleDrive.GenerateGoogleFilePickerUrl


Generate a Google File Picker URL for user-driven file selection and authorization. This tool generates a URL that directs the end-user to a Google File Picker interface where they can select or upload Google Drive files. Users can grant permission to access their Drive files, providing a secure and authorized way to interact with their files.

This is particularly useful when prior tools encountered failures due to file non-existence or permission errors. Once the user completes the file picker flow, the prior tool can be retried.

Parameters

This tool does not take any parameters.


GoogleDrive.SearchFiles


Search for files in Google Drive. The provided query should only contain the search terms; the tool will construct the full search query for you.

Parameters

  • query (string, required): The search query to find files in Google Drive. Will search for filenames and file contents that match the provided query.
  • folder_path_or_id (string, optional): Search only within this specific folder. Provide either a path like folder/subfolder or a folder ID. If None, searches across all accessible locations. Defaults to None.
  • shared_drive_id (string, optional): If provided, search only within this shared drive. Defaults to None (searches My Drive and optionally all shared drives).
  • include_shared_drives (boolean, optional): If True and shared_drive_id is not set, include all shared drives in search. Defaults to False (My Drive only).
  • include_organization_domain_documents (boolean, optional): Whether to include documents from the organization’s domain. This is applicable to admin users who have permissions to view organization-wide documents in a Google Workspace account. Defaults to False.
  • order_by (Enum OrderBy, optional): Sort order for search results. Defaults to listing the most recently modified documents first. If the query contains fullText, then the order_by will be ignored.
  • limit (integer, optional): The maximum number of search results to return. Defaults to 50.
  • file_types (Enum GoogleDriveFileType, optional): Filter by specific file types. Defaults to None, which includes all file types.

GoogleDrive.CreateFolder


Create a new folder in Google Drive. By default, parent folder paths are resolved in My Drive. For shared drives, use folder IDs or provide shared_drive_id.

Parameters

  • folder_name (string, required): The name of the new folder to create.
  • parent_folder_path_or_id (string, optional): The parent folder path like folder/subfolder or folder ID where to create. If None, creates at the root of My Drive. If providing a path, it will be resolved within My Drive by default. Do not include the folder to create in this path. Defaults to None.
  • shared_drive_id (string, optional): If creating in a shared drive and using a parent folder path, provide the shared drive ID. Not needed when using folder IDs or creating in My Drive. Defaults to None.

GoogleDrive.RenameFile


Rename a file or folder in Google Drive. By default, paths are resolved in My Drive. For files in shared drives, either use the file ID directly or provide the shared_drive_id parameter.

Parameters

  • file_path_or_id (string, required): The path like folder/subfolder/filename or the file ID to rename. If providing a path, it will be resolved within My Drive by default.
  • new_filename (string, required): The new name for the file.
  • shared_drive_id (string, optional): If the file is in a shared drive and you’re using a path (not ID), provide the shared drive ID to resolve the path within that drive. Not needed when using file IDs. Defaults to None (searches My Drive).

GoogleDrive.MoveFile


Move a file or folder to a different folder within the same Google Drive. Can move to a folder (keeping name), or move and rename in one operation. By default, paths are resolved in My Drive. For shared drives, use file IDs or provide shared_drive_id.

Parameters

  • source_file_path_or_id (string, required): The source file path like folder/subfolder/filename or the file ID of the file to move. If providing a path, it will be resolved within My Drive by default.
  • destination_folder_path_or_id (string, required): The path to the file’s parent folder (exclude the file to be moved) or parent folder ID to move the file into.
  • new_filename (string, optional): Optional new name for the file after moving. If None, keeps the original name. Defaults to None.
  • shared_drive_id (string, optional): If working with paths in a shared drive, provide the shared drive ID. Not needed when using IDs. Defaults to None (uses My Drive).

GoogleDrive.DownloadFile


DO NOT feed this tool’s response to a language model. The response is too large. Instead, let the language model select this tool, and then directly execute the tool, decode its response, and then save the contents to a local file.

This tool is intended to be used in conjunction with DownloadFileChunk.

Download a blob file (non-workspace file) from Google Drive as base64 encoded content. For small files (under ~5MB raw), returns the file content directly in the response as base64. For large files, returns metadata with requires_chunked_download=True - use DownloadFileChunk to retrieve the file in parts.

Parameters

  • file_path_or_id (string, required): The file path like folder/subfolder/filename or the file ID of the file to download. Folders NOT supported. If providing a path, it will be resolved within My Drive by default.
  • shared_drive_id (string, optional): If the file is in a shared drive and using a path, provide the shared drive ID. Not needed when using file IDs. Defaults to None (uses My Drive).

GoogleDrive.DownloadFileChunk


DO NOT feed this tool’s response to a language model. The response is too large. Instead, let the language model select this tool, and then directly execute the tool, decode its response, and then save the contents to a local file.

This tool is intended to be used in conjunction with DownloadFile.

Download a specific byte range of a file from Google Drive. Use this for large files that require chunked download (when DownloadFile returns requires_chunked_download=True). Call repeatedly with increasing start_byte values to retrieve the complete file.

Returns the chunk content as base64, along with progress information including whether this is the final chunk.

Parameters

  • file_path_or_id (string, required): The file path like folder/subfolder/filename or the file ID to download a chunk from. If providing a path, it will be resolved within My Drive by default.
  • start_byte (integer, required): The starting byte position for this chunk (0-indexed).
  • chunk_size (integer, optional): The size of the chunk to download in bytes. Max 5MB (5242880). Defaults to 5MB (5242880).
  • shared_drive_id (string, optional): If the file is in a shared drive and using a path, provide the shared drive ID. Not needed when using file IDs. Defaults to None (uses My Drive).

GoogleDrive.UploadFile


Upload a file to Google Drive from a URL. Fetches the file content from the provided URL and uploads it to Google Drive. Supports files of any size - uses resumable upload internally for large files.

This tool cannot upload Google Workspace files (Google Docs, Sheets, Slides). Only regular files are supported.

Parameters

  • file_name (string, required): The name for the uploaded file.
  • source_url (string, required): The public download URL to fetch the file content from. The tool will download from this URL and upload to Google Drive.
  • mime_type (Enum UploadMimeType, optional): The file type. If not provided, will be inferred from the URL or Content-Type header. Supported: text (txt, csv, json, html, md), pdf, images (png, jpeg, gif). Defaults to None (auto-detect).
  • destination_folder_path_or_id (string, optional): The folder path like folder/subfolder or folder ID where to upload. If None, uploads to the root of My Drive. If providing a path, it will be resolved within My Drive by default. Defaults to None.
  • shared_drive_id (string, optional): If uploading to a folder in a shared drive using a path, provide the shared drive ID. Not needed when using folder IDs or uploading to My Drive. Defaults to None (My Drive).

GoogleDrive.ShareFile


Share a file or folder in Google Drive with specific people by granting them permissions. If a user already has permission on the file, their role will be updated to the new role. By default, paths are resolved in My Drive. For shared drives, use file IDs or provide shared_drive_id.

Parameters

  • file_path_or_id (string, required): The file path like folder/subfolder/filename or the file ID to share. If providing a path, it will be resolved within My Drive by default.
  • email_addresses (list[string], required): List of email addresses like user@domain.com to share with.
  • role (Enum PermissionRole, optional): The permission role to grant. Defaults to reader (view-only).
  • send_notification_email (boolean, optional): Whether to send an email notification to the recipients. Defaults to True.
  • message (string, optional): Optional message to include in the notification email. Defaults to None.
  • shared_drive_id (string, optional): If the file is in a shared drive and using a path, provide the shared drive ID. Not needed when using file IDs. Defaults to None (uses My Drive).

Auth

The Arcade Google Drive MCP Server uses the Google auth provider to connect to users’ Google Drive accounts. Please refer to the Google auth provider documentation to learn how to configure auth.

Last updated on

Google Drive | Arcade Docs