waterloo-learn-mcp
An MCP server that gives desktop AI apps access to your Waterloo LEARN courses, enabling listing courses, getting announcements, content, grades, and upcoming events through natural language.
README
waterloo-learn-mcp
MCP server exposing your Waterloo LEARN courses to AI apps. LEARN sits behind WatIAM + Duo, so auth is split out: you log in once in a real browser, the session is saved to auth.json, and the server runs headless off that until it expires.
auth.json and .env.local hold secrets. Both are gitignored — treat them like passwords.
Install
npm install
npx playwright install chromium
npm run build
npm run login # browser opens; sign in + approve Duo. Saves auth.json
Tools
| Tool | Args | Returns |
|---|---|---|
list_courses |
— | Course names + ou IDs |
get_announcements |
courseId |
Announcements (title, body, date, attachments) |
get_content |
courseId |
Content modules/topics with URLs |
get_topic_file |
courseId, topicId, pages? |
Lecture PDF/PPTX rendered as one image per slide (cap 25; pages like "4" or "2-6") |
get_grades |
courseId |
Grade items (grade, points, weight, feedback) |
get_assignments |
courseId |
Assignments with due dates, instructions, your submission status + files, released feedback |
get_upcoming |
courseId, daysAhead? |
Due dates / events (default 30 days) |
Connect to Claude Desktop
Add to ~/Library/Application Support/Claude/claude_desktop_config.json, then restart the app:
{
"mcpServers": {
"waterloo-learn": {
"command": "node",
"args": ["/absolute/path/to/waterloo-learn-mcp/dist/index.js"]
}
}
}
Local, no tunnel, no exposed session. Details: skills/connect-claude-desktop/SKILL.md.
Connect to a web chat (ChatGPT or Claude.ai)
ChatGPT and Claude.ai are cloud-hosted — they reach your server remotely over HTTPS, unlike Claude Desktop (local). This exposes one URL over Tailscale Funnel (free, no VPS, stable URL) that both apps share:
npm run setup:web # builds, enables Funnel, prints your connector URL + per-app steps
npm run autostart:web # optional: keep server running across reboots
It prints a URL like https://<device>.ts.net/mcp/<secret>. Add it as a custom connector with No Auth (neither app has an API-key field, so the secret rides in the path):
- ChatGPT → Settings → Connectors → Developer mode → Add custom connector → Server URL.
- Claude.ai → Settings → Connectors → "+" → name + URL (no Developer mode needed).
Details: skills/connect-web-chat/SKILL.md. (setup:chatgpt / autostart:chatgpt still work as aliases.)
The full URL is the password — anyone with it can read your LEARN data. Your laptop must be awake with the server running for the chat app to reach it.
After a reboot (web chat path)
setup:web is one-time. The connector URL, secret, Funnel config, and auth.json all persist. Only the server process stops on reboot:
- Ran
autostart:web→ nothing to do; it restarts itself on login. - Didn't →
npm run start:httpto bring the server back. (No need to re-run setup.)
Tailscale must be running for Funnel to work (the macOS app auto-starts on login by default).
Notes
list_coursesuses the enrollments API, falling back to homepage scraping. Other tools call D2L's REST API through the authenticated session.get_topic_filereturns slides as images so the model can read diagrams, not just text. PDFs need nothing extra; PowerPoint topics additionally need LibreOffice (brew install --cask libreoffice) for the PPTX→PDF step. Works in Claude (Desktop + Claude.ai) and ChatGPT.- "No valid LEARN session" (or tools failing after weeks) = session expired →
npm run loginagain. Independent of reboots. - Override with env vars:
LEARN_BASE_URL,LEARN_AUTH_FILE,PORT,LEARN_MCP_TOKEN.
Disclaimer
This is an unofficial, independent tool built for personal academic use. It is not affiliated with, endorsed by, or supported by the University of Waterloo, D2L, or any related entity. "Waterloo LEARN" and related marks belong to their respective owners.
The server acts on your behalf using your own credentials to access only your own course data — it accesses nothing you couldn't already see by logging into LEARN yourself. You are responsible for using it in accordance with the University of Waterloo's acceptable-use policies and LEARN's terms of service. Don't use it to access data that isn't yours, and don't share course content in ways that violate copyright or your instructors' wishes.
LEARN's internal APIs and page structure can change without notice, which may break this tool at any time. It is provided as-is, without warranty of any kind. AI models can also misread or hallucinate content — always verify grades, due dates, and other important information against LEARN directly. Use at your own risk.
Recommended Servers
playwright-mcp
A Model Context Protocol server that enables LLMs to interact with web pages through structured accessibility snapshots without requiring vision models or screenshots.
Magic Component Platform (MCP)
An AI-powered tool that generates modern UI components from natural language descriptions, integrating with popular IDEs to streamline UI development workflow.
Audiense Insights MCP Server
Enables interaction with Audiense Insights accounts via the Model Context Protocol, facilitating the extraction and analysis of marketing insights and audience data including demographics, behavior, and influencer engagement.
VeyraX MCP
Single MCP tool to connect all your favorite tools: Gmail, Calendar and 40 more.
graphlit-mcp-server
The Model Context Protocol (MCP) Server enables integration between MCP clients and the Graphlit service. Ingest anything from Slack to Gmail to podcast feeds, in addition to web crawling, into a Graphlit project - and then retrieve relevant contents from the MCP client.
Kagi MCP Server
An MCP server that integrates Kagi search capabilities with Claude AI, enabling Claude to perform real-time web searches when answering questions that require up-to-date information.
E2B
Using MCP to run code via e2b.
Neon Database
MCP server for interacting with Neon Management API and databases
Exa Search
A Model Context Protocol (MCP) server lets AI assistants like Claude use the Exa AI Search API for web searches. This setup allows AI models to get real-time web information in a safe and controlled way.
Qdrant Server
This repository is an example of how to create a MCP server for Qdrant, a vector search engine.