Skip to main content
Glama

get_document_content

Read-only

Read and analyze a document's text by ID. For long documents, use offset and max_chars to request a character slice and continue reading.

Instructions

Get the text content of a specific document by ID. Use this when you need to read or analyze the actual document text. For long documents, read a slice with max_chars (and offset to continue) — e.g. max_chars: 2000 is usually enough to identify a document. Paperless stores the text without page boundaries, so slices are by characters, not pages.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
idYes
offsetNoStart at this character (default 0) — continue a previous partial read
max_charsNoReturn at most this many characters; the result then includes total_chars and truncated

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed2 schema fields changedv3.2.1
    • addedInput schema / properties / max_chars
      Added value: +{
      +  "description": "Return at most this many characters; the result then includes total_chars and truncated",
      +  "maximum": 9007199254740991,
      +  "minimum": 1,
      +  "type": "integer"
      +}
    • addedInput schema / properties / offset
      Added value: +{
      +  "description": "Start at this character (default 0) — continue a previous partial read",
      +  "maximum": 9007199254740991,
      +  "minimum": 0,
      +  "type": "integer"
      +}
  2. First observedv3.2.0

TDQS

A4.4/5.0
Behavior4/5

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

readOnlyHint=true already covers the safety profile, and the description adds non-obvious behavior: text is stored without page boundaries so slices are character-based, and results include total_chars/truncated when max_chars is set. It stops short of stating default behavior when no slice is requested or any size limits.

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?

Three tightly packed sentences, front-loaded with the purpose before the slicing advice; every sentence carries actionable information with no filler.

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?

With no output schema, the description helpfully names the returned fields (total_chars, truncated) and explains the character-slicing model. It is nearly complete for a 3-param read tool, missing only explicit default/limit behavior when no slice is given.

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 coverage is 67%, and the description compensates by explaining the offset/max_chars contract and the continuation pattern ('offset to continue') with a concrete example. This adds meaning beyond the schema's terse field descriptions.

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 ('Get the text content of a specific document by ID'), which clearly separates it from metadata-oriented siblings like get_document and get_document_metadata. An agent can select it 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 Guidelines4/5

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

Gives a clear trigger ('when you need to read or analyze the actual document text') plus tactical guidance for long documents (use max_chars with offset, ~2000 chars to identify a document). It does not explicitly name which sibling to use instead for metadata or previews, so it falls short of full when/when-not routing.

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

Deploy Server

Other Tools