GroupService#

class GroupService[source]#

Methods

add_member

Add a user (member) to a group.

get

Get a group by id.

delete

Delete a group by id.

remove_member

Remove a member from a group.

rename_group

Update the name of the group.

add_member(json_body, *, group_id, extra_parameters=None)[source]#

Add a user (member) to a group.

Parameters:
Returns:

The group with the newly added user.

Return type:

ExtendedGroup

get(*, group_id, extra_parameters=None)[source]#

Get a group by id.

Parameters:
Returns:

The requested group.

Return type:

ExtendedGroup

delete(*, group_id, extra_parameters=None)[source]#

Delete a group by id.

This action is irreversible!

This is only possible if the group doesn’t have any submissions associated with it.

Parameters:
Returns:

Nothing.

Return type:

None

remove_member(*, group_id, user_id, extra_parameters=None)[source]#

Remove a member from a group.

If the group has a submission you cannot delete the last remaining member of a group.

Parameters:
Returns:

The group without the removed user.

Return type:

ExtendedGroup

rename_group(json_body, *, group_id, extra_parameters=None)[source]#

Update the name of the group.

Parameters:
Returns:

The group with the updated name.

Return type:

ExtendedGroup