Concept
Permissions
The permissions field inside of a request holds permission sets. Permission sets consist of elements that contain departments
, userGroups
& requireAllUserGroups
.
Property | Value | Description |
---|---|---|
requireAllUserGroups | boolean |
Determines whether a single or all user groups are required for the permission. If UserGroups is empty this can't be true. |
departments | string / guid |
Departments that has access. Leave with an empty array if you want all departments selected. |
userGroups | string / guid |
User groups that has permission. Leave with an empty array if you want all user groups selected. |
Please note: Depending on module settings it may not be possible to create default permissions. This is the case for modules that has permissions requirement set for a department or user group.
Example scenarios:
Scenario 1 - No department or user group ids provided. This will cause a default creation to occur where all departments and user groups are selected.
[
{
"requireAllUserGroups": false,
"departments": [],
"userGroups": []
}
]
Scenario 2 - No department ids provided. This will cause a default creation to occur where all departments are selected and specified user groups.
[
{
"requireAllUserGroups": true,
"departments": [],
"userGroups": [
"439cb823-d581-4e25-b791-275033a61225"
]
}
]
Scenario 3 - No user group ids provided. This will cause a default creation to occur where all user groups are selected and specified departments.
[
{
"requireAllUserGroups": false,
"departments": [
"84b130b1-ecf2-4eab-9c78-24b1ee4317e6"
],
"userGroups": []
}
]
Scenario 4 - Selected department and user group ids provided.
[
{
"requireAllUserGroups": true,
"departments": [
"84b130b1-ecf2-4eab-9c78-24b1ee4317e6"
],
"userGroups": [
"439cb823-d581-4e25-b791-275033a61225"
]
}
]