POST/sharedrives/{sharedriveId}/permissions
Creates a member permission for a collaborative drive, which can be assigned to a specified user, team, or group.
The accessibleRange for the collaborative drive is changed to MEMBER.
To change the accessibleRange to TENANT or DOMAIN, you need to use the "Update a collaborative drive" API operation.
OAuth 2.0 authentication.
For more information, see Authentication and Authorization.
file
| Parameter | Type | Description |
|---|---|---|
| sharedriveId | string | Collaborative drive ID required example : @2101000000000008 |
| Header | type | Description |
|---|---|---|
| Authorization | string | Bearer {token} required |
It is used to obtain the ID and type of a user to add permissions for.
| Property | Type | Description |
|---|---|---|
| userId | string | User ID
required minLength : 1 |
| userType | string | User type
required Allowed values : USER, ORGUNIT, GROUP |
| type | string | Permission type
default : WRITE Allowed values : READ, WRITE |
example
1{2 "userId": "works@example.com",3 "userType": "USER",4 "type": "READ"5}OK
| Property | Type | Description |
|---|---|---|
| permissionId | string | Permission ID required minLength : 1 readOnly : true |
| type | string | Permission type
required Allowed values : READ, WRITE |
| userId | string | User ID required minLength : 1 readOnly : true |
| userType | string | User type
required Allowed values : USER, ORGUNIT, GROUP |
| userName | string | User name required minLength : 1 readOnly : true |
example
1{2 "permissionId": "QDIxMDAwMDAwMDAwMTcwfEdST1VQfDEwMTAwMDAwMDExNDY1MA",3 "type": "WRITE",4 "userId": "group127-8545-4463-603b-04d550d23bf",5 "userType": "GROUP",6 "userName": "test name"7}Forbidden