Skip to main content

adb-automation-mcp

CI PyPI

An MCP server exposing Android Debug Bridge (ADB) capabilities as typed, documented tools and resources.

Full documentation — architecture, decision log, per-tool reference, and client integration guides.

Install

uvx adb-automation-mcp
# or
pip install adb-automation-mcp

Quickstart

uv sync
uv run adb-automation-mcp

Talks to the adb binary on PATH by default. For real-device setup, the fake backend, the full tool list, and per-client integration guides (Claude Code, Claude Desktop, ...), see the docs site.

Installation prompt

Prefer not to configure this by hand? Hand the AI-assisted install prompt to an AI coding assistant that can run shell commands and edit MCP config (Claude Code, GitHub Copilot in agent mode, ...) — it detects/installs uv, resolves adb's absolute path, and registers this server for you.

MCP client configuration

Add this to your client's mcp.json (e.g. Claude Desktop's config, or a Claude Code project's .mcp.json). Every real-device env var is shown below — all are optional, see the full reference for defaults and details (including ADB_AUTOMATION_BACKEND, a testing-only switch to the fake in-memory backend, not something a real client config needs):

{
  "mcpServers": {
    "adb-automation-mcp": {
      "command": "uvx",
      "args": ["adb-automation-mcp"],
      "env": {
        "ADB_AUTOMATION_ADB_PATH": "/path/to/platform-tools/adb",
        "ADB_AUTOMATION_TIMEOUT_S": "10",
        "ADB_AUTOMATION_ALLOW_DESTRUCTIVE": "1",
        "ADB_AUTOMATION_LOCAL_ROOT": "/path/to/local/root"
      }
    }
  }
}
  • ADB_AUTOMATION_ADB_PATH — explicit path to the adb binary; MCP clients usually launch the server with a minimal environment that doesn't include your shell's PATH customizations, so set this explicitly rather than relying on PATH resolution
  • ADB_AUTOMATION_TIMEOUT_S — per-command timeout in seconds
  • ADB_AUTOMATION_ALLOW_DESTRUCTIVE=1 — allow destructive-category tools (e.g. remove_user); denied by default
  • ADB_AUTOMATION_LOCAL_ROOT — the folder on this machine where file-saving tools (pull_file, stop_log_session, take_screenshot) are allowed to write; unset means those tools refuse to write anywhere

Testing

uv run pytest        # meta (Layer 0), unit (Layer 1), and e2e (Layer 3) tests
uv run mypy src       # strict type checking
uv run ruff check .   # lint
uv run mkdocs build --strict   # docs site

Tools

42 tools. Full signatures, docstrings, and worked examples are in the tool reference. Tools marked † are destructive — not registered unless ADB_AUTOMATION_ALLOW_DESTRUCTIVE=1.

Module Tools
activities (1) start_activity
android_services (1) start_service
app_data (1) clear_app_data
broadcasts (1) send_broadcast
connection (4) restart_adb_server, connect_device, disconnect_device, restart_adbd_as_root
date_time (1) get_date_time
device_info (1) list_connected_devices
diagnostics (1) check_adb_available
files (1) pull_file
input (1) tap
logger (6) read_logs, clear_logs, get_log_buffer_size, read_package_logs, start_log_session, stop_log_session
network (1) list_network_interfaces
packages (4) list_packages, install_apk, uninstall_package†, install_existing_for_user
permissions (1) grant_permission
power (1) get_power_state
processes (1) force_stop_app
screen (1) take_screenshot
settings (1) get_setting
system_properties (4) get_property, list_properties, get_property_metadata, set_property
ui (1) dump_ui_hierarchy
user (8) get_current_user, dump_user, user_info, list_users, switch_user, create_user, remove_user†, get_user_capabilities

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

adb_automation_mcp-0.1.1.tar.gz (328.2 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

adb_automation_mcp-0.1.1-py3-none-any.whl (141.2 kB view details)

Uploaded Python 3

File details

Details for the file adb_automation_mcp-0.1.1.tar.gz.

File metadata

  • Download URL: adb_automation_mcp-0.1.1.tar.gz
  • Upload date:
  • Size: 328.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for adb_automation_mcp-0.1.1.tar.gz
Algorithm Hash digest
SHA256 168f67c4b540765cd4366822c8a2e48a5232e924f86aee8a346ecb9fe3418a39
MD5 fa3fa1e0f23e4e5892113eb8103f2d8f
BLAKE2b-256 a96409be5e191d5a0a78deff61e268a9e485422dc4f5e431713342226508e0a8

See more details on using hashes here.

Provenance

The following attestation bundles were made for adb_automation_mcp-0.1.1.tar.gz:

Publisher: publish.yml on allaudin/adb-automation-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file adb_automation_mcp-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for adb_automation_mcp-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 d77d3692954cd40559ca8514abea7039dc769e3a04ba50965ab380f5e1626830
MD5 cafe62df76d9fb4d9945e8a6b36a7871
BLAKE2b-256 1886533c7e031a326c0f422049ff986e9620babd68274876402abdacda436d5c

See more details on using hashes here.

Provenance

The following attestation bundles were made for adb_automation_mcp-0.1.1-py3-none-any.whl:

Publisher: publish.yml on allaudin/adb-automation-mcp

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Release history Release notifications | RSS feed

1.0.1

2 files

0.2.0

2 files

This release

0.1.1 This release

2 files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page