> For clean Markdown of any page, append .md to the page URL.
> For a complete documentation index, see https://docs.tropicalia.dev/llms.txt.
> For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.tropicalia.dev/_mcp/server.

# Google Drive

> Google Drive integration with Tropicalia

This connector enables AI agents and RAG systems to retrieve context from Google Drive through Tropicalia's unified search layer.

## Configuration

Google Drive source connector integrates with the Google Drive API to extract files.

Supports both personal Google Drive (My Drive) and shared drives.

It supports downloading and processing files
while maintaining proper organization and access permissions.

### Authentication

This connector uses **OAuth 2.0 with custom credentials**. You need to provide your OAuth application's Client ID and Client Secret, then complete the OAuth consent flow.

#### OAuth Setup Required

1. Create an OAuth application in your provider's developer console
2. Enter your Client ID and Client Secret when configuring the connection
3. Complete the OAuth consent flow

## Integrate with Google APIs

This guide will walk you through connecting Google Workspace APIs to Tropicalia.
Google provides extensive [documentation](https://developers.google.com/workspace/guides/get-started) on setting up your workspace.
Below is a streamlined process for connecting Google APIs to Tropicalia.

1. [Create a Google Cloud project](https://developers.google.com/workspace/guides/create-project) for your Google Workspace (if you don't already have one)
2. [Enable the Google Drive API](https://developers.google.com/workspace/guides/enable-apis)
3. [Configure Google OAuth 2.0 consent screen](https://developers.google.com/workspace/guides/configure-oauth-consent)
4. Under `Audience`, select `Make external` and add test users
5. Under `Data Access`, add the following scopes:

```
https://www.googleapis.com/auth/drive.photos.readonly
https://www.googleapis.com/auth/drive
https://www.googleapis.com/auth/drive.readonly
https://www.googleapis.com/auth/drive.metadata
https://www.googleapis.com/auth/drive.metadata.readonly
```

6. [Create OAuth client ID credentials](https://developers.google.com/workspace/guides/create-credentials#oauth-client-id)
7. Under "Authorized JavaScript origins," click "+ Add URI" and add:
   ```
   https://app.tropicalia.dev
   ```
8. Under "Authorized redirect URIs," click "+ Add URI" and add the Redirect URI. Use the URL below:
   ```
   https://api.tropicalia.dev/v1/source-connections/callback
   ```
9. Locate the client ID and client secret from your newly created OAuth client. Add these credentials to the Google Drive connector page at [Connectors](https://app.tropicalia.dev/credentials).