Skip to main content
Glama

desktop_click_element

Clicks or invokes a visible UI control by matching its text within a specified window, using UI Automation when supported and falling back to a center click.

Instructions

元素级执行:按可见文本定位控件并触发它。 优先用 UI Automation 的 InvokePattern(对按钮最可靠),不支持时退回点击其中心。 会真实操作界面,调用前请确认控件名称。

Input Schema

NameRequiredDescriptionDefault
nameYes控件文本,支持模糊匹配,如 "确定"
handleYes窗口句柄
verifyNo截图比对前后变化
verifyRegionNo只比对这块矩形(一般传该窗口的 rect),不传则全屏

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.2.2

TDQS

B3.4/5.0
Behavior3/5

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

With no annotations, the description carries the full burden, and it does disclose the crucial trait that this "会真实操作界面" (really manipulates the live UI) plus the fallback to clicking the element's center, which implies positional mis-click risk. It leaves open what happens on fuzzy multi-match or no-match, and says nothing about the effects of verify/verifyRegion.

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?

Three compact lines: the action, the dispatch strategy, then the safety caution. Front-loaded and free of filler, though the middle line leans toward implementation detail an agent cannot act on.

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

Completeness3/5

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

For a live-UI mutation tool with no annotations and no output schema, the description covers the safety warning and matching strategy but omits the result contract (what is returned on success/failure) and multi-match ambiguity handling with fuzzy text. Adequate but with clear gaps.

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

Parameters3/5

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

Schema description coverage is 100%, so name, handle, verify and verifyRegion are already documented in the schema; that sets the baseline at 3. The description reinforces the text-matching intent of `name` but adds no meaning beyond the schema for handle or the screenshot-comparison parameters.

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

Purpose4/5

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

"元素级执行:按可见文本定位控件并触发它" gives a specific verb (trigger) plus a specific locating strategy (visible text), which distinguishes it from the coordinate-based sibling desktop_click. It stops short of naming desktop_click/desktop_elements explicitly as the alternative, so the differentiation is implied rather than stated.

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

Usage Guidelines3/5

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

The "prefer InvokePattern, fall back to center click" sentence describes internal dispatch, not when an agent should choose this tool over desktop_click or desktop_elements. The only actionable directive is the caution to confirm the control name first; there is no explicit when-not condition or named alternative.

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