Endast på engelska
Den här sidan finns inte på svenska ännu. Innehållet visas på engelska.
Groups
What is a group?
A group is a collection of users in an organization. Groups can be added as members of a zone, granting them access rights similar to those of individual users. Groups provide an efficient way to organize users within an organization. A group consists of one or more managers and as many members as desired. If needed, a group can also be a member of another group.
As an administrator you will be able to manage groups. Each group has at least one manager responsible for handling the members of the group.
Create a group
To create a group provide the endpoint /api/groups with name, description and group members.
curl --location --request POST http://<your-organization-name>.synkzone.com/api/groups
--header 'Authorization: 3881603599579212345'
--data-raw '{
"members": [
{"accessLevel": "Manage", "memberId": "helen@organization.com"},
{"accessLevel": "Access", "memberId": "bob@organization.com"},
{"accessLevel": "Access", "memberId": "joe@organization.com"},
],
"name": "Sales",
"description": "Everyone working at the sales department"
}'
{
"members": [
{
"accessLevel": "Manage",
"authorization": "Administrator",
"displayName": "Helen",
"memberId": "helen@organization.com",
"memberType": "User"
},
{
"accessLevel": "Access",
"authorization": "Internal",
"displayName": "Bob",
"memberId": "bob@organization.com",
"memberType": "User"
},
{
"accessLevel": "Access",
"authorization": "Administrator",
"displayName": "Joe",
"memberId": "joe@organization.com",
"memberType": "User"
}
],
"properties": {
"administratorManaged": false,
"createdAt": "2024-04-26T11:56:10.493+02:00",
"createdBy": "helen@organization.com",
"description": "Everyone working at the sales department",
"groupId": "group.451d5g41-44y7-4978-8c25-d3e12cceuy6d@organization.com",
"name": "Sales",
"open": true,
"zoneActions": {
"assignAccessRights": false
}
}
}
It's possible to add a group as a member in another group. To do that, add the group id instead of the user id when adding members to the group. See example "Create group with group as member".
curl --location --request POST http://<your-organization-name>.synkzone.com/api/groups
--header 'Authorization: 3881603599579212345'
--data-raw '{
"members": [
{"accessLevel": "Manage", "memberId": "joe@organization.com"},
{"accessLevel": "Access", "memberId": "group.ba4ca7b0-1bb5-4303-9d05-72586b86a9e1@organization.com"}
],
"name": "Groupmania",
"description": "A group with a group as member"
}'
{
"members": [
{
"accessLevel": "Access",
"memberType": "Group",
"displayName": "Summer interns",
"memberId": "group.ba4ca7b0-1bb5-4303-9d05-72586b86a9e1@organization.com"
},
{
"accessLevel": "Manage",
"authorization": "Administrator"
"memberType": "User",
"displayName": "Joe",
"memberId": "joe@organization.com"
}
],
"properties": {
"administratorManaged": false,
"createdAt": "2024-04-26T16:03:53.701+02:00",
"createdBy": "joe@organization.com",
"description": "Summer interns of 2024",
"groupId": "group.a49d73f7-80ea-4a56-9711-057e362f7cfe@organization.com",
"name": "Sales",
"open": true,
"zoneActions": {
"assignAccessRights": false
}
}
}
Manage groups
When making changes to the member list of an existing group, the provided member list in the request body can either be applied as changes to the current access rights of the group or as a replacement to the current access rights. This is specified by the flag "relative", a boolean added as a query parameter. The default is to apply the given members list as changes to the current access rights of the group, having relative=true.
Let's say the starting point is a group with Bob as manager and Joe as a member in it. If updating using the default value of "relative" (true), where Joe should be manager and Helen a member the request should be as in example "Update access rights in group".
curl --location --request PUT http://<your-organization-name>.synkzone.com/api/groups/group.ed5548f1-6681-40a9-a11e-80232b7be4f6@organization.com
--header 'Authorization: 3881603599579212345'
--data-raw '{
"members": [
{"accessLevel": "Manage", "memberId": "joe@organization.com"},
{"accessLevel": "Access", "memberId": "helen@organization.com"}
]
}'
The result of this will be a group with Bob and Joe as managers, and Helen as a member, see "Update access rights in group response".
{
"members": [
{
"accessLevel": "Access",
"authorization": "Administrator",
"displayName": "Helen",
"memberId": "helen@organization.com",
"memberType": "User"
},
{
"accessLevel": "Manage",
"authorization": "Internal",
"displayName": "Bob",
"memberId": "bob@organization.com",
"memberType": "User"
},
{
"accessLevel": "Manage",
"authorization": "Administrator",
"displayName": "Joe",
"memberId": "joe@organization.com",
"memberType": "User"
}
],
"properties": {
"administratorManaged": false,
"createdAt": "2024-04-26T07:22:10.313+02:00",
"createdBy": "bob@organization.com",
"description": "Sales management team",
"groupId": "group.ed5548f1-6681-40a9-a11e-80232b7be4f6@organization.com",
"name": "Sales management",
"open": true,
"zoneActions": {
"assignAccessRights": false
}
}
}
If updating and setting "relative" to false, the current access rights of the group is replaced. If the starting point is the same (Bob as manager and Joe as a member) and the request is as stated in "Replace access rights in group" the result of the request will be that only Joe is left in the group, and has changed access righs to being the manager for the group.
curl --location --request PUT http://<your-organization-name>.synkzone.com/api/groups/group.1c4f5180-a008-4bf0-828c-fdd11cdc60dd@organization.com?relative=false
--header 'Authorization: 3881603599579212345'
--data-raw '{
"members": [
{"accessLevel": "Manage", "memberId": "joe@organization.com"}
]
}'
{
"members": [
{
"accessLevel": "Access",
"authorization": "Administrator",
"displayName": "Helen",
"memberId": "helen@organization.com",
"memberType": "User"
},
{
"accessLevel": "Manage",
"authorization": "Internal",
"displayName": "Bob",
"memberId": "bob@organization.com",
"memberType": "User"
},
{
"accessLevel": "Manage",
"authorization": "Administrator",
"displayName": "Joe",
"memberId": "joe@organization.com",
"memberType": "User"
}
],
"properties": {
"administratorManaged": false,
"createdAt": "2024-04-26T07:22:10.313+02:00",
"createdBy": "bob@organization.com",
"description": "Sales management team",
"groupId": "group.ed5548f1-6681-40a9-a11e-80232b7be4f6@organization.com",
"name": "Sales management",
"open": true,
"zoneActions": {
"assignAccessRights": false
}
}
}
It's possible to make updates to the access rights of an individual member at a time using the endpoint /api/groups/{groupid}/members/{memberid}.
curl --location --request PUT http://<your-organization-name>.synkzone.com/api/groups/group.ed5548f1-6681-40a9-a11e-80232b7be4f6@organization.com/members/joe@organization.com?accesslevel=Manage
--header 'Authorization: 3881603599579212345'
To remove a member of the group, set the group member access right to 'None'.
Delete groups
A group is deleted by a delete request to /api/groups/{groupid}.
curl --location --request DELETE http://<your-organization-name>.synkzone.com/api/groups/group.ed5548f1-6681-40a9-a11e-80232b7be4f6@organization.com/
--header 'Authorization: 3881603599579212345'
When a group is deleted all it's members will lose the zone access that was given by the group being a zone member.
Group properties
All groups are currently configured to be open, meaning a user in the system will be able to view which of its coworkers that are members of a group.
Groups as zone members
When giving a group access rights to a zone, making it a zone member, all members of the group will get access to the zone and its content just as if they were added individually. A group can have any access level in a zone except being a zone manager. If access rights to a zone are provided by multiple group memberships, the highest access level will be used. If an explicit access level is set for a user in a zone, that explicit level will take precedence over all other access levels provided by group memberships (excluding None level which is not applicable). E.g. the user is individually added to the zone with 'Add' rights and the group is added with 'Modify' rights, then the resulting access right for that user will be 'Add'. If the group is removed as a zone member, the user will still have the individual access right to the zone.