Skip to main content

Google Drive setup

Connecting Google Drive requires one authorization step. Completing setup allows the following functionality.

  • Read and write tools. Glean and Glean agents can search Drive, read and download files, and create files, docs, and sheets. Every tool runs with a user's Google authorization and Drive permissions.
  • Permission-aware search. Turn on data indexing and Glean builds a search index of your Drive content. Glean mirrors Drive access controls through domain-wide delegation and enforces them at query time. Each user sees only the files they can open in Drive.
  1. Connect and authorizetodaycurrent step
  2. Use read and write toolstodaycurrent step
  3. Indexing runs in the backgroundtodayhappens automatically
  4. Permission-aware search switches ontomorrowhappens automatically

Feature availability after setup

Read and write tools are available upon connecting. Search switches on once you begin indexing and the first crawl completes.

CapabilityWhen it becomes availableWhose permissions apply
Read and write toolsImmediately after you connectEach user's own Google permissions, through their own Google authorization
Permission-aware searchOnce you begin indexing and the first crawl completesDrive access controls, mirrored through domain-wide delegation and enforced at query time

Indexing is optional at setup. You can begin it right away or skip it and start later from the connector page.

Connector setup

Prerequisites

Confirm the following before you begin.

RequirementWhy it is needed
A Glean admin who can add and configure connectorsAdds the Google Drive connector and authorizes it in the Admin console
A Google Super Admin, or a user with the required custom admin roleAuthorizes the MCP connection and, for indexing, sets up domain-wide delegation

Step 1. Connect

In the Glean Admin console, go to Connectors and add the Google Drive connector. This step authorizes Google Drive's tools.

  1. Enter a Name for the connector. This is the name your organization members see.

  2. Under Select an authorization method, pick one option.

    • Central (recommended). Use Glean's managed OAuth app, which needs no configuration.
    • Custom. Use your own Google OAuth app. You provide a Client ID and Client secret.

    See Google tools setup for the full instructions.

  3. Select Continue. You return to Glean to set up indexing.

Step 2. Set up indexing

To add permission-aware search, set up data indexing.

  • Directory admin email. Enter a Google Super Admin, or a user with a custom admin role that has the required privileges. Glean impersonates this identity through domain-wide delegation.
  • Domain-wide delegation and scopes. Add Glean's client ID and the required OAuth scopes in the Google Admin console.
  • Additional domains. Retrieve domains from your Google Workspace account, or enter them manually.
  • Google Group mappings. Upload a CSV that maps target audience IDs to Google Groups.
  • Drive labels. Leave this on to crawl Drive labels for filters and facets, or turn it off.

Step 3. Review access and begin indexing

Review who can use the connector and any data access rules, then finish setup.

  • User access. Make the connector available to all users, or to a test group only.
  • Data access. Set inclusion, exclusion, and additional rules for what Glean indexes.
  • Select Begin indexing to start the crawl, or Skip for now to defer it and start later from the connector page.

Manage tools

Connecting Google Drive makes its tools available. You can see all available tools on the Tools tab of your connector and edit permissions through Advanced settings.

Tool settings you can change afterwards

For the full guide, see Tools overview.

Per-user authorization

Setup authorizes Glean to Google Drive at the connector level. From there, two identities decide what each person sees.

CapabilityRuns asWhat it enforces
Indexed searchThe Glean service account, through domain-wide delegationDrive access controls, mirrored into the index and enforced at query time
Read and write toolsEach user's own Google accountThat user's own Drive permissions, checked by Google on every call

Each teammate authorizes their own Google account over OAuth the first time they use a tool. Indexed search needs no action from end users once the crawl completes.

After setup

  • Broaden coverage by adding Google Workspace domains.
  • Refine what is indexed with inclusion, exclusion, and restriction rules, and Drive labels.
  • Check progress any time from the Google Drive connector page in the Admin console.

See also