Google Drive

Google Drive

By gdrive GitHub

File access and search capabilities for Google Drive

gdrive file-access
Overview

what is Google Drive?

Google Drive is a server integration tool that enables users to access, list, read, and search over files stored in Google Drive.

how to use Google Drive?

To use Google Drive, set up a Google Cloud project, enable the Google Drive API, and configure OAuth to authenticate your application. Once set up, you can search for files using specific queries.

key features of Google Drive?

  • Search functionality for finding files in Google Drive using queries.
  • Ability to access and read various file types, including Google Workspace files converted into different formats (e.g., Docs to Markdown, Sheets to CSV).
  • Supported authentication flow for secure file access.

use cases of Google Drive?

  1. Quickly finding specific documents among a large collection of files.
  2. Accessing various file formats seamlessly through a single integration point.
  3. Building applications that require file handling capabilities powered by Google Drive data.

FAQ from Google Drive?

  • What types of files can I access with Google Drive?

You can access any file type supported by Google Drive, including Google Workspace files and others in their native formats.

  • Do I need to create a Google Cloud project to use this?

Yes, a Google Cloud project must be created, and the Google Drive API needs to be enabled.

  • Is there a cost associated with using Google Drive API?

The Google Drive API can be used within the free tier of Google Cloud services, but usage limits apply.

Content

# Google Drive server

This MCP server integrates with Google Drive to allow listing, reading, and searching over files.

Components

Tools

  • **search**
    • Search for files in Google Drive
    • Input: `query` (string): Search query
    • Returns file names and MIME types of matching files

Resources

The server provides access to Google Drive files:

  • **Files** (`gdrive:///<file_id>`)
    • Supports all file types
    • Google Workspace files are automatically exported:
      • Docs → Markdown
      • Sheets → CSV
      • Presentations → Plain text
      • Drawings → PNG
    • Other files are provided in their native format

Getting started

  1. [Create a new Google Cloud project](https://console.cloud.google.com/projectcreate)
  2. [Enable the Google Drive API](https://console.cloud.google.com/workspace-api/products)
  3. [Configure an OAuth consent screen](https://console.cloud.google.com/apis/credentials/consent) ("internal" is fine for testing)
  4. Add OAuth scope `https://www.googleapis.com/auth/drive.readonly\`
  5. [Create an OAuth Client ID](https://console.cloud.google.com/apis/credentials/oauthclient) for application type "Desktop App"
  6. Download the JSON file of your client's OAuth keys
  7. Rename the key file to `gcp-oauth.keys.json` and place into the root of this repo (i.e. `servers/gcp-oauth.keys.json`)

Make sure to build the server with either `npm run build` or `npm run watch`.

Authentication

To authenticate and save credentials:

  1. Run the server with the `auth` argument: `node ./dist auth`
  2. This will open an authentication flow in your system browser
  3. Complete the authentication process
  4. Credentials will be saved in the root of this repo (i.e. `servers/.gdrive-server-credentials.json`)

Usage with Desktop App

To integrate this server with the desktop app, add the following to your app's server configuration:

```json { "mcpServers": { "gdrive": { "command": "npx", "args": [ "-y", "@modelcontextprotocol/server-gdrive" ] } } } ```

License

This MCP server is licensed under the MIT License. This means you are free to use, modify, and distribute the software, subject to the terms and conditions of the MIT License. For more details, please see the LICENSE file in the project repository.

No tools information available.

Efficient implementation of the Google Drive MCP server

gdrive mcp
View Details

Mirror of

gdrive mcp-server
View Details
Google Drive server
Google Drive server by tonioshikanlu

Google Drive MCP server for integrating with Google Drive to allow listing, reading, and searching over files.

gdrive google-drive
View Details