Skip to main content
Glama

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".

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
doc_idYes
tab_idYes
headingYes

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.0

TDQS

A4.5/5.0
Behavior5/5

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

With no annotations, the description carries full behavioral burden and does so well. It discloses case-insensitive substring matching, the computed_at_revision stamp, the staleness constraint on range-editing tools, and the instruction not to cache ranges. This is substantial behavioral context beyond the bare schema.

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 compact and front-loaded. The first sentence states the core purpose, followed by usage context, a critical freshness warning, and matching semantics. Every sentence adds necessary information with 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?

Given the tool's moderate complexity and the presence of an output schema, the description covers what an agent needs to invoke it correctly: purpose, when to call it, matching behavior, and the revision-staleness constraint. No critical operational detail 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?

Schema description coverage is 0%, so the description must compensate. It meaningfully explains the heading parameter via case-insensitive substring matching, but doc_id and tab_id are only inferred from their names and the phrase 'document tab.' This is adequate but not richly documented.

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 first sentence states a specific action and resource: 'Find headings in a document tab and return their document ranges.' This clearly describes what the tool does and distinguishes it from siblings like replace_text, read_document, and table tools, none of which locate heading ranges.

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?

The description gives explicit usage context: use it to locate a section by heading text before making a targeted edit. It also warns against caching ranges and says to call immediately before editing. It does not name alternative tools or state when not to use it, but the intended workflow is clear.

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