Install Archie's CLI
Archie's command line is how you put his team to work from your terminal. Rich tables when you read it, plain JSON when you pipe it.
The same heyarchie package ships the Python SDK and the archie command, so anything you script here you can later move into code.
Install With Pipx or Uv
The archie command is a standalone app, so install it in its own isolated environment with pipx or uv. That keeps it off your system Python and puts archie straight onto your PATH. uv is identical on every operating system. Sign in with your region's address, or name the region with --environment uk; archie saves the address with your credentials, so you give it once.
brew install pipx pipx install heyarchie archie auth login --api-url https://uk.heyarchie.com
python3 -m pip install --user pipx python3 -m pipx ensurepath pipx install heyarchie archie auth login --api-url https://uk.heyarchie.com
py -m pip install --user pipx py -m pipx ensurepath py -m pipx install heyarchie archie auth login --api-url https://uk.heyarchie.com
uv tool install heyarchie archie auth login --api-url https://uk.heyarchie.com
A bare pip install heyarchie trips an externally-managed-environment error on macOS and recent Debian and Ubuntu (PEP 668), because the system Python is guarded. pipx and uv manage a virtualenv for you. To use the SDK as a library, run pip install heyarchie inside your project's virtualenv.
From Install to First Command
Sign in With Your Browser
archie auth login opens your browser, shows a one-time code, and waits while you sign in with your firm's SSO. If you belong to more than one workspace, add --workspace <id> to choose one. It uses the RFC 8628 device flow, so nothing is pasted and no long-lived key is minted.
Archie Saves Your Session
The short-lived session is written to ~/.archie/credentials.toml (chmod 600) under the [default] profile, so every other command reads it the same way. No keys to paste, no files to edit.
Check Who You Are
Run archie auth status to see your profile, the address it talks to and your token, redacted. Run archie auth logout to drop the session.
Put Him to Work
Prove the sign-in worked with archie keys list, which reads your real Connect keys using the session Archie just saved. Then list his skills or start a WorkStream.
Your First Commands
Three commands cover most first sessions. For CI, swap the browser flow for a Connect key: create one with archie keys create while you are signed in, then pass it to login or set ARCHIE_API_KEY and skip login entirely.
archie skills list # everything Archie can do archie keys list # your Connect keys archie workstreams run month-end-close # put a WorkStream to work (its id, permakey or slug)
archie auth login --api-key sk_xxxxxxxxxxxxxxxx --api-url https://uk.heyarchie.com # or set ARCHIE_API_KEY and ARCHIE_ENVIRONMENT (or ARCHIE_API_URL) in the environment and skip login entirely
Sign In
A workstream id accepts a UUID, a WorkStream slug, or a 7-character permakey; Archie resolves all three.
Browser sign-in (the default). Add --api-key to sign in with a Connect key instead.
Shows your profile, the address it talks to and your token, redacted.
Prints the bearer token for use in scripts.
Drops the saved session.
Keys and Skills
Lists your Connect keys.
Creates an sk_ key and prints it once. Add --scope for each permission it gets. Needs permission to manage keys.
The skill catalogue.
One typed command per skill (heyarchie 1.4.0 and later).
Calls one skill with raw JSON input.
Run a Workstream
The WorkStreams you can see.
A WorkStream's metadata and step graph.
Starts a cycle.
Follow a Run
Shows a cycle's progress.
Cancels a running cycle.
Streams a cycle's events live.
Run Any Skill With Typed Flags
Every public skill is also a command under archie skills run, generated from the skill registry. Required fields become required flags, list and object fields take inline JSON, and each command's --help is the skill's input schema. No JSON body to assemble by hand.
# Create a topic, typed flags instead of a JSON body archie skills run topic-create --name "FY26 audit — Acme" --type client # List topics, pipe-friendly archie skills run topic-list --limit 5 --json | jq '.topics[].name' # ask_archie as a typed command (--query is required) archie skills run ask-archie --query "Under ASC 606, when is revenue recognised?" # A list-typed field takes inline JSON archie skills run accruals-suggest \ --client-id "$CLIENT" --period 2026-04 \ --focus-areas '["wages", "rent"]'
$ archie skills run topic-create --help
Usage: archie skills run topic-create [OPTIONS]
Create a Topic in the caller's workspace (optionally bound to a client). The
topic is stamped created_by_type=archie.
Options:
--name TEXT The new topic's name, from 1 to 200 characters.
[required]
--client-id TEXT UUID of the client to bind
--theme-color TEXT Hex like #DAFBE1; default applied server-side
--type TEXT Topic type: client | matter | process_period | advisory
| compliance | internal (DB-enforced enum)
--json Emit raw JSON to stdout (machine-friendly).
--profile TEXT Credentials profile in ~/.archie/credentials.toml
(default: 'default').
--api-url TEXT API base URL. Falls back to env ARCHIE_API_URL or saved
credentials.
--api-key TEXT Bearer token. Falls back to env ARCHIE_API_KEY or saved
credentials.
--help Show this message and exit.Ask Archie and Run a Cycle
ask_archie is the general-purpose skill, the fallback for any accounting question that doesn't fit a more specific one. Every skill takes the same invoke <slug> --input shape, and the CLI sends the same body as POST /api/v1/skills/<slug>/invoke. Long questions can live in a file, passed with @.
archie skills invoke ask_archie \
--input '{"query": "What is the BAS, and when is it due?"}' \
--json | jq -r '.answer'
# Every answer carries citations to the standard it came from:
archie skills invoke ask_archie \
--input '{"query": "Capitalise or expense a 3-year SaaS subscription?"}' \
--json | jq -r '.citations[].standard'echo '{"query": "Walk me through the lease classification test for our new warehouse."}' > q.json
archie skills invoke ask_archie --input @q.json# Ask for tax advice in one jurisdiction
archie skills invoke advise_tax \
--input '{"topic": "CGT discount on an active asset", "jurisdiction": "AU"}'
# List every slug you can call
archie skills list --json | jq -r '.[].slug'CYCLE=$(archie workstreams run month-end-close \ --period FY26-Q1 \ --var include_deferred=true \ --idempotency-key close-2026-04-acme-001 \ --json | jq -r .cycle_id) archie workstreams logs "$CYCLE" --follow
Flags
These flags ride along on every command. CLI flags win over environment variables, which win over the saved credentials file.
Emits raw JSON to stdout instead of a rich table.
The credentials profile in ~/.archie/credentials.toml (default: 'default').
Your region's address. Falls back to ARCHIE_API_URL, then ARCHIE_ENVIRONMENT, then the address saved at sign-in.
A bearer token. Falls back to ARCHIE_API_KEY or saved credentials.
Environment Variables
The API base URL, Your region's address, for example https://uk.heyarchie.com.
A bearer token. When set, you can skip login.
Your region's name: uk, us, au or ca. Read when ARCHIE_API_URL is not set.
The workspace to work in, when your sign-in reaches more than one.