Add a class member
POST/public/classes/:classId/members
Adds a user to a class in the instance bound to the caller's API key. The user must belong to the instance, or to another instance in its super instance when cross-building collaboration is enabled, and must not already be a member of the class. Interactive videos and playlists already assigned to the class are not shared with the new member. Only instance owners may call this endpoint.
Request
Responses
- 201
- 400
- 401
- 403
- 404
The user was added to the class.
The userId is missing, the memberType is not a known role, or the user is already a member of the class.
Missing or invalid API key.
The request is not authenticated with an API key, the API key's user does not own the instance, the user to add belongs to another instance, or the class is linked to an LMS and can only be managed from the LMS.
No class with that ID in the instance, or no user with that ID.