Permissions
Manages user and group access permissions for Drive resources, supporting fine-grained control over sharing and collaboration.
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 unique identifier assigned to a specific permission entry for the file or folder. |
| ResourceId [KEY] | String | False |
The unique identifier of the file or folder to which the permission applies. |
| Role | String | False |
The access level granted by the permission. Supported values are 'READER', 'COMMENTER', 'WRITER', 'OWNER', 'FILE_ORGANIZER', and 'ORGANIZER'. |
| Type | String | False |
The type of entity that the permission applies to. Valid values are 'USER', 'GROUP', 'DOMAIN', and 'ANYONE'. |
| EmailAddress | String | False |
The email address of the user or group associated with the permission entry. |
| Domain | String | False |
The domain associated with the permission, applicable when the type is 'DOMAIN'. |
| AllowFileDiscovery | Boolean | False |
If the value is 'true', the file or folder can be found via search by users in the specified domain or by anyone, depending on the permission type. This applies only to permissions of type 'DOMAIN' or 'ANYONE'. Default is 'false'. |