Skip to main content
Glama

Robot Actions — Remote Device Control

device_two_finger_swipe

Two-finger swipe from (x1,y1) to (x2,y2) on an Android device — a two-finger scroll/pan. Both fingers travel the vector in parallel, offset perpendicular to it so one never runs through the other. Use where a one-finger swipe does the wrong thing, e.g. tilting a map or scrolling a view that pans with one finger. Coordinates are PHYSICAL pixels.Pass input="hid" to require the virtual touchscreen: the gesture then reaches the app as real kernel input and fails loudly instead of silently falling back to injected input. That strict path used to be device_uhid_two_finger_swipe, which stays callable under its old name.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
x1YesStart X
x2YesEnd X
y1YesStart Y
y2YesEnd Y
gapNoPixels between the two contacts (default: 120)
udidYesDevice serial number (UDID)
inputNoInput path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly.
durationNoGesture duration in ms (default: 400)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changed
    • changedInput schema / properties / input / description
      Previous value: -"Input path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly."New value: +"Input path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly."
  2. Changed1 schema field changed
    • changedInput schema / properties / input / description
      Previous value: -"Input path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly."New value: +"Input path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly."
  3. Changed1 schema field changed
    • addedInput schema / properties / input
      Added value: +{
      +  "description": "Input path. 'auto' (default) prefers the virtual touchscreen and falls back to injected input. 'hid' requires the virtual touchscreen and fails if the device does not provide one — use it when the gesture must be real kernel input or must fail loudly.",
      +  "enum": [
      +    "auto",
      +    "hid"
      +  ],
      +  "type": "string"
      +}
  4. Added

TDQS

A4.9/5.0
Behavior5/5

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

With no annotations provided, the description carries the full behavioral burden, and it excels: it discloses the perpendicular finger offset geometry, PHYSICAL pixel units, the injected-input fallback behavior, and the loud-failure mode for input='hid'. This goes well beyond the structured schema and leaves the agent well-informed about runtime behavior.

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?

Every sentence earns its place: primary action, geometry detail, use case, coordinate units, strict input behavior, and legacy alias. The most decision-relevant information is front-loaded, and there is no filler or repetition.

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 gesture tool with 8 parameters, a rich schema, and no output schema, this description is complete: it explains what the gesture does, how the fingers move, when to prefer it over a one-finger swipe, what input='hid' changes, and how to refer to the legacy tool. Nothing essential for selection or invocation is missing.

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 baseline is 3. The description adds meaning beyond the schema by clarifying that coordinates are physical pixels and explaining how gap relates to the perpendicular finger offset. It also expands the input parameter's behavior beyond the enum text, though it does not walk through every parameter individually.

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 action ('two-finger swipe') on a specific resource (Android device) with explicit coordinates. It also differentiates itself from one-finger swipe by giving concrete examples like tilting a map, so an agent can distinguish it from device_swipe and similar gesture tools.

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?

Gives explicit guidance on when to use this tool: when a one-finger swipe does the wrong thing, with examples. It also explains when to choose input='hid' versus the default behavior, and even mentions the old alias device_uhid_two_finger_swipe, removing ambiguity about legacy call patterns.

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

Try in Browser

Glama MCP Gateway

Add one secure layer between your agents and this server.

Resources