Skip to main content
Glama

execute_adb_command

Execute Android Debug Bridge commands to control devices and emulators programmatically, with safe parsing to prevent shell injection.

Instructions

The output of an ADB command. Parsed safely via shlex and never passed to a system shell.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
commandYesADB command to execute. Parsed safely — no shell injection possible.
use_shellNoWhen True, runs as an Android shell command (adb shell ...). When False, runs as a top-level ADB command (adb devices, adb install, etc.).
device_serialNoAndroid device serial (e.g. 'emulator-5554' or '192.168.1.10:5555'). Omit only when a single device is connected. If the tool returns a multi-device error: STOP. Present the device list to the user verbatim and wait for their explicit choice. Do NOT retry with a guessed or inferred serial — this is a hard requirement. Once the user provides a serial, use it for every subsequent call in this session. To switch devices mid-session, ask the user first.

Output Schema

TableJSON Schema
NameRequiredDescriptionDefault
resultYes
Behavior4/5

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

With no annotations provided, the description carries the full burden. It discloses safety traits (parsed safely via shlex, no shell injection) and implies execution behavior, but doesn't cover rate limits, auth needs, or error handling beyond device serial instructions in the schema. It adds useful context beyond the schema.

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?

The description is a single, efficient sentence with zero waste, front-loaded with the core purpose. It's appropriately sized and structured without unnecessary elaboration.

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?

Given 3 parameters, 100% schema coverage, and an output schema (implied by 'Has output schema: true'), the description is reasonably complete. It covers safety aspects but could benefit from more context on tool scope versus siblings. The output schema likely handles return values, reducing the need for description details.

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%, so the schema already documents all parameters thoroughly. The description doesn't add meaning beyond what the schema provides, such as explaining parameter interactions or usage examples. Baseline 3 is appropriate when schema does the heavy lifting.

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

Purpose3/5

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

The description states the tool executes an ADB command and mentions safe parsing via shlex, but it's vague about what ADB commands are (Android Debug Bridge) and doesn't clearly distinguish from siblings like press_key or type_text which are specific ADB operations. It doesn't specify the verb+resource combination explicitly.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines2/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

No guidance on when to use this tool versus sibling tools like press_key or type_text, which are specific ADB operations. The description lacks explicit when/when-not instructions or alternatives, leaving usage context unclear.

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

Install Server

Other Tools

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/Neverlow512/agent-droid-bridge'

If you have feedback or need assistance with the MCP directory API, please join our Discord server