moodle-mcp-serverSAFE
Open-source MCP server that connects AI agents to Moodle LMS data through Moodle Web Services.
Overview
From the repository's own README, as read at the audited commit. Badges and raw HTML are left out.
Ask your Moodle instance anything. Get structured answers in seconds.
moodle-mcp-server is an open-source MCP (Model Context Protocol) server that connects AI agents directly to Moodle's Web Services API. It is the Moodle connector behind CSMediaPro's broader Agentic Query Layer (AQL) work.
Instead of learning report builders, writing SQL, or exporting CSVs, you ask questions in plain English — the AI agent queries your LMS and returns structured data.
Project home: https://csmediapro.com/products/moodle-mcp-server npm package: https://www.npmjs.com/package/moodle-mcp-server-aql MCP Registry: io.github.csmediapro/moodle-mcp-server-aql
Features
- Core query tools — course catalog, user enrollment, assignments, category navigation, site metadata, user lookup, and cache management
- Premium reporting plugins — optional tools such as course completion reports and recent activity can be attached through the plugin runtime
- LLM-agnostic — works with Claude, GPT, Gemini, Ollama, or any MCP-compatible AI client
- Zero LMS modification — uses Moodle's existing Web Services API, no plugin installation required
- Compliance-ready data handling — secure, efficient data processing with privacy by design
- Read-only — never modifies Moodle data, safe for production
- Plugin-extensible — drop new tool modules into a directory; tools and optional agent routing hints auto-register at runtime
Quick Start
Prerequisites
- Node.js 20+
- A Moodle instance with Web Services enabled
- A Moodle API token (Site administration → Plugins → Web services → Manage tokens)
Use With An MCP Client
Most users launch the server through an MCP client such as Claude Desktop:
{
"mcpServers": {
"moodle-mcp-server-aql": {
"command": "npx",
"args": ["-y", "moodle-mcp-server-aql"],
"env": {
"MOODLE_URL": "https://your-moodle-instance.exa6c893815aee0OBSERVED · 2026-10-11Connect
Built from this server's own package name, version and transport as found in its source — not copied from anyone's documentation, so it cannot drift against a page we do not control. Replace the environment placeholders with a token scoped to the least it needs.
claude mcp add moodle-mcp-server-aql --env MOODLE_TOKEN=${MOODLE_TOKEN} -- npx -y [email protected]Exposed tools (8)
8 read · 0 write · 0 destructive.
| Tool | Risk | Description |
|---|---|---|
Category | read | |
Duplicate | read | |
Healthcare | read | |
get_recent_activity | read | Show recent course engagement |
hello_plugin | read | Return a simple plugin test payload |
list_courses | read | List courses |
test_plugin_tool | read | Test tool |
zod4_progress_report | read | Build a progress report. |
Trust audit
SAFEgrade B · trust 89/100 Nothing in the source contradicts what it says it does. Grade A is reserved for packages that have also passed the behavioural sandbox.
| Layer | What it checks | Result |
|---|---|---|
| L0 | Provenance & inventory | PASS |
| L1 | Static analysis of the code | PASS |
| L2 | Instruction surface (what it tells the agent) | PASS |
| L3 | Class-specific surface | PASS |
| L4 | Behavioural (sandbox) | SKIPPED |
What the source does
- Filesystem
- none-observed
- Network
- declared (5 observation(s))
- Shell
- none-observed
- Dependencies
- not all pinned
- Secrets in source
- none-found
Findings (5)
const patternId = createHash("sha1").update(patternSeed).digest("hex").slice(0, 12);const examplePath = resolve(process.cwd(), "../../examples/plugins/hello-plugin");
typescript
@modelcontextprotocol/sdk, @tanstack/react-table, lucide-react, next, react, react-dom, zod, @tailwindcss/postcss
@modelcontextprotocol/sdk, dotenv, zod, @types/node, typescript
Gates applied: no_behavioural_pass.
6c893815aee0full audit observations/trust-audit/mcp-server/csmediapro__moodle-mcp-server.json · Report an issue / request a re-scanAudit history
Every audit this server has had. A grade with a past is a grade somebody is still checking.
| Date | Source | Verdict | Grade | Score | Change |
|---|---|---|---|---|---|
| 2026-10-11 | 6c893815aee0 | SAFE | B | 89 | first audit |
Questions
What is the moodle-mcp-server MCP server?
Open-source MCP server that connects AI agents to Moodle LMS data through Moodle Web Services.
What tools does moodle-mcp-server expose?
8 in total: 8 read-only, 0 that write, and 0 that can delete or overwrite. Every one is listed on this page with its risk.
Is moodle-mcp-server safe to connect to an agent?
The audit found nothing in the source that contradicts what it says it does, and graded it B (89/100). Grade A is held back for packages that have also passed a sandboxed behavioural run, which is why a clean server reads B.
What credentials does moodle-mcp-server need?
It reads MCP_AGENT_EDGE_TOKEN, MOODLE_TOKEN and OLLAMA_API_KEY from the environment. Give it a token scoped to the least it needs — an agent that can be talked into calling a tool can be talked into calling it with your credentials.
How does moodle-mcp-server run?
It speaks stdio and streamable-http, so it runs as a local process your client starts. It is published on npm as moodle-mcp-server-aql at 0.1.7.
How current is this page?
The grade is for one exact copy of the source (6c893815aee0), read on 2026-10-11. The repository is watched and re-audited when it changes.