quiz-docente-mcp
Server Configuration
Describes the environment variables required to run the server.
| Name | Required | Description | Default |
|---|---|---|---|
| MOODLE_URL | No | URL of the Moodle site. | https://www.ferrarisacireale.edu.it/moodle |
| MOODLE_MCP_DIR | No | Directory where the session and login browser profile are saved. | ~/.moodle-mcp |
| MOODLE_READ_ONLY | No | Set to 1 to expose only read-only tools. | |
| MOODLE_AUTO_LOGIN | No | Controls automatic login: 1 opens login at startup and when the session expires; 'ondemand' only when needed by a tool; 0 never. | 1 |
| MOODLE_BROWSER_PATH | No | Path to chrome.exe or msedge.exe if the browser is not found automatically. | |
| MOODLE_LOGIN_TIMEOUT_MS | No | Maximum wait time for login, in milliseconds. | 300000 |
Instructions
Guidance the server publishes about itself, which clients place ahead of the tool catalog so the model reads it before choosing anything.
Manage quizzes on the Moodle site https://www.ferrarisacireale.edu.it/moodle as the signed-in teacher. This server is meant for educational purposes only: a teacher managing the quizzes of their own courses. Identifiers: courseid = course id; cmid = course-module id of a quiz (the id in mod/quiz/view.php?id=...); slot ids come from moodle_get_quiz; question ids and category ids from the question-bank tools. When the Moodle session is missing or expired the server opens a browser window on the Moodle login page by itself: tell the user to sign in there; the tool call continues once they are logged in. moodle_login forces a new login. Questions can be created from structured JSON (moodle_create_questions) or from GIFT / Moodle XML (moodle_import_questions). Quizzes that already have student attempts cannot have questions added/removed. There are no tools to delete quizzes or questions: deletions are done by the teacher manually in Moodle.
Capabilities
Features and capabilities supported by this server
Protocol revision2025-11-25
| Capability | Details |
|---|---|
| tools | {
"listChanged": true
} |
Tools
Functions exposed to the LLM to take actions
| Name | Description |
|---|---|
| moodle_loginA | Opens a browser window on the Moodle login page; the user signs in (reCAPTCHA) and the session is saved for the next calls. Normally not needed: the server opens the login window by itself when the session is missing or expired. Blocks until the login completes or times out. |
| moodle_statusA | Checks whether the saved Moodle session is valid and who is signed in. |
| moodle_list_coursesC | Courses the user is enrolled in (id, name, category). |
| moodle_list_sectionsB | Sections (topics) of a course with their numbers, needed to choose where to create a quiz. |
| moodle_list_quizzesB | All quizzes in a course with cmid, visibility and section. |
| moodle_get_quizC | Quiz structure (slots with slot id, page, question id, name, type, mark), totals, editability, plus the main settings. |
| moodle_get_quiz_settingsB | All quiz settings (timing, attempts, grading, layout, behaviour, review options, visibility). include_raw=true also returns every raw form field. |
| moodle_get_quiz_gradesB | Overview report: each attempt with state, times, total grade and per-question marks, plus attempt ids for moodle_get_attempt_review. |
| moodle_get_quiz_responsesC | Responses report: the answer each student gave to each question (optionally with the right answer and question text). |
| moodle_get_attempt_reviewA | Detailed review of a single attempt: per question text, answer given, state, mark, feedback, whether manual grading is needed. |
| moodle_get_quiz_statisticsC | Statistics report (facility index, discrimination, etc.) of a quiz. |
| moodle_list_question_categoriesB | Question categories of the course (or quiz) question bank with ids and question counts. |
| moodle_list_questionsC | Questions of one category: id, name, type, status, version, usage count. |
| moodle_get_questionB | Full definition of a question (text, answers, fractions, feedback, settings) as Moodle XML. Embedded images are omitted unless include_files=true. |
| moodle_export_questionsB | Exports all questions of a category in GIFT (compact, readable) or Moodle XML (complete). |
| moodle_create_quizA | Creates a new quiz in a course section. New quizzes are hidden by default (visible=false) unless visible=true is passed. Returns the new cmid. |
| moodle_update_quiz_settingsC | Changes quiz settings; only the given fields are modified. Returns the settings after saving. |
| moodle_add_questions_to_quizB | Adds existing question-bank questions to a quiz (at the end, or to a given page). |
| moodle_add_random_questionsB | Adds N random-question slots drawing from a question category (each student gets different questions). |
| moodle_remove_quiz_slotsA | Removes slots from a quiz (the questions stay in the question bank). Use slot ids from moodle_get_quiz. |
| moodle_set_slot_markC | Sets the maximum mark of one quiz slot. |
| moodle_move_quiz_slotB | Moves a slot after another slot (after_slot_id) or to the beginning (after_slot_id omitted). |
| moodle_set_quiz_max_gradeB | Sets the maximum grade of the quiz (e.g. 10), rescaling the sum of marks. |
| moodle_repaginate_quizB | Re-paginates the quiz with N questions per page (0 = all on one page). |
| moodle_create_question_categoryC | Creates a question category (optionally under a parent category). |
| moodle_create_questionsA | Creates one or more questions in a question-bank category from structured definitions (multichoice, truefalse, shortanswer, numerical, essay, match, description). Returns the new question ids. |
| moodle_import_questionsA | Imports questions from text in GIFT, Moodle XML, Aiken, missing-word or Cloze (multianswer) format into a category. Supports every question type. Returns the new question ids. |
| moodle_update_questionB | Edits an existing question (Moodle saves it as a new version). Only the given fields change. "answers" replaces the whole answer list (multichoice/shortanswer/numerical); "correct" is for truefalse. |
| moodle_grade_attempt_questionB | Manually sets the mark (and optional comment) of one question in a student attempt, e.g. essay questions. |
Prompts
Interactive templates invoked by user choice
| Name | Description |
|---|---|
No prompts | |
Resources
Contextual data attached and managed by the client
| Name | Description |
|---|---|
No resources | |
TDQS
Scored across 29 tools
Most tools have crisply separated purposes: quiz structure vs settings vs grades vs responses vs statistics vs attempt review are clearly delineated, as are the slot-manipulation tools. The main overlaps are moodle_create_questions vs moodle_import_questions (both create questions, differing only in input format) and moodle_get_quiz vs moodle_get_quiz_settings, but the descriptions make the boundary reasonably clear.
Every tool follows the same moodle_verb_noun snake_case pattern with a consistent server prefix (moodle_get_quiz, moodle_list_questions, moodle_create_quiz, moodle_set_slot_mark). Verb choice is predictable by intent: list_* for enumeration, get_* for single-resource detail, create/update/remove/add/move/set for mutations.
At 29 tools the surface is heavy and sits above the comfortable range, though the breadth follows from a genuinely large domain (quizzes, slots, question bank, grading, reports). Almost every tool maps to a distinct Moodle operation, so the size is defensible, but several could be consolidated (e.g. get_quiz/get_quiz_settings, create/import questions).
Read and authoring coverage is strong across quizzes, slots, questions and grading, but destructive lifecycle operations are entirely absent: no delete_quiz, delete_question, delete_question_category, or delete/duplicate quiz, and no enrollment/participant listing. These gaps will force agents to fall back on the Moodle web UI for common cleanup tasks.