Skip to main content
Glama

read_attachment

Read-only

Read a Google Classroom attachment from its Drive, Docs, Slides, or Sheets link or file ID, returning text, CSV, or a local cached file path for uploaded files.

Instructions

Read a file attached in Classroom: pass its Google Drive / Docs / Slides / Sheets link (or file id). Docs and Slides come back as text, Sheets as CSV. Uploaded files (PDF, Word, PowerPoint, code, zip, ...) are saved under classroom-mcp's private cache folder and their local path is returned; .docx, .pptx and text files also come back as text (PDFs too if pypdf is installed).

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": {
      "link": "<link>"
    },
    "name": "read_attachment"
  }
}

Input Schema

NameRequiredDescriptionDefault
linkYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/5.0
Behavior5/5

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

Annotations only declare readOnlyHint and openWorldHint; the description goes well past that by disclosing conversion behavior (Docs/Slides to text, Sheets to CSV) and the side effect that uploaded binaries are written to a private cache folder with the local path returned. It also names a conditional dependency ('PDFs too if pypdf is installed'), which is exactly the kind of runtime caveat an agent cannot infer.

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

Conciseness4/5

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

The purpose and input contract are front-loaded in the first sentence, with format behavior following in descending order of importance. The parenthetical file-type enumeration ('PDF, Word, PowerPoint, code, zip, ...') is slightly sprawling but still earns its place by setting expectations for return shape.

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 one-parameter read tool with no output schema, the definition covers input form, per-format return behavior, and the cache-path side effect — enough for an agent to call it and interpret the result. It does not mention failure modes (inaccessible link, unsupported type) or size limits, which would round it out.

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

Parameters4/5

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

Schema description coverage is 0% and the sole 'link' property carries no description, so the definition has to compensate — and it does, spelling out that the value may be a Google Drive/Docs/Slides/Sheets link or a bare file id. It stops short of giving concrete syntax or an example, which keeps it from a 5.

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

Purpose5/5

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

States a specific verb and resource — 'Read a file attached in Classroom' — and immediately narrows the input domain to Google Drive/Docs/Slides/Sheets links or file ids. This is clearly distinguishable from sibling tools like read_page or get_assignment without opening any schema.

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

Usage Guidelines3/5

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

It tells the agent what to supply ('pass its Google Drive / Docs / Slides / Sheets link (or file id)') but never states when to reach for this over alternatives such as read_page, nor any precondition like the file needing to be attached to an accessible classwork item. Usage is implied by the resource name rather than explained.

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