导出选择器
browser_get_selectorGenerates a verified CSS selector for a snapshot ref element so you can reuse it in scripts, tests, or querySelector-based follow-up work.
Instructions
Generate a CSS selector for a snapshot ref element (verified against the DOM). Use it to reuse the element in scripts, tests, or querySelector-based follow-up work.
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": {
"ref": "<ref>"
},
"name": "browser_get_selector"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ref | Yes | Element ref from browser_snapshot | |
| tabId | No | Tab id (default: active tab) |