Connect an assistant
Your endpoint
Every organization gets its own MCP endpoint, backed by its own Moodle, at a per-organization subdomain:
https://<your-org>.moodlemcp.com/mcp
You don't need to build the URL by hand: the panel shows it with a copy button in Organization → Moodle, and if you were provisioned from the plugin it also arrives by email alongside your key.
It speaks the standard MCP Streamable HTTP transport, so any compliant client can connect. Per-client instructions are in Client setup.
Two ways to authenticate
Pick whichever fits your client. If you use ChatGPT or Claude — the most common case — the first route is for you.
Sign in with your Moodle (OAuth) — recommended
This is the route for ChatGPT and Claude (both claude.ai in the browser and Claude Desktop), and the recommended one whenever your client supports it. Add the endpoint as a remote MCP connector; the first time you connect, a browser window opens — choose Sign in with your Moodle, log in on your own Moodle and approve.
From there the assistant is bound to your identity and roles in Moodle. There is no key to copy, store or email, so there is nothing that can leak. Re-authorizing, or revoking the underlying key, cuts the connection.
An MCP key
For clients that accept a token (Cursor, Claude Code, scripts, CI): send the key as a Bearer header. Owners and admins mint keys in Organization → Moodle → MCP keys, and the plugin can email one to each provisioned user. The value is shown once.
What happens on every call
Whichever route you took, the MCP server executes Moodle web-service functions with your stored token and roles. Authentication is checked on every request, so a revoked, suspended or expired credential is cut off on its very next call — there's no session to expire.
Every call, direct or routed through the gateway tools, goes through the same hardened Moodle client (SSRF-pinned connections, request timeout and a streaming response-size cap) and the same role gate. What a key may do is covered in Keys & permissions.
No client? Use the panel
The panel's AI chat uses the same tool catalog with no client setup at all, which is useful for confirming the connection works before you configure anything.