Skip to main content
Glama

snapshot

Read-only

Returns a compact text outline of a page's headings, landmarks and interactive elements with stable refs for clicking, typing and form filling. Use it first to understand page structure before acting.

Instructions

Read-only: return a compact text outline of the page: headings, landmarks and every visible interactive element (links, buttons, inputs, selects) with its role, accessible name, state and a ref such as [ref=e12]. It sees through shadow DOM and same-origin iframes. Use the refs with click, hover, type, fill_form and scroll. Call it first on any page, and again after navigation or large page changes, because refs go stale. Far cheaper than screenshot for understanding structure. mode=all also includes text blocks; use get_text to just read content.

Input Schema

NameRequiredDescriptionDefault
tabNoTab id from tabs_list. Defaults to the current tab.
modeNointeractive (default): headings and interactive elements only; all: also include text blocks.
selectorNoCSS selector of a subtree to outline instead of the whole page, e.g. "form" or "#checkout".
max_charsNoMaximum characters of output (default 20000); narrow with selector for big pages.

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.1.2
    • changedInput schema / properties / max_chars / description
      Previous value: -"Output budget (default 20000)."New value: +"Maximum characters of output (default 20000); narrow with selector for big pages."
    • changedInput schema / properties / mode / description
      Previous value: -"interactive (default) or all (adds text blocks)."New value: +"interactive (default): headings and interactive elements only; all: also include text blocks."
    • changedInput schema / properties / selector / description
      Previous value: -"Limit the snapshot to the subtree matching this CSS selector."New value: +"CSS selector of a subtree to outline instead of the whole page, e.g. \"form\" or \"#checkout\"."
  2. First observedv0.1.1

TDQS

A4.7/5.0
Behavior5/5

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

Annotations already declare readOnlyHint=true, but the description adds substantial context beyond that: refs go stale, it sees through shadow DOM and same-origin iframes, output includes stale ref identifiers, and it is cheaper than screenshot. These are operational traits an agent needs and they are not in the annotations.

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?

Front-loads the read-only nature and what is returned, then moves to refs, usage timing, alternatives, and mode caveat. Every sentence contributes a distinct decision or behavioral fact 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?

No output schema exists, but the description explains the output format (role, accessible name, state, [ref=e12]), coverage (shadow DOM, iframes), staleness, and mode differences. An agent has everything needed to call it correctly and interpret the result.

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 100%, so all four parameters are already documented. The description mentions mode=all including text blocks and implies selector-based narrowing, but largely repeats schema content. Baseline 3 is appropriate when the schema does the heavy lifting.

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?

Uses a specific verb ('return a compact text outline') and names exactly what is included: headings, landmarks, interactive elements with role, name, state, and ref. It clearly differentiates itself from screenshot and get_text, so an agent can pick it without opening the 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?

Gives explicit sequencing ('Call it first on any page, and again after navigation'), names the alternatives ('Far cheaper than screenshot', 'use get_text to just read content'), and explains the staleness condition that triggers re-invocation. Nothing is left to inference.

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