@charlie.act7/canvas-mcp-server 1.1.0 → 1.1.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/plugin.json +11 -0
- package/.mcp.json +10 -0
- package/README.es.md +173 -0
- package/README.md +143 -87
- package/llms-install.md +46 -0
- package/package.json +5 -2
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
{
|
|
2
|
+
"name": "canvas-lms",
|
|
3
|
+
"description": "Canvas LMS integration for teachers. Manage courses, assignments, grades, quizzes, students, modules, and more — directly from Claude Code.",
|
|
4
|
+
"version": "1.1.0",
|
|
5
|
+
"author": {
|
|
6
|
+
"name": "CharlieCardenasToledo"
|
|
7
|
+
},
|
|
8
|
+
"homepage": "https://github.com/CharlieCardenasToledo/canvas-mcp-server",
|
|
9
|
+
"repository": "https://github.com/CharlieCardenasToledo/canvas-mcp-server",
|
|
10
|
+
"license": "MIT"
|
|
11
|
+
}
|
package/.mcp.json
ADDED
package/README.es.md
ADDED
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
# 🎓 Canvas LMS MCP Server
|
|
2
|
+
|
|
3
|
+
[](https://www.npmjs.com/package/@charlie.act7/canvas-mcp-server)
|
|
4
|
+
[](https://opensource.org/licenses/MIT)
|
|
5
|
+
|
|
6
|
+
**¡Lleva tu aula virtual de Canvas al siguiente nivel con Inteligencia Artificial!** 🚀
|
|
7
|
+
|
|
8
|
+
Este proyecto es un servidor de **Model Context Protocol (MCP)** para **Canvas LMS**. En palabras sencillas, funciona como un "traductor" o puente que permite a asistentes de Inteligencia Artificial (como Claude Desktop, Claude Code, Cursor, etc.) comprender y realizar acciones en tus cursos de Canvas mediante instrucciones en lenguaje natural.
|
|
9
|
+
|
|
10
|
+
---
|
|
11
|
+
|
|
12
|
+
## 🔍 ¿Cómo funciona?
|
|
13
|
+
|
|
14
|
+
Cuando utilizas este servidor, la comunicación fluye de la siguiente manera:
|
|
15
|
+
|
|
16
|
+
```mermaid
|
|
17
|
+
graph LR
|
|
18
|
+
User([Usuario]) -->|Instrucción en Lenguaje Natural| AI["Asistente de IA (Claude)"]
|
|
19
|
+
AI -->|Petición MCP| MCP["Canvas MCP Server"]
|
|
20
|
+
MCP -->|API REST (HTTPS)| Canvas["Canvas LMS"]
|
|
21
|
+
Canvas -->|Respuesta| MCP
|
|
22
|
+
MCP -->|Datos procesados| AI
|
|
23
|
+
AI -->|Respuesta amigable| User
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
1. **Tú le pides algo a Claude** (por ejemplo: *"Crea una tarea para el próximo viernes"*).
|
|
27
|
+
2. **Claude detecta la intención** y se comunica con el **Canvas MCP Server** enviándole los parámetros necesarios.
|
|
28
|
+
3. **El servidor realiza la llamada segura** a la API de Canvas.
|
|
29
|
+
4. **Canvas procesa la acción** y devuelve el resultado.
|
|
30
|
+
5. **Claude te confirma el éxito de la operación** en lenguaje natural.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 💡 ¿Qué puedes pedirle a tu Asistente?
|
|
35
|
+
|
|
36
|
+
¡Cualquier tarea administrativa o de consulta que harías manualmente en Canvas! Aquí tienes algunos ejemplos de lo que puedes pedirle:
|
|
37
|
+
|
|
38
|
+
### 📖 Para Consultar Información
|
|
39
|
+
* 💬 *"¿Qué cursos tengo activos este semestre?"*
|
|
40
|
+
* 💬 *"Muéstrame las entregas pendientes de calificar para la Tarea 2 en Biología."*
|
|
41
|
+
* 💬 *"¿Cuáles son los estudiantes del Grupo B de Química?"*
|
|
42
|
+
* 💬 *"¿Qué cuestionarios o exámenes tenemos programados para esta semana?"*
|
|
43
|
+
|
|
44
|
+
### ✍️ Para Administrar y Crear Contenido
|
|
45
|
+
* 💬 *"Crea una nueva tarea llamada 'Ensayo final de Historia' con fecha de entrega para el próximo viernes."*
|
|
46
|
+
* 💬 *"Publica un anuncio en el curso de Matemáticas avisando que la clase de mañana será virtual."*
|
|
47
|
+
* 💬 *"Crea un nuevo módulo llamado 'Semana 5: Introducción a React' en mi curso."*
|
|
48
|
+
|
|
49
|
+
### 💯 Para Calificar y Dar Retroalimentación
|
|
50
|
+
* 💬 *"Califica el ensayo de María con un 90/100 y agrégale un comentario que diga: 'Excelente análisis crítico, continúa así'."*
|
|
51
|
+
* 💬 *"Genera un reporte de las notas actuales de los alumnos del curso de Física."*
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
## 🛠️ Guía de Instalación Paso a Paso
|
|
56
|
+
|
|
57
|
+
Para conectar tu asistente de IA a Canvas, necesitas configurar **dos cosas**: tus credenciales de Canvas y el cliente de IA (como Claude).
|
|
58
|
+
|
|
59
|
+
### Paso 1: Obtener tus credenciales de Canvas LMS
|
|
60
|
+
Para que el servidor pueda actuar en tu nombre, necesita permiso:
|
|
61
|
+
1. Inicia sesión en tu cuenta de **Canvas LMS**.
|
|
62
|
+
2. Dirígete a **Cuenta (Account)** ➡️ **Configuración (Settings)** en el menú lateral.
|
|
63
|
+
3. Baja hasta la sección **Integraciones Aprobadas (Approved Integrations)** y haz clic en el botón **+ Nuevo token de acceso (+ New Access Token)**.
|
|
64
|
+
4. Escribe un propósito (ej. "Asistente Claude") y haz clic en **Generar token**.
|
|
65
|
+
5. **Copia el token generado inmediatamente** y guárdalo en un lugar seguro (no podrás volver a verlo después de cerrar la pantalla).
|
|
66
|
+
|
|
67
|
+
> [!IMPORTANT]
|
|
68
|
+
> También necesitarás el dominio de tu Canvas. Es la dirección web de tu escuela/universidad, por ejemplo: `miuniversidad.instructure.com`.
|
|
69
|
+
|
|
70
|
+
---
|
|
71
|
+
|
|
72
|
+
### Paso 2: Configurar tu Cliente de IA
|
|
73
|
+
|
|
74
|
+
#### Opción A: Claude Desktop (Aplicación de Escritorio)
|
|
75
|
+
1. Abre tu archivo de configuración de Claude Desktop. En Windows se encuentra en:
|
|
76
|
+
`%APPDATA%\Claude\claude_desktop_config.json`
|
|
77
|
+
*(En macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`)*
|
|
78
|
+
2. Agrega la configuración del servidor Canvas bajo `mcpServers`:
|
|
79
|
+
|
|
80
|
+
```json
|
|
81
|
+
{
|
|
82
|
+
"mcpServers": {
|
|
83
|
+
"canvas": {
|
|
84
|
+
"command": "npx",
|
|
85
|
+
"args": ["-y", "@charlie.act7/canvas-mcp-server"],
|
|
86
|
+
"env": {
|
|
87
|
+
"CANVAS_API_TOKEN": "TU_TOKEN_DE_ACCESO_AQUÍ",
|
|
88
|
+
"CANVAS_API_DOMAIN": "miuniversidad.instructure.com"
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
```
|
|
94
|
+
3. Guarda el archivo y reinicia Claude Desktop. Verás un icono de enchufe indicando que el servidor está conectado.
|
|
95
|
+
|
|
96
|
+
#### Opción B: Claude Code (Terminal)
|
|
97
|
+
Si utilizas la herramienta de línea de comandos Claude Code, simplemente instala el plugin ejecutando:
|
|
98
|
+
```bash
|
|
99
|
+
/plugin install canvas-lms@claude-community
|
|
100
|
+
```
|
|
101
|
+
Luego, configura tus credenciales de forma interactiva:
|
|
102
|
+
```bash
|
|
103
|
+
/canvas-lms:config
|
|
104
|
+
```
|
|
105
|
+
|
|
106
|
+
---
|
|
107
|
+
|
|
108
|
+
## 💻 Configuración Interactiva por Consola (CLI)
|
|
109
|
+
Si prefieres configurar las credenciales de manera local e interactiva en tu terminal para desarrollo, puedes ejecutar:
|
|
110
|
+
```bash
|
|
111
|
+
npx @charlie.act7/canvas-mcp-server config
|
|
112
|
+
```
|
|
113
|
+
Esto te pedirá el dominio y tu API token paso a paso, guardándolos de forma segura en un archivo de configuración local.
|
|
114
|
+
|
|
115
|
+
---
|
|
116
|
+
|
|
117
|
+
<details>
|
|
118
|
+
<summary>🛠️ <b>Ver Lista Detallada de Herramientas Soportadas (Técnico)</b></summary>
|
|
119
|
+
|
|
120
|
+
El servidor expone internamente las siguientes herramientas organizadas por categorías:
|
|
121
|
+
|
|
122
|
+
| Categoría | Herramientas Incluidas |
|
|
123
|
+
|---|---|
|
|
124
|
+
| **Cursos (Courses)** | Listar cursos, detalles del curso, configuración básica |
|
|
125
|
+
| **Módulos (Modules)** | Listar y gestionar módulos del curso |
|
|
126
|
+
| **Páginas (Pages)** | Listar páginas de contenido, leer el HTML de una página |
|
|
127
|
+
| **Archivos (Files)** | Listar archivos cargados en el curso |
|
|
128
|
+
| **Anuncios (Announcements)** | Listar y crear anuncios para el curso |
|
|
129
|
+
| **Tareas (Assignments)** | Listar, crear, actualizar tareas y modificar fechas de entrega masivamente |
|
|
130
|
+
| **Entregas (Submissions)** | Ver entregas y archivos adjuntos de alumnos |
|
|
131
|
+
| **Calificaciones (Grading)** | Calificar entregas de tareas, auditar notas del curso |
|
|
132
|
+
| **Exámenes (Quizzes)** | Listar quizzes, gestionar preguntas y modificar fechas límite |
|
|
133
|
+
| **Estudiantes (Students)** | Roster de alumnos, progreso de aprendizaje y detalles |
|
|
134
|
+
| **Grupos (Groups)** | Listar y gestionar grupos de estudiantes |
|
|
135
|
+
| **Calendario (Calendar)** | Listar y crear eventos o recordatorios en la agenda |
|
|
136
|
+
| **Rúbricas (Rubrics)** | Crear y gestionar rúbricas de evaluación |
|
|
137
|
+
| **Comunicación (Communication)** | Enviar mensajes directos, gestionar foros y discusiones |
|
|
138
|
+
|
|
139
|
+
### Recursos MCP Soportados
|
|
140
|
+
Para clientes compatibles con recursos directos:
|
|
141
|
+
* `canvas://courses/{id}/readme` — Resumen general formateado de un curso.
|
|
142
|
+
* `canvas://courses/{id}/pages/{slug}` — Contenido HTML directo de páginas de Canvas.
|
|
143
|
+
</details>
|
|
144
|
+
|
|
145
|
+
---
|
|
146
|
+
|
|
147
|
+
## 🛠️ Desarrollo Local (Para Programadores)
|
|
148
|
+
|
|
149
|
+
Si deseas clonar este repositorio y hacer modificaciones:
|
|
150
|
+
|
|
151
|
+
1. **Instalar Dependencias:**
|
|
152
|
+
```bash
|
|
153
|
+
npm install
|
|
154
|
+
```
|
|
155
|
+
2. **Compilar el Proyecto (TypeScript a JavaScript):**
|
|
156
|
+
```bash
|
|
157
|
+
npm run build
|
|
158
|
+
```
|
|
159
|
+
3. **Ejecutar Servidor en Modo Stdio (MCP):**
|
|
160
|
+
```bash
|
|
161
|
+
npm start
|
|
162
|
+
```
|
|
163
|
+
4. **Ejecutar Servidor HTTP con Documentación Swagger:**
|
|
164
|
+
Si deseas utilizarlo como una acción de GPTs de OpenAI, levanta el servidor web con:
|
|
165
|
+
```bash
|
|
166
|
+
npm run start:http
|
|
167
|
+
```
|
|
168
|
+
Si deseas ver la interfaz interactiva de Swagger, visita `http://localhost:3000`.
|
|
169
|
+
|
|
170
|
+
---
|
|
171
|
+
|
|
172
|
+
## 📄 Licencia
|
|
173
|
+
Este proyecto está bajo la licencia MIT. Creado por [Charlie Cárdenas Toledo](https://github.com/charlie-act7).
|
package/README.md
CHANGED
|
@@ -1,15 +1,81 @@
|
|
|
1
|
-
# Canvas MCP Server
|
|
1
|
+
# 🎓 Canvas LMS MCP Server
|
|
2
2
|
|
|
3
3
|
[](https://www.npmjs.com/package/@charlie.act7/canvas-mcp-server)
|
|
4
4
|
[](https://opensource.org/licenses/MIT)
|
|
5
5
|
|
|
6
|
-
|
|
6
|
+
**Bring AI to your Canvas Virtual Classroom!** 🚀
|
|
7
7
|
|
|
8
|
-
|
|
8
|
+
This project is a **Model Context Protocol (MCP)** server for **Canvas LMS**. In simple terms, it acts as a "translator" or bridge that allows AI assistants (like Claude Desktop, Claude Code, Cursor, etc.) to understand and perform actions in your Canvas courses using natural language.
|
|
9
9
|
|
|
10
|
-
|
|
10
|
+
---
|
|
11
11
|
|
|
12
|
-
|
|
12
|
+
## 🔍 How It Works
|
|
13
|
+
|
|
14
|
+
When you interact with the server, communication flows as follows:
|
|
15
|
+
|
|
16
|
+
```mermaid
|
|
17
|
+
graph LR
|
|
18
|
+
User([User]) -->|Natural Language Instruction| AI["AI Assistant (e.g., Claude)"]
|
|
19
|
+
AI -->|MCP Request| MCP["Canvas MCP Server"]
|
|
20
|
+
MCP -->|REST API (HTTPS)| Canvas["Canvas LMS"]
|
|
21
|
+
Canvas -->|Response| MCP
|
|
22
|
+
MCP -->|Processed Data| AI
|
|
23
|
+
AI -->|Friendly Answer| User
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
1. **You ask Claude for something** (e.g., *"Create an assignment due next Friday"*).
|
|
27
|
+
2. **Claude detects your intent** and communicates with the **Canvas MCP Server**, sending the required parameters.
|
|
28
|
+
3. **The server makes a secure call** to the official Canvas API.
|
|
29
|
+
4. **Canvas processes the action** and returns the result.
|
|
30
|
+
5. **Claude confirms the success of the action** back to you in plain, natural language.
|
|
31
|
+
|
|
32
|
+
---
|
|
33
|
+
|
|
34
|
+
## 💡 What Can You Ask Your Assistant?
|
|
35
|
+
|
|
36
|
+
Anything you would normally do manually in Canvas! Here are some everyday examples:
|
|
37
|
+
|
|
38
|
+
### 📖 Querying Information
|
|
39
|
+
* 💬 *"What active courses do I have this semester?"*
|
|
40
|
+
* 💬 *"Show me the ungraded submissions for Assignment 2 in Biology."*
|
|
41
|
+
* 💬 *"Who is in Group B of my Chemistry class?"*
|
|
42
|
+
* 💬 *"What quizzes or exams are scheduled for this week?"*
|
|
43
|
+
|
|
44
|
+
### ✍️ Creating and Managing Content
|
|
45
|
+
* 💬 *"Create a new assignment named 'History Term Paper' due next Friday."*
|
|
46
|
+
* 💬 *"Post an announcement in my Math course letting everyone know tomorrow's lecture is online."*
|
|
47
|
+
* 💬 *"Create a new module named 'Week 5: Introduction to React' in my course."*
|
|
48
|
+
|
|
49
|
+
### 💯 Grading & Giving Feedback
|
|
50
|
+
* 💬 *"Grade Maria's essay with a 90/100 and add a comment saying: 'Excellent critical analysis, keep it up!'"*
|
|
51
|
+
* 💬 *"Give me a summary of current student grades in the Physics course."*
|
|
52
|
+
|
|
53
|
+
---
|
|
54
|
+
|
|
55
|
+
## 🛠️ Step-by-Step Setup Guide
|
|
56
|
+
|
|
57
|
+
To connect your AI assistant to Canvas, you need to configure **two things**: your Canvas credentials and your AI client (like Claude).
|
|
58
|
+
|
|
59
|
+
### Step 1: Obtain your Canvas credentials
|
|
60
|
+
To let the server act on your behalf, it needs permission:
|
|
61
|
+
1. Log in to your **Canvas LMS** account.
|
|
62
|
+
2. Go to **Account** ➡️ **Settings** in the sidebar menu.
|
|
63
|
+
3. Scroll down to the **Approved Integrations** section and click **+ New Access Token**.
|
|
64
|
+
4. Enter a purpose (e.g., "Claude Assistant") and click **Generate Token**.
|
|
65
|
+
5. **Copy the generated token immediately** and store it somewhere safe (you won't be able to see it again after closing the page).
|
|
66
|
+
|
|
67
|
+
> [!IMPORTANT]
|
|
68
|
+
> You will also need your Canvas Domain. This is the web address of your school/university, for example: `myschool.instructure.com`.
|
|
69
|
+
|
|
70
|
+
---
|
|
71
|
+
|
|
72
|
+
### Step 2: Connect to your AI Client
|
|
73
|
+
|
|
74
|
+
#### Option A: Claude Desktop (Desktop Application)
|
|
75
|
+
1. Open your Claude Desktop configuration file. On Windows, it is located at:
|
|
76
|
+
`%APPDATA%\Claude\claude_desktop_config.json`
|
|
77
|
+
*(On macOS: `~/Library/Application Support/Claude/claude_desktop_config.json`)*
|
|
78
|
+
2. Add the Canvas server configuration under `mcpServers`:
|
|
13
79
|
|
|
14
80
|
```json
|
|
15
81
|
{
|
|
@@ -18,100 +84,90 @@ Add this to your `claude_desktop_config.json`:
|
|
|
18
84
|
"command": "npx",
|
|
19
85
|
"args": ["-y", "@charlie.act7/canvas-mcp-server"],
|
|
20
86
|
"env": {
|
|
21
|
-
"CANVAS_API_TOKEN": "
|
|
22
|
-
"CANVAS_API_DOMAIN": "
|
|
87
|
+
"CANVAS_API_TOKEN": "YOUR_ACCESS_TOKEN_HERE",
|
|
88
|
+
"CANVAS_API_DOMAIN": "myschool.instructure.com"
|
|
23
89
|
}
|
|
24
90
|
}
|
|
25
91
|
}
|
|
26
92
|
}
|
|
27
93
|
```
|
|
94
|
+
3. Save the file and restart Claude Desktop. You will see a socket/plug icon indicating the server is successfully connected.
|
|
28
95
|
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
```
|
|
32
|
-
|
|
33
|
-
"mcpServers": {
|
|
34
|
-
"canvas": {
|
|
35
|
-
"command": "docker",
|
|
36
|
-
"args": [
|
|
37
|
-
"run", "-i", "--rm",
|
|
38
|
-
"-e", "CANVAS_API_TOKEN=your_token_here",
|
|
39
|
-
"-e", "CANVAS_API_DOMAIN=your_school.instructure.com",
|
|
40
|
-
"charliecardenas/canvas-mcp"
|
|
41
|
-
]
|
|
42
|
-
}
|
|
43
|
-
}
|
|
44
|
-
}
|
|
96
|
+
#### Option B: Claude Code (Terminal CLI)
|
|
97
|
+
If you are using the Claude Code terminal tool, install the plugin by running:
|
|
98
|
+
```bash
|
|
99
|
+
/plugin install canvas-lms@claude-community
|
|
45
100
|
```
|
|
46
|
-
|
|
47
|
-
> **Note:** Build the image first: `docker build -t charliecardenas/canvas-mcp .`
|
|
48
|
-
|
|
49
|
-
## Getting Your Canvas Credentials
|
|
50
|
-
|
|
51
|
-
1. Log in to Canvas
|
|
52
|
-
2. Go to **Account → Settings**
|
|
53
|
-
3. Scroll to **Approved Integrations** → click **New Access Token**
|
|
54
|
-
4. Copy the token — you won't see it again
|
|
55
|
-
|
|
56
|
-
Your domain is the hostname of your Canvas instance (e.g. `uide.instructure.com`).
|
|
57
|
-
|
|
58
|
-
## Available Tools
|
|
59
|
-
|
|
60
|
-
| Category | Tools |
|
|
61
|
-
|---|---|
|
|
62
|
-
| **Courses** | `canvas_list_courses`, `set_canvas_config` |
|
|
63
|
-
| **Modules** | `canvas_list_modules` |
|
|
64
|
-
| **Pages** | `canvas_list_pages`, `canvas_get_page_content` |
|
|
65
|
-
| **Files** | `canvas_list_files` |
|
|
66
|
-
| **Announcements** | `canvas_list_announcements` |
|
|
67
|
-
| **Assignments** | `canvas_get_assignments`, `canvas_get_submissions` |
|
|
68
|
-
| **Grading** | `canvas_grade_submission`, `canvas_audit_course` |
|
|
69
|
-
| **Quizzes** | Quiz listing and question management |
|
|
70
|
-
| **Students** | Student roster and progress |
|
|
71
|
-
| **Groups** | Group management |
|
|
72
|
-
| **Calendar** | Calendar events |
|
|
73
|
-
| **Rubrics** | Rubric creation and management |
|
|
74
|
-
| **Create** | Create assignments, pages, announcements |
|
|
75
|
-
| **Communication** | Messaging and discussions |
|
|
76
|
-
|
|
77
|
-
## Resources
|
|
78
|
-
|
|
79
|
-
MCP clients that support resources can access Canvas content directly:
|
|
80
|
-
|
|
81
|
-
- `canvas://courses/{id}/readme` — Course summary
|
|
82
|
-
- `canvas://courses/{id}/pages/{slug}` — Page HTML content
|
|
83
|
-
|
|
84
|
-
## Local Development
|
|
85
|
-
|
|
101
|
+
Then, configure your credentials interactively:
|
|
86
102
|
```bash
|
|
87
|
-
|
|
88
|
-
npm install
|
|
89
|
-
|
|
90
|
-
# Configure credentials interactively
|
|
91
|
-
npx canvas-mcp config
|
|
92
|
-
|
|
93
|
-
# Build
|
|
94
|
-
npm run build
|
|
95
|
-
|
|
96
|
-
# Start MCP server (stdio)
|
|
97
|
-
npm start
|
|
98
|
-
|
|
99
|
-
# Start HTTP API (for GPT Builder / OpenAPI)
|
|
100
|
-
npm run start:http
|
|
103
|
+
/canvas-lms:config
|
|
101
104
|
```
|
|
102
105
|
|
|
103
|
-
|
|
104
|
-
- Swagger UI: `http://localhost:3000/docs`
|
|
105
|
-
- OpenAPI JSON: `http://localhost:3000/openapi.json`
|
|
106
|
+
---
|
|
106
107
|
|
|
107
|
-
##
|
|
108
|
+
## 💻 Interactive Console Configuration (CLI)
|
|
109
|
+
If you prefer to configure your credentials locally for development, run:
|
|
110
|
+
```bash
|
|
111
|
+
npx @charlie.act7/canvas-mcp-server config
|
|
112
|
+
```
|
|
113
|
+
This will guide you step-by-step to input your domain and API token, storing them securely in a local configuration file.
|
|
108
114
|
|
|
109
|
-
|
|
115
|
+
---
|
|
110
116
|
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
- `CANVAS_API_DOMAIN` (e.g. `your-school.instructure.com`)
|
|
117
|
+
<details>
|
|
118
|
+
<summary>🛠️ <b>View Detailed List of Supported Tools (Technical)</b></summary>
|
|
114
119
|
|
|
115
|
-
|
|
120
|
+
The server exposes the following tools organized by category:
|
|
116
121
|
|
|
117
|
-
|
|
122
|
+
| Category | Included Tools |
|
|
123
|
+
|---|---|
|
|
124
|
+
| **Courses** | List courses, get course details, set basic configuration |
|
|
125
|
+
| **Modules** | List and manage course modules |
|
|
126
|
+
| **Pages** | List pages, read page content HTML |
|
|
127
|
+
| **Files** | List files uploaded to a course |
|
|
128
|
+
| **Announcements** | List and create announcements |
|
|
129
|
+
| **Assignments** | List, create, and update assignments; bulk update due dates |
|
|
130
|
+
| **Submissions** | View student submissions and attachments |
|
|
131
|
+
| **Grading** | Grade submissions, audit course grades |
|
|
132
|
+
| **Quizzes** | List quizzes, manage questions, update quiz dates |
|
|
133
|
+
| **Students** | Course roster, progress tracking, and student details |
|
|
134
|
+
| **Groups** | List and manage student groups |
|
|
135
|
+
| **Calendar** | List and create calendar events/reminders |
|
|
136
|
+
| **Rubrics** | Create and manage grading rubrics |
|
|
137
|
+
| **Communication** | Send direct messages, manage discussions and threads |
|
|
138
|
+
|
|
139
|
+
### Supported MCP Resources
|
|
140
|
+
For clients supporting direct resources:
|
|
141
|
+
* `canvas://courses/{id}/readme` — Formatted course summary.
|
|
142
|
+
* `canvas://courses/{id}/pages/{slug}` — Direct HTML content of Canvas pages.
|
|
143
|
+
</details>
|
|
144
|
+
|
|
145
|
+
---
|
|
146
|
+
|
|
147
|
+
## 🛠️ Local Development (For Developers)
|
|
148
|
+
|
|
149
|
+
To clone this repository and modify the code:
|
|
150
|
+
|
|
151
|
+
1. **Install Dependencies:**
|
|
152
|
+
```bash
|
|
153
|
+
npm install
|
|
154
|
+
```
|
|
155
|
+
2. **Build the Project (TypeScript to JavaScript):**
|
|
156
|
+
```bash
|
|
157
|
+
npm run build
|
|
158
|
+
```
|
|
159
|
+
3. **Start Server in Stdio Mode (MCP):**
|
|
160
|
+
```bash
|
|
161
|
+
npm start
|
|
162
|
+
```
|
|
163
|
+
4. **Start HTTP Server with Swagger Documentation:**
|
|
164
|
+
If you want to use this as an OpenAI GPT Custom Action, spin up the web server with:
|
|
165
|
+
```bash
|
|
166
|
+
npm run start:http
|
|
167
|
+
```
|
|
168
|
+
Then visit `http://localhost:3000` to view the interactive Swagger interface.
|
|
169
|
+
|
|
170
|
+
---
|
|
171
|
+
|
|
172
|
+
## 📄 License
|
|
173
|
+
This project is licensed under the MIT License. Created by [Charlie Cárdenas Toledo](https://github.com/charlie-act7).
|
package/llms-install.md
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
# Canvas LMS MCP Server — Installation Guide for AI Agents
|
|
2
|
+
|
|
3
|
+
This server requires two environment variables to function.
|
|
4
|
+
|
|
5
|
+
## Required Environment Variables
|
|
6
|
+
|
|
7
|
+
| Variable | Description | Example |
|
|
8
|
+
|---|---|---|
|
|
9
|
+
| `CANVAS_API_TOKEN` | Canvas LMS personal access token | `1234~abcXYZ...` |
|
|
10
|
+
| `CANVAS_API_DOMAIN` | Hostname of the Canvas instance (no `https://`) | `myschool.instructure.com` |
|
|
11
|
+
|
|
12
|
+
## How to Get a Canvas API Token
|
|
13
|
+
|
|
14
|
+
1. Log in to Canvas at your institution's URL
|
|
15
|
+
2. Click your profile picture → **Settings**
|
|
16
|
+
3. Scroll to **Approved Integrations**
|
|
17
|
+
4. Click **+ New Access Token**
|
|
18
|
+
5. Give it a name and click **Generate Token**
|
|
19
|
+
6. Copy the token immediately — it will not be shown again
|
|
20
|
+
|
|
21
|
+
## MCP Configuration
|
|
22
|
+
|
|
23
|
+
```json
|
|
24
|
+
{
|
|
25
|
+
"mcpServers": {
|
|
26
|
+
"canvas": {
|
|
27
|
+
"command": "npx",
|
|
28
|
+
"args": ["-y", "@charlie.act7/canvas-mcp-server"],
|
|
29
|
+
"env": {
|
|
30
|
+
"CANVAS_API_TOKEN": "<paste token here>",
|
|
31
|
+
"CANVAS_API_DOMAIN": "<your school>.instructure.com"
|
|
32
|
+
}
|
|
33
|
+
}
|
|
34
|
+
}
|
|
35
|
+
}
|
|
36
|
+
```
|
|
37
|
+
|
|
38
|
+
## Verification
|
|
39
|
+
|
|
40
|
+
After installation, ask the AI: *"List my Canvas courses"*. If credentials are correct, it will return your active courses.
|
|
41
|
+
|
|
42
|
+
## Troubleshooting
|
|
43
|
+
|
|
44
|
+
- **401 Unauthorized**: Token is invalid or expired — generate a new one in Canvas Settings
|
|
45
|
+
- **404 Not Found**: Check that `CANVAS_API_DOMAIN` does not include `https://` — use the hostname only
|
|
46
|
+
- **No courses returned**: Ensure you are enrolled in at least one active course as a Teacher or Admin
|
package/package.json
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
"publishConfig": {
|
|
4
4
|
"access": "public"
|
|
5
5
|
},
|
|
6
|
-
"version": "1.1.
|
|
6
|
+
"version": "1.1.2",
|
|
7
7
|
"description": "MCP Server for Canvas LMS - Use AI to interact with your courses, assignments, and grades.",
|
|
8
8
|
"main": "dist/index.js",
|
|
9
9
|
"bin": {
|
|
@@ -18,7 +18,10 @@
|
|
|
18
18
|
"dist/resources",
|
|
19
19
|
"dist/services",
|
|
20
20
|
"dist/tools",
|
|
21
|
-
"README.md"
|
|
21
|
+
"README.md",
|
|
22
|
+
"llms-install.md",
|
|
23
|
+
".claude-plugin",
|
|
24
|
+
".mcp.json"
|
|
22
25
|
],
|
|
23
26
|
"scripts": {
|
|
24
27
|
"build": "tsc",
|