Permissions

For a list of methods for this resource, see the end of this page.

Resource representations

A permission for a file. A permission grants a user, group, domain or the world access to a file or a folder hierarchy.

{
  "kind": "drive#permission",
  "id": string,
  "type": string,
  "emailAddress": string,
  "domain": string,
  "role": string,
  "allowFileDiscovery": boolean,
  "displayName": string,
  "photoLink": string,
  "expirationTime": datetime
}
Property name Value Description Notes
kind string Identifies what kind of resource this is. Value: the fixed string "drive#permission".
id string The ID of this permission. This is a unique identifier for the grantee, and is published in User resources as permissionId.
type string The type of the grantee. Valid values are:
  • user
  • group
  • domain
  • anyone
writable
emailAddress string The email address of the user or group to which this permission refers. writable
domain string The domain to which this permission refers. writable
role string The role granted by this permission. Valid values are:
  • owner
  • writer
  • commenter
  • reader
writable
allowFileDiscovery boolean Whether the permission allows the file to be discovered through search. This is only applicable for permissions of type domain or anyone. writable
displayName string A displayable name for users, groups or domains.
expirationTime datetime The time at which this permission will expire (RFC 3339 date-time).

Methods

create
Creates a permission for a file.
delete
Deletes a permission.
get
Gets a permission by ID.
list
Lists a file's permissions.
update
Updates a permission with patch semantics.

Send feedback about...

Drive REST API
Drive REST API