Skip to main content
Glama
Mobile Device Farm MCP

Mobile Device Farm MCP

adb_shell

Executes raw ADB shell commands on a connected Android device to inspect system state, debug issues, or automate device tasks.

Instructions

Run a raw ADB shell command (use carefully).

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": {
      "command": "<command>"
    },
    "name": "adb_shell"
  }
}

Input Schema

NameRequiredDescriptionDefault
commandYesCommand to run inside 'adb shell'
deviceIdNo

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv1.0.0

TDQS

C2.9/5.0
Behavior2/5

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

With no annotations, the description carries the full behavioral burden, and it delivers almost nothing beyond the parenthetical warning. It does not say whether arbitrary commands run with device-level privileges, whether output is captured or truncated, how errors or non-zero exit codes are surfaced, whether there is a timeout, or what happens if the device is not connected. An unrestricted command-execution tool deserves far more disclosure.

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 single sentence is front-loaded with zero filler, so it is maximally concise. However, the brevity is achieved by omission rather than economy, leaving the structure too thin to guide correct invocation of a high-risk tool.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness3/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a two-parameter tool with no output schema and no annotations, a short description could suffice, but raw shell execution is inherently complex and the definition omits return format, error behavior, timeout, and device-targeting rules. The safety warning is present but unelaborated, leaving real gaps for an agent deciding whether and how to call it.

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 coverage is only 50%: 'command' is documented in the schema, but 'deviceId' has no description anywhere. The description adds no meaning to either parameter, not even clarifying that command strings run inside the device shell versus the host, nor the format expected for deviceId (serial, index, or alias).

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+resource: 'Run a raw ADB shell command'. The word 'raw' signals this is the generic escape hatch as opposed to the purpose-built siblings like adb_tap, adb_input_text, or adb_install, so an agent can distinguish it without opening a schema. It stops short of explicitly naming a sibling or the scope of what commands are permitted.

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?

'(use carefully)' implies caution but gives no actual condition for choosing this over the many specific ADB tools in the catalog. There is no when-to-use, when-not-to-use, or stated alternative, so an agent must infer that this is the fallback for commands the dedicated tools don't cover.

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