Skip to main content
Glama

adb_workflow_run

Run JSON-defined Android device workflows with variable substitution, conditional steps, and loops to automate shell, install, screenshot, logcat, and other ADB tasks.

Instructions

Execute a workflow — a JSON-defined sequence of device operations with variable substitution, conditional steps, and loop support. Supported actions: shell, root_shell, install, screenshot, logcat, getprop, sleep. Pass the workflow as a JSON string or provide a saved workflow name.

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": {
      "workflow": "<workflow>"
    },
    "name": "adb_workflow_run"
  }
}

Input Schema

NameRequiredDescriptionDefault
deviceNoDevice serial
dryRunNoValidate and show execution plan without running
workflowYesWorkflow JSON string, or the name of a saved workflow file
variablesNoOverride workflow variables (merged with defaults)

Schema Changelog

Changes observed during successful MCP inspections.

  1. Changed1 schema field changedv1.1.6
    • changedInput schema / $schema
      Previous value: -"http://json-schema.org/draft-07/schema#"New value: +"https://json-schema.org/draft/2020-12/schema"
  2. Changed2 schema fields changedv1.1.3
    • removedInput schema / additionalProperties
      Removed value: -false
    • addedInput schema / properties / variables / propertyNames
      Added value: +{
      +  "type": "string"
      +}
  3. First observedv1.1.1

TDQS

B3.3/5.0
Behavior2/5

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

No annotations are supplied, so the description carries the full behavioral burden. It discloses the action vocabulary and that conditional steps and loops are supported, but says nothing about failure semantics (does the workflow abort on a failed step?), timeouts, permission or root requirements, or that actions like install and root_shell mutate device state destructively. For an execution tool with no annotation coverage, that is a substantial gap.

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?

Two sentences, front-loaded with the core verb and resource, then the action vocabulary and calling convention. No filler or restated name/title; every clause carries information.

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 complex orchestration tool with no annotations and no output schema, the description covers what the tool is and what it can run, but leaves out what it returns, how partial failures are reported, and whether dryRun is the safe preview path. It is adequate to select the tool but not fully sufficient to invoke it confidently.

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 all four parameters including dryRun and variables are already documented in the schema; baseline 3 applies. The description adds only marginal meaning beyond it, mentioning variable substitution and the JSON-string-or-saved-name duality, both of which the schema already states.

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 ('Execute a workflow') and immediately defines it as a JSON-defined sequence of device operations, then enumerates the supported action vocabulary (shell, root_shell, install, screenshot, logcat, getprop, sleep). That enumeration meaningfully separates it from single-purpose siblings like adb_shell or adb_install, though it never explicitly names adb_workflow_validate or adb_workflow_list as the non-executing counterparts.

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?

The second sentence gives a practical calling convention ('Pass the workflow as a JSON string or provide a saved workflow name'), which is real usage guidance. However, there is no when-to-use vs when-not guidance against adb_workflow_validate, adb_batch_actions, adb_multi_shell, or adb_test_session_start, and no prerequisites or preconditions are stated.

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

Deploy Server

Other Tools