Skip to main content
Glama

iphone_tap

Trigger single, double, or long-press touches at exact iPhone screen coordinates. Use positions from the UI tree or screenshot to act on whatever is at that point.

Instructions

Touch the screen at a coordinate: single tap, double tap or long press.

Use it when you know the position – from iphone_ui_tree (center point) or iphone_screenshot (pixel =
point). To hit an element by its visible text, iphone_tap_text is more robust. The touch acts on
whatever is at that point, like a finger would; it does not wait for the app to finish reacting, so
look again (or call iphone_wait_for) before the next step.

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": "iphone_tap"
  }
}

Input Schema

NameRequiredDescriptionDefault
xYesHorizontal position in iOS points, from the left edge (0) to the screen width shown by iphone_status / iphone_screenshot.
yYesVertical position in iOS points, from the top edge (0) to the screen height shown by iphone_status / iphone_screenshot.
gestureNo'tap' = single tap (buttons, links, fields); 'double' = double tap (zoom, select a word); 'long' = touch and hold (context menus, moving icons).tap
hold_secondsNoHow long to hold for gesture='long' (0.3–10 s).

Output Schema

NameRequiredDescriptionDefault
resultYes

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed6 schema fields changedv0.2.0
    • addedInput schema / properties / gesture
      Added value: +{
      +  "default": "tap",
      +  "description": "'tap' = single tap (buttons, links, fields); 'double' = double tap (zoom, select a word); 'long' = touch and hold (context menus, moving icons).",
      +  "enum": [
      +    "tap",
      +    "double",
      +    "long"
      +  ],
      +  "title": "Gesture",
      +  "type": "string"
      +}
    • addedInput schema / properties / hold_seconds
      Added value: +{
      +  "default": 1,
      +  "description": "How long to hold for gesture='long' (0.3–10 s).",
      +  "maximum": 10,
      +  "minimum": 0.3,
      +  "title": "Hold Seconds",
      +  "type": "number"
      +}
    • addedInput schema / properties / x / description
      Added value: +"Horizontal position in iOS points, from the left edge (0) to the screen width shown by iphone_status / iphone_screenshot."
    • addedInput schema / properties / x / minimum
      Added value: +0
    • addedInput schema / properties / y / description
      Added value: +"Vertical position in iOS points, from the top edge (0) to the screen height shown by iphone_status / iphone_screenshot."
    • addedInput schema / properties / y / minimum
      Added value: +0
  2. First observedv0.1.0

TDQS

A4.7/5.0
Behavior4/5

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

Annotations already declare readOnlyHint=false, openWorldHint=true, idempotentHint=false, and destructiveHint=false. The description adds important behavior beyond that: the touch acts on whatever is at the point like a finger, does not wait for the app to react, and requires re-checking or waiting before the next step. It does not cover edge cases such as out-of-bounds coordinates, but it substantially improves behavioral understanding.

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?

The description is three sentences and front-loads the core action before usage guidance and behavioral caveats. Every sentence carries useful information: what it does, when to use it versus alternatives, and how it behaves. There is no redundant or filler wording.

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 four-parameter tap tool with annotations and an output schema, the description is complete enough to call correctly. It covers coordinate sourcing, gesture choices, the better alternative for text targeting, and the non-blocking behavior that affects subsequent steps. Detail about coordinate bounds and hold duration is already handled by the schema.

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 100%, so the schema already documents x, y, gesture, and hold_seconds. The description still adds practical meaning by explaining where coordinates come from: iphone_ui_tree center points and iphone_screenshot pixel coordinates, with pixel equal to point. It reinforces the gesture modes but leaves detail such as hold_seconds to the schema.

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?

The description states a specific verb and resource: 'Touch the screen at a coordinate' with single tap, double tap, or long press. It clearly distinguishes this from iphone_tap_text by explaining that text-based targeting is more robust when hitting an element by visible text. An agent can tell exactly what this tool does and how it differs from siblings.

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?

It gives explicit when-to-use guidance: use this when you know the position from iphone_ui_tree or iphone_screenshot. It names the alternative iphone_tap_text for visible text and explains the pixel-equals-point convention. It also tells the agent to look again or call iphone_wait_for before the next step, which is actionable sequencing guidance.

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