REST Resource: labels.permissions
Stay organized with collections
Save and categorize content based on your preferences.
Resource: LabelPermission
The permission that applies to a principal (user, group, audience) on a label.
JSON representation |
{
"name": string,
"email": string,
"role": enum (LabelRole ),
// Union field principal can be only one of the following:
"person": string,
"group": string,
"audience": string
// End of list of possible types for union field principal .
} |
Fields |
name |
string
Resource name of this permission.
|
email |
string
Specifies the email address for a user or group principal. Not populated for audience principals. User and group permissions may only be inserted using an email address. On update requests, if email address is specified, no principal should be specified.
|
role |
enum (LabelRole )
The role the principal should have.
|
Union field principal . The principal this permission applies to. Must be either an email, user, group, or audience. Example: * people/12345 * groups/45678 * audiences/default principal can be only one of the following: |
person |
string
Person resource name.
|
group |
string
Group resource name.
|
audience |
string
Audience to grant a role to. The magic value of audiences/default may be used to apply the role to the default audience in the context of the organization that owns the label.
|
LabelRole
Roles are concentric with subsequent role.
Enums |
LABEL_ROLE_UNSPECIFIED |
Unknown role. |
READER |
A reader can read the label and associated metadata applied to Drive items. |
APPLIER |
An applier can write associated metadata on Drive items in which they also have write access to. Implies READER . |
ORGANIZER |
An organizer can pin this label in shared drives they manage and add new appliers to the label. |
EDITOR |
Editors can make any update including deleting the label which also deletes the associated Drive item metadata. Implies APPLIER . |
Methods |
|
Deletes label permissions. |
|
Updates label permissions. |
|
Updates a label's permissions. |
|
Deletes a label's permission. |
|
Lists a label's permissions. |
Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.
Last updated 2025-08-04 UTC.
[null,null,["Last updated 2025-08-04 UTC."],[],[],null,["# REST Resource: labels.permissions\n\n- [Resource: LabelPermission](#LabelPermission)\n - [JSON representation](#LabelPermission.SCHEMA_REPRESENTATION)\n - [LabelRole](#LabelPermission.LabelRole)\n- [Methods](#METHODS_SUMMARY)\n\nResource: LabelPermission\n-------------------------\n\nThe permission that applies to a principal (user, group, audience) on a label.\n\n| JSON representation |\n|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| ``` { \"name\": string, \"email\": string, \"role\": enum (/workspace/drive/labels/reference/rest/v2/labels.permissions#LabelPermission.LabelRole), // Union field `principal` can be only one of the following: \"person\": string, \"group\": string, \"audience\": string // End of list of possible types for union field `principal`. } ``` |\n\n| Fields ||\n|------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `name` | `string` Resource name of this permission. |\n| `email` | `string` Specifies the email address for a user or group principal. Not populated for audience principals. User and group permissions may only be inserted using an email address. On update requests, if email address is specified, no principal should be specified. |\n| `role` | `enum (`[LabelRole](/workspace/drive/labels/reference/rest/v2/labels.permissions#LabelPermission.LabelRole)`)` The role the principal should have. |\n| Union field `principal`. The principal this permission applies to. Must be either an email, user, group, or audience. Example: \\* `people/12345` \\* `groups/45678` \\* `audiences/default` `principal` can be only one of the following: ||\n| `person` | `string` Person resource name. |\n| `group` | `string` Group resource name. |\n| `audience` | `string` Audience to grant a role to. The magic value of `audiences/default` may be used to apply the role to the default audience in the context of the organization that owns the label. |\n\n### LabelRole\n\nRoles are concentric with subsequent role.\n\n| Enums ||\n|--------------------------|------------------------------------------------------------------------------------------------------------------------------------|\n| `LABEL_ROLE_UNSPECIFIED` | Unknown role. |\n| `READER` | A reader can read the label and associated metadata applied to Drive items. |\n| `APPLIER` | An applier can write associated metadata on Drive items in which they also have write access to. Implies `READER`. |\n| `ORGANIZER` | An organizer can pin this label in shared drives they manage and add new appliers to the label. |\n| `EDITOR` | Editors can make any update including deleting the label which also deletes the associated Drive item metadata. Implies `APPLIER`. |\n\n| Methods ------- ||\n|---------------------------------------------------------------------------------------------|--------------------------------|\n| ### [batchDelete](/workspace/drive/labels/reference/rest/v2/labels.permissions/batchDelete) | Deletes label permissions. |\n| ### [batchUpdate](/workspace/drive/labels/reference/rest/v2/labels.permissions/batchUpdate) | Updates label permissions. |\n| ### [create](/workspace/drive/labels/reference/rest/v2/labels.permissions/create) | Updates a label's permissions. |\n| ### [delete](/workspace/drive/labels/reference/rest/v2/labels.permissions/delete) | Deletes a label's permission. |\n| ### [list](/workspace/drive/labels/reference/rest/v2/labels.permissions/list) | Lists a label's permissions. |"]]