Skip to main content

appium-pilot

An agent-first, session-based CLI for driving native mobile apps via Appium. One verb per invocation, state persisted across calls, output tuned for an LLM agent: snapshot the screen to get element refs, then act on them by ref.

Install

pipx install .          # or: pip install -e .

You also need Node + the Appium server and drivers (appium-pilot does not install them — run appium-pilot doctor to see what's missing):

npm i -g appium
appium driver install uiautomator2   # Android
appium driver install xcuitest       # iOS

Quick start

# Launch an installed Android app (auto-picks a booted emulator)
appium-pilot open --platform android --app-package com.example.app

# Or an iOS Simulator app bundle
appium-pilot open --platform ios --app /path/to/MyApp.app

# Inspect the screen — returns filtered XML with e1..eN refs
appium-pilot snapshot

# Act on a ref from the latest snapshot
appium-pilot tap e7

# Record a flow once, then replay it forever (deterministic regression)
appium-pilot flow save checkout.yaml
appium-pilot flow replay checkout.yaml

# Multiple parallel sessions
appium-pilot -s=checkout open --platform ios --app /path/to/MyApp.app

Session state lives under ~/.appium-pilot/ (so any invocation can reattach regardless of cwd). Artifacts you want to find — screenshots and videos — are written to ./appium-pilot/ in the current directory (override with APPIUM_PILOT_OUTPUT).

Use from AI coding agents

A skill ships inside the package so agents discover the commands and drive the CLI themselves. Install it into whichever tool you use — no manual symlink:

appium-pilot skills install                # Claude Code (~/.claude/skills/), the default
appium-pilot skills install --tool cursor  # Cursor       (.cursor/rules/)
appium-pilot skills install --tool copilot # GitHub Copilot (.github/copilot-instructions.md)
appium-pilot skills install --tool agents  # AGENTS.md (the cross-tool standard)
appium-pilot skills install --tool all     # all of the above
appium-pilot skills uninstall --tool all   # remove

claude installs user-level (once, for every project); the others write into the current project. The skill source lives at src/appium_pilot/skilldata/SKILL.md; re-run skills install after editing it.

Platform support

  • macOS — full: iOS Simulator + Android Emulator.
  • Windows / Linux — Android only (iOS needs a Mac). External tools are resolved through shutil.which (honoring PATHEXT, so appium.cmd/adb.exe work) and background processes detach via OS-appropriate flags. On Windows, make is uncommon — run the underlying commands directly (.venv\Scripts\pytest, python -m appium_pilot ...). The Windows path is implemented but not yet exercised on a Windows host.

Testing

Two tiers (see tests/):

make install          # pip install -e ".[dev]"
make test             # fast unit tests, no device — run after every change
make test-e2e-android # device-backed E2E (auto-boots an emulator)
make test-e2e-ios     # device-backed E2E (auto-boots a simulator)
make test-e2e         # both platforms
  • Unit (tests/unit/, ~0.2s, no device): locks in the snapshot filtering, per-platform locators, quoting, output/JSON contract, parsing and config logic. pytest runs only these by default.
  • E2E (tests/e2e/, marked e2e): drives the real CLI against official Appium sample apps — ApiDemos (Android) and TestApp (iOS, built on demand) — covering every command on both platforms. Apps are cached under tests/_apps/; tests skip cleanly if a device/toolchain is unavailable.

Status

All v1 commands implemented and smoke-tested end-to-end on an iOS Simulator (open → snapshot → tap → re-snapshot → screenshot → stale-ref handling → close):

open · close · list · close-all · kill-all · snapshot [--raw] · source · screenshot [ref] · devices · doctor · tap · type · clear · swipe · scroll · press · hide-keyboard · orientation · wait · get · find · expect · flow save/replay/show/clear · url · alert · video-start/video-stop · launch/activate/terminate/background/install/remove/reset.

Targets iOS Simulator + Android Emulator. Deferred to v2: hybrid webview, geolocation, network conditions, deep links, real devices, cloud farms.

Metadata

Release files for appium-pilot 0.3.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for appium-pilot 0.3.0
File Size Uploaded
appium_pilot-0.3.0.tar.gz 80.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for appium-pilot 0.3.0
File Interpreter ABI Platform
appium_pilot-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 150.5 kB

Release files / appium_pilot-0.3.0.tar.gz

Download URL appium_pilot-0.3.0.tar.gz
Size 80.1 kB
Tags Source
SHA-256 checksum
How to use checksums
5b6774a9dfa42089b0871f5de96e4ec0fe15da51bfb4249820537996438a13a0
BLAKE2b-256 checksum
How to use checksums
f2ac2247d9686aee05c4e5b9716c3a9cbc61bb1466952a58b71d69fd563cf44e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.7

Release files / appium_pilot-0.3.0-py3-none-any.whl

Download URL appium_pilot-0.3.0-py3-none-any.whl
Size 70.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
58d7a0ee5bc5901e3515bbc6bdeef41c33b38c6af4cf853cc21facc5a7287398
BLAKE2b-256 checksum
How to use checksums
855eca25d5eb4fd898b14d3d7e1b43ad375eed944a3eb183d0a2ed9f843d973b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.12.7

Release history Release notifications | RSS feed

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.0

2 release 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