Tools reference¶
34 tools: 21 read and 13 write. Clients discover them with tools/list. Disabled tools, write tools while write mode is off, and tools whose scope the user or token cannot use are not listed. Errors inside a tool come back as a tool error with a short message (for example Course not found.).
Read · General¶
| Tool | Moodle permission |
|---|---|
site_info |
— |
search_courses |
Course visibility for the user |
get_course_structure |
Access to the course |
list_participants |
moodle/course:viewparticipants |
list_activities |
Access to the course |
get_grades_summary |
moodle/grade:view; moodle/grade:viewall for averages and other users; hidden grades need moodle/grade:viewhidden |
get_task_status |
Only the user who queued the task, or a site administrator |
Read · Student¶
| Tool | Moodle permission |
|---|---|
get_my_deadlines |
Calendar action events for that user; activity visibility |
get_my_grades |
moodle/grade:view in each course |
get_my_progress |
Access to the course |
get_assignment_details |
mod/assign:view |
get_forum_posts |
mod/forum:viewdiscussion |
get_calendar_events |
Calendar visibility |
search_course_content |
Visible activities only |
Read · Teacher¶
| Tool | Moodle permission |
|---|---|
get_submissions_status |
mod/assign:grade (moodle/site:accessallgroups to see all groups) |
get_ungraded_work |
mod/assign:grade, mod/quiz:grade |
get_quiz_results |
mod/quiz:viewreports |
get_inactive_students |
moodle/course:viewparticipants and report/outline:view |
get_activity_completion_report |
report/progress:view |
get_course_logs_summary |
report/log:view |
get_forum_unanswered |
mod/forum:viewdiscussion |
Write¶
| Tool | Moodle permission |
|---|---|
create_course |
moodle/course:create in the category |
build_course |
New course: moodle/course:create in the category |
add_section |
moodle/course:update |
add_activity |
moodle/course:manageactivities and mod/<type>:addinstance |
create_quiz |
moodle/course:manageactivities and mod/quiz:addinstance |
add_quiz_questions |
mod/quiz:manage and moodle/question:add (moodle/question:managecategory to create a category) |
import_questions |
moodle/question:add (mod/quiz:manage to add them to a quiz) |
update_activity |
Moodle's normal activity update check (moodle/course:manageactivities); moodle/course:activityvisibility to change visible |
enrol_user |
enrol/manual:enrol |
create_group |
moodle/course:managegroups |
set_visibility |
moodle/course:visibility, moodle/course:sectionvisibility or moodle/course:activityvisibility, depending on the target |
delete_activity |
moodle/course:manageactivities |
delete_section |
moodle/course:update |