Skip to main content
Glama

run_shell

Execute arbitrary commands on an Android device after opting in via ADB_MCP_ALLOW_SHELL, serving as a fallback when scoped tools cannot complete the task. Returns rc and output.

Instructions

Run an arbitrary device shell command. DISABLED by default — set the env var ADB_MCP_ALLOW_SHELL=1 to enable. Prefer the specific scoped tools; this exists only as an explicit, opt-in escape hatch. Returns {rc, output}.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
serialNo
commandYes
timeoutNo

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault

No arguments

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.3/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 well: it discloses that the tool is DISABLED by default and requires an env var to enable, and gives the return shape {rc, output}. It stops short of stating that commands execute with device shell privileges or any timeout/failure semantics, so not fully complete for an arbitrary-execution escape hatch.

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 tightly packed sentences: purpose first, then gating/opt-in behavior, then return shape. No filler, front-loaded, and every sentence adds actionable information.

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?

An output schema exists and the description still concisely summarizes {rc, output}. Purpose, gating, and alternative-routing are all covered; the only gap is the undocumentable-from-schema parameter semantics (serial/timeout), which is minor for an escape-hatch tool.

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

Parameters2/5

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

Schema description coverage is 0%, so the description must compensate for three undocumented params, but it only loosely implies the 'command' param. The 'serial' target and 'timeout' (units, default 30) are explained nowhere, leaving the agent to infer them.

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 (run) and resource (arbitrary device shell command), and immediately positions itself against the ~90 scoped siblings as the general-purpose escape hatch. An agent can distinguish it from list_packages, push, dumpsys, etc. without opening any schema.

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?

Explicitly says 'Prefer the specific scoped tools' and frames itself as 'only an explicit, opt-in escape hatch', giving a clear when-not-to-use rule plus the enablement condition (ADB_MCP_ALLOW_SHELL=1). This is exactly the routing guidance needed for a fallback tool.

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