extract_bounding_boxes
Retrieve bounding boxes for DOM elements to determine their exact screen position, size, z-index, and visibility within the viewport.
Instructions
Returns the geometric position, size, z-index, and viewport visibility for one or more DOM elements. Use to answer: where exactly on screen is this element? Is it visible? Is it off-screen?
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": {
"url": "<url>",
"selectors": "<selectors>"
},
"name": "extract_bounding_boxes"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| url | Yes | URL of the page to analyze | |
| viewport | No | Viewport size (default: 1280×720) | |
| selectors | Yes | CSS selectors or Playwright locator strings |