Google Drive Integration
Sync files from Google Drive to keep your agent's knowledge base up-to-date automatically
Google Drive Integration#
Connect Google Drive to automatically sync documents into your agent's knowledge base. When files change in Google Drive, your agent's knowledge stays up-to-date.
Connecting Google Drive#
- Go to your agent's dashboard
- Click Sources in the sidebar, then open GDrive
- Click Connect Google Drive
- Sign in with your Google account
- Grant access to view your files
Connection States#
| State | Meaning |
|---|---|
| Not Connected | No Google Drive integration set up yet |
| Connected | Token is valid -- you can browse and link files |
| Broken | Token expired or permissions were lost (you will see a refresh prompt) |
If your connection shows as broken, click the refresh button to re-authorize.
Browsing and Linking Files#
After connecting:
- Click Link Files to open the file browser
- Navigate folders using the breadcrumb navigation ("My Drive" as root)
- Click folders to browse their contents
- Select files using checkboxes
- Click Link Selected
Supported File Types#
- PDF documents
- Word documents (.docx)
- Excel spreadsheets (.xlsx)
- CSV files
- Text files
Lazy Linking#
Files are linked with metadata only at first. The actual content is downloaded and processed when the source is synced, reducing upfront storage requirements.
Excel Sheet Configuration#
For Excel files with multiple sheets:
- Link the Excel file
- Click Configure on the file
- The system auto-analyzes sheets (detects headers, data ranges, columns)
- Select which sheets to include
- Override header row detection per sheet if needed
- Set data ranges (start and end rows) per sheet
- Assign column roles:
- Primary Key: Unique identifiers for exact lookups
- Searchable: Included in search and retrieval
- Filterable: Stored as metadata for filtering
- Ignore: Excluded from indexing
- Choose chunk format: key-value, CSV, or JSON
- Save configuration
Managing Linked Files#
File Status#
| Status | Meaning |
|---|---|
| New | File linked, waiting for first sync |
| Training | Content is being processed for the knowledge base |
| Trained | Content is up-to-date and in the knowledge base |
| Error | Download or processing failed |
| Removed | File was deleted from Google Drive |
| Quota Exceeded | Storage quota reached |
File Actions#
- Search linked files by name
- Sort by name, date, or size
- Bulk select for delete or restore operations
- Preview file contents
Automatic Syncing#
Linked files sync automatically:
- On Sync: Files are re-downloaded when you run the sync/process flow
- Change Detection: AlonChat detects when files are modified in Google Drive
- Manual Sync: Click Sync Now to force a re-download
File metadata (modification time, size) is tracked to detect changes without downloading content every time.
Best Practices#
- Keep files organized in a dedicated folder in Google Drive
- Use descriptive filenames so they are easy to identify in the GDrive list
- Avoid very large files (files over 10MB may take longer to process)
- Check permissions if sync fails -- make sure the file is shared with your Google account
- Configure Excel sheets to include only the columns and sheets that are relevant to your agent
Troubleshooting#
"File not found" error:
- The file may have been deleted or moved in Google Drive
- Check if you still have access to the file
"Permission denied" error:
- Re-authorize the Google Drive connection
- Ensure the file is shared with the Google account you used to connect
"Sync failed" error:
- Try unlinking and re-linking the file
- Check if the file format is supported
Connection shows "Broken":
- Your Google OAuth token has expired
- Click the refresh button to re-authorize
- If the problem persists, disconnect and reconnect Google Drive