Cmdlets for Google Drive

Build 24.0.9060

Permissions

Create, update, delete, and query permissions for resources in a user's Google Drive.

Select

The ResourceId field must be specified to get data from this table. This is the only supported filter.

SELECT * FROM Permissions WHERE ResourceId = '0B5AH3NIqjXDKX3pJS3NncTZJa01'

Insert

To insert into Permissions, you must specify values at least for the ResourceId, Role, Type, and EmailAddress fields.

INSERT INTO Permissions (ResourceId, Role, Type, EmailAddress) VALUES ('0B5AH3NIqjXDKX3pJS3NncTZJa01', 'WRITER', 'USER', '[email protected]')

Update

The PermissionId and ResourceId fields are required for updating a Permission.

UPDATE Permissions SET Role = 'organizer' WHERE PermissionId = '3NIqjXDK' AND ResourceId = '0B5AH3NIqjXDKX3pJS3NncTZJa01'

Delete

To delete a Permission, the PermissionId and ResourceId fields are required.

Delete From Permissions WHERE PermissionId = '3NIqjXDK' AND ResourceId = '0B5AH3NIqjXDKX3pJS3NncTZJa01'

Columns

Name Type ReadOnly Description
PermissionId [KEY] String True

The Id of the permission for the resource.

ResourceId [KEY] String True

The Id of the resource (a file or folder).

Role String False

The role specified for the permission. It can take only these values: 'READER', 'COMMENTER', 'WRITER', 'OWNER', 'FILE_ORGANIZER', 'ORGANIZER'.

Type String False

The type entity to which the permission applies. It can take only these values: 'USER', 'GROUP', 'DOMAIN', 'ANYONE'.

EmailAddress String False

The email address of the user or group to which this permission refers.

Domain String False

The domain to which this permission refers.

AllowFileDiscovery Boolean False

Whether the permission allows the file or folder to be discovered through search. This is only applicable for permissions of type 'DOMAIN' or 'ANYONE'. The default value for this field is 'false'

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 24.0.9060