tab_click
Click a browser page element or canvas point with the real mouse, scrolling it into view and confirming pointer placement before clicking; fails if the element is covered.
Instructions
Click an element of a page in the user's browser with the real mouse. The tab is brought to the front, the element is scrolled into view if needed, and the pointer moves onto it and clicks once the page confirms the pointer is over it, so the browser window may sit anywhere on screen. Fails without clicking when something covers the element. Take the ref from tab_read. On a canvas page, click a point instead with x and y, read off tab_screenshot: the page confirms the pointer reached that point before the click. Returns what changed on the page (lines that appeared with +, went with -), or the new screen after a navigation, so a menu or dialog the click opened needs no tab_read; take a tab_screenshot when that leaves you unsure what happened. A download the click starts is saved where the browser's save dialog proposes, and the result names the file.
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": "tab_click"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| x | No | CSS pixels from the top-left corner of the viewport, for a page that draws on a canvas (a design tool, a map) and has no element to name: read the point off a tab_screenshot, scaling its pixels by the viewport width it reports divided by the image's width. Give x and y together, instead of a ref. | |
| y | No | CSS pixels from the top-left corner of the viewport, for a page that draws on a canvas (a design tool, a map) and has no element to name: read the point off a tab_screenshot, scaling its pixels by the viewport width it reports divided by the image's width. Give x and y together, instead of a ref. | |
| ref | No | Element ref: the number in brackets in tab_read output, e.g. 12 for "[12] button". Refs stay valid while the element stays on the page. | |
| tabId | No | Tab id from tab_list or tab_read. Defaults to the active tab of the browser window the user used last. | |
| button | No | Mouse button. Defaults to left. | |
| waitFor | No | Text the click makes appear after a load the page shows as loading, such as the button of an export being prepared: the result waits up to 30 seconds for it before reporting what changed. | |
| modifiers | No | Modifiers held during the action: Shift, Alt (Option), Meta (Command), Control. E.g. ["Meta"] for a Cmd+click that adds to a selection, ["Alt"] for an Option-drag that duplicates in a design tool. | |
| doubleClick | No | Double-click instead of a single click. Defaults to false. |