Skip to main content
Glama

Read a document's blocks

folio_document
Read-onlyIdempotent

Read a document as Folio models it: block IDs, expanded page structure, declared kind and fields, and data files. Use the returned block IDs for provenance, history, and block links.

Instructions

Read one document as Folio's model holds it: its blocks with their ids, the blocks its page shows once includes are expanded, its declared kind and fields, and the data files it reads. Call it for the block ids that folio_provenance and folio_history take and that a link to a block names - an id is 8 hex characters Folio derives, never invented - and to see what a page is made of; read the file itself for its full text. Answers {path, kind: markdown or mermaid, blocks: [{id, kind, lines: [first, last] from 1, text: its first 100 characters}], page: [{id, kind, source: the file the block comes from, lines, at: its lines in the expanded page, version}], conventions: {declarations, kind, declaredIn, fields}, data: [paths]}. A document Folio has not read yet is an error: ask again shortly. A list cut to fit one answer adds omitted, the entries each list left out, and narrow, how to ask for less.

Input Schema

NameRequiredDescriptionDefault
pathYesThe document's path, relative to the served folder or absolute under it, such as notes/plan.md

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observed

TDQS

A4.6/5.0
Behavior5/5

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

Beyond the supplied annotations (readOnly, idempotent, non-destructive), the description discloses a failure mode ('A document Folio has not read yet is an error: ask again shortly') and a truncation contract ('A list cut to fit one answer adds omitted ... and narrow'). That is behavioral context the annotations cannot express.

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?

Front-loaded with purpose and call conditions before the return contract, and no sentence is filler. However, the inline return-shape dump is a dense run-on that is harder to parse than a short prose summary of the same fields.

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

Completeness5/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 carries the full burden and does so: it documents the return object, the meaning of the 8-hex block ids, the transient 'not read yet' error, and the truncation fields. Nothing an agent needs in order to call this correctly or interpret the answer is missing.

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?

The single parameter is fully documented in the schema (100% coverage), including the relative-or-absolute path form, so the description adds essentially nothing about the input. It spends its words on the return shape instead, which is reasonable but leaves parameter semantics at the baseline.

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?

The description leads with a specific verb and resource ('Read one document as Folio's model holds it') and immediately enumerates what is returned: block ids, expanded page blocks, declared kind/fields, and data files. It distinguishes itself from the sibling list tool and from plain file reading ('read the file itself for its full text'), so an agent can separate it from folio_documents and folio_reads without opening a schema.

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

Usage Guidelines5/5

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

It names the concrete trigger ('for the block ids that folio_provenance and folio_history take and that a link to a block names') and a second use case ('to see what a page is made of'). It also names the alternative for full text ('read the file itself'), giving an explicit when-not condition.

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