- Canvas MCP Server
Canvas MCP Server
Canvas MCP Server
A Model Context Protocol (MCP) server for interacting with the Canvas LMS API.
Overview
This MCP server provides tools for interacting with the Canvas Learning Management System (LMS) API, allowing AI assistants to perform operations on Canvas courses, assignments, users, and more.
Features
- Full access to Canvas LMS API functionality
- Authentication via Canvas API tokens
- Support for all Canvas resources and endpoints
- Organized tools by resource category
Prerequisites
- Node.js (v16 or higher)
- npm (v7 or higher)
- Canvas API access token (generated from Canvas settings)
- Canvas course URL
Installation
-
Clone this repository:
git clone https://github.com/yourusername/canvas-mcp-server.git cd canvas-mcp-server -
Install dependencies:
npm install -
Create a
.envfile in the root directory with your Canvas API credentials:CANVAS_API_TOKEN=your_canvas_api_token CANVAS_API_URL=https://your-institution.instructure.com/api/v1 MCP_SERVER_NAME=canvas-mcp
Usage
-
Build the server:
npm run build -
Start the server:
npm start -
Connect to the server using an MCP-compatible client.
Available Tools
The Canvas MCP Server provides tools for interacting with various Canvas resources, including:
- Courses
- Users
- Assignments
- Quizzes
- Modules
- Pages
- Files
- Discussions
- Announcements
- Grades
- And many more...
Each tool is organized by resource category and follows the Canvas API naming conventions.
Authentication
To use this MCP server, you need to generate an API token from your Canvas account:
- Log in to your Canvas account
- Go to Account > Settings
- Scroll down to the "Approved Integrations" section
- Click "New Access Token"
- Enter a purpose and expiration date
- Click "Generate Token"
- Copy the token and add it to your
.envfile
Development
To run the server in development mode with automatic reloading:
npm run dev
License
MIT