Open Source MCP Server

AI meets Canvas LMS

Canvas MCP gives AI assistants direct access to your Canvas LMS courses. Grade assignments, track progress, manage content, and communicate with students — all through natural language.

92
MCP Tools
8
Agent Skills
307
Tests
99.7%
Token Savings

Four personas, one server

Canvas MCP serves different needs depending on who you are. The same server adapts to students, educators, learning designers, and developers.

S

Students

Track upcoming assignments, check submission status, view grades, and manage peer reviews. 5 self-service tools that use Canvas "self" endpoints — you only see your own data.

5 tools
E

Educators

Grade assignments with rubrics, send targeted messages, analyze peer review completion, manage discussions, and run automated follow-up campaigns. Bulk grade 90+ submissions in one call.

50+ tools
D

Learning Designers

Audit course quality, scan for WCAG accessibility violations, scaffold complete course structures from specs, and verify publishing state across modules.

4 tools + 3 skills
V

Developers

Execute custom TypeScript in a sandboxed environment for bulk operations with 99.7% token savings. Add custom tools, create skills, deploy to your own infrastructure.

3 tools + Code API

Key innovations

T

TypeScript Sandbox

Write TypeScript that runs locally with Canvas credentials. Data stays on the server — only results enter the AI context window. Saves 99.7% of tokens on bulk operations.

P

FERPA Compliance

Three-layer privacy model: PII redaction in logs, student data anonymization in responses, and structured audit trails. Student names become consistent anonymous IDs.

H

Zero-Install Setup

Run npx canvas-mcp setup and answer 3 questions. The wizard configures your MCP client to connect to the hosted server. No Python, no dependencies.

System Architecture

Canvas MCP is organized into 5 capability layers. Each layer builds on the one below, enabling progressively more sophisticated operations.

0

Transport Layer

The connection between AI clients and the server. Two modes: local stdio for single-user, HTTP for multi-tenant hosting. The HTTP transport uses ContextVar-based per-request credential isolation.

stdio JSON-RPC Streamable HTTP CanvasCredentialMiddleware ContextVar isolation nginx + Cloudflare
1

Core Infrastructure

Shared utilities every tool depends on. The HTTP client handles all outbound requests with retry, rate limiting, and a concurrency semaphore. The validation decorator automatically coerces MCP tool parameters to the correct Python types.

HTTP Client (httpx) Course Cache @validate_params Config (.env) FERPA Anonymization Audit Logger PII Logger Date Utils File Validation
2

MCP Tools (92 registered)

The primary interface surface. 58 read tools, 27 write tools, 5 local-only tools, and 2 disabled tools (Canvas API bugs). Organized by Canvas entity type with progressive disclosure patterns.

Courses (3) Assignments (8) Discussions (14) Modules (8) Pages (9) Rubrics (11) Messaging (8) Files (3) Accessibility (4) Student (5) Analytics (9) Code Exec (3) Utility (4)
3

Composite Operations

Tools and systems that orchestrate multiple Layer 2 calls. The peer review follow-up campaign runs analytics, filters students, and sends targeted messages in one tool call. The TypeScript code API enables custom bulk operations.

Peer Review Campaign Course Structure Criteria-Based Deletion Bulk Grade TS bulkGradeDiscussion
4

Agent Skills (8 workflows)

Multi-step workflows that combine tools with decision logic. Distributed via skills.sh and usable as slash commands in 40+ AI coding agents. Each skill is a procedural guide that an AI follows step-by-step.

Morning Check Week Plan Bulk Grading Discussion Facilitator Peer Review Manager Course QC Accessibility Auditor Course Builder
5

Custom Extensions

User-defined compositions built on all layers below. Write TypeScript for custom bulk operations, create skills for repeatable workflows, add MCP resources, or deploy with institutional configuration overlays.

Custom TypeScript Custom Skills MCP Resources Config Overlays Institutional Deployment

Security Model

Three-layer privacy architecture designed for FERPA compliance in educational environments.

1

Transport Masking

All log output automatically redacts PII fields (names, emails, login IDs). Numeric IDs truncated to last 4 characters. Output goes to stderr only — stdout reserved for MCP protocol.

2

Data Anonymization

Student names replaced with consistent SHA-256 pseudonyms (Student_a8f7e23d). Emails removed. Real user IDs preserved for functional operations. Configurable per deployment.

3

Audit Trail

Structured JSON-lines audit log with rotating file handler. Endpoint paths sanitized. Code execution logged by SHA-256 hash. ISO 8601 timestamps. Off by default, enable for compliance.

System Knowledge Graph

Interactive visualization of how every component connects. Hover nodes for details. Click and drag to explore. Filter by category to focus on specific layers.

System
Transport
Core
Tools
Code API
Skills
Personas
Deploy
Security

All 92 Tools

