Required Scopes
To configure a Sync for Google Drive, you need to request the following scopes from your Google OAuth application:https://www.googleapis.com/auth/drive.readonly
https://www.googleapis.com/auth/admin.reports.audit.readonly
(optional - for ingesting Permissions Sync link sharing access)
Synced Objects
Google Drive supports the following Synced Objects:Files
Sync Configuration Options
Example
A Google Drive Folder ID to limit the Sync scope to. If not specified, the Sync will ingest all available files.
Choosing Files and Folders
You can allow your user to select files from their Google Drive account in your app with the Google Drive File Picker provided by the Paragon SDK.
- In your Google Cloud Console dashboard, navigate to APIs & Services > Library in the sidebar for your app.
- Search for “Google Picker API” from the API Library.
- Select the “Google Picker API” and press the blue “Enable” button to enable the API for your application.

- Navigate to Google Cloud Console > APIs & Services > Credentials. Make sure the selected project in the header is your app.
- Click Create Credentials and select API key.
- An API key value will appear. Copy this value to use in Showing the File Picker.

- Application restrictions: Websites with your origin/domain
- API restrictions: Google Drive API
Showing the File Picker
You can allow your user to select files from their Google Drive account in your app with the Google Drive File Picker provided by the Paragon SDK.
- In your Google Cloud Console dashboard, navigate to APIs & Services > Library in the sidebar for your app.
- Search for “Google Picker API” from the API Library.
- Select the “Google Picker API” and press the blue “Enable” button to enable the API for your application.

- Navigate to Google Cloud Console > APIs & Services > Credentials. Make sure the selected project in the header is your app.
- Click Create Credentials and select API key.
- An API key value will appear. Copy this value to use in Showing the File Picker.

- Application restrictions: Websites with your origin/domain
- API restrictions: Google Drive API
Showing the File Picker
Use the Paragon SDK in your frontend application to show the File Picker in your app. The SDK provides anExternalFilePicker
class to load Google’s JavaScript into your page and authenticate with your user’s connected Google Drive account.
To initialize the picker you will need your Google Drive API key and your Google Cloud project number. The Google Cloud project number is a unique, numerical identifier for your project. You can find it within the Google Cloud Console from the sidebar navigation under IAM & Admin section > Settings.