Skip to main content
Glama
Neem2004

Android ADB MCP Server

adb_dump_hierarchy

Dump the Android device's current UI hierarchy as XML/text via uiautomator to inspect the visible layout. Falls back to /sdcard/window_dump.xml; may be empty if no window is focused.

Instructions

Returns the current UI hierarchy of the Android device as XML/text via uiautomator. Tries /dev/tty first and falls back to /sdcard/window_dump.xml. May return empty when no window is focused. Useful to understand the visible layout. / Devuelve la jerarquía de la UI actual del dispositivo como texto/XML vía uiautomator. Prueba /dev/tty primero y cae a /sdcard/window_dump.xml como respaldo. Puede devolver vacío cuando no hay ventana enfocada. Útil para entender el layout visible.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

A3.7/5.0
Behavior4/5

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

With no annotations, the description carries the full burden and does meaningful work: it discloses the internal fallback chain (/dev/tty first, then /sdcard/window_dump.xml) and a real failure mode (may return empty when no window is focused). It does not state permissions or whether the device/ADB must be connected, which keeps it short of 5.

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

Conciseness3/5

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

The content is front-loaded and the English sentence is efficient, but the entire description is duplicated verbatim in Spanish, roughly doubling the token cost with zero added information for an agent that reads either language. No other waste is present.

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?

There is no output schema, so the description must cover the return value, and it does: XML/text, with the caveat that an empty result means no focused window. For a zero-parameter, read-only inspection tool with a fallback path already described, this is essentially complete; only connection/permission prerequisites are unstated.

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?

The tool takes zero parameters, so there are no parameter semantics to explain and the baseline is 4. The description correctly does not invent parameters or claim configurable options that the empty schema does not support.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose4/5

Does the description clearly state what the tool does and how it differs from similar tools?

States a specific verb and resource: returns the current UI hierarchy of the Android device as XML/text via uiautomator. An agent can tell this apart from the logcat/package/shell siblings without opening a schema. It does not explicitly name those siblings or contrast with them, which keeps it at 4 rather than 5.

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?

"Useful to understand the visible layout" gives implied usage context, so the agent knows this is a layout-inspection tool. However there is no explicit when-to-use vs. when-not guidance and no alternative named (e.g., adb_execute_shell running uiautomator directly), leaving the selection decision to inference.

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