Skip to content
Documentation

The arcane command line

arcane is one command for the whole suite. A person signs a computer in once, in the browser, and from then on git pushes without a password, apps deploy, databases are made, traces and designs are read, all from the terminal. It's written for developers and for the AI agents working beside them: every command prints plain text or JSON and exits 1 when it fails. The same text is at /cli/llms.txt for agents to read.

Quick start#

  1. Install it. It needs Node 18 or newer and has no dependencies.

    Terminal
    npm install -g @arcana-labs/cli --registry https://npm.arcanesuite.com/
  2. Sign this computer in. The CLI prints a code and opens the browser; confirm it there while signed in to Arcane. This is done once.

    Terminal
    arcane login
  3. Check who it's signed in as, and look around.

    Terminal
    arcane whoami
    arcane repo list
    arcane app list

arcane help prints every command. arcane --version prints the version.

Install and update#

CommandDoes
npm install -g @arcana-labs/cli --registry https://npm.arcanesuite.com/Installs arcane. Node 18 or newer; Arcane Code needs Node 22.
arcane updateGets the latest version. It's downloaded from Arcane, its signature is checked, and it's kept in ~/.arcane/cli/<version>: no npm and no sudo.
arcane --versionThe version that's running.

After arcane update, the arcane on your PATH runs the newest version it finds in ~/.arcane/cli, so there is nothing else to switch. A computer with Arcane Code on also updates by itself, between requests.

Signing in#

arcane login is OAuth's device flow. The CLI shows a short code and a link to account.arcanesuite.com/cli; a person opens it, checks the code and the computer's name, and approves. The computer then gets a token of its own.

CommandDoes
arcane loginSigns this computer in as the default account and makes the CLI git's credential helper for Arcane Git.
arcane login --no-browserOnly prints the link, for a machine without a browser: open it on any other device.
arcane whoamiWho is signed in here, and with which account when it isn't the default. Exits 1 when nobody is.
arcane logoutRevokes the token of the account in use and forgets it. git's setup is undone with the last account.
arcane git setupSets git up again, after its configuration was changed by hand.
  • The token stands for the person who signed in: the CLI can do what they can do in the browser, under the same roles and permissions, and nothing more.
  • It's kept in ~/.config/arcane/git.json, readable only by its owner. It doesn't expire.
  • Every signed-in computer is listed in Account → Security → Your devices. Signing one out there revokes its token at once.

Signing in always takes a person in a browser, once. A CI job doesn't sign in: see Scripts and CI for what it uses instead.

Several accounts on one computer#

One computer can be signed in to several Arcane accounts at once: your own, a client's, another company's. Each project folder is given the account it uses, and every command run there, git's pushes and pulls included, is that account's. Nothing is written inside the project, so a token can never be committed.

Terminal
cd ~/work/acme-api
arcane login --local acme        # sign in as another account, for this project only

cd ~/work/globex-site
arcane login --local globex      # a third account, for this one

arcane whoami                    # says which account is used here, and why
CommandDoes
arcane loginSigns in the default account: the one used wherever a folder has none of its own.
arcane login --local [name]Signs another account in, keeps it under name, and gives it to this project's folder. Without a name it's kept under its email address.
arcane account add [name]Signs another account in without changing which one any folder uses.
arcane account listThe accounts signed in here, the folders that use each, and a * on the one used where you are.
arcane account use <name>Gives this project's folder an account that's already signed in, by its name or its email address. default names the default account outright.
arcane account clearTakes the account off this folder: it uses the default again.
arcane account remove <name>Signs that account out and revokes its token. Folders that used it go back to the default.

Which account a command uses

  1. --account <name> on the command, which works on every command: arcane --account acme app list.

  2. Else the ARCANE_ACCOUNT environment variable.

  3. Else the nearest folder that was given an account, looking from where the command runs up through its parent folders.

  4. Else the default account, from arcane login.

  • The folder an account is given to is the repository's top folder when you're inside one, and the folder you're in otherwise. Giving an account to a parent folder (~/work/acme) covers every project inside it.
  • git follows the same rule: a git push inside a folder uses that folder's account, and so does a git clone run inside it. A worktree made outside the folder (git worktree add ../x) is still its repository's, and uses the same account.
  • A folder whose account isn't signed in on this computer is an error that names it. The default is never used in its place, because the command would act as someone else.
  • A folder that's moved or renamed loses its account: run arcane account use <name> there again.

