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
| Name | Required | Description | Default |
|---|---|---|---|
| doc_id | Yes | ||
| format | No | markdown | |
| tab_id | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||