Skip to content

Getting started

Headless install

Set up Catalyst in CI, an image build or an agent VM, with no prompts and no browser.

The headless path is for a machine with no person at it. It assumes every browser step already happened:

  • someone minted a personal key at Settings → API keys;
  • Linear and the GitHub App are connected for the workspace;
  • the person behind the key connected their own Linear and GitHub accounts.

A headless run never asks a question, never opens a browser and never starts a browser sign-in. It takes every input from a flag, an environment variable or a file. With --json it prints one JSON document. The exit code names the kind of problem, and the output names each item.

Input Flag (catalyst onboard) Environment
Personal key --key-file <path> CATALYST_CLOUD_TOKEN, or CATALYST_CLOUD_TOKEN_FILE
Linear team --team <ID or key> CATALYST_ONBOARD_TEAM
Repositories --repo <owner/name>, repeatable CATALYST_ONBOARD_REPOS (comma or space separated)
AI account --coding-account <slot> CATALYST_ONBOARD_CODING_ACCOUNT
Runner opt-in --runner yes|no CATALYST_ONBOARD_RUNNER
Machine name, for a runner --machine-name <name> none
Cloud --base-url <url> CATALYST_CLOUD_BASE_URL
  • A flag wins over its variable. With the one-line installer, give these inputs as environment variables. CATALYST_ONBOARD_HEADLESS=1 works in place of --headless.
  • A machine that already has a saved login needs no key.
  • catalyst accounts lists the AI accounts in your workspace.
  • --runner yes makes this machine a self-hosted runner, the same as catalyst setup --runner; see Self-hosting. The key must belong to a workspace owner or administrator. The CLI uses its own pinned public images and gets the machine’s runner key from your workspace. CATALYST_RUNNER_ORG_KEY_FILE names a file holding a runner key you already have, to use instead.
  • A headless runner is named after the machine’s hostname unless you pass --machine-name. The one-line installer has no way to pass it, so run catalyst onboard --headless yourself to choose the name.
  • A headless run with --runner yes exits 0 only after the runner is enrolled, reports its capacity and the project admits it. A missing gate exits 11 with that gate named; a failed step exits 10. --runner no skips this machine’s runner.

The key is read only from the environment or from a file. It is never accepted on the command line, because other processes on the machine can read a command line: --key with --headless exits 12.

  • A key file must be a regular file, owned by you or by root, that other users cannot write. If other users can read it, it is used with a warning. The output never prints the key file’s path, in case the variable holds the key itself by mistake.
  • A key for a different person than this machine’s saved login or setup record is refused with exit 12, and the saved login is left as it was.
  • --dry-run makes no network call and saves nothing.
  • The CLI removes the supplied key variables before its onboarding steps run. The shell installer passes them to its bootstrap child processes, including npm. Use a key file when provisioning the machine so those processes receive the file path instead of the key value.
  • The key is saved in the login config (~/.config/catalyst-cloud/customer.json, mode 0600), the same as catalyst login --key.
  • The key never appears in the output, the install log or the setup receipt. The JSON reports only where the key came from: env, file or saved.
  • In an image build, don’t leave the key in a layer. Either run setup when the container starts, or remove the login config in the same build step.
Step Headless If it is not done
Install the CLI, skills and folders runs —
Sign in runs with the key exit 11 account_key_missing or account_key_rejected, with the API keys page. A host account key is refused: exit 12 account_key_not_personal.
Linear for the workspace checks only exit 11 linear_workspace_grant_missing; open Settings → Integrations. The returned /a/account/connections URL redirects there.
GitHub App for the workspace checks only exit 11 github_app_grant_missing; open Settings → Integrations. The returned /a/account/connections URL redirects there.
Your Linear account checks only exit 11 linear_personal_grant_missing, /settings/connected-accounts
Your GitHub account checks only exit 11 github_personal_grant_missing, /settings/connected-accounts
Linear team, project, repositories, AI account check run with your inputs exit 11 with the step’s reason
Settings file, values, daily update run when possible listed under deferred; the exit code does not wait for them