Where it's kept

FileHolds
~/.config/arcane/git.jsonThe default account's sign-in.
~/.config/arcane/accounts/<name>.jsonEach other account's sign-in.
~/.config/arcane/folders.jsonWhich folder uses which account, by path.

All of them are readable only by you. With XDG_CONFIG_HOME set, they're under it instead of ~/.config.

Arcane Git#

After arcane login, git itself needs nothing else: clone, pull and push to https://git.arcanesuite.com/<owner>/<name>.git work without a password. These commands do what git doesn't. Pull requests, issues and the rest of the API are in Arcane Git's guide.

CommandDoes
arcane repo listYour repositories as owner/name, with visibility and default branch.
arcane repo create <name> [--internal] [--branch main] [--description …] [--import <https url>]A new repository: private unless --internal. --import copies a public repository with its history.
arcane secret set <NAME> --repo <owner/name> [--value … | --file …]An Actions secret. Without --value or --file the value is read from stdin, which keeps it out of the shell's history.
arcane variable set <NAME> --repo <owner/name> --value …An Actions variable.
arcane run list --repo <owner/name>The latest 20 Actions runs: number, workflow, event, branch and status.
arcane run view <number> --repo <owner/name>One run with its jobs and steps, as JSON.
arcane pr create --title … [--body … | --body-file f] [--head branch] [--base branch] [--repo owner/name] [--oversight <issue id>]A pull request as you, from a pushed branch (the current one) into the default branch; in a clone, the repository is its remote's. --oversight names the Oversight error issue it fixes, whose fix then follows the pull request. It never merges.
Terminal
arcane repo create api
git remote add origin https://git.arcanesuite.com/acme/api.git
git push -u origin main
printf '%s' "$STRIPE_KEY" | arcane secret set STRIPE_KEY --repo acme/api

Arcane Compute#

Servers, databases and apps. A server, a database or an app is named by its id or its name; when two share a name, use the id. arcane servers list prints the ids. Arcane Compute's guide explains arcane.yml, services and the variables apps get.

Servers and databases

CommandDoes
arcane servers listYour servers: id, name, state and address.
arcane db listYour databases, caches, queues and search services: id, name, engine, status, server and address.
arcane db create <name> --engine <engine> [--version v] [--server s] [--public-port p]A new one, and waits until it's running. Engines: postgres, mysql, mariadb, mongodb, clickhouse, redis, valkey, rabbitmq, nats, elasticmq, rustfs, meilisearch, typesense, elasticsearch. --server can be left out when you have one server.
arcane db password <db>Its connection URL, password included.
arcane db backup <db>Starts a backup now.

arcane db password prints a secret. In a shared terminal or an agent's transcript, read it into a variable instead of printing it: DATABASE_URL=$(arcane db password main).

Apps

CommandDoes
arcane app listYour apps: id, name, status, source and address.
arcane app create <name> (--repo <owner/name> | --git-url <url> | --image <image>) [options]A new app from an Arcane Git repository, any git URL or a container image, then deploys it and follows the deployment. --no-deploy only creates it. --worker is an app with no web port; otherwise --port (3000 when unsaid). Takes every app set option too.
arcane app show <app>Everything about it, as JSON.
arcane app set <app> [options]Changes its settings. They apply at the next deployment.
arcane app env <app>Prints its variables.
arcane app env <app> KEY=value … [--file .env] [--unset KEY]Changes them: each KEY=value replaces that key or adds it, --file merges a file in, --unset removes one. They apply at the next deployment.
arcane app deploy <app> [--no-wait]Deploys and follows each step. Exits 1 when the deployment fails, after printing the end of its output.
arcane app logs <app> [--process p] [--lines n]Its latest log lines (200 when unsaid), each with its time, process and replica.
arcane app run <app> -- <command>A one-off command in a container of the app: a migration, a console task. Prints its output and exits 1 when the command does.
arcane app hook <app>Its deploy hook: a URL that deploys the app when it gets a POST.
Option of `app set`Sets
--port <n|none>The port the web process listens on; none for an app without one.
--health </path>The path that answers 200 when the app is ready.
--replicas <n>How many web containers run.
--builder auto|dockerfile|railpack, --dockerfile <path>How it's built.
--build-command …, --start-command …, --deploy-command …The build's command, the web process's, and one run at each deployment before it goes live.
--process name="command"[@replicas]A background process (a queue worker, a scheduler). Repeat it for more; name= removes one.
--volume name=/pathA folder kept across deployments. name= removes it.
--db <database>A database the app is attached to, so it gets its connection variables. Repeat it for more.
--domain <name>, --free-domain on|offIts own domains, and whether it keeps the free address Arcane gives it.
--cpus <n>, --memory <MB>, --stop-timeout <s>Its limits, and how long a container gets to stop.
--auto-deploy on|off, --branch <b>, --directory <d>Whether a push deploys it, and the branch and folder it's built from.
A project from nothing to live
arcane db create main --engine postgres
arcane app create api --repo acme/api --port 8080 --health /healthz --db main \
  --process worker="node worker.js"@2 --deploy-command "npm run migrate"
