# CLI reference (/docs/reference/cli)



The commands available to external developers, by group. Every command prints one JSON value to stdout (errors go to stderr with a non-zero exit). Pipe to `jq`, never scrape help text. Run everything through `pnpm exec milo …` in your repo. Setup and login are covered in [Set up milo](/docs/start/milo-setup); the config workflow in [Config with milo](/docs/build/config-with-milo).

## auth [#auth]

| Command         | Purpose                                                                 |
| --------------- | ----------------------------------------------------------------------- |
| `login <shop>`  | Browser sign-in; 24h session per shop. `--pick` forces the store picker |
| `logout [shop]` | End a session                                                           |
| `switch <shop>` | Point this directory at another signed-in store                         |
| `auth status`   | Session, email, and active app — offline                                |

## theme [#theme]

| Command                          | Purpose                                                          |
| -------------------------------- | ---------------------------------------------------------------- |
| `theme list`                     | Live, draft, and scheduled themes                                |
| `theme create "<name>"`          | New draft cloned from live (`--base <themeId>` to clone another) |
| `theme use <themeId>`            | Set the active theme for config commands (`use reset` to clear)  |
| `theme preview`                  | Preview link + QR code for the active theme                      |
| `theme rename` / `theme archive` | Housekeeping                                                     |

## config [#config]

| Command                                                         | Purpose                                                  |
| --------------------------------------------------------------- | -------------------------------------------------------- |
| `config pull [themeId]`                                         | Sync the theme's config to `.milo/sync/<themeId>/draft/` |
| `config status`                                                 | Dirty/missing/read-only state, offline                   |
| `config show` / `entities` / `search <term>`                    | Inspect entities without opening files                   |
| `config diff [--release]`                                       | What changed vs the snapshot (or last release)           |
| `config commit <kind> <entityId>`                               | Save one entity (`--new` to create)                      |
| `config create-screen "<name>"`                                 | Scaffold a new screen entity                             |
| `config push`                                                   | Merge the draft into its theme                           |
| `config refresh <kind> <id> --force`                            | Re-pull one entity (conflict recovery)                   |
| `config create-backup` / `list-backups` / `restore-backup <ts>` | Config backups                                           |
| `config list-releases` / `restore-release <id>`                 | Released config history                                  |

## integration [#integration]

| Command                                 | Purpose                                                                           |
| --------------------------------------- | --------------------------------------------------------------------------------- |
| `integration catalog [term]`            | Search the [integration catalog](/docs/reference/integrations)                    |
| `integration list`                      | Integrations enabled on this app                                                  |
| `integration info <id>`                 | Manifest and README for one integration                                           |
| `integration get <id>`                  | Its current settings (values masked; `--reveal` unmasks — treat output as secret) |
| `integration add` / `update` / `remove` | Manage integration settings                                                       |
| `integration backups` / `restore`       | Settings history                                                                  |

## blueprint [#blueprint]

| Command                        | Purpose                                                            |
| ------------------------------ | ------------------------------------------------------------------ |
| `blueprint list` / `show <id>` | Curated theme templates usable as `theme create --blueprint` bases |

## shopify [#shopify]

| Command                                | Purpose                                              |
| -------------------------------------- | ---------------------------------------------------- |
| `shopify query`                        | Admin GraphQL, **read-only** (mutations are blocked) |
| `shopify storefront-query`             | Storefront GraphQL                                   |
| `shopify discounts` / `discount <gid>` | Store discounts                                      |

## push [#push]

| Command                             | Purpose                          |
| ----------------------------------- | -------------------------------- |
| `push list` / `get`                 | Scheduled and sent notifications |
| `push create` / `update` / `cancel` | Manage campaigns                 |
| `push test`                         | Send a test push to a device     |

## More groups [#more-groups]

| Group       | Purpose                                                                                                      |
| ----------- | ------------------------------------------------------------------------------------------------------------ |
| `app`       | `which`, `preflight`, `brand-context` (brand voice/colors for agent-written copy), `metadata`, `cache-clear` |
| `bundle`    | Remote JS bundles: `build`, `promote <buildId>`, `current`                                                   |
| `analytics` | `metrics` and `query` over app analytics                                                                     |
| `discount`  | App-created discounts: `list`, `get`                                                                         |
| `onelink`   | Smart links: `list`, `get`, `subdomains`                                                                     |
| `files`     | Store file uploads: `list`, `upload`, `upload-icon`                                                          |
| `skills`    | Agent-skill management: `status`, `sync`, `list`, `get` ([Set up milo](/docs/start/milo-setup))              |

<Callout type="info" title="Seeing “not available”?">
  A command that answers `<group> <cmd> is not available` is outside the
  external surface — nothing is broken. If you believe you need it,
  [contact Appbrew](/docs/start/getting-help).
</Callout>
