Skip to main content
Glama

canvas_upload_file

Uploads a file to a Canvas course for assignment submission and returns the file ID needed to complete the submission.

Instructions

Upload a file to a course for assignment submission. Returns the file ID to use when submitting.

Tool call template

Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.

{
  "id": 1,
  "jsonrpc": "2.0",
  "method": "tools/call",
  "params": {
    "arguments": {
      "course_id": "<course_id>",
      "assignment_id": "<assignment_id>",
      "file_name": "<file_name>",
      "file_content": "<file_content>"
    },
    "name": "canvas_upload_file"
  }
}

Input Schema

NameRequiredDescriptionDefault
course_idYesThe Canvas course ID
file_nameYesName of the file
content_typeNoMIME type of the file. Defaults to text/plain.
file_contentYesFile content as a string (for text files)
assignment_idYesThe assignment ID to upload for

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.8/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are supplied, so the description carries the full behavioral burden. It usefully states the return value (file ID) despite there being no output schema, but it says nothing about permissions, file size limits, whether content must be plain text (schema hints 'for text files'), or whether re-uploads duplicate state.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two short sentences, front-loaded with the action and followed by the return value. Nothing extraneous.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a five-parameter upload tool with no output schema, the description covers the essential outcome (file ID for subsequent submission). Gaps remain around permission requirements, content-type expectations, and size limits, but the core call contract is conveyed.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so all five parameters are documented in the schema itself. The description adds no additional meaning about parameter formats or constraints, which matches the baseline when the schema does the work.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description gives a specific verb and resource ('Upload a file to a course') and states the intent ('for assignment submission'), which distinguishes it reasonably from the sibling canvas_submit_file_assignment. It does not name that sibling, so the differentiation is implied rather than explicit.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines4/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

It implies a two-step workflow by saying the returned file ID is 'to use when submitting', which tells the agent that this is the upload half of a submission flow. It stops short of explicitly naming canvas_submit_file_assignment or stating when not to use it.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.