Maestro AGENTS.md

Repository instructions for Maestro, a tool that drives Android and iOS devices for automated end-to-end tests.

In plain words
What is it for?
They are for navigating Maestro's Gradle and Swift modules, understanding where device drivers and compiled artifacts live, and following the repository's end-to-end testing rules.
Why use it?
They give coding agents a shared map of the project, its modules, test fixtures, test suites, and required test workflow.

Instructions file for CodexOpenCode

Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

agentmods
npx agentmods add instructions/mobile-dev-inc/maestro/agents-md
Clone the repo
git clone --depth 1 https://github.com/mobile-dev-inc/Maestro

Made for: Codex, OpenCode.

Per session 3,171 This file is loaded in full into every session.
When invoked 3,171 The same file — it is already loaded in full.
Security scan A 0 findings. Scan, not verified.
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5 $0.03171 $0.03171
Opus 5 $0.01586 $0.01586
Sonnet 5 $0.00634 $0.00634
Haiku 4.5 $0.00317 $0.00317

Measured 2d ago against content hash 6156767260be, method: parsed. Prices are Anthropic first-party input rates as of 2026-08-30, from the pricing page.

Security

Grade A, and why

Maestro AGENTS.md scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 2d ago.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

AGENTS.md · 135 lines

How it starts

The opening of the file, as written. The whole thing — 135 lines — stays where its author put it; the contents beside it link to each section on GitHub.

AGENTS.md — Maestro

Shared context for any Claude Code skill or subagent operating in this repo. Skills (.claude/skills/*) reference this file rather than restating module roles; if a description here drifts from reality, fix it here once and every skill follows.

Module map

Top-level Gradle modules. Code lives under each module's src/main/.

Module Role
maestro-android/ On-device Android driver. Kotlin sources compile to two checked-in APKs (maestro-app.apk, maestro-server.apk) consumed by maestro-client/. The build's copyMaestroAndroid / copyMaestroServer finalizers update those APKs plus a maestro-android-source.sha256 checksum.
maestro-ios-driver/ Host side of iOS driver wrapper (Kotlin). The actual XCTest runner lives in maestro-ios-xctest-runner/.
maestro-ios-xctest-runner/ Swift XCTest runner that runs on the iOS device/simulator. The compiled artifacts (maestro-driver-ios*.zip) are checked in under maestro-ios-driver/src/main/resources/driver-iPhoneSimulator/Debug-iphonesimulator/.
maestro-ios/ iOS host-side glue (small — most iOS host code lives in maestro-client/).
maestro-client/ Host-side Kotlin SDK that drives devices. Platform drivers live in src/main/java/maestro/drivers/: AndroidDriver.kt, IOSDriver.kt, WebDriver.kt, CdpWebDriver.kt. This is where most "auto-grant", "auto-dismiss", system-dialog handling and platform-specific quirks belong.
maestro-orchestra/ Command execution layer. Orchestra.kt interprets each Maestro command, applies retries, manages the command lifecycle. Sub-packages: error/, filter/, workspace/, yaml/.
maestro-orchestra-models/ Shared command/data models (used by maestro-orchestra/ and consumers).
maestro-cli/ CLI entry point + MCP server. Mixed Kotlin (~100 files) + Swift (~56 files for iOS-related CLI bits).
maestro-utils/ Shared utilities.
maestro-web/ Web (browser) driver pieces.
maestro-proto/ Protobuf definitions shared across modules.
maestro-test/ Cross-module tests that doesn't require devices.

Read the full file on GitHub · 135 lines

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. 2d ago First seen · 135 lines · 3,171 tokens per session scan A 6156767260be

Subscribe to this mod's changes

Maestro AGENTS.md is an instructions file published in the GitHub repository mobile-dev-inc/Maestro (15,456 stars, last pushed 4d ago), licensed Apache-2.0. It adds 3,171 tokens to every session, about $0.0159 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.