Inspiration
In my time at university, which used an OpenLMS deployment based on Moodle, course content was often scattered and hard to dig through.
When OpenAI announced The WebMCP Challenge, the lightbulb went off. WebMCP moves tool execution right into the browser. So instead of fighting IT firewalls or using API keys, tools run inside the student's active browser session. I wanted to build a real WebMCP enablement plugin that turns standard Moodle course pages into active, agentic workspaces for both students and instructors, requiring no additional setup from them.
What it does
moodle-webmcp is a Moodle plugin that enables a number of useful WebMCP tools primarily for students, with some extra tools useful for course admins.
When you open course pages in ChatGPT's in-app browser or Chrome 146+, the plugin automatically declares structured AI tools directly on the web page to:
- Retrieve upcoming assignments and labs in chronological order
- Fetch relevant lecture summaries and course materials
- Generate an adaptive day-by-day study schedule based on available daily hours
- Critique a student's draft essay based on the assignment's official grading rubrics
How we built it
- Moodle Plugin Core: Developed
local_webmcpin PHP, integrating with Moodle's navigation hooks and AMD loader. - Deployment: Packaged Alpine Linux with PHP 8.3, Moodle 5.2.2, and SQLite3 on Render with persistent disk storage and a custom domain (
moodle-webmcp.akashgpt.me). - Development Tooling: Built and debugged the full stack with Codex and Chrome DevTools MCP.
Challenges we ran into
Minimal issues overall. The main hurdles involved working through Moodle-specific quirks and container setup, such as aligning with Moodle 5.x's public document root structure and ensuring database gradebook items were properly registered for assignment activities.
Accomplishments that we're proud of
- True Zero-Token Authentication: No API keys required. Tools inherit the student's existing authenticated web session and CSRF tokens automatically.
- Real, Live Moodle Environment: Built and deployed a full Moodle 5.2.2 LMS with seeded courses and working student/teacher roles rather than a static mockup.
- Practical Student Utility: Tools like adaptive study scheduling and rubric draft critique solve real, everyday student problems.
What we learned
- WebMCP vs. MCP: For web applications, in-browser execution is fundamentally more secure and accessible than backend daemons for everyday users.
- Defense-in-Depth in the Browser: Constraining tool inputs with strict JSON schemas and enforcing read-only boundaries protects against indirect prompt injection from untrusted course forums or scraped HTML.
- Moodle Plugin Internals: Deepened our understanding of Moodle's local plugin architecture, AMD modules, and database hooks.
What's next for moodle-webmcp
Expanding the number and types of tools available and integrating deeper with Moodle, including:
- Two-Way Action Tools with Confirmation Gates: Adding safe, human-confirmed write capabilities like
save_assignment_draftandpost_forum_reply. - Discussion Board & Workshop Integration: Extending WebMCP tools to summarize peer reviews and handle complex forum threads.
- Official Moodle Plugins Directory Release: Packaging
local_webmcpfor official submission to the Moodle Plugins Directory so LMS administrators worldwide can install it in one click.
Log in or sign up for Devpost to join the conversation.