MCP prompts¶
Besides tools, the server answers prompts/list and prompts/get. initialize and server/discover advertise the prompts capability. A prompt returns one user message with step-by-step guidance; its text is the matching skill, with your arguments filled in. All arguments are optional strings (up to 500 characters). An argument you do not send reads not specified.
| Prompt | Title | Arguments | Based on |
|---|---|---|---|
design_course |
Design a course | subject, audience, length |
moodle-course-design |
create_quiz_from_content |
Create a quiz from content | courseId, source, cmid, questionCount, questionTypes |
moodle-course-design |
grade_assignment |
Grade an assignment | cmid, userId, focus |
moodle-grading |
design_course¶
How to design and build a Moodle course with these tools, then check the structure.
subject: what the course teaches.audience: who the students are.length: how long the course is, for example 8 weeks.
create_quiz_from_content¶
Draft a quiz from a topic or an existing activity, show it, then save after confirmation.
courseId: course id or short name, if it is already known.source: topic or content to base the questions on.cmid: optional course module id of the page, label or resource to read.questionCount: how many questions to write.questionTypes: question types to use, for example multichoice and truefalse.
grade_assignment¶
How to read a submission and propose a grade. Nothing is saved until the teacher confirms. See Grading with dryRun.
cmid: assignment course module id, if it is already known.userId: student user id, if it is already known.focus: what the teacher asked you to look for.
Example¶
{"jsonrpc": "2.0", "id": 3, "method": "prompts/get",
"params": {"name": "design_course", "arguments": {"subject": "Intro to statistics", "audience": "First-year students", "length": "8 weeks"}}}
An unknown prompt name or argument returns an error.