Instructors can create course tags and assign them to students. Tags are used in features like activity subsetting or groups.
A tag belongs to a single course but a course can have multiple tags.
Tags and students are a many-to-many relationship.
Course tags can be listed by using the Course.tags field. This returns a list of Tag models that contain information like label, color or the assigned students. For more details, check out the Tag model in the API Reference.
The Tag.students field is a GraphQL connection. Read how to paginate a connection in the dedicated guide.
You can add students to a tag via the addStudentsToTag mutation. The mutation returns the updated tag so details like the complete list of students can be fetched. The studentIds are Participant.id values that can be fetched from the Course.participants connection.
Based on the tag id, only student ids from tag's course are accepted