agent-device is an open-source mobile app automation and verification tool from Callstack, with the goal of giving AI coding agents a real-time feedback loop for a running app. Agents can inspect, control, debug, and verify apps through the CLI, a built-in MCP server, or a typed Node.js API.
Purpose: let coding agents verify their changes in a real running app, read a streamlined snapshot based on the accessibility tree rather than relying only on screenshots, perform actions through refs and selectors, and save reviewable evidence.
Main capabilities: inspect app state (accessibility snapshots, refs, selectors, and analyze React Native rendering performance); operate the visible UI (tap, type, scroll, gestures, wait, assert, handle dialogs); diagnose failures (screenshots, video, logs, traces, network data, performance sampling, crash information, React profiles); save steps as .ad scripts for local or CI replay, and also export strict Maestro YAML.
Supported platforms: iOS, Android, HarmonyOS simulators, emulators, and real devices, as well as tvOS, Android TV, Amazon Vega OS TV, Web, macOS, and Linux. Different targets have different depths of support; use agent-device capabilities --platform <platform> to view them.
How to use: install the CLI and check the environment, requiring Node.js 22.12 or higher, and Web automation requires Node.js 24 or higher; run doctor yourself before handing it to an agent. agent-device mcp starts the official stdio MCP server; createAgentDeviceClient() provides typed Node.js access. Sessions are isolated by the caller's git worktree, and device claims can prevent parallel agents from seizing simulators from each other; use agent-device device status to view ownership, and agent-device device release --stale to release invalid claims.
Use cases: works with agents such as Claude Code, Codex, Cursor, Windsurf, Cline, Goose, and others that can run a CLI or connect to MCPit supports native iOS/Android apps and React Native, Expo, and Flutter apps; .ad scripts can be replayed in CI with screenshots and logs retained; it can also connect to remote device clouds such as BrowserStack, AWS Device Farm, TestMu AI, and Limrun.
Limitations: some backends (such as HarmonyOS and Vega OS) cover only part of the commands; refs are only valid in the latest output, and after running a --settle command you should use the refs from its diff; when accessibility data quality is poor, you need to rely on screenshots or video. The project is open source under the MIT license.