Skip to main content
Glama

adb_input_long_press

Simulate a long press at specified screen coordinates to open context menus, enter selection mode, or activate drag handles using a configurable hold duration.

Instructions

Long press at a point on screen. Triggers context menus, selection mode, drag handles, and other long-press behaviors. Implemented as a zero-distance swipe with configurable hold duration.

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

Input Schema

NameRequiredDescriptionDefault
xYesX coordinate
yYesY coordinate
deviceNoDevice serial
durationMsNoHold duration in ms (300-10000, default 1500)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.1.6
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Changed1 schema field changedv1.1.3
    • removedInput schema / additionalProperties
      Removed value: -false
  3. First observedv1.1.1

TDQS

A4.2/5.0
Behavior4/5

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

With no annotations supplied, the description carries the full burden, and it discloses a genuinely useful implementation trait: the gesture is a zero-distance swipe with configurable hold duration, which warns the agent that the system may classify it as a swipe. It does not state prerequisites (screen on/unlocked) or whether it waits for the gesture to complete before returning.

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 short sentences, front-loaded with the action, then the triggering behaviors, then the mechanism. Nothing is redundant or padded.

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 four-parameter input tool with full schema coverage and no output schema, the description covers what the tool does and how it is implemented. The remaining gap is state prerequisites and post-gesture behavior, which an agent would otherwise have to discover through failure.

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%, with x/y, device serial, and durationMs (300-10000, default 1500) all documented in the schema, so the baseline is 3. The description only adds that the point is the press origin of a zero-distance swipe and that duration is configurable, which is marginal beyond 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 opens with a specific verb+resource ('Long press at a point on screen') and then enumerates the concrete outcomes it produces (context menus, selection mode, drag handles), which distinguishes it from tap, double-tap, and drag siblings. An agent can identify the tool's effect 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?

The list of triggered behaviors gives clear context for when to reach for it: use it when a context menu or selection mode is the goal. There is no explicit when-not guidance or named alternative (e.g. adb_input_drag / adb_input_double_tap), so it stops short of full routing guidance.

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

Deploy Server

Other Tools