Add Drive permission
Action ID:tools.google_drive.add_permission
Grant access to a file or folder
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/permissions/create
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
Email address to grant access to
string
required
The file or folder ID
string
Fields to return (’*’ for all)Default:
"*".string
Role: reader, writer, commenter, ownerDefault:
"reader".boolean
Send email notificationDefault:
false.Create Drive folder
Action ID:tools.google_drive.create_folder
Create a new folder in Google Drive
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/files/create
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
Name for the new folder
string
Fields to return (’*’ for all)Default:
"*".string
Parent folder ID (empty = root)Default:
"".Delete Drive file
Action ID:tools.google_drive.delete_file
Move a file or folder to trash
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/files/update
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
The file or folder ID to delete
string
Fields to return (’*’ for all)Default:
"*".Get Drive file
Action ID:tools.google_drive.get_file
Get metadata for a specific file
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/files/get
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
The file ID
string
Fields to return (’*’ for all)Default:
"*".Get Drive file permissions
Action ID:tools.google_drive.get_file_permissions
List all permissions for a file
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/permissions/list
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
The file ID
string
Fields to return (’*’ for all)Default:
"*".integer | null
The maximum number of permissions to return per page. When not set for files in a shared drive, at most 100 results will be returned. When not set for files that are not in a shared drive, the entire list will be returned.Default:
null.string | null
The token for continuing a previous list request on the next page. This should be set to the value of nextPageToken from the previous response.Default:
null.List Drive files
Action ID:tools.google_drive.list_files
List and search files in Google Drive
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/files/list
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
Optional Shared Drive ID to scope the search to a single Shared Drive. Implies include_shared_drives.Default:
"".string
Fields to return (e.g., ‘files(id,name,mimeType)’ or ’*’ for all)Default:
"*".Include files from Shared Drives (sets supportsAllDrives and includeItemsFromAllDrives).Default:
false.integer
Maximum number of results. The maximum value is 1000; values above 1000 will be coerced to 1000.Default:
10.string
Sort orderDefault:
"modifiedTime desc".string | null
The token for continuing a previous list request on the next page. This should be set to the value of nextPageToken from the previous response.Default:
null.string
Search query (e.g., ‘name contains “report”’)Default:
"".Permanently delete Drive file
Action ID:tools.google_drive.permanently_delete_file
Permanently delete a file (bypass trash)
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/files/delete
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
The file or folder ID to permanently delete
Query Drive activity
Action ID:tools.google_drive.query_activity
Query past activity in Google Drive.
Reference: https://developers.google.com/workspace/drive/activity/v2/reference/rest/v2/activity/query
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string | null
Return activities for this Drive folder, plus all children and descendants. The format is
items/ITEM_ID.Default: null.object | null
Details on how to consolidate related actions that make up the activity. If not set, then related actions aren’t consolidated. Union field
strategy, one of: none (the individual activities are not consolidated), legacy (the individual activities are consolidated using the legacy strategy). See https://developers.google.com/workspace/drive/activity/v2/reference/rest/v2/activity/query#ConsolidationStrategyDefault: null.string | null
The filtering for items returned from this query request. The format of the filter string is a sequence of expressions, joined by an optional
AND, where each expression is of the form field operator value. Supported fields are time and detail.action_detail_case.Default: null.string | null
Return activities for this Drive item. The format is
items/ITEM_ID.Default: null.integer | null
The minimum number of activities desired in the response; the server attempts to return at least this quantity. The server may also return fewer activities if it has a partial response ready before the request times out. If not set, a default value is used.Default:
null.string | null
The token identifies which page of results to return. Set this to the
nextPageToken value returned from a previous query to obtain the following page of results. If not set, the first page of results is returned.Default: null.Revoke Drive permission
Action ID:tools.google_drive.revoke_permission
Remove access to a file or folder
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/permissions/delete
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
The file or folder ID
string
required
The permission ID to revoke
Update Drive permission
Action ID:tools.google_drive.update_permission
Modify an existing permission
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/permissions/update
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
The file or folder ID
string
required
The permission ID to update
string
required
New role: reader, writer, commenter
string
Fields to return (’*’ for all)Default:
"*".Upload Drive file
Action ID:tools.google_drive.upload_file
Upload a file to Google Drive
Reference: https://developers.google.com/workspace/drive/api/reference/rest/v3/files/create
Secrets
Optional secrets:google_drive_oauth: OAuth tokenGOOGLE_DRIVE_USER_TOKEN.google_drive_oauth: OAuth tokenGOOGLE_DRIVE_SERVICE_TOKEN.google_api: required valuesGOOGLE_API_CREDENTIALS; optional valuesGOOGLE_API_SUBJECT.
Input fields
string
required
Base64-encoded file content
string
required
Name for the uploaded file
string
Fields to return (’*’ for all)Default:
"*".string
MIME type of fileDefault:
"application/octet-stream".string
Parent folder ID (empty = root)Default:
"".