browser_snapshot
Capture an accessibility tree snapshot of the current page with element refs (e.g., [ref=e5]) for reasoning and element targeting without screenshots.
Instructions
Capture an accessibility tree snapshot of the current page with element refs (e.g. [ref=e5]). Prefer this over screenshots for reasoning and element targeting.
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": "browser_snapshot"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| filename | No | Optional file path to save the snapshot text to instead of returning it inline. | |
| sessionId | No | Optional target browser session ID. If omitted, uses the currently active session (or auto-launches one). |