Before any network call, the run checks that every input is present. Every missing input is listed at once with its flag and variable, and the run exits 11. The one-line installer makes the same check before it installs anything.

Exit Meaning
0 Ready for work.
10 A step failed. See failed.
11 Something is missing: an input, a browser approval or a step that waits. See missing.
12 Refused: a key on the command line, a key file other users can write or own, a host key, a key for another person than the saved login, a malformed runner choice or an unknown option. See refused.

The codingAccount field and --coding-account flag retain their command names; the app calls these AI accounts. The /a/account/connections URL in the receipt redirects to Settings → Integrations.

The installer itself can stop before the CLI takes over. It then exits 11 when the key or an onboarding input is missing, 12 when the runner choice or coding-account slot is invalid, or 10 when the machine needs fixing first. Its --json object is the install record, and its message names the reason, for example account_key_missing or the missing CATALYST_ONBOARD_* variables.

Exactly one document goes to stdout; everything else goes to stderr. It is the setup receipt (steps, exit, complete), plus a headless block:

{
"schema": 1,
"exit": 11,
"complete": false,
"steps": [{ "id": "linear.workspace", "state": "waiting", "reason": "linear_workspace_grant_missing" }],
"headless": {
"schema": "catalyst-onboard-headless/1",
"inputs": {
"accountKey": "env",
"baseUrl": "https://staging.catalystcloud.dev",
"team": "ENG",
"repos": ["acme/api"],
"codingAccount": "claude-one",
"runner": "no"
},
"missing": [
{
"id": "linear.workspace",
"kind": "grant",
"reason": "linear_workspace_grant_missing",
"text": "Linear is not connected for this workspace. A workspace owner or administrator connects it at https://staging.catalystcloud.dev/a/account/connections, then run the same command.",
"url": "https://staging.catalystcloud.dev/a/account/connections"
}
],
"refused": [],
"failed": [],
"deferred": [],
"warnings": []
}
}

Each item has an id, a kind (input, grant or step), a reason, and a text that ends in the fix. It also has flag, env and url where they apply.

CI. The key comes from the CI secret store:

Terminal window
export CATALYST_CLOUD_TOKEN="$CATALYST_KEY"
export CATALYST_ONBOARD_TEAM=ENG CATALYST_ONBOARD_REPOS=acme/api
export CATALYST_ONBOARD_CODING_ACCOUNT=claude-one CATALYST_ONBOARD_RUNNER=no
curl -fsSL https://staging.catalystcloud.dev/install.sh | sh -s -- --headless --housekeeping no --json > setup.json

A Docker build. The key is a BuildKit secret, so it never becomes a build argument:

RUN --mount=type=secret,id=catalyst_key \
CATALYST_CLOUD_TOKEN_FILE=/run/secrets/catalyst_key \
CATALYST_ONBOARD_TEAM=ENG CATALYST_ONBOARD_REPOS=acme/api \
CATALYST_ONBOARD_CODING_ACCOUNT=claude-one CATALYST_ONBOARD_RUNNER=no \
sh -c 'curl -fsSL https://staging.catalystcloud.dev/install.sh | sh -s -- --headless --housekeeping no; \
code=$?; config_home="${CATALYST_SKILLS_HOME-$HOME}"; \
rm -f "${config_home:-.}/.config/catalyst-cloud/customer.json" \
"${XDG_CONFIG_HOME:-$HOME/.config}/catalyst-cloud/customer.json" \
"$HOME/.config/catalyst-cloud/customer.json" || exit $?; exit $code'

An agent VM with the CLI already installed. The key file is provisioned with mode 0600:

Terminal window
catalyst onboard --headless --json --key-file /etc/catalyst/key \
--team ENG --repo acme/api --repo acme/web --coding-account claude-one --runner no

Run the same command again after fixing what it names. Steps that are already done are checked again and skipped.