drive_search_files
Search Google Drive for files by name, type, or content across My Drive and Shared Drives. Supports raw query syntax and optional drive restriction.
Instructions
Search for files in Google Drive. Searches across My Drive and all Shared Drives the user is a member of by default; pass driveId to scope the search to a single Shared Drive (discover IDs with drive_list_shared_drives). Supports shorthand syntax: type:document, type:spreadsheet, type:pdf, type:folder, type:image, type:video, type:audio (converted to mimeType queries), and content:keyword (searches inside file contents via fullText). Also accepts raw Drive API query syntax (e.g., "name contains 'report'").
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| query | Yes | Drive search query (e.g., "name contains 'report'") | |
| driveId | No | Restrict search to a single Shared Drive (omit to search My Drive + all Shared Drives) | |
| accountId | Yes | The Google account ID, alias, or email | |
| pageToken | No | Token for pagination | |
| maxResults | No | Maximum number of results (default: 20) |