Moodle Mcp — independently scanned and version-tracked by SaferSkills.
SaferSkills independently audited Moodle Mcp (Agent Skill) and scored it 100/100 (green). The audit ran 55 deterministic rules across Security, Supply Chain, Maintenance, Transparency, and Community; it found 0 high-severity and 0 lower-severity findings. The full rule-by-rule trace and per-finding evidence are below. Free, methodology-open.
Findings & checks · 0 flagged
Every scanned point with the score it earned and what moved between them.
First recorded scan — no prior version to compare against.
The primary manifest — the file an agent reads to learn what this artifact does.
<div align="center">
Model Context Protocol integration for Moodle LMS
Features • Installation • Usage • Documentation • Contributing
</div>
A powerful Model Context Protocol (MCP) server that seamlessly integrates AI assistants with Moodle Learning Management System. Enable your AI assistant to access courses, retrieve educational content, download resources, and search through your learning materials.
🔌 Compatible with: Claude Desktop, and any MCP-compatible AI assistant
# Clone the repository
git clone <repository-url>
cd moodle-mcp
# Install dependencies
npm install
# Build the project
npm run buildcp .env.example .envMOODLE_URL=https://your-moodle-instance.com
MOODLE_USERNAME=your_username
MOODLE_PASSWORD=your_password
MOODLE_SERVICE=moodle_mobile_app # OptionalYour Moodle instance must have Web Services enabled. If you're a Moodle administrator:
moodle_mobile_app servicecore_webservice_get_site_infocore_enrol_get_users_coursescore_course_get_coursescore_course_get_contents# Production
node dist/index.js
# Development with auto-reload
npm run devAdd to your Claude Desktop configuration:
macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%/Claude/claude_desktop_config.json Linux: ~/.config/Claude/claude_desktop_config.json
{
"mcpServers": {
"moodle": {
"command": "node",
"args": ["/absolute/path/to/moodle-mcp/dist/index.js"],
"env": {
"MOODLE_URL": "https://your-moodle-instance.com",
"MOODLE_USERNAME": "your_username",
"MOODLE_PASSWORD": "your_password"
}
}
}
}| Tool | Description |
|---|---|
list_courses | List all enrolled courses with details |
get_course_contents | Retrieve complete course structure with sections and modules |
get_course_documents | Get all downloadable files from a course with direct URLs |
search_resources | Search for resources by name across all courses |
📚 Detailed documentation: See USAGE.md for comprehensive tool documentation
# Run the complete test suite
npm test| Method | Description |
|---|---|
| Automated Tests | npm test - Full test suite |
| MCP Inspector | Interactive web-based tool testing |
| Standalone Script | Direct API testing without MCP |
| Manual cURL | Test Moodle API endpoints directly |
📘 Full testing guide: See TESTING.md
moodle-mcp/
├── src/
│ ├── index.ts # MCP server implementation
│ ├── moodle-client.ts # Moodle API client
│ ├── types.ts # TypeScript type definitions
│ └── test.ts # Standalone test script
├── dist/ # Compiled JavaScript
├── .env.example # Environment template
├── README.md # This file
├── USAGE.md # Tool usage guide
└── TESTING.md # Testing guide# Build the project
npm run build
# Watch mode (auto-rebuild)
npm run watch
# Run tests
npm test
# Development mode
npm run dev1. Token Generation → POST /login/token.php
2. API Calls → GET/POST /webservice/rest/server.php?wstoken={token}
3. File Downloads → GET /pluginfile.php/...?token={token}core_webservice_get_site_info - User and site informationcore_enrol_get_users_courses - Enrolled courses listcore_course_get_courses - All available coursescore_course_get_contents - Course structure and resources<details> <summary><strong>Authentication Errors</strong></summary>
.env</details>
<details> <summary><strong>Permission Errors</strong></summary>
</details>
<details> <summary><strong>Connection Errors</strong></summary>
</details>
.env file to version controlContributions are welcome! Here's how you can help:
git checkout -b feature/amazing-feature)git commit -m 'Add amazing feature')git push origin feature/amazing-feature)Please ensure your PR:
This project is licensed under the MIT License - see the LICENSE file for details.
<div align="center">
Made with ❤️ for the Moodle and AI community
⭐ Star this repo if you find it helpful!
</div>
~30 seconds. Free. No account. Every finding cites a rule and a line of evidence.