Google Drive Custom icon

Google Drive Custom

Interact with Google Drive API with auto-refreshing token

Actions9

File → Share

AI-generated

Summary

Share a Google Drive file by granting a specified user email an access permission role.

Inputs

  • Authentication (required) — Select the authentication method: 'Refresh Token (Auto-Refresh)' to use OAuth refresh token with automatic token refreshing, or 'Bearer Token (Manual)' to use a manually provided access token.
  • File ID (required) — The ID of the Google Drive file to share.
  • Email (required) — The email address of the user to share the file with.
  • Role (required) — The permission role to grant the user. Valid roles are Reader (view only), Writer (edit), Commenter (comment rights), or Owner (full ownership).
  • Options.Custom Refresh Token — Optionally override the default refresh token for authentication if using 'Refresh Token (Auto-Refresh)' method.

Output shape

a single JSON object representing the created permission resource for the file sharing action.

The output contains the permission resource returned from the Google Drive API on successfully creating a sharing permission. If the operation fails and 'Continue on Fail' is enabled, the output will contain an error message for each failed item.

Examples

Example 1: Share a file with a user as a reader

Set Authentication to 'Refresh Token (Auto-Refresh)', specify the File ID, the user's Email, and set Role to 'Reader'. Execute to grant view access to the specified user.

Discussion