Every MCP tool organized by domain. Read tools query Canvas data. Write tools create, update, or delete content. All tools accept Canvas IDs, course codes, or SIS IDs.

Student Tools

5 tools
ToolPurposeType
get_my_upcoming_assignmentsAssignments due in next N days with submission statusRead
get_my_submission_statusSubmitted vs. missing across coursesRead
get_my_course_gradesCurrent grades for all active coursesRead
get_my_todo_itemsCanvas TODO listRead
get_my_peer_reviews_todoPending peer reviews to completeRead

Course Management

3 tools
ToolPurposeType
list_coursesList enrolled courses (refreshes identifier cache)Read
get_course_detailsCourse info: dates, timezone, syllabus, blueprintRead
get_course_content_overviewPages summary + module structure + syllabusRead

Assignments & Submissions

8 tools
ToolPurposeType
list_assignmentsAll assignments with due dates, pointsRead
get_assignment_detailsFull assignment info with descriptionRead
list_submissionsStudent submissions with scoresRead
get_assignment_analyticsPerformance stats: mean, median, missing studentsRead
create_assignmentCreate with full validation (grading, dates, peer reviews)Write
update_assignmentPartial update (only sends changed fields)Write
assign_peer_reviewManually assign reviewer to revieweeWrite
list_peer_reviewsPeer review assignments per submissionRead

Discussions & Announcements

14 tools
ToolPurposeType
list_discussion_topicsDiscussion forums with optional announcementsRead
get_discussion_topic_detailsSingle discussion with statisticsRead
list_discussion_entriesAll entries with replies (3-method fallback)Read
get_discussion_entry_detailsSingle entry with replies (4-method fallback)Read
get_discussion_with_repliesEntries + replies in tree formatRead
post_discussion_entryNew top-level discussion postWrite
reply_to_discussion_entryReply to an existing entryWrite
create_discussion_topicCreate new discussion forumWrite
list_announcementsCourse announcementsRead
create_announcementPost a course announcementWrite
delete_announcementDelete with title confirmationWrite
bulk_delete_announcementsBatch delete by ID listWrite
delete_announcement_with_confirmationSafe delete with title match + dry runWrite
delete_announcements_by_criteriaFilter-then-delete (dry_run default)Write

Modules & Structure

9 tools
ToolPurposeType
list_modulesCourse modules with item summariesRead
get_course_structureFull module/items tree as JSON (one call)Read
create_moduleNew module with prerequisites, unlock dateWrite
update_moduleUpdate module settingsWrite
delete_moduleRemove module (content preserved)Write
add_module_itemAdd content to module (type-specific validation)Write
update_module_itemUpdate item or move between modulesWrite
delete_module_itemRemove item from moduleWrite
list_module_itemsItems in a specific moduleRead

Rubrics & Grading

11 tools
ToolPurposeType
list_all_rubricsAll rubrics in a course with criteriaRead
list_assignment_rubricsRubric summary for an assignmentRead
get_rubric_detailsFull rubric with criteria and ratingsRead
get_assignment_rubric_detailsAssignment-specific rubric detailsRead
get_submission_rubric_assessmentRubric scores for a student submissionRead
grade_with_rubricGrade one submission with rubric criteriaWrite
bulk_grade_submissionsConcurrent grading with batching + dry runWrite
associate_rubric_with_assignmentLink rubric to assignmentWrite
delete_rubricDelete rubric and associationsWrite
create_rubricDisabled — Canvas API returns 500Disabled
update_rubricDisabled — Canvas does full replacementDisabled

Messaging & Communication

8 tools
ToolPurposeType
send_conversationSend Canvas inbox message (form data required)Write
list_conversationsList by scope (unread/starred/sent/all)Read
get_conversation_detailsSingle conversation with all messagesRead
get_unread_countCount of unread conversationsRead
mark_conversations_readBulk mark conversations as readWrite
send_bulk_messages_from_listTemplated messages to multiple recipientsWrite
send_peer_review_remindersAutomated peer review remindersWrite
send_peer_review_followup_campaignFull pipeline: analytics + filter + sendWrite

Get Started

Two paths: zero-install via the hosted server, or local installation for full control and FERPA compliance.

Path A: Zero-Install (Hosted Server)

1

Get your Canvas API token

In Canvas, go to Account > Settings > New Access Token. Copy the token — you will not see it again.

2

Run the setup wizard

One command configures your AI coding client. Supports Claude Desktop, Codex, Cursor, Windsurf, VS Code, and Claude Code.

npx canvas-mcp setup
3

Start using Canvas tools

Restart your AI client and ask natural language questions about your courses.

# Ask your AI assistant: "What assignments are due this week?" "Show me the rubric for Assignment 5" "Grade these 50 submissions using the rubric"

Path B: Local Installation

1

Install the package

pip install canvas-mcp # or with uv: uv pip install canvas-mcp
2

Configure credentials

Create a .env file with your Canvas API token and institution URL.

