Google Workspace
Google Workspace
Scan Google Drive files, Docs, Sheets, and Slides across My Drive and shared drives.
- Category
- Collaboration
- Source type
- GOOGLE_WORKSPACE
- Produces
- fileimagedrive
Google Drive is where the working documents live — the spreadsheets, the exported reports, the shared folder someone made public in 2019 and forgot.
What you need to connect
Two ways in:
| Method | What you supply | Use it when |
|---|---|---|
| Service account | The service account JSON, plus the user to impersonate | Scanning on behalf of the organisation, with domain-wide delegation |
| OAuth | Client ID, client secret and a refresh token | Scanning one account’s own Drive |
The read-only Drive scope is enough. For domain-wide delegation, authorise the service account’s client ID against that scope in the Admin console.
What Classifyre reads
My Drive, shared drives, or both — narrowed to specific drive IDs, to folders, and by file extension.
Google-native files (Docs, Sheets, Slides) have no downloadable bytes of their own, so they’re exported to Office formats before being read — meaning your actual documents are scanned, not just their titles.
Optionally, sharing permissions are captured too, which turns “this document has customer data in it” into “this document has customer data and is shared with anyone who has the link”.
Files in Drive are read with the shared file pipeline: see Supported File Formats for everything it can open, and OCR & Transcription for reading text out of images, audio and video.
Metadata on every asset
Asset kind · file
| Field | Type | Always present | What it is |
|---|---|---|---|
| size_bytes | integer | Yes | Raw byte size of the content |
| mime_type | string | Yes | Resolved MIME type |
| parse_error | string | No | Set when content extraction failed |
| image_width | integer | No | Width in pixels |
| image_height | integer | No | Height in pixels |
| page_count | integer | No | Number of pages (pdf) |
| paragraph_count | integer | No | Number of paragraphs (docx) |
| table_count | integer | No | Number of tables (docx) |
| row_count | integer | No | Number of data rows |
| columns | object[] | No | Columns as {name, type} objects (type may be empty for csv/xlsx) |
| encoding | string | No | Detected character encoding |
| json_root_type | string | No | Root JSON type: object, array, or scalar |
| top_level_keys | integer | No | Number of top-level keys when the root is an object |
| array_length | integer | No | Length when the root is an array |
| drive_name | string | Yes | Shared drive or 'My Drive' display name |
| item_path | string | Yes | Best-effort path within the drive (folder names joined by '/') |
| web_url | string | No | Browser-accessible URL for the item (webViewLink) |
| md5_checksum | string | No | Drive-reported MD5 checksum of the file content (binary files only) |
| owner | string | No | Display name or email of the file owner |
| permissions | string[] | No | Sharing permissions on the item: list of {role, grantee_type, grantee} entries (requires include_permissions) |
| google_mime_type | string | No | Original Drive mimeType for Google-native files (e.g. application/vnd.google-apps.document) |
| exported_as | string | No | Export MIME type used to download a Google-native file, if applicable |
Asset kind · image
| Field | Type | Always present | What it is |
|---|---|---|---|
| size_bytes | integer | Yes | Raw byte size of the content |
| mime_type | string | Yes | Resolved MIME type |
| parse_error | string | No | Set when content extraction failed |
| source_hash | string | Yes | Hash of the parent file asset |
| location | string | Yes | Location of the embedded image within the parent |
Asset kind · drive
| Field | Type | Always present | What it is |
|---|---|---|---|
| drive_id | string | Yes | Google Drive ID (shared drive ID, or a synthetic ID for My Drive) |
| drive_name | string | Yes | Drive display name |
| drive_type | string | No | Drive type (my_drive or shared_drive) |
Lineage
Lineage
This source records no lineage. Nothing in the system it reads describes data moving from one place to another, so no FLOW edges are produced. Related items are still linked — see Lineage & Relationships for what those links mean and how they differ from lineage.
Worth knowing
- Domain-wide delegation is powerful. The delegated user determines what the scan can see; pick that account deliberately.
- Shared drives are usually the priority — they’re where cross-team data accumulates without a clear owner.
Configuration
Beyond the fields below, every source also has the settings shared by all of them: the sampling strategy, the detectors to run, the scan schedule, and the compute limits for its scan jobs.
Required
Without these, the source will not save.
This section depends on which authentication method you pick — one of the following applies.
Google Workspace Service Account
| Field | Type | Required | What it does | Default |
|---|---|---|---|---|
| auth_method | "service_account" | Yes | — | — |
| delegated_subject | string | No | User email to impersonate via domain-wide delegation (optional) | — |
Google Workspace OAuth
| Field | Type | Required | What it does | Default |
|---|---|---|---|---|
| auth_method | "oauth" | Yes | — | — |
| client_id | string | Yes | OAuth 2.0 client ID | — |
Secrets
Stored encrypted and never shown again after you save them. See Configuration & Fields.
This section depends on which authentication method you pick — one of the following applies.
Google Workspace Service Account
| Field | Type | Required | What it does | Default |
|---|---|---|---|---|
| service_account_json | string | Yes | Full JSON key for the Google service account | — |
Google Workspace OAuth
| Field | Type | Required | What it does | Default |
|---|---|---|---|---|
| client_secret | string | Yes | OAuth 2.0 client secret | — |
| refresh_token | string | Yes | OAuth 2.0 refresh token | — |
Optional
Everything you can tune. Sensible defaults apply when you leave them alone.
| Field | Type | Required | What it does | Default |
|---|---|---|---|---|
| optional | object | No | —no extra properties | — |
| connection | object | No | Network and pagination controls for Drive API requests.no extra properties | — |
| connection.max_object_bytes | integer | No | Skip files larger than this many bytes (default 100 MB)min 0 | 104857600 |
| connection.max_retries | integer | No | Maximum retries on transient errorsmin 0, max 10 | 5 |
| connection.page_size | integer | No | Items per page for Drive API list requestsmin 1, max 1000 | 1000 |
| connection.timeout_seconds | integer | No | Socket timeout for Drive API operationsmin 5, max 300 | 30 |
| extraction | object | No | Controls which structural assets to emit and how Google-native files are handled.no extra properties | — |
| extraction.export_google_formats | boolean | No | Export Google-native files (Docs/Sheets/Slides) to Office formats for content extraction | true |
| extraction.include_drive_metadata | boolean | No | Emit drive-level assets with metadata | true |
| scope | object | No | Drive/folder selection and content filtering.no extra properties | — |
| scope.drive_ids | array | No | Shared drive IDs to scan (empty = all accessible shared drives) | — |
| scope.drive_ids[] | string | No | — | — |
| scope.exclude_file_extensions | array | No | Skip files with these extensions | — |
| scope.exclude_file_extensions[] | string | No | — | — |
| scope.folder_ids | array | No | Only scan these folder IDs recursively (empty = full drives) | — |
| scope.folder_ids[] | string | No | — | — |
| scope.include_file_extensions | array | No | Only include files with these extensions (e.g. .pdf, .docx) | — |
| scope.include_file_extensions[] | string | No | — | — |
| scope.include_my_drive | boolean | No | Include the authenticated/delegated user's My Drive | true |
| scope.include_permissions | boolean | No | Include file sharing permission metadata | false |
| scope.include_shared_drives | boolean | No | Include shared drives | true |