Custom Permissions
Introduction
Custom permissions are new profile permissions that you can provide in the extension you develop. These permissions will be displayed under the PERMISSIONS tab on the extension detail page. Only the admins of a Zoho Desk portal will be able to configure these permissions.
How to define the custom permissions for the extension?
An extension developer can specify the Permissions details in resources.json file.
How does it work?
Custom permissions will be added when an admin installs the extension and deleted when they uninstall the extension. The permissions are specific to each installation of an extension. Therefore, admins can configure different permissions for an extension by installing it multiple times.
Note: Maximum limit for adding custom permissions is 10.
Admin configuration Permission Tab:
You can fetch the details of custom permissions in two ways:
1. Through the My Custom Permissions API within the extension, or
2. Through the My Custom Permissions REST API.
resources.json
Copied{
"permissions": [{
"resourceName": "Mypermission",
"apiName": "createResolution",
"displayName": "create Resolution test",
"description": "Able to create the task",
"defaultState": true
}]
}
#CUSTOM_PERMISSION_FIELDS
Field | Required | Type | Description |
---|---|---|---|
resourceName | yes | string | Unique identifier of the created permission in the resources. For more information, see resourceName. |
apiName | yes | string | apiName is the unique name given to each permission.apiName should be unique across each extension.apiName can have AlphaNumeric and underscore. |
displayName | yes | string | Name of the custom permission. This name will be displayed in "PERMISSIONS" tab. AlphaNumeric values are allowed here. |
description | no | string | Description of the custom permission. |
defaultState | yes | string | Default state of custom permission. It can have boolean value. Either true or false (Case sensitive). |