find_sections
Search headings in a Google Docs tab by text and retrieve section ranges stamped with the current revision, enabling precise pre-edit targeting without stale references.
Instructions
Find headings in a document tab and return their document ranges.
Use this tool when you need to locate a section by its heading text before performing a targeted edit on that section. The returned ranges carry a computed_at_revision stamp; range-editing tools in later milestones will refuse stale ranges (ranges computed against an older document revision). Call find_sections immediately before editing — do not cache returned ranges across separate edits.
Matching is case-insensitive and substring-based: a query of "intro" will match a heading "Introduction".
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": {
"doc_id": "<doc_id>",
"heading": "<heading>",
"tab_id": "<tab_id>"
},
"name": "find_sections"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| doc_id | Yes | ||
| tab_id | Yes | ||
| heading | Yes |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
No arguments | |||