Editing a Permissions Template
Function
Edit a permissions template.
URI
POST /koodrive/ose/v1/permission/template/edit
Request Parameters
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
Authorization |
Yes |
String |
The format is Bearer {app_access_token}. The application-level token needs to be passed for calling by an application server. The token is obtained by calling an API using clientid and clientSecret obtained during application creation. |
X-User-Id |
Yes |
String |
User ID, which is used for app authentication. |
X-Date |
Yes |
String |
Date, which is used for app authentication. |
Host |
No |
String |
Address, which is used for app authentication. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
id |
Yes |
Long |
Template ID. |
name |
Yes |
String |
Template name. |
description |
No |
String |
Description. |
capabilities |
No |
Capabilities object |
Permissions. |
Parameter |
Mandatory |
Type |
Description |
---|---|---|---|
addChildNodePermission |
Yes |
Boolean |
Permission to create a file or folder. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
copyPermission |
Yes |
Boolean |
Copy permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
deletePermission |
Yes |
Boolean |
Delete permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
downloadPermission |
Yes |
Boolean |
Download permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
editPermission |
Yes |
Boolean |
Edit permissions. true: granted; false: not granted (editing is not supported.) |
listChildNodePermission |
Yes |
Boolean |
Permission to view the list. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
removeChildNodePermission |
Yes |
Boolean |
Move permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
renameFilePermission |
Yes |
Boolean |
Rename permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
shareFilePermission |
Yes |
Boolean |
Share permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
uploadPermission |
Yes |
Boolean |
Upload permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
viewPermission |
Yes |
Boolean |
Preview permission. The value true indicates that the permission is granted, and the value false indicates that the permission is not granted. |
Response Parameters
Status code: 200
Parameter |
Type |
Description |
---|---|---|
code |
Integer |
Response code. |
msg |
String |
Response information. |
Example Requests
/koodrive/ose/v1/permission/template/edit { "id" : "1590******215169", "name" : "***", "description" : "s", "capabilities" : { "listChildNodePermission" : true, "viewPermission" : false, "editPermission" : false, "uploadPermission" : false, "downloadPermission" : false, "shareFilePermission" : false, "removeChildNodePermission" : false, "copyPermission" : false, "renameFilePermission" : false, "deletePermission" : false, "addChildNodePermission" : false } }
Example Responses
Status code: 200
Response body for editing a permissions template.
{ "code" : 0, "msg" : "Successful." }
Status Codes
Status Code |
Description |
---|---|
200 |
Response body for editing a permissions template. |
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot