Skip to main content
Glama

read_document

Retrieve the content of a specific Google Doc tab as markdown, structured data, or headings outline. Pass the doc_id and tab_id obtained from list_tabs to get text, tables, or section structure.

Instructions

Read the content of a specific tab in a Google Doc.

Use this tool when you need to read the text, headings, tables, or structure of a document tab. Call list_tabs first to get the tab_id.

format="markdown" (default): returns markdown text. Out-of-subset elements (images, smart chips, footnotes) appear as stable placeholder tokens and are listed in lossy_elements.

format="structured": returns paragraph positions and style runs from the raw Docs JSON, suitable for computing exact edit ranges.

format="outline": returns only the tab's headings (level, text, start_index, end_index), in document order. Use this when you only need geometry — e.g. to see the tab's section structure before deciding where to write — without pulling the whole tab as markdown. If you already know which heading you want to target, find_sections is the lighter tool: it filters to matches and returns section (not just heading) ranges.

Drive's files.export cannot scope to a single tab, which is why this server uses its own Docs JSON converter for markdown output.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
doc_idYes
formatNomarkdown
tab_idYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations provided, the description carries the full burden of behavioral disclosure. It transparently explains markdown lossy behavior with placeholder tokens and lossy_elements, describes the structured format's raw positions, and outlines the outline format's heading geometry. This gives the agent a strong model of what happens when the tool runs.

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?

The description is well-structured and front-loaded with the core purpose, then branches into format details and alternatives. Each sentence adds useful information, including the justification about Drive's export limitation. Despite its length, there is no filler.

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?

The description covers what each format returns, when to use which, prerequisites, and how this tool relates to siblings. Even with an output schema present, the description provides enough context for an agent to select and invoke the tool correctly without ambiguity.

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%, so the description must compensate. It thoroughly documents the format enum with per-value behavior and tells users to call list_tabs first for tab_id. The doc_id parameter is only implicitly described as identifying a Google Doc, which is slightly thin but acceptable given the tool context.

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 opens with a clear verb and resource: 'Read the content of a specific tab in a Google Doc.' It also explains the three output formats, making the tool's capabilities concrete and differentiating it from siblings like find_sections.

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?

The description explicitly says when to use the tool ('when you need to read the text, headings, tables, or structure'), and instructs calling list_tabs first to get the tab_id. It also names find_sections as the lighter alternative when targeting a known heading, providing clear when-not-to-use guidance.

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