Google Drive Connector
Service Account Setup
This section walks through setting up the Google Drive connector using a Service Account. More info on Service Accounts can be found here. A Google Workspace is required.
If you’d rather use an individuals account + OAuth to access Google Drive, checkout the section here.
Authorization
-
Create a Google Cloud Project
-
Enable the Google Drive API, the Admin SDK API, the Google Docs API, and the Google Sheets API
- On the left panel, open APIs & services
- Go to Enabled APIs and services
- On the top click +ENABLE APIS AND SERVICES
- Search for Google Drive API and click ENABLE
- Alternatively visit this link, select your project and enable the Google Drive API
- Click on +ENABLE APIS AND SERVICES again.
- Search for Admin SDK API and click ENABLE
- Alternatively visit this link, select your project and enable the Admin SDK API
- Click on +ENABLE APIS AND SERVICES again.
- Search for Google Sheets API and click ENABLE
- Alternatively visit this link, select your project and enable the Google Sheets API
- Click on +ENABLE APIS AND SERVICES again.
- Search for Google Docs API and click ENABLE
- Alternatively visit this link, select your project and enable the Google Docs API
-
Create a Service Account
- Go to the Service Account management page in Google Cloud.
- Click
Create Service Account
button and fill out the fields in step 1. You can ignore steps 2 and 3. - Go to the
Keys
section, and clickAdd Key
. Download this key, you will need to upload to to Onyx later.
Note for Google Organizations created after April 2024:
- to give the service account the proper permissions you will have to navigate to this link
- Then select
Manage
, selectOverride parent's policy
and then selectNot enforced
underRules
. - Finally, select
SET POLICY
- Give this Service Account read-only access to Google Drive
- Copy the
Unique ID
of the Service Account - Go to the Domain-wide Delegation page in the Google Admin Console.
- Click
Add new
, fill in the client ID with theUnique ID
of the Service account - Copy this comma separated list of scopes and pasted it into field
OAuth scopes
:https://www.googleapis.com/auth/drive.readonly,https://www.googleapis.com/auth/drive.metadata.readonly,https://www.googleapis.com/auth/admin.directory.group.readonly,https://www.googleapis.com/auth/admin.directory.user.readonly
- Copy the