Skip to main content
Glama

Tap

tap

Press a React Native element by text, testID, or x/y coordinates; use duration_ms for long press and via for JS handler or OS touch, returning coordinates, path, and screen changes.

Instructions

Tap an element by text, testID, or x+y coordinates. Pass duration_ms for a long press. via picks the delivery path (js = call the component's own press handler through the app runtime, os = a real simulator/device touch, default auto). Returns the coordinates tapped, the path used, and what changed on screen.

Input Schema

NameRequiredDescriptionDefault
xNo
yNo
viaNo
textNo
deviceNo
testIDNo
duration_msNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.4/5.0
Behavior4/5

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

With no annotations, the description carries the burden and does well: it discloses the default delivery path ('default auto'), the two execution semantics (calling the component's own handler through the app runtime vs a real device touch), and what is returned (coordinates, path used, screen changes). It omits failure behavior, such as what happens when text/testID matches nothing or matches multiple elements.

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, front-loaded with the core action and targeting modes before the modifiers and the return contract. No filler or restated name.

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

Completeness4/5

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

For a 7-parameter tool with no annotations and no output schema, the description covers the essential contract including return values and the default path. The remaining gaps are the undocumented 'device' parameter and ambiguous-selector/error handling, which an agent would need in edge cases.

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

Parameters4/5

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

Schema coverage is 0%, so the description must compensate and largely does: text, testID, x, y, duration_ms, and the via enum are all given meaning beyond their names. However, the 7th parameter 'device' is never mentioned, and the precedence between element selectors and coordinates (or whether x and y must be supplied together) is left unspecified.

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 an element') and enumerates the three targeting modes (text, testID, x+y coordinates), which cleanly separates it from siblings like swipe, type_text, and press_key. An agent can pick this tool without opening the schema.

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

Usage Guidelines4/5

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

It gives conditional guidance within the tool: duration_ms selects a long press, and via selects js vs os with an explicit 'auto' default. It does not name alternatives (e.g. when to prefer swipe or scroll_to instead), so exclusion guidance is absent.

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