GroupSetService#
- class GroupSetService[source]#
Methods
Create a group for the given group set.
Get a single GroupSet by id.
Delete a GroupSet.
Get all groups for a given group set.
Get the group for a specific user within a given group set.
- create_group(json_body, *, group_set_id)[source]#
Create a group for the given group set.
- Parameters:
json_body (
CreateGroupGroupSetData
) – The body of the request. SeeCreateGroupGroupSetData
for information about the possible fields. You can provide this data as aCreateGroupGroupSetData
or as a dictionary.group_set_id (
int
) – The id of the group set where the new group should be placed in.self (GroupSetService[AuthenticatedClient]) –
- Returns:
The newly created group.
- Return type:
- get(*, group_set_id)[source]#
Get a single GroupSet by id.
- Parameters:
group_set_id (
int
) – The id of the group setself (GroupSetService[AuthenticatedClient]) –
- Returns:
A response containing the JSON serialized group set.
- Return type:
- delete(*, group_set_id)[source]#
Delete a GroupSet.
You can only delete a group set if there are no groups in the set and no assignment is connected to the group set.
- Parameters:
group_set_id (
int
) – The id of the group setself (GroupSetService[AuthenticatedClient]) –
- Returns:
Nothing.
- Return type:
None
- get_all_groups(*, group_set_id, page_size=20)[source]#
Get all groups for a given group set.
- Parameters:
group_set_id (
int
) – The group set for which the groups should be returned.page_size (
int
) – The size of a single page, maximum is 50.self (GroupSetService[AuthenticatedClient]) –
- Returns:
All the groups for the given group set.
- Return type:
Response[Group]
- get_user_group(*, group_set_id, user_id)[source]#
Get the group for a specific user within a given group set.
- Parameters:
group_set_id (
int
) – The group set to search within.user_id (
int
) – The ID of the user whose group is to be found.self (GroupSetService[AuthenticatedClient]) –
- Returns:
The single group object for the given user.
- Return type: