by vishalsachdev
This repository contains a Message Control Protocol (MCP) server implementation for interacting with the Canvas Learning Management System API. The server is designed to work with Claude Desktop and potentially other MCP clients.
Note: Recently refactored to a modular architecture for better maintainability. The legacy monolithic implementation has been archived.
The Canvas MCP Server bridges the gap between Claude Desktop and Canvas Learning Management System, providing educators with an intelligent interface to their Canvas environment. Built on the Message Control Protocol (MCP), it enables natural language interactions with Canvas data while maintaining FERPA compliance through advanced privacy protection features.
Recently Implemented: Complete FERPA compliance through systematic data anonymization across all tools.
The Problem: Using AI tools with student data creates FERPA compliance risks and privacy violations.
What We Built:
ENABLE_DATA_ANONYMIZATION=true
)All student data is anonymized before it reaches AI systems, ensuring complete privacy protection while maintaining full educational functionality. 8 core tools now include comprehensive privacy protection with production-ready error handling.
The fastest way to get started is with our automated installer:
# Clone the repository git clone https://github.com/vishalsachdev/canvas-mcp.git cd canvas-mcp # Run the automated installer python scripts/install.py
The installer will:
uv
package managerIf you prefer manual setup:
# Install uv package manager (faster than pip) pip install uv # Install the package uv pip install -e .
# Copy environment template cp env.template .env # Edit with your Canvas credentials # Required: CANVAS_API_TOKEN, CANVAS_API_URL
Get your Canvas API token from: Canvas ā Account ā Settings ā New Access Token
Add to ~/Library/Application Support/Claude/claude_desktop_config.json
:
*Configuration content*
Test your setup:
# Test Canvas API connection canvas-mcp-server --test # View configuration canvas-mcp-server --config # Start server (for manual testing) canvas-mcp-server
The Canvas MCP Server provides a comprehensive set of tools for interacting with the Canvas LMS API. These tools are organized into logical categories for better discoverability and maintainability.
š View Full Tool Documentation for detailed information about all available tools.
This MCP server works seamlessly with Claude Desktop:
Modern Python package structure following 2025 best practices:
canvas-mcp/
āāā pyproject.toml # Modern Python project config
āāā env.template # Environment configuration template
āāā src/
ā āāā canvas_mcp/ # Main package
ā āāā __init__.py # Package initialization
ā āāā server.py # Main server entry point
ā āāā core/ # Core utilities
ā ā āāā config.py # Configuration management
ā ā āāā client.py # HTTP client
ā ā āāā cache.py # Caching system
ā ā āāā validation.py # Input validation
ā āāā tools/ # MCP tool implementations
ā ā āāā courses.py # Course management
ā ā āāā assignments.py # Assignment tools
ā ā āāā discussions.py # Discussion tools
ā ā āāā rubrics.py # Rubric tools
ā ā āāā other_tools.py # Misc tools
ā āāā resources/ # MCP resources
āāā scripts/
ā āāā install.py # Automated installation
āāā docs/ # Documentation
Built with current Python ecosystem best practices:
src/
layout with pyproject.toml
uv
package manager with locked dependenciespyproject.toml
scriptshttpx
client with connection pooling and rate limitingModern Python packages (see pyproject.toml
):
fastmcp
: MCP server frameworkhttpx
: Async HTTP clientpython-dotenv
: Environment configurationpydantic
: Data validation and settingspython-dateutil
: Date/time handlingmypy
support for type safetyruff
and black
for formatting and lintingFor contributors, see the Development Guide for detailed architecture and contribution guidelines.
If you encounter issues:
.env
file, virtual environment path, and dependencies.env
file to version controlConfigure privacy settings in your .env
file:
# Enable automatic student data anonymization (recommended) ENABLE_DATA_ANONYMIZATION=true # Debug anonymization process (for testing) ANONYMIZATION_DEBUG=true
Contributions are welcome! Feel free to:
This project is licensed under the MIT License - see the LICENSE file for details.
Created by Vishal Sachdev
No version information available
0 contributors