Skip to main content
Glama

click

Destructive

Clicks at absolute pixel coordinates in a sandboxed browser or desktop instance and returns what was under the point, optionally with the resulting screen state.

Instructions

Click at absolute pixel coords (top-left origin) in an instance.

For anything with a label, find_elements('Save') -> click_element(id) beats guessing pixels. Returns {"ok", "action", "instance", "detail", "hit"?, "warnings"?}. "hit" (Chromium-family browsers only, read from the page's DOM just before the click) names what was under the point: {"role": "checkbox", "name": "Remember me", "tag", "checked_before", "disabled", "href", …} or {"role": "browser-ui"} for the toolbar/tab strip — compare it with what you meant to click; it is absent for native apps. "warnings" appears when the pointer was not where this server left it (a person or another agent is using the instance — re-screenshot). button: 1=left, 2=middle, 3=right. count: 1–3 clicks (2 = double-click, 3 = triple-click selects a line/paragraph). modifiers: keys held during the click — 'ctrl' (open in new tab / multi-select), 'shift' (range select), 'alt', 'super', combinable 'ctrl+shift'; released afterwards whatever happens. observe='screenshot'|'parse'|'elements'|'changes' additionally returns the resulting screen state in the SAME call (saves a round-trip): the image, the image plus the parsed elements, the element list alone (no image tokens), or only what the action CHANGED — "changes": {appeared: [elements with fresh ids], disappeared, changed: [{id, label, before, after} for states/value], focus?, page?: {before, after}, unchanged: n} from the app's accessibility information before and after (fails before acting, with the fix, for apps that expose none); settle_ms (max 5000, "settle_clamped": true if you asked for more) waits for the UI to update first — use 400–1500 after anything that navigates or submits, or wait_for_stable() when you don't know how long. observe_region='x,y,w,h' crops that screenshot to the part you care about (implies observe='screenshot'; far fewer tokens than the full display; validated before the action). Fails (isError) if the instance is down, the coordinates are outside the display or a modifier name is unknown (nothing is clicked then). A failed observation after a successful click is reported as "observed": false inside an ok result — the click is not repeated.

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": {
      "x": "<x>",
      "y": "<y>"
    },
    "name": "click"
  }
}

Input Schema

NameRequiredDescriptionDefault
xYes
yYes
countNo
buttonNo
observeNonone
instanceNo
modifiersNo
settle_msNo
observe_regionNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed3 schema fields changedv0.6.1
    • addedInput schema / properties / count
      Added value: +{
      +  "default": 1,
      +  "title": "Count",
      +  "type": "integer"
      +}
    • addedInput schema / properties / modifiers
      Added value: +{
      +  "default": "",
      +  "title": "Modifiers",
      +  "type": "string"
      +}
    • addedInput schema / properties / observe_region
      Added value: +{
      +  "default": "",
      +  "title": "Observe Region",
      +  "type": "string"
      +}
  2. First observedv0.1.0

TDQS

A4.9/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Goes well past the annotations (readOnly=false, destructive=true, openWorld=true) by disclosing the "hit" DOM read-back for Chromium so the agent can verify what was under the cursor, and the "warnings" signal when another actor moved the pointer (re-screenshot). It also enumerates failure semantics precisely: isError with nothing clicked for a downed instance, out-of-display coords, or unknown modifier, and a post-click observation failure reported as observed:false inside an ok result rather than re-clicking.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness4/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Front-loaded with the core pixel-click statement and the sibling alternative, then organized by parameter concern. It is a dense single block — a bulleted per-parameter layout would scan faster — but no sentence is filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a nine-parameter, destructive, coordinate-driven tool with no output schema and no parameter documentation, the description covers return shape, verification signal, failure modes, and timing guidance. An agent can call this correctly and interpret the result without further information.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema coverage is 0% — the schema only has bare titles — so the description carries the entire burden and does: coordinate origin, button 1/2/3 mapping, count 1–3 with double/triple-click effects, named modifiers with combinability and release behavior, observe enum modes with the change-diff payload shape, settle_ms cap of 5000 with settle_clamped, and observe_region 'x,y,w,h' syntax with its implicit observe='screenshot'.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource with scope: "Click at absolute pixel coords (top-left origin) in an instance." It immediately distinguishes itself from the label-based sibling by naming find_elements('Save') -> click_element(id) as the better path when a label exists.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

Explicitly routes the agent: prefer find_elements/click_element when anything has a label, and only guess pixels otherwise. It also gives conditional guidance for settle_ms (400–1500 after navigation/submits) and the fallback wait_for_stable() when timing is unknown, plus which observe mode to pick.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.