Login

Groups

A group in Coassemble is a collection of learners that can be enrolled in one or many courses. Adding a group into a course, automatically enrolls every learner into that course. Learners added at a later date, will be enrolled into the same course.

Endpoints

Get groups

GET /api/v1/groups

Returns a list of all groups in your workspace. Groups are returned sorted by creation date, with the most recently created groups appearing first. Filter groups using the query parameters listed in the table.

Query parameters

FieldTypeDescriptionRequiredDefaultPattern
ownerstringOwner User IDNonull\d+
coursestringCourse IDNonull\d+
searchstringSearch by Group nameNo"" N/A
sortstringSort byNo"created"(alpha|recent|created)
pagestringWhich page of items to display, starting with zeroNo"0"\d+
lengthstringItems per page (0-100)No"10"\d+
simplestringSimple searchNonull(true|false)

Responses

CodeDescription
200Returned when successful

Create a group

POST /api/v1/groups

Create a new group.

FormData properties

FieldDescriptionRequired
nameGroup nameNo

Responses

CodeDescription
201Returned when successful

Get a specific group

GET /api/v1/groups/{group}

Get details of specific group.

Path variables

FieldDescription
groupID of group you want details about

Responses

CodeDescription
200Returned when successful

Delete a group

DELETE /api/v1/groups/{group}

Delete an existing group.

Path variables

FieldDescription
groupID of group you wish to delete

Responses

CodeDescription
204Returned when successful

Modify a group

PATCH /api/v1/groups/{group}

This endpoint can change the name of the group.

Path variables

FieldDescription
groupID of group you wish to modify

FormData properties

FieldDescriptionRequired
nameGroup nameNo

Responses

CodeDescription
204Returned when successful

Copy a group

POST /api/v1/groups/{source}/copies

Duplicate an existing group.

Path variables

FieldDescription
source

Query parameters

FieldTypeDescriptionRequiredDefaultPattern
namestringName of new groupNonull\w+

Responses

CodeDescription
200Returned when successful

List learners in a group

GET /api/v1/groups/{group}/students

Returns a list of learners in a specific group.

Path variables

FieldDescription
groupID of the group

Query parameters

FieldTypeDescriptionRequiredDefaultPattern
pagestringWhich page of items to display, starting with zeroNo"0"\d+
lengthstringItems per page (0-100)No"10"\d+
searchstringAn input to search forNo"" N/A

Responses

CodeDescription
200Returned when successful

Add learners to a group

POST /api/v1/groups/{group}/students

Add one or many existing learners into a group.

Path variables

FieldDescription
groupID of the group

Body properties

FieldTypeDescriptionRequired
idsinteger[]No

Responses

CodeDescription
204Returned when successful

List trainers in a group

GET /api/v1/groups/{group}/teachers

Returns a list of trainers who teach a group.

Path variables

FieldDescription
groupID of the group

Responses

CodeDescription
200Returned when successful

Add trainers to a group

POST /api/v1/groups/{group}/teachers

Add one or many existing trainers to a group.

Path variables

FieldDescription
groupID of the group

Body properties

FieldTypeDescriptionRequired
idsinteger[]No

Responses

CodeDescription
204Returned when successful