Files & Folders
List, search, create, update, copy, export and delete files, folders and Google-native documents
Sharing & Permissions
Grant, change and revoke access for users, groups, domains or anyone with the link
Comments & Revisions
Browse and manage comment threads, replies and historical revisions of any file
Prerequisites
- A Google account with access to the Drive content you want to expose. For Google Workspace drives, the workspace admin may need to allow third-party OAuth apps.
- A Google Cloud project with the Drive API enabled at console.cloud.google.com/apis/library/drive.googleapis.com.
- A Google OAuth 2.0 Client of type Web application, created at console.cloud.google.com/apis/credentials. The Authorized redirect URIs must contain the value shown in the
OAuth Callback URLfield of the installed app instance (auto-populated on install — copy it back into the Google Cloud Console after installation). - An OAuth consent screen configured in the Google Cloud project. While the app is in Testing state, add the end-user’s email to Test users. The full Drive scope (
https://www.googleapis.com/auth/drive) is classed restricted and requires CASA verification when the consent screen moves to Production. - Base URL (default:
https://www.googleapis.com)
- Usage as App
- Usage as MCP
Installation
- Go to Apps in your workspace
- Search for Google Drive and install it
- Open the app instance configuration and fill in the required fields
Configuration
| Field | Description |
|---|---|
| Google Drive API Base URL | Base URL of the Drive API (default https://www.googleapis.com) |
| API Token (fallback) | Optional static OAuth access token used as a shared fallback for all users of this tenant. Stored as a workspace secret. Most deployments leave this empty and rely on per-user OAuth. |
| OAuth2 Client ID | Google OAuth Application Client ID. Create an OAuth client of type Web application in the Google Cloud Console. Stored as a workspace secret. |
| OAuth2 Client Secret | Google OAuth Client Secret, stored as a workspace secret |
| OAuth Authorize URL | Default https://accounts.google.com/o/oauth2/v2/auth |
| OAuth Token URL | Default https://oauth2.googleapis.com/token |
| OAuth Revoke URL | Default https://oauth2.googleapis.com/revoke |
| OAuth Scopes | Space-separated Google API scopes. Default https://www.googleapis.com/auth/drive (full Drive access). Other common values: drive.readonly, drive.file, drive.metadata, drive.appdata |
| Refresh Token TTL (seconds) | Default 15552000 (180 days, Google’s max) |
| MCP Endpoint | Auto-populated on install — URL of the MCP endpoint for this instance |
| MCP API Key | Auto-populated on install — signed key used in the mcp-api-key header. Do not modify |
MCP Endpoint and MCP API Key are generated automatically by the onInstall flow. The OAuth credentials (OAuth2 Client ID, OAuth2 Client Secret) must be filled in manually after creating the OAuth client in the Google Cloud Console.Authorize end-users
Once the app instance is configured, each end-user authorizes their own Google account through a browser-based consent screen:Trigger the connect flow
From an MCP client (Agent Creator capability or any tool client), call any data tool. If no OAuth session exists for the current user × tenant, the MCP server returns a
connector_auth_required payload with a connect_url. Alternatively, call the connect tool explicitly to receive the same payload.Open the connect URL
Open the returned URL in a browser tab where the user is already authenticated to Prisme.ai. The platform redirects to the Google OAuth consent screen.
Grant access
The user reviews the requested scopes (default
https://www.googleapis.com/auth/drive) and clicks Allow. Google redirects back to the platform’s oauthCallback webhook.Available Instructions
Every instruction resolves credentials from the workspace configuration. Most list operations acceptpageSize (default 100, max 1000) and pageToken for pagination, plus a fields parameter using Google’s partial response syntax to control the returned payload size.Files
| Instruction | Arguments |
|---|---|
listFiles | q, pageSize, pageToken, orderBy, fields, spaces, corpora, driveId, includeItemsFromAllDrives, supportsAllDrives |
getFile | fileId*, fields, supportsAllDrives, includePermissionsForView |
createFile | name, mimeType, description, parents, starred, properties, appProperties, supportsAllDrives, ignoreDefaultVisibility, keepRevisionForever, ocrLanguage, useContentAsIndexableText, fields |
updateFile | fileId*, addParents, removeParents, keepRevisionForever, ocrLanguage, useContentAsIndexableText, supportsAllDrives, fields, name, mimeType, description, starred, trashed, properties, appProperties |
copyFile | fileId*, name, parents, description, supportsAllDrives, keepRevisionForever, ocrLanguage, ignoreDefaultVisibility, fields |
deleteFile | fileId*, supportsAllDrives |
exportFile | fileId, mimeType |
emptyTrash | enforceSingleParent |
generateFileIds | count, space, type |
Permissions
| Instruction | Arguments |
|---|---|
listPermissions | fileId*, pageSize, pageToken, fields, supportsAllDrives, includePermissionsForView |
getPermission | fileId, permissionId, supportsAllDrives, fields |
createPermission | fileId, type, role*, emailAddress, domain, allowFileDiscovery, expirationTime, emailMessage, sendNotificationEmail, supportsAllDrives, transferOwnership, moveToNewOwnersRoot, fields |
updatePermission | fileId, permissionId, removeExpiration, transferOwnership, supportsAllDrives, fields, role, expirationTime |
deletePermission | fileId, permissionId, supportsAllDrives |
Comments
| Instruction | Arguments |
|---|---|
listComments | fileId*, pageSize, pageToken, includeDeleted, startModifiedTime, fields |
getComment | fileId, commentId, includeDeleted, fields |
createComment | fileId, content, anchor, quotedFileContent, fields |
updateComment | fileId, commentId, content, resolved, fields |
deleteComment | fileId, commentId |
Replies
| Instruction | Arguments |
|---|---|
listReplies | fileId, commentId, pageSize, pageToken, includeDeleted, fields |
createReply | fileId, commentId, content, action, fields |
updateReply | fileId, commentId, replyId*, content, fields |
deleteReply | fileId, commentId, replyId* |
Revisions
| Instruction | Arguments |
|---|---|
listRevisions | fileId*, pageSize, pageToken, fields |
getRevision | fileId, revisionId, fields |
updateRevision | fileId, revisionId, keepForever, publishAuto, published, publishedOutsideDomain, fields |
deleteRevision | fileId, revisionId |
Arguments flagged with
* are required.DSUL Examples
Search the latest spreadsheets in My Drive
Create a folder and a Google Doc inside it
Share a file with a user as commenter
Export a Google Sheet to XLSX
Resolve a comment thread
Error Handling
| HTTP Status | Error | Solution |
|---|---|---|
| 401 | Unauthorized / token expired | The OAuth token was revoked or expired. Re-run the connect flow for that user. The connector auto-refreshes when a refresh token is present |
| 403 | Forbidden | Check the OAuth scopes (https://www.googleapis.com/auth/drive for full access) and verify the Drive API is enabled on the Google Cloud project |
| 404 | Not Found | Verify the fileId / permissionId / commentId / revisionId. Drive IDs are case-sensitive and never include a trailing slash |
| 429 | Rate Limited / Quota exceeded | Drive enforces per-user and per-project quotas. Back off and retry with exponential delay |
| 500 | Server error | Transient. Retry once with a small delay |
Common Issues
“Not configured” — The app instance has no OAuth client. Fill inOAuth2 Client ID and OAuth2 Client Secret from the Google Cloud Console.
“Invalid API key” (MCP) — The mcp-api-key header does not match the central app secret. Reinstall the app instance to regenerate a signed key.
“Credentials lookup failed” — The MCP endpoint could not reach the getConfig webhook of the installed app. Verify that the app instance is still installed in the expected workspace.
redirect_uri_mismatch at the Google consent screen — The redirect URI registered in your Google OAuth client does not match the one the connector sends. Copy the value of OAuth Callback URL from the app instance configuration and paste it verbatim into the Authorized redirect URIs list of your OAuth client in the Google Cloud Console.
Drive API has not been used in project ... or it is disabled — Enable the Drive API at console.cloud.google.com/apis/library/drive.googleapis.com for the project that owns your OAuth client. Propagation takes up to a minute.
File not found: <id> on a shared drive — Pass supportsAllDrives: true (and includeItemsFromAllDrives: true on listFiles). Without these flags, the Drive API silently scopes the request to My Drive only.
fileNotDownloadable on exportFile — exportFile works only on Google-native files (Docs/Sheets/Slides/Drawings). For uploaded binaries (PDF, DOCX, …), use a file-content endpoint instead.
External Resources
Google Drive API Reference
Official Drive REST v3 reference
Tool Agents
Plug MCP servers into AI Knowledge agents