arcane app env api STRIPE_KEY=sk_live_… LOG_LEVEL=info
arcane app deploy api
arcane app logs api --process worker --lines 50
arcane app run api -- npm run seed

ARCANE_VERBOSE=1 arcane app deploy <app> prints the deployment's whole output as it runs, not only its steps.

Arcane Oversight#

Traces, read only: what a person sees on the Traces pages, as text an agent can read. The workspace is the signed-in person's organization's.

CommandDoes
arcane traces list [search]Requests, newest first, each with its trace id, service, duration and status. search is the Traces page's own syntax, such as resource_name:"GET /orders" @http.status_code:5xx.
arcane traces show <trace id> [--span <id>]One trace as a report: totals, time by service, errors with their stacks, repeated operations (N+1), the slowest spans, the tree of spans and its logs. --span gives one span in full.
arcane traces services [--range 1h] [--env e]Each service's requests, errors, and average, p95 and p99 latency.
Option of `traces list`Narrows to
--service <s>, --env <e>One service, one environment.
--errorsRequests that failed.
--min <500ms>Requests at least that slow.
--range <1h> or --from <t> --to <t>A period: the last 15m, 1h, 4h, 1d, 7d, or between two dates (2026-11-14T10:00:00Z) or times in milliseconds. The last hour when unsaid.
--limit <n>How many (25 when unsaid).
--spansEvery span that matches, not only where a request entered a service.
Why did requests fail this afternoon?
arcane traces list --service api --errors --range 4h
arcane traces show 6f1c0e9d2b7a4c35a1e8d0b94f6c2a71

--json on any of them prints the API's answer as it is. Logs, metrics and the rest of Oversight are reached with `arcane api oversight`.

Arcane Design#

Designs, read only and where they are: nothing is downloaded or cloned. An agent building what was designed reads the design's own files.

CommandDoes
arcane design list [words]Your designs and those shared with you, with their pages. words searches them.
arcane design show <id>A design's pages, artboards with their sizes, preview links, and its list of files.
arcane design page <id> <page>All of one page's files at once: styles, components, notes and sources.
arcane design cat <id> <path>One file.

--json prints the API's answer as it is.

Arcane Drive#

Your Drive's files: list, search, read, download and upload, with your permissions. Files and folders are named by id, which ls and search show.

CommandDoes
arcane drive ls [folder]The top of your My Drive, or a folder's items: folders first, then newest.
arcane drive search <words> [--in folder]Everything you can see, as Drive's search box: names and the text inside files, and operators like type:pdf, owner:me, before:2026-01-01.
arcane drive info <id>A file or folder: type, size, owner, dates and its link.
arcane drive cat <id>The text in it: Docs, Sheets (as CSV), PDFs, Office and text files. --max-chars for more than a million characters.
arcane drive get <id> [--out path]Downloads it, of any size, to the current folder (--out a path or folder, - for stdout). An existing file is replaced only with --force.
arcane drive put <file> [--to folder]Uploads a file of up to 5 GB. --name renames it, --type sets its type when the extension doesn't, --replace <id> makes it a new version of that file (Drive never overwrites otherwise).
arcane drive mkdir <name> [--in folder]A new folder. drive:<id> as the folder is the top of a shared drive.
Terminal
arcane drive search "type:pdf invoice"
arcane drive get 9b2f4c1e --out ~/Downloads
arcane drive put report.pdf --to 3a7d0e52

--json prints the API's answer as it is. Uploads count toward your storage, as in Drive.

Arcane Artifacts#