CANVAS_API_TOKEN=your_token_here CANVAS_API_URL=https://your-school.instructure.com/api/v1 ENABLE_DATA_ANONYMIZATION=true
3

Add to your MCP client

Add the server to your MCP client configuration.

{ "mcpServers": { "canvas": { "command": "canvas-mcp-server" } } }
4

Install agent skills (optional)

Add 8 pre-built workflows for common tasks.

npx skills add vishalsachdev/canvas-mcp

Common Workflows

Step-by-step workflows for each persona. Click to expand and see the exact tools used at each step.

S

Student: Weekly Planning

Check upcoming work: get_my_upcoming_assignments(days=7) — shows assignments due with submission status

Verify submissions: get_my_submission_status() — submitted vs. missing across all courses

Check peer reviews: get_my_peer_reviews_todo() — pending reviews to complete

View grades: get_my_course_grades() — current standing in each course

E

Educator: Morning Health Check

Scan submissions: list_assignments + get_assignment_analytics for the past 7 days

Identify at-risk students: Missing 2+ assignments or declining scores

Check peer reviews: get_peer_review_completion_analytics — who hasn't started

Send reminders: send_conversation to students needing attention

E

Educator: Bulk Grading (30+ submissions)

Get the rubric: get_assignment_rubric_details — review criteria and point values

Choose approach: 1-9 submissions: grade_with_rubric. 10-29: bulk_grade_submissions. 30+: execute_typescript

Dry run first: Always pass dry_run=true to preview grades before committing

Execute: Confirm results, then run with dry_run=false

D

Learning Designer: Course QC

Get structure: get_course_structure — full module/items tree with stats

Check content: list_assignments + list_pages — verify all content exists

Verify publishing: Flag unpublished content that should be live

Scan accessibility: scan_course_content_accessibility for WCAG violations

Report: Prioritized findings by severity

V

Developer: Custom Bulk Operation

Discover API: search_canvas_tools("grading", "signatures") or list_code_api_modules

Write TypeScript: Import from the Code API library, write custom logic

Execute in sandbox: execute_typescript(code) — runs in isolated environment

Results only: Data stays on server. Only the summary enters your AI context window.

Extend & Customize

Canvas MCP is designed for extension. Add new tools, create custom skills, write TypeScript for bulk operations, or deploy with institutional configuration.

01 Add a New MCP Tool

Create or edit a tool file, add decorators, register, and test.

# 1. Create tool in src/canvas_mcp/tools/my_tools.py @mcp.tool() @validate_params async def my_custom_tool(course_identifier: Union[str, int]) -> str: course_id = await get_course_id(course_identifier) result = await make_canvas_request("get", f"/courses/{course_id}/custom") return json.dumps(result) # 2. Register in tools/__init__.py # 3. Add tests in tests/tools/ # 4. Update tools/README.md, AGENTS.md, TOOL_MANIFEST.json

02 Create an Agent Skill

Skills are markdown files with YAML frontmatter that describe multi-step workflows for AI agents.

# skills/my-skill/SKILL.md --- name: my-canvas-skill description: Custom Canvas workflow for [purpose] --- ## Steps 1. Fetch data: list_assignments(course_identifier) 2. Analyze: Look for [criteria] 3. Act: send_conversation(recipients, subject, body) 4. Report: Format results as markdown

03 Write Custom TypeScript

The Code API provides a typed Canvas client for bulk operations. Data stays on the server.

// Runs via execute_typescript MCP tool import { bulkGrade } from './canvas/grading/bulkGrade.js'; import { listSubmissions } from './canvas/assignments/listSubmissions.js'; const result = await bulkGrade({ courseIdentifier: "CS101", assignmentId: "67890", gradingFunction: (submission) => ({ grade: submission.score >= 70 ? "pass" : "fail" }) }); console.log(JSON.stringify(result));

04 Institutional Deployment

Deploy with configuration overlays for baseline, public, or enterprise environments.

# Start with the base template cp env.template .env # Layer on institutional config cat config/overlays/enterprise.env >> .env # Deploy to VPS bash deploy/setup.sh

Project Structure

Where to find everything and what to modify for different types of changes.

Add a new Canvas tool

src/canvas_mcp/tools/ — create or edit tool file
tools/__init__.py — register
tests/tools/ — add tests
tools/README.md — document

Modify privacy behavior

core/anonymization.py — data masking rules
core/client.py — endpoint matching
core/audit.py — audit trail config
.env — toggle settings

Add TypeScript bulk ops

src/canvas_mcp/code_api/canvas/ — add module
code_api/canvas/index.ts — re-export
code_api/README.md — usage guide

Deploy to new server

deploy/setup.sh — clone + configure
deploy/canvas-mcp.service — systemd unit
deploy/nginx-canvas-mcp.conf — reverse proxy
config/overlays/ — environment tier