canvas::API method course users (public)
<instance of canvas::API> course users \ [ -search_term search_term ] [ -sort sort ] \ [ -enrollment_type enrollment_type ] \ [ -enrollment_role_id enrollment_role_id ] [ -include include ] \ [ -user_ids user_ids ] [ -enrollment_state enrollment_state ] \ [ -page page ] [ -per_page per_page ] [ -max_entries max_entries ] \ course_id
Defined in packages/xooauth/tcl/canvas-procs.tcl
Returns the paginated list of users in this course. And optionally the user's enrollments in the course. Details: https://canvas.instructure.com/doc/api/courses.html
- Switches:
- -search_term
(optional)- The partial name or full ID of the users to match and return in the results list.
- -sort
(optional)- When set, sort the results of the search based on the given Allowed values: username, last_login, email, sis_id
- -enrollment_type
(optional)- When set, only return users where the user is enrolled as this type. “student_view” implies include[]=test_student. This argument is ignored if enrollment_role is given. Allowed values: teacher, student, student_view, ta, observer, designer
- -enrollment_role_id
(optional)- When set, only return courses where the user is enrolled with the specified course-level role. This can be a role created with the Add Role API or a built_in role id with type 'StudentEnrollment', 'TeacherEnrollment', 'TaEnrollment', 'ObserverEnrollment', or 'DesignerEnrollment'.
- -include
(optional)- Optionally included content. Allowed values: enrollments, locked, avatar_url, test_student, bio, custom_links, current_grading_period_scores, uuid
- -user_ids
(optional)- If included, the course users set will only include users with IDs specified by the param.
- -enrollment_state
(optional)- When set, only return users where the enrollment workflow state is of one of the given types. “active” and “invited” enrollments are returned by default. Allowed values: active, invited, rejected, completed, inactive
- -page
(defaults to"1"
) (optional)- Return the nth page of the result set
- -per_page
(defaults to"10"
) (optional)- Return this number of entries per page
- -max_entries
(optional)- perform potentially multiple requests until the requested number of entries can be returned.
- Parameters:
- course_id
- Partial Call Graph (max 5 caller/called nodes):
- Testcases:
- No testcase defined.