Skip to main content
Glama

Tap screen

phone_tap

Tap an Android screen by pixel coordinates or by a UI element captured in the last observation. Optionally long-press and return the resulting screen.

Instructions

Tap by pixel coordinates (x,y) or by an element from the last phone_observe (index, text, resourceId, contentDesc). Optional durationMs performs a long-press. Returns the resulting screen.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
xNo
yNo
textNoMatch element text or content-desc
indexNoElement index from the last phone_observe list
observeNoRe-dump the UI after the action (default true)
settleMsNoWait before re-observing, milliseconds
classNameNoClass name substring, e.g. EditText
durationMsNoLong-press duration
resourceIdNoAndroid resource-id (full or short)
contentDescNocontent-desc exact match
packageNameNoOwning package name
textContainsNo
includeScreenshotNoInclude a PNG screenshot in the response

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A3.7/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 behavioral burden. It does disclose a key trait — that the tool returns the resulting screen and that durationMs turns the tap into a long-press — which is valuable given there is no output schema. It omits other meaningful behavior, such as the default UI re-dump after each action (observe default true) and the settleMs wait, both of which affect timing and latency.

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

Conciseness5/5

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

Three tight sentences with zero filler: the action plus targeting modes first, then the long-press modifier, then the return behavior. Front-loaded and every sentence earns its place, especially the return-value statement given the absence of an output schema.

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 13-parameter, annotation-free, output-schema-free tool, the description is only partially complete. It covers the targeting model and return behavior adequately, but leaves six parameters (including behaviorally significant ones like observe and settleMs) unexplained and does not describe failure modes when an element selector matches nothing.

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 77%, close to the high-coverage baseline, so the schema already documents most parameters. The description adds real semantic value by grouping the element selectors (index, text, resourceId, contentDesc) as alternatives drawn from the last phone_observe, but it says nothing about the remaining params (className, packageName, textContains, observe, settleMs, includeScreenshot).

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 ('tap' on the screen) and explicitly defines the two targeting modes: pixel coordinates or an element from the last phone_observe. This clearly separates it from siblings like phone_swipe, phone_type, and phone_key, and it names the observe dependency that makes the element-targeting mode work.

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?

Usage is implied through the two targeting modes and the note that long-press is achieved via durationMs, plus the prerequisite that element-based taps must reference the last phone_observe. However, there is no explicit when-to-use/when-not guidance and no routing to alternatives (e.g., phone_swipe for gestures, phone_type for text entry), so the agent must infer the boundaries.

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