Drive Labels API . labels . revisions

Instance Methods

locks()

Returns the locks Resource.

permissions()

Returns the permissions Resource.

close()

Close httplib2 connections.

updatePermissions(parent, body=None, useAdminAccess=None, x__xgafv=None)

Updates a Label's permissions. If a permission for the indicated principal doesn't exist, a new Label Permission is created, otherwise the existing permission is updated. Permissions affect the Label resource as a whole, are not revisioned, and do not require publishing.

Method Details

close()
Close httplib2 connections.
updatePermissions(parent, body=None, useAdminAccess=None, x__xgafv=None)
Updates a Label's permissions. If a permission for the indicated principal doesn't exist, a new Label Permission is created, otherwise the existing permission is updated. Permissions affect the Label resource as a whole, are not revisioned, and do not require publishing.

Args:
  parent: string, Required. The parent Label resource name. (required)
  body: object, The request body.
    The object takes the form of:

{ # The permission that applies to a principal (user, group, audience) on a label.
  "audience": "A 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.
  "email": "A String", # Specifies the email address for a user or group pricinpal. Not populated for audience principals. User and Group permissions may only be inserted using email address. On update requests, if email address is specified, no principal should be specified.
  "group": "A String", # Group resource name.
  "name": "A String", # Resource name of this permission.
  "person": "A String", # Person resource name.
  "role": "A String", # The role the principal should have.
}

  useAdminAccess: boolean, Set to `true` in order to use the user's admin credentials. The server will verify the user is an admin for the Label before allowing access.
  x__xgafv: string, V1 error format.
    Allowed values
      1 - v1 error format
      2 - v2 error format

Returns:
  An object of the form:

    { # The permission that applies to a principal (user, group, audience) on a label.
  "audience": "A 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.
  "email": "A String", # Specifies the email address for a user or group pricinpal. Not populated for audience principals. User and Group permissions may only be inserted using email address. On update requests, if email address is specified, no principal should be specified.
  "group": "A String", # Group resource name.
  "name": "A String", # Resource name of this permission.
  "person": "A String", # Person resource name.
  "role": "A String", # The role the principal should have.
}