Google Drive Connector
Overviewโ
The Google Drive Connector is a versatile tool designed to facilitate seamless access to your Google Drive files and folders. With just a few inputs, this connector allows you to quickly retrieve, organize, and manage your Google Drive content. Whether you're dealing with documents, spreadsheets, presentations, or any other file type, the Google Drive Connector ensures you have easy and structured access to your file contents in our products ACE Search and Chat.
Table of Contentsโ
- Google Drive Connector
Setup Processโ
Set Up the Service Accountโ
- Go to the Google Cloud Console
- Create a new project or select an existing project
- Navigate to IAM & Admin > Service accounts
- Click Create Service Account and follow the prompts
- Grant the service account the Editor role
- Create a key for the service account and download the JSON key file
- Enable the Google Drive API from APIs and Services
Share the Google Drive Folder with the Service Account Emailโ
- Go to your Google Drive
- Right-click the folder you want to access and select Share
- Share the folder with the service account email address (something like
your-service-account@your-project.iam.gserviceaccount.com
) - Set the permission level to "Editor" or "Viewer" depending on your needs
Configuring the Connectorโ
Upload the JSON credentials file
- This is the file you downloaded when creating the service account key
- The file contains authentication information required to access Google Drive
Write the folder name
- Enter the exact name of the folder you shared with the service account
- Make sure the spelling and capitalization match exactly
- For example:
Project Documents
Working with Nested Foldersโ
The connector can access files within nested folder structures using two approaches:
Option 1: Use Path Notationโ
Create a single connector with a path to the specific nested folder:
- Format:
ParentFolder/ChildFolder
- Example:
Project Documents/Research Data
Option 2: Create Multiple Connectorsโ
Create separate connector configurations for different nested folders:
- Create one connector for
Test/folder1
- Create another connector for
Test/folder2
Important Notes on Nested Folders:โ
- The service account must have access to all parent folders in the path
- For deep nesting, it's often clearer to create separate connector configurations
- Each folder path should be specific to avoid retrieving unnecessary files
Supported File Typesโ
The Google Drive Connector supports the following file formats:
- PDF Documents (.pdf)
- Extracts text content from PDF files
- Handles multi-page documents
- Word Documents (.docx)
- Extracts formatted text and content
- Preserves document structure
- PowerPoint Presentations (.pptx)
- Extracts slide content
- Captures text from slides and notes
- Text Files (.txt)
- Processes plain text documents
- Preserves line breaks and basic formatting
- Excel Spreadsheets (.xlsx)
- Extracts data from cells
- Processes multiple sheets
Best Practicesโ
- Organize Your Folders
- Use a clear folder structure in Google Drive
- Avoid sharing the root of your Drive to prevent retrieving unnecessary files
- Service Account Security
- Store your service account credentials securely
- Use a dedicated service account for this connector
- Only share the specific folders needed for your use case
- File Naming
- Use descriptive file names to make search results more meaningful
- Avoid special characters in file names
- Permissions Management
- Regularly review which folders are shared with the service account
- Remove access when no longer needed
- Storage Optimization
- Periodically review and clean up files in connected folders
- Archive older files to maintain performance
Troubleshootingโ
Issue | Solution |
---|---|
"Access denied" error | Verify the folder is shared with the service account email |
Files not appearing | Check file types are supported and permissions are correct |
Authentication failure | Ensure the JSON credentials file is valid and not expired |
"Folder not found" error | Confirm the folder name is spelled exactly as it appears in Google Drive |
Slow performance | Reduce the number of files in the shared folder |
Advanced Configurationโ
Scheduled Updatesโ
You can configure the connector to regularly update its data:
- Enable the "Recurring" option
- Select update frequency:
- Hourly: For frequently changing documents
- Daily: For regular working documents
- Weekly: For archival or reference materials
- Specify the interval (e.g., every 12 hours, every 3 days)
Custom Filteringโ
To limit which files are processed:
- Use folder organization in Google Drive to separate files
- Create multiple connector configurations with specific folder paths
- Use the Knowledge Set feature to group related connector outputs
FAQโ
Q: Can I connect multiple Google Drive accounts?
A: Yes, create separate service accounts and connector configurations for each Google Drive account.
Q: How are file updates handled?
A: When the connector runs (manually or on schedule), it will detect and process updated files.
Q: Is there a limit to how many files can be processed?
A: While there's no hard limit, performance may decrease with very large collections (1000+ files).
Q: Can I connect to Google Workspace shared drives?
A: Yes, share the appropriate shared drive folders with your service account.
Q: Does the connector maintain file versions?
A: No, only the current version of each file is processed.