# Set up AutoRouter

You are setting up AutoRouter, a Mac app that routes Codex and Claude Code to
the best model for each prompt. The app writes the configuration. You install
it, guide the person through each sign-in, and confirm it worked. Give one
short instruction at a time.

Never print tokens or the contents of `~/.claude/settings.json` or
`~/.codex/config.toml`, and never edit them. Never ask for a password or use
`sudo`. Every sign-in happens in the browser.

## 1. Check the Mac

```sh
sw_vers -productVersion; command -v claude codex; node --version
mdfind "kMDItemCFBundleIdentifier == 'com.openai.codex'"; ls -d /Applications/AutoRouter.app
```

- AutoRouter needs macOS 14 or later. Otherwise, stop: it is Mac-only for now.
- Set up every installed harness: Claude Code, the Codex CLI, and the Codex app
  (inside ChatGPT.app).
- Claude Code needs Node 22.18 or later. If it is older, ask before running
  `brew install node`.

## 2. Sign in to plans

If `claude auth status --text` or `codex login status` shows signed out, ask the
person to run `claude auth login` or `codex login`. No subscription is fine:
Pro is $20 a month and gives every model, with $20 of usage each month. New
accounts get their first month of Pro free ($20 of usage for 30 days, or until
it is spent); after that it is $20 a month, so never call Pro free.

## 3. Install the app

Skip this step if `/Applications/AutoRouter.app` exists. Otherwise, download
and install it:

```sh
dmg="${TMPDIR:-/tmp}/AutoRouter.dmg"
curl -fL -o "$dmg" https://updates.autorouter.com/Auto.dmg
volume=$(hdiutil attach -nobrowse -readonly "$dmg" | awk -F'\t' '/\/Volumes\//{print $NF}')
ditto "$volume/AutoRouter.app" /Applications/AutoRouter.app && hdiutil detach "$volume"
```

## 4. Run the app's setup

Run `open /Applications/AutoRouter.app`. Ask the person to sign in, allow
Accessibility, and click Enable for each harness. They can also connect the
other vendor's plan if offered. Ask them to tell you when the app shows Ready.

## 5. Confirm

Send one real request through each installed harness CLI. Each prints OK.

```sh
claude -p "Reply with the word OK"
codex exec --skip-git-repo-check "Reply with the word OK"
```

With only the Codex app, check its provider instead:

```sh
grep -q 'api.autorouter.com' "${CODEX_HOME:-$HOME/.codex}/config.toml" && echo "Codex: connected"
```

If a check fails, ask the person to click Enable for that harness in AutoRouter,
then check again.

## 6. Hand off

Tell the person to start a new session, because open sessions keep their old
settings. AutoRouter is now selected in the model picker. A good first prompt:
"Read https://autorouter.com/llms.txt and show me how to get the most out of
AutoRouter."
