Semantic snapshot
semantic_snapshotExtract a compact map of UI elements with data-agent-id hints, grouped by roles like regions, actions, and inputs, for quick first observation before full accessibility snapshots.
Instructions
Return a compact map of hinted UI elements (only elements carrying data-agent-id), grouped into regions/actions/inputs/observables/navigation/other. Use this as a cheap first observation instead of a full accessibility snapshot. To act on an element, pick its id and use the Playwright MCP with selector [data-agent-id='']. Returns compact JSON only — never HTML, DOM, or class names.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "semantic_snapshot"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | No | Optional URL to open before extracting. If omitted, reads the current page. | |
| scope | No | Optional data-agent-id or CSS selector to limit extraction to a subtree. | |
| includeHidden | No | Include hidden elements (default false). |