npm packages and docker images in your namespace, with this computer's sign-in instead of an access token. The account is the folder's, as for git. Admins can push and publish; other members only install and pull, unless an admin lets them publish in Arcane Artifacts → Settings. For anything else (CI, a server), an access token.

CommandDoes
arcane npm <npm's arguments>Runs npm signed in to npm.arcanesuite.com, with your namespace's scope pointed there: arcane npm publish, arcane npm install @acme/ui. Your own .npmrc still applies; nothing is written to it.
arcane docker setupMakes docker ask the CLI for cr.arcanesuite.com (a credential helper, docker-credential-arcane), so docker push and docker pull work without docker login. Run it once.
arcane artifacts visibility <name> [public|private]Says who can pull an image (acme/api) or install a package (@acme/ui), or changes it. Public means anyone, signed out too; private, only your namespace. Only admins change it (or an access token with the delete scope in ARCANE_ARTIFACTS_TOKEN).
Terminal
arcane npm publish
arcane docker setup
docker push cr.arcanesuite.com/acme/api:1.4.0
arcane artifacts visibility acme/api public

Arcane Code#

Arcane Code runs the requests you send from Arcane Design on your own computer, with the agent command lines you already have and pay for (Claude Code, Codex, Grok Build, Muse Code, OpenCode), instead of on Arcane AI. In Arcane Design, pick the computer next to the send button. It needs Node 22 or newer.

CommandDoes
arcane code enableTurns it on as a service that starts with the computer, for every account signed in here, and lists the agent command lines it found.
arcane code disableTurns it off.
arcane code enable --account <name> / arcane code disable --account <name>Turns it on or off for one account only: the other accounts' requests go on as they were.
arcane code statusWhether each account is connected, the agents it found, and where its log is.
arcane code runThe same in this terminal, instead of as a service.
arcane code jobsThe requests running here.
arcane code logs [id] [--no-follow]What a request is doing, live until it ends.
arcane code allow <cli> / arcane code deny <cli>Lets an agent that isn't kept to the design's folder run (codex, grok, muse, opencode), or stops it.

Claude Code is kept to the design's folder and runs as soon as it's installed. The others aren't: what a design says, a shared design's text included, could get them to read your files. Allow one only for designs you trust.

Arcane Code always runs as the default account, whatever a folder uses.

Arcane Git Actions on your computer#

Your computer can run Arcane Git Actions jobs instead of Arcane's cloud runner, at no charge. Each job runs in a new Docker container of the same Ubuntu 24.04 image the cloud uses, so a workflow behaves the same, services: and Docker steps included. When the computer is busy, asleep or off, the job runs on Arcane as usual. It needs Docker (Docker Desktop, OrbStack or Docker Engine) and Node 22 or newer.

CommandDoes
arcane actions enable [--jobs N] [--cpus N] [--memory 8g]Pulls the runner image and starts taking jobs, as a service that starts with the computer: up to N at once (1 by default), each container within those limits.
arcane actions disableStops taking jobs here; they run on Arcane.
arcane actions statusWhether it's on and connected, Docker's version, and whether the runner image is here.
arcane actions jobsThe jobs running here now.

Jobs of your own repositories go to your computers. An organization's go to its members' computers only once an admin turns that on, in Arcane Store's settings. runs-on: arcane-local keeps a job on your computers: it waits for one instead of running in the cloud.

YAML
jobs:
  build:
    runs-on: ubuntu-latest   # your computer when free, else Arcane
  heavy:
    runs-on: arcane-local    # only your computers

A job gets its repository's code and secrets, and its container is privileged (it runs its own Docker for services:). On Linux that can reach the computer itself: turn this on only where you trust whoever can push to those repositories. The image is x86-64; on Apple silicon Docker runs it under emulation, slower.

Any route: arcane api#

arcane api calls any route of an app's HTTP API with this computer's token, prints the answer, and exits 1 with the error's message when it fails. It's how to reach what has no command of its own.

