- LLDB breakpoints
box debugstops at a line you name and prints the stack and the variables. - Live view in your browserWatch the simulator while the agent works, and tap in it yourself.
- Video, dark mode, languagesOne option records the run, turns on dark mode or changes the app language.
- Pay by the started minute$0.05 a minute of build and test time, $0 when the failure is ours, and a $300 cap on what one account holds.
Agent runbook
If you are the agent that was handed this page, work through the six steps from top to bottom and close with the report
in step 6. The pasted line is the user's consent to install. The installer runs without sudo, writes nothing
outside ~/.local/bin/box and ~/.config/box/, and verifies the download against the server's
SHA256SUMS.
- Secrets stay out of the conversation and out of the repository. Do not request a token, a code or a password, and do not save one in the project.
- Money is the user's call. Do not top up and do not pay for them.
1 Get the CLI
Runs on Linux (x86_64 and arm64), WSL, and macOS on Apple silicon. Native Windows and Intel Macs are not supported.
command -v box >/dev/null 2>&1 || curl -fsSL https://xenoci.com/install.sh | sh
export PATH="$HOME/.local/bin:$PATH"
box --version
The last line prints the version that was installed.
2 Sign the user in with GitHub
Run box status. If the output has a login line and a balance, this machine is signed in
already and you can move on to step 3.
If it does not, run box login --no-browser. It prints a GitHub address and a one-time code and returns at
once. Send the user both in one message, then run box login --wait right away without waiting for a reply.
On GitHub they enter the code and approve; box login --wait notices that by itself and answers
box: signed in as <login>, so the user never has to tell you they are done. The approval tells box
which account they are and nothing more: no repository or organization access. A first sign-in also adds $10 of credit.
box login --wait waits about 2 minutes at a time, under the limit many agent shells have. If it says the code is still good, run it again without messaging the user. If it says the code
expired, start this step over for a new link. Finish with box status, which should exit 0 and list the
login and the balance. Through MCP, the login tool does the same: call it once for the link, then again with
wait_seconds until it says signed_in.
- Cloud agents. Cursor background agents, Codex cloud and Claude Code on the web begin every session
signed out. The user can fix that once, in the settings of the agent's environment: store a
BOX_TOKENsecret there and add step 1's install command to the setup script. Leave the token value out of the conversation. - A low balance. When
box statusprints alowline (normally under $1, about 20 Mac minutes; the line decides, not your own sense of enough) or a job stops with exit 3 and an empty balance, ask the user once: “box has $x left. Shall I make a top-up link?” Money is their decision: never top up by yourself, and do not ask again. If they say yes, runbox topup --print, give them the address, then runbox topup --wait, again each time it says the balance has not gone up yet; it returns when the balance goes up and you carry on. If they say no, carry on with what the balance allows.
3 Connect your agents
box setup
This sets box up for the user, once per machine, for every project: the box skill for Claude Code
(~/.claude/skills/box/) and Codex (~/.agents/skills/box/), a short marked box section in
~/.claude/CLAUDE.md and ~/.codex/AGENTS.md (their other text is kept), and the MCP server for
both. It writes nothing into the project, and running it again changes nothing. Then go to the top folder of the iOS
project, the one that holds the .xcodeproj, .xcworkspace or project.yml, and add
.box/ to .gitignore, because job results are saved there. Cursor has no file for user-wide
rules: for Cursor, or when the user wants the notes committed for their team, run box setup --project there.
4 Check the MCP server
box setup already registered it. Check it for the agent you are running as; do not add it again.
claude mcp get box # Claude Code
codex mcp get box # Codex
The server provides these tools:
build test screenshot run debug exec describe find tap type swipe press_button look stop report_problem report_job claims status logs usage login topup
They load the next time the agent starts. For the rest of this session, call the CLI.
Or install the plugin (skill and MCP server together): claude plugin marketplace add Xeno-CI/box-cli then claude plugin install box@xenoci; any other MCP client can run npx -y @xenoci/box mcp. See github.com/Xeno-CI/box-cli.
5 Run a first build
box build --dry-run # list the files a build would upload, and stop there
box build # compile on the Mac
box test --screenshot out.png # tests, then a picture, in one Mac job
box screenshot out.png # a picture alone
box run --detach # start the app, print a job id and a live view link
box ui describe # one short line per element: role, label, value, ref
box ui find --text "Sign in"
box ui tap --id <ref>
box stop
A .box/setup script at the project root runs on the build machine before box build, box test and box run, once until its contents change. If it fails, the build does not start and the job exits 1 with the script's own output. Use it for framework downloads and .xcconfig copies, never for secrets. The dry run says box: setup would run or box: setup would be skipped (unchanged).
Begin with the dry run. If the user also asked for tests or a picture, go straight to box test --screenshot out.png without a plain box build first: every job builds and reports compile errors the same way, so a separate build only adds a Mac job. The lines after that are what an agent usually needs next.
When a job fails, its last line is box: details: .box/out/<job>/why.txt. Read that file and the .box/out/<job>/why-*.png pictures first: they are what only the Mac has, crash stacks with symbols, failing tests with file:line and the screen at the moment of the failure. test.log and test.xcresult.zip sit next to them.
6 Do the rest of the task, then report
If the user asked for more than setup in the same message (“then build and screenshot the app”), do it now with box,
without asking first. Then end with: box is installed, the GitHub login that is signed in, the balance from
box status, the job ids and results, and one line saying box was set up for every project on this machine in
~/.claude and ~/.codex, with nothing added to the repository.
Android
For an Android app, add --platform android to any job command, for example
box build --platform android. The steps above stay the same.
- Every job command takes
--platform iosor--platform android, and so does every MCP job tool (platform). - Without it, box looks at the project folder: an Xcode project,
project.yml,Package.swiftor anios/folder means iOS;settings.gradle,gradlewor anandroid/folder means Android. - When both are there (Flutter, React Native, Expo), box picks neither and exits 2 asking for
--platform, so no job runs on the platform you did not mean. - To fix the choice for a project, put
platform = "android"(or"ios") in.box.toml.--platformstill wins. - Android has one size: 4 vCPU / 16 GB. It runs on a Linux Android emulator, and the emulator boot time is not billed.
--xcodeis for iOS only; with--platform androidit exits 2.box debugandbox build --device-buildare iOS only and exit 2 on Android.box testruns every unit test (GradletestDebugUnitTest), so--only-testingis not used.- The debug APK is saved as
.box/out/<job>/app-debug.apk. The Gradle cache stays between jobs of the same project, so the next build is incremental.
box build --platform android # app-debug.apk in .box/out/<job>/ box test --platform android box screenshot --platform android out.png box run --platform android box ui tap --label "Sign in" # also describe, type, swipe, button home box exec --platform android -- ./gradlew tasks box purge --platform android --yes
Android costs $0.02 per minute on the one Android size (4 vCPU / 16 GB), from the same US dollar balance as the Mac. The emulator boot time is free. The current rate is at xenoci.com/api/v1/pricing, and every job prints its rate when it is submitted.
Debug, watch and record
Breakpoints with LLDB
box debug --break File.swift:42 --print count starts the app under LLDB on the Mac. At every stop it prints
the stack and the variables.
- Up to 10
--breakpoints, each afile:lineor a function name. --stopssets how many stops to report, 20 at most.--tap-labelor--tap-idpresses a button first, for code that only runs after a tap.- Over MCP it is the
debugtool.
$ box debug --break BoxDemoApp.swift:22 --tap-id add
debug: attached to com.xenoci.box.BoxDemo
breakpoint 1: BoxDemoApp.swift:22
== stop 1: thread 1, breakpoint 1.1
#0 ContentView.add(_:) at BoxDemoApp.swift:22
#1 closure #2 in closure #1 in ContentView.body.getter at BoxDemoApp.swift:15
variables:
before (Swift.Int) = 0
step (Swift.Int) = 3
label (Swift.String) = "added 3"
box: bj_fxXzCejnrvbFLA5B succeeded, 180s billed
A live view of the simulator
box run compiles the app and boots it in a simulator that stays up afterwards. An agent should always pass
--detach. Without it the command stays attached and streams the log until the session is over. With it the
command returns a job id and a live view link.
Pass that link to the user. It opens only for their GitHub account, and on the page they can tap, swipe and type in the app.
The agent drives the same session with box ui: describe, screen out.png,
tap --id, tap --label, tap X Y, swipe, type and
button home. The MCP tools do the same.
A session closes in one of four ways: box stop, another build, test, run or debug of the same project,
10 minutes with no change on screen, or 30 minutes in total.
Why a job failed, and did the screen change
A failed build or test ends with one line, box: ai: File.swift:42: the cause; fix: the direction, read by
an AI model from what only the Mac has: the log tail, failing tests with their locations and crash stacks symbolicated with
the build's dSYM. box why prints the full where, why and fix for the last job, or box why <job>.
box screenshot --compare last compares the screen with this project's last succeeded screenshot. It saves
a diff picture per changed screen in .box/out/<job>/compare/ and prints one line saying whether the
change looks intended or broken.
- Over MCP these are the
whytool andscreenshotwithcompare: true. - Tokens, keys, passwords and user folder paths are masked before anything is sent. Source files and environment values are not sent. The models (Microsoft Azure, Anthropic as the fallback) do not train on it. See terms 6-1.
box ai offturns both off for the account: nothing goes to a model, and--comparestill saves its diff pictures.box ai onturns them back on.
Video, dark mode and languages
box screenshot --record out.png takes the screenshot and also saves the run as screen.mp4.
--dark turns on dark mode and --locale ko_KR sets the language. ja, ar
and the rest work the same way, and ar and he lay the app out right to left. Both options work
with screenshot, run and ui. The language only changes when the app ships it.
Pricing
$0.05 per minute of build and test time, every started minute. Prepaid in US dollars, with no subscription and no daily limit.
| Rounding | Each job is rounded up to the minute. 1 to 60 seconds on the Mac is one minute ($0.05), 61 to 120 seconds is two ($0.10). |
|---|---|
| Free | Uploading, time in the queue and starting the Mac. |
| Failure on our side | $0 for that job. |
| Sign-up credit | $10, once per account. That is 200 minutes, to use within 14 days. |
| Balance cap | One account holds $300 at most. |
| Android | $0.02 per minute on the one Android size (4 vCPU / 16 GB), rounded the same way and paid from the same balance. The emulator boot time is free. Rate: xenoci.com/api/v1/pricing. |
box status prints what is left. box usage --csv lists every job and
box balance --csv every balance change. box topup opens the top-up page.
Platform support
| Native iOS | Xcode projects and workspaces. Swift, SwiftUI, UIKit and Objective-C. Swift Package Manager and XcodeGen. |
|---|---|
| With a setup command | CocoaPods, Tuist, fastlane, Flutter, React Native and Expo. Run the tool's own setup through box exec before building. Each of these was built and launched on a simulator. |
| Android | Gradle projects, and the Android side of Flutter, React Native and Expo, with --platform android. See Android. |
| Targets | The iOS simulator on Xcode 27.2, the one version installed, and unsigned builds for real iPhones (build --device-build). |
| Not yet | Native Windows, Intel Macs, choosing the Xcode or iOS version, physical iPhones, signing or TestFlight upload done for you, Kotlin Multiplatform, Capacitor, .NET MAUI, and team or organization accounts. |
Commands
Jobs and output
box logs | Follows the last job again. |
|---|---|
box cancel | Stops the last job. |
box jobs | Lists recent jobs. |
box test --only-testing Target/Class/test | Runs only the tests you name. |
box test --screenshot out.png | Runs the tests, then launches the app and saves a picture, in the same Mac job. |
--json | Prints one JSON event per line. The last one is a result with billed_seconds. |
Exit codes
0 | Success. |
|---|---|
1 | A compile error or a failing test. Every error comes as file:line:col with your local path and the lines around it. Fix the code and run the command again. |
2 | The command was called the wrong way, or the local machine is at fault. |
3 | The account or box itself: signed out, an empty balance or a Mac fault. The message names the cause. Tell the user instead of retrying. |
130 | The job was cancelled. |
Worktrees and project names
The Mac keeps one code copy and one build cache per project name. The name is the folder name unless you pass
--project NAME, so two git worktrees do not overwrite each other.
Builds for a real iPhone
box build --device-build compiles a Release build and leaves it unsigned. You get
device-build.zip in .box/out/<job>/. Signing and uploading happen on your own machine, so
signing keys stay off box. Over MCP, the build tool takes device_build: true.
Steps that run on the Mac
A project.yml makes box run xcodegen generate by itself. For any other step, such as
pod install, flutter build ios or a code generator, use
box exec -- <command>. It runs in the project folder on the Mac, and whatever it produces is still
there for the next build.
A folder with no app project at its top (a Rust crate, a Tauri app's root, a script) is refused before anything is
uploaded or billed. Run its own tool with box exec, for example box exec -- cargo build, or name the
Xcode project inside it with box build --workspace path/App.xcodeproj. Rust and Bun are not on the Mac
image: install them in the same command, as in
box exec -- 'curl -fsSL https://sh.rustup.rs | sh -s -- -y && . ~/.cargo/env && cargo build'.
node_modules is never uploaded, so run npm ci or bun install in the same box exec
as the build that needs it.
Code and data
A job syncs your project folder to a Mac and builds it there. The CLI prints one line per step:
- Upload box checks every file and sends only the new or changed ones.
.gitignoreis respected and.envis never sentbox: upload: 70 files checked, 3 new (12 KB), .gitignore respected, .env never sent - Mac The job waits for a free Mac (not billed), which unpacks your source next to the project's previous build
box: machine: source unpacked - Build xcodebuild compiles only what changed since that build
box: build: done in 41s - Test Your tests run on a simulator and are counted
box: tests 3 passed, 0 failed - Results Logs, the result bundle and screenshots come back to
.box/out/<job>/, and the last line says what it costbox: bj_… succeeded, 120s billed, $0.10
| Uploaded | The project folder, minus whatever .gitignore and .boxignore exclude. After the first sync, only files whose contents changed. |
|---|---|
| Never uploaded | .env files (.env.example is uploaded), .git, .box, node_modules, Pods, .build and DerivedData. |
| Check first | box build --dry-run prints every file a build would upload. |
| Kept on the Mac | The code copy and its build cache, between jobs, so later builds start warm. |
| Deleted | A project idle for 7 days. box purge --yes deletes this project's workspace on the Mac immediately. Neither one changes the files on your machine. |
| Returned to you | Logs, screenshots, videos and zips, in .box/out/<job>/. We keep job logs and results for 7 days. |
Failure reports
When a command fails, the CLI sends the box team a short report: the command, the exit code, step timings, the box version, the OS and CPU, our error code and message, and the job id. Paths, addresses, tokens and e-mail addresses are stripped from the message before it leaves. Your code, file contents and environment values are never part of it.
To switch it off, run box telemetry off or set BOX_TELEMETRY=0 or
DO_NOT_TRACK=1.
Contact
Run box feedback "what went wrong". The message goes to the people who run box, with your last job
attached. MCP agents call report_problem instead. A job that failed on our side ends with
box: looks like our side: run box report bj_… --reason "..." (MCP report_job);
box claims shows the result. What a failure on our side costs follows the terms. You can also write to
play@xenoci.com.
Docs for people are at xenoci.com/docs, and service status is at xenoci.com/status.
