← Back to library

Query a Canvas LMS course through a chat tool

Vishal Sachdev, an educator who does not code professionally, spent four months with Claude Code building an MCP tool that connects Claude to Canvas LMS. A small script listing his courses grew to handle assignments, submissions, peer reviews, discussions, rubric grading and student analytics, all running on his own computer with credentials kept out of the code.

  • OutcomeAnswer course questions like who has not submitted or how grades are spread without clicking through LMS menus.
  • SetupAn afternoon+
  • LevelAdvanced
  • CreditVishal Sachdev
View original
Works with
Claude CodeClaude

Published Oct 23, 2026Updated Oct 23, 2026AI dry run on sample input: passed Oct 23, 2026Source verified Oct 23, 2026

When should you use it?

  • You teach on Canvas and repeat the same lookups weekly
  • Answers need several API calls stitched together
  • You can run a small local tool

Not for: Changing grades without review; Sharing identifiable student data with tools your institution has not approved

What do you need, and what do you get?

You need

  • A Canvas API token
  • Course IDs
  • The questions you ask most often

You get

  • A local tool the chat app can call
  • Plain-English answers about submissions, grades and participation

How does it work, step by step?

  1. Check your institution's rulesConfirm you are allowed to use an API token and an AI assistant with course data.
  2. Start with one read-only questionHave the agent build a tool that only lists your courses, and test it.
  3. Add the lookups you repeatGrow to submissions, grade spreads and discussion activity, one tool at a time.
  4. Keep secrets out of codeStore the token in environment variables and run everything locally.
  5. Review before actingUse answers to decide whom to contact; make any grade changes yourself.

The prompt

Our own prompt, inspired by Vishal Sachdev and written to work in Claude Code and Claude. Values in lime are placeholders.

Prompt0 variables
Build a small local MCP tool in Python that lets my assistant query Canvas with my API token from an environment variable. Start read-only with: list my courses; list assignments for a course; list students who have not submitted a given assignment. Handle pagination. Do not include any write actions. Add a README explaining setup and how to test each tool against the Canvas web interface.

Inspired by Vishal Sachdev: When Claude Code Becomes Your Co-Developer: Building a Canvas LMS Tool That Actually Works. The prompt above is written by playbooks.bot in our own words; nothing from the original is quoted.

What can go wrong?

  • Canvas questions often need many paginated calls; test answers against the LMS by hand at first.
  • Student privacy obligations still apply when the data passes through an assistant.

Our take

Vishal Sachdev's project is a model of how a non-developer can build the exact internal tool their job needs. He began with a single read-only question, which courses he teaches, and added lookups as real needs came up, so every feature earned its place. Keeping access tokens in environment variables rather than in the code is a habit every educator experimenting with AI should copy, especially before sharing scripts with colleagues. The main question to settle first is data protection. Student submissions, grades and analytics are covered by privacy rules such as FERPA in the US, and many institutions restrict which AI services may process them. Check your institution's policy before connecting, and prefer setups where student data stays on your machine or in an approved service. Keep grading decisions with you: an assistant can apply a rubric consistently and draft comments, but a grade affects a student, so review each one before it is saved. Write down which actions the tool can take, and keep anything that posts or changes grades behind a confirmation.

Where the time goes back: A question that took several screens of clicking becomes one sentence and one answer.

FAQ

Do I need to code?
The author is an educator, not a developer; the agent wrote the code while he decided what teachers need.
Why a tool rather than an app?
An MCP tool lets the chat assistant be the interface, so there is no front end to build.

Source and credit

Inspired by Vishal Sachdev. We describe the idea in our own words, link to the original, and wrote the prompt ourselves; nothing is quoted.

Inspired by
When Claude Code Becomes Your Co-Developer: Building a Canvas LMS Tool That Actually Works
Creator
Vishal Sachdev
Published on
chatwithgpt.substack.com (Substack)
Original date
Jun 20, 2025
License
Not openly licensed (the poster keeps all rights), so we quote nothing and link to the original
Originally for
Claude Code
AI dry run
Oct 23, 2026: passed. Dry-run tested by our AI test agent on sample input. PASS: Gates held on desk check; no live sends or purchases.
AI dry run on sample data; not run with live connected accounts. The playbooks.bot test agent filled the prompt with synthetic inputs, produced the output and checked it against the page's stated outputs and guardrails.
Verified
Oct 23, 2026: source link resolves to the original, the credited creator published it, our excerpt or prompt matches it, and the license allows our use.

Are you the creator? Claim or correct this page.

More in Operations & Admin

All 203 Operations & Admin playbooks →

Related playbooks

Operations & AdminWorkflow✓ AI dry run

Ask Reddit's experience before you pick a library

Let your coding agent search Reddit for long-term user reports on a library, an error message or a competitor before you commit to a choice.

Credit: u/karanb192 on r/ClaudeCode

Minutes
Operations & AdminSkill✓ AI dry run

Compare design options with a weighted score and stress test

Use the trade-study-report skill from Anthropic's Claude for Manufacturing plugin to turn a filled-in options matrix and test results into a ranked, sourced comparison, set aside any option that breaks a hard requirement, vary the weights to see whether the winner changes, and draft a decision memo an engineer reviews and signs.

Credit: anthropics

Under an hour
Operations & AdminSkill✓ AI dry run

Connect your agent to a system with no ready connector

Use the custom-connector skill from Anthropic's Claude for Manufacturing plugin to name the exact system and one data flow, check for an existing vendor or community MCP server before building anything, settle on the highest workable access route down to a scheduled export, record why, keep credentials out of the chat and explain how the chosen route is likely to break.

Credit: anthropics

An afternoon+
Operations & AdminWorkflow✓ AI dry run

Fill PDF forms from your own documents with an agent

Upload a fillable PDF and the documents that hold the answers; the agent stages a value for each field, shows you the pending edits and saves the filled form.

Credit: Jerry Liu (@jerryjliu0)

Under an hour
Operations & AdminRoutine✓ AI dry run

Get the plant report ready before the morning meeting

Schedule the morning-plant-pulse skill from Anthropic's Claude for Manufacturing plugin to combine the overnight exports from planning, production and maintenance, compute output against plan, OEE and its three parts, downtime ranked by minutes and by count and the cost of losses, then refresh one operations dashboard per site with 14- and 30-day trends, all without changing any business system.

Credit: anthropics

An afternoon+