Form
arcane api <git|compute|oversight|design|drive> <METHOD> <path> [--data <json> | --data @file.json]
AppAddressReaches
githttps://git.arcanesuite.comEverything the app does: pull requests, issues, code, Actions. Listed in Arcane Git's guide.
computehttps://compute.arcanesuite.comEverything the app does: servers, apps, databases, deployments, backups.
oversighthttps://oversight.arcanesuite.comEverything the app does: traces, logs, metrics, errors.
designhttps://design.arcanesuite.comIts public API only, under /api/v1.
drivehttps://drive.arcanesuite.comIts public API only, under /api/v1.
Terminal
arcane api git POST /api/repos/acme/api/pulls --data '{"title":"Fix login","base":"main","head":"fix-login"}'
arcane api compute GET /api/apps
arcane api oversight GET "/api/spans?range=1h&q=status:error"
arcane api compute PATCH /api/apps/<id> --data @settings.json

JSON answers are printed indented; anything else is printed as it came. Quote paths that have ? or & in them.

Scripts and CI#

  • Exit codes. 0 when the command did what it was asked, 1 when it didn't. arcane app deploy exits 1 when the deployment fails and arcane app run when the command does, so a script can stop on them.
  • Output. Results go to stdout and errors to stderr, as one line that says what was wrong. Lists are aligned columns with a header; (none) when empty.
  • JSON. arcane app show, arcane run view and every arcane api call print JSON. arcane traces, arcane design and arcane drive take --json.
  • Secrets. arcane secret set reads the value from stdin when it gets no --value, and arcane app env --file reads variables from a file, so neither has to appear on a command line.

A CI job can't sign in, since that takes a person in a browser. It doesn't need to:

ToUse
Deploy an app from a workflowIts deploy hook. Save arcane app hook <app> as a secret and POST to it: curl -fsS -X POST "$DEPLOY_HOOK".
Clone or push from CI or a serverA personal access token or a deploy token as git's password. See Authentication.
Anything else, on a machine you keeparcane login --no-browser there, once: it prints a link to confirm from any device, and the machine stays signed in.

For AI agents#

An agent working on a signed-in computer uses the CLI as the person does, with their permissions. Give it this in the project's instructions:

AGENTS.md
## Arcane

This project is on Arcane Suite. Use the `arcane` CLI, which is already signed in.

- Check the account first: `arcane whoami`. Never run `arcane login` or `arcane logout`.
- Repositories: git works as usual. Pull requests: push the branch, then `arcane pr create --title … --body …` (never merge it yourself). Runs: `arcane run list --repo <owner/name>`.
- Deploy: `arcane app deploy <app>` (exits 1 when it fails, with the output). Logs: `arcane app logs <app>`.
- Failing requests: `arcane traces list --errors`, then `arcane traces show <trace id>`.
- Designs to build from: `arcane design list`, `arcane design show <id>`.
- Files in Drive: `arcane drive search <words>`, `arcane drive cat <id>` (text), `arcane drive get <id>`.
- Don't print secrets: no `arcane db password` or `arcane app env` in your output.
- The whole CLI: https://arcanesuite.com/cli/llms.txt
  • Everything the agent does is done as the person who signed in, and appears as theirs. Signing the computer out in Account → Security → Your devices stops it at once.
  • An assistant without a terminal uses the MCP server instead: https://mcp.arcanesuite.com/mcp, connected in Arcane Store → AI assistants.

Environment and files#

VariableDoes
ARCANE_ACCOUNTThe account every command uses, whatever the folder. --account wins over it.
ARCANE_VERBOSEWith any value, arcane app deploy prints the deployment's whole output.
XDG_CONFIG_HOMEWhere the sign-ins are kept, instead of ~/.config.
PathHolds
~/.config/arcane/The sign-ins, the folders' accounts and Arcane Code's settings.
~/.arcane/cli/<version>/Versions arcane update downloaded. The newest one runs.

When something goes wrong#

It saysDo
Not signed in. Run arcane login.Nobody is signed in as the account this command uses. arcane account list shows what's there.
… uses the account "x", which isn't signed in on this computer.The folder was given an account that's gone. arcane account add x, or arcane account use <another>.
Arcane Git refused the account "x"…The repository is another account's, or that account's access was revoked. arcane whoami in the folder says which account git used and why; arcane account use <name> gives the folder the right one. Only for the default account is arcane login the way to sign in again: it replaces the default, which other folders may use.
git asks for a passwordgit's setup was changed. arcane git setup.
A 403 on a commandThe account signed in isn't allowed to do it. arcane whoami says which account this folder uses.
Several apps are called "x": use the id.Two things share the name. arcane app list (or db list, servers list) prints the ids.
The code expired.The sign-in code lasts 10 minutes. Run arcane login again.

Create your Arcane Suite account

Who is this account for?