@catalyst-cloud/cli 0.16.20 → 0.16.21

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/CHANGELOG.md CHANGED
@@ -1,5 +1,9 @@
1
1
  # Changelog
2
2
 
3
+ ## 0.16.21
4
+
5
+ `catalyst accounts` now leaves out removed AI accounts: ones an admin revoked, or whose paid access ended. They take no work and take no new credential, so they no longer appear as accounts to repair. The list says how many it left out, and `catalyst accounts --all` shows them, marked "removed — kept for history". Setup now names a revoked account as ended instead of asking you to turn it on. Update the Catalyst plugin's skills along with the CLI: setup's account check uses `--all`, which older CLIs do not know.
6
+
3
7
  ## 0.16.20
4
8
 
5
9
  Setup on Linux now prints every command whole, on its own line, so you can copy it from any terminal width. When this computer still needs the session egress service, setup prints one `sudo` command that checks the installer's fingerprint and installs and starts the service. Run it, then run the same setup command again. When nothing may take work for your workspace yet, setup now names the command that enrolls this computer as a self-hosted machine: `catalyst onboard --runner --team <your team>`.
package/dist/args.js CHANGED
@@ -331,7 +331,9 @@ export const FLAG_TABLES = {
331
331
  help: "skip the published-release check (no network)",
332
332
  },
333
333
  },
334
- accounts: {},
334
+ accounts: {
335
+ all: { value: false, help: "also list removed accounts, which are kept for history and take no work" },
336
+ },
335
337
  seat: {
336
338
  size: { value: true, help: "model size: big or med" },
337
339
  stage: { value: true, help: "sized relay stage; defaults from size" },
@@ -538,7 +540,7 @@ export const VERB_USAGE = {
538
540
  write: "write <comment <ticket> --body|--stdin [--parent] [--bookkeeping] [--as-user] | state <ticket> --slot|--state-id|--state-type | label <ticket> --add... --remove... | create --team --title [--description|--stdin] [--label] [--priority] | reaction <ticket>|--comment <id> --emoji <e> | attachment <ticket> --title --url | session <ticket> [--title] [--plan-file] [--activity]>",
539
541
  ask: "ask <raise --team --title [--context] [--option]... [--default] --blocks <ticket>...|--nothing-to-block [--ask-key] [--gates-pr <n>... --released-by <letter>... [--gates-label hold|hold:preview]... [--gates-repo <owner/name>]] | accept <askTicket> --answer <commentId> --role <role> | list [--anyone] [--json]>",
540
542
  ready: "ready [--onboarding] [--local-sync] [--json] [--offline]",
541
- accounts: "accounts [--json]",
543
+ accounts: "accounts [--all] [--json]",
542
544
  seat: "seat checkout --size big|med --harness claude,codex,opencode [--session-id ID] [--stage STAGE] [--key-env NAME]",
543
545
  mcp: "mcp <add <name> --url URL <--auth none|--bearer SECRET_NAME|--header NAME=SECRET_NAME...>|list|remove <name>> [--json]",
544
546
  team: "team <list|check <KEY>|check --all|map <KEY> [--stage role=StateName]... [--yes --plan-hash H]|adopt <KEY> [--undo] [--yes --plan-hash H]|migrate <KEY> [--choice sourceId=destinationId]... [--retire] [--yes --plan-hash H]|checklist <KEY>> [--json]",
package/dist/execution.js CHANGED
@@ -311,9 +311,12 @@ export async function cmdQueue(args, ctx) {
311
311
  ctx.stdout(args.json ? JSON.stringify(out) : JSON.stringify(out, null, 2));
312
312
  return 0;
313
313
  }
314
- /** The five status words `/api/v1/coding-accounts` reports, in the words a customer reads. */
314
+ /** The status words `/api/v1/coding-accounts` reports, in the words a customer reads. */
315
315
  export const ACCOUNT_STATUS = {
316
- "expired-or-revoked": "expired or revoked — replace its credential on the AI accounts page (Settings → AI accounts → the account → Replace credential) before it can take work",
316
+ "expired-or-revoked": "credential expired or missing — replace its credential on the AI accounts page (Settings → AI accounts → the account → Replace credential) before it can take work",
317
+ // CTC-6204: revoked and ended accounts share one history-only end state (Ryan, 2026-10-19).
318
+ ended: "removed — kept for history, takes no work",
319
+ "out-of-rotation": "paused — its owner took it out of rotation",
317
320
  walled: "walled — the provider's usage limit is spent for now",
318
321
  active: "active — observed working",
319
322
  attested: "attested — healthy at last check, no work observed since",
@@ -326,12 +329,18 @@ export function accountDisplayName(a) {
326
329
  return v.trim();
327
330
  return a.accountSlot ?? "?";
328
331
  }
332
+ /** CTC-6204: a revoked account, or one whose paid access ended, can never take work again and takes
333
+ * no new credential. It is kept for history only. An older cloud still calls a revoked account
334
+ * `expired-or-revoked`, so `revokedAtMs` decides as well as the status word. */
335
+ export function historyOnly(a) {
336
+ return typeof a.revokedAtMs === "number" || a.status === "ended";
337
+ }
329
338
  /** One slot as a line a human reads: who it is, what state it is in, and what it is spending on. */
330
339
  export function renderAccount(a) {
331
340
  const display = accountDisplayName(a);
332
341
  const name = display === (a.accountSlot ?? "?") ? display : `${display} (${a.accountSlot ?? "?"})`;
333
342
  const harness = a.harness ? `/${a.harness}` : "";
334
- const status = a.status ? (ACCOUNT_STATUS[a.status] ?? a.status) : "status unknown";
343
+ const status = historyOnly(a) ? ACCOUNT_STATUS.ended : a.status ? (ACCOUNT_STATUS[a.status] ?? a.status) : "status unknown";
335
344
  const bits = [`${name} ${a.provider ?? "?"}${harness} ${status}`];
336
345
  // CTC-4199: a cancelled subscription is kept for reporting and not used; never re-credential it (Ryan, 2026-09-29).
337
346
  if (a.renewalStatus === "canceled")
@@ -367,17 +376,29 @@ export async function cmdAccounts(args, ctx) {
367
376
  if (res.status === 404)
368
377
  throw needsNewerCloud("coding-account status", cfg);
369
378
  const accounts = Array.isArray(res.body) ? res.body : (res.body?.accounts ?? []);
379
+ // CTC-6204: removed accounts are history, so they are left out unless --all asks for them. Listed,
380
+ // they read as accounts to repair, and agents kept trying to revive them.
381
+ const shown = flagBool(args, "all") ? accounts : accounts.filter((a) => !historyOnly(a));
382
+ const hidden = accounts.length - shown.length;
370
383
  if (args.json) {
371
- const named = accounts.map((a) => ({ ...a, displayName: accountDisplayName(a) }));
372
- ctx.stdout(JSON.stringify(Array.isArray(res.body) ? named : { ...res.body, accounts: named }));
384
+ const named = shown.map((a) => ({ ...a, displayName: accountDisplayName(a), removed: historyOnly(a) }));
385
+ ctx.stdout(JSON.stringify(Array.isArray(res.body) ? named : { ...res.body, accounts: named, removedHidden: hidden }));
373
386
  return 0;
374
387
  }
388
+ const addAt = `${normalizeBaseUrl(cfg.baseUrl)}/settings/coding-accounts`;
389
+ const hiddenLine = `${hidden} removed account${hidden === 1 ? " is" : "s are"} kept for history and take no work; catalyst accounts --all lists ${hidden === 1 ? "it" : "them"}.`;
375
390
  if (accounts.length === 0) {
376
- ctx.stdout(`No coding accounts are enrolled in this workspace. A workspace owner or admin adds one at ${normalizeBaseUrl(cfg.baseUrl)}/settings/coding-accounts; there is no command for that yet.`);
391
+ ctx.stdout(`No coding accounts are enrolled in this workspace. A workspace owner or admin adds one at ${addAt}; there is no command for that yet.`);
392
+ return 0;
393
+ }
394
+ if (shown.length === 0) {
395
+ ctx.stdout(`No AI account in this workspace can take work. A workspace owner or admin adds one at ${addAt}. ${hiddenLine}`);
377
396
  return 0;
378
397
  }
379
- for (const a of accounts)
398
+ for (const a of shown)
380
399
  ctx.stdout(renderAccount(a));
400
+ if (hidden > 0)
401
+ ctx.stdout(hiddenLine);
381
402
  return 0;
382
403
  }
383
404
  /**
@@ -97,11 +97,13 @@ async function inventory(ctx, journal, signal) {
97
97
  * (the server's isUsableCodingAccount): any provider, any member's account, and a canceled
98
98
  * subscription keeps working until its paid access ends. */
99
99
  function unusableCause(row, now) {
100
- if (row.declaredState !== "active")
101
- return "coding_account_inactive";
100
+ // CTC-6204: ended first. A revoked account is usually also declared inactive, and "turn it on"
101
+ // is advice it can never take.
102
102
  if (row.revokedAtMs !== null ||
103
103
  (row.accessEndsAtMs !== null && row.accessEndsAtMs <= now))
104
104
  return "coding_account_ended";
105
+ if (row.declaredState !== "active")
106
+ return "coding_account_inactive";
105
107
  if (row.needsCredential)
106
108
  return "coding_account_needs_login";
107
109
  if (row.quarantined)
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@catalyst-cloud/cli",
3
- "version": "0.16.20",
3
+ "version": "0.16.21",
4
4
  "description": "Set up Catalyst Cloud, check your tickets and manage your account from the command line.",
5
5
  "license": "MIT",
6
6
  "type": "module",
@@ -4,7 +4,7 @@ description: >-
4
4
  Catalyst's GitHub: show a ticket's pull request with its checks, reviews and review threads, say whether it is mergeable under this repository's policy, and explain what a PR accumulates as the ticket moves (the branch, the draft, the rewrite, the force-pushes, the labels, the queue). Use when someone asks "show me the PR", "what are the checks saying", "why hasn't it merged", "what does the queue need", "what does that label mean", or wants the branch and merge conventions Catalyst follows.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # Catalyst's GitHub
10
10
 
@@ -4,7 +4,7 @@ description: >-
4
4
  Catalyst's view of Linear on the customer's own cloud account. Reads a ticket with its comments, relations, labels, linked pull requests and agent sessions inline, from the cloud API by default, with local replica reads available as an explicit opt-in, always naming the source; searches tickets, PRs, projects and initiatives; writes comments, card moves, labels and new tickets through the account's agent proxy as the app actor, with every route, stage id, label id and marker read from the account's contract. Knows what a ticket accumulates as Catalyst works it (phase-outcome comments, the document per phase, the agent session, the labels, the single blocks relation, the bookkeeping marker, the eyes acknowledgement). Use when a person says "show me the ticket", "what did Catalyst write on it", "comment on it", "move it", "label it" or "file a ticket". Not for raising a decision for a human (what-needs-me) and not for pull requests (catalyst-github).
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # Catalyst Linear
10
10
 
@@ -4,7 +4,7 @@ description: >-
4
4
  Set up Catalyst Cloud and say whether setup is working. Walks a person from nothing to their first ticket running, one step at a time: the coding account, the project, the integrations and connected accounts, each repository's settings file, then one real ticket moving. Also logs this machine in, reads the readiness verdict with who can fix each failure, and checks the optional local replica. Use when someone says "set me up", "onboard me", "I just signed up", "get me started", "what do I do first", "log me in", "which account is this machine on", "am I set up", "what is missing", "why does nothing happen" or "is the replica running", when a login expired, or when a skill script exits 2 saying this machine is not connected. Does every step a key can do through the catalyst CLI, hands over the exact page for the steps only a browser can do, and never claims a step it did not watch succeed.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # Onboard me
10
10
 
@@ -32,7 +32,7 @@ const NOTES = [
32
32
  "Reads, in this order: `status` (machine), `ready --json` (machine checks and project checks, kept apart),",
33
33
  "`replica status --probe --json` and `events status --from-cache --probe --json` (optional local freshness),",
34
34
  "`me --json` and personal connection statuses (person), `contract --path …` for the account, the projects and the repositories,",
35
- "`contract --path codingAccounts` and `accounts --json` (coding accounts, and which one needs a new credential), and each",
35
+ "`contract --path codingAccounts` and `accounts --all --json` (coding accounts, and which one needs a new credential), and each",
36
36
  "project's hosts_current check with its fixedWhere (host), and each project's environment_declared check with its per-repository notes (repository declarations). The teams read is refreshed, so a mapping just saved reads back mapped.",
37
37
  "Reads `capabilities --json` once: when the installed CLI can run a step for this person's role (`team check`, `team map`), the next step is that command; otherwise the page, with who can.",
38
38
  "Reads `legacy --json` when the CLI has the verb: leftovers of the old local Catalyst runtime become a machine line and a note; removing them is the person's yes.",
@@ -716,7 +716,8 @@ const credentialProblem = (a) => {
716
716
  return null;
717
717
  };
718
718
  const readAccountRows = () => {
719
- const acc = runCli(["accounts", "--json"]);
719
+ // --all: the CLI leaves removed accounts out by default, and the retire note needs them.
720
+ const acc = runCli(["accounts", "--all", "--json"]);
720
721
  const doc = tryJson(acc.stdout);
721
722
  const rows = Array.isArray(doc)
722
723
  ? doc
@@ -4,7 +4,7 @@ description: >-
4
4
  Own one Catalyst Cloud project end to end until it closes. Use when the person says "run this project for me", "own this until it ships", "keep this moving", or hands you a project id or a set of tickets to drive. Subscribes to the account's event stream for the scope through the catalyst CLI, reacts to each change in the same turn, makes tickets ready and moves them to dispatch, parks what should stop, chases stalls, escalates inward, and keeps one status summary current. Writes to Linear as the app actor; never polls.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # Run this project
10
10
 
@@ -4,7 +4,7 @@ description: >-
4
4
  Get a stuck Catalyst Cloud ticket moving again. Use when the person asks "why is this parked and can you release it?", "unpark this", "get things flowing again", "the outage is over, retry what failed", or hands you a ticket that is not moving. Reads why nothing runs and what holds the ticket through the catalyst CLI, decides whether the recorded cause is fixed, previews the release, releases every governor holding the ticket the right way (or one failure class across a team), and raises an ask only for what a person has to do. Never releases a cause it cannot show changed without saying so.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # Unstick
10
10
 
@@ -4,7 +4,7 @@ description: >-
4
4
  The human's decision inbox on Catalyst Cloud, and the one way an agent raises a decision on their behalf. Use when the person asks "what needs me?", "what am I blocking?", or when active work is gated on a choice only they can make. Lists open asks ranked by how much open work each one holds, files an ask through the cloud's ask route with the account's own template, and records the answer so the held work releases. Never answers as the human, never duplicates an open ask.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # What needs me
10
10
 
@@ -4,7 +4,7 @@ description: >-
4
4
  What environment variable names does this repository need, and where does each one come from? Scans the repository offline (no login, no network) and lists the names in three groups (build/test, deploy-only, bindings), each with where it was found, what uses it, and where a local value would come from. Never reads a value or prints one. Also checks the environment variable table in `.catalyst/catalyst.toml` offline. Use when someone asks "what does catalyst.env.json mean", "what env vars does this repo need", "why does the container need this", or before reviewing or writing the declaration.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # What this repository needs
10
10
 
@@ -4,7 +4,7 @@ description: >-
4
4
  Use for "what's happening?", "what machines do we have?", "how much capacity do we have?", "where are we?", "why is that stuck?", "what closed?", "what's next?", "how does this work?", "why did it do that?", "how does it prioritise?" and "what does this setting do, where is it set?" in Catalyst Cloud, or asks for something to be done rather than known. Reads the contract via catalyst CLI. Read-only: route work/decisions, never answer as the human.
5
5
  allowed-tools: Bash(catalyst:*) Bash(npx -p @catalyst-cloud/cli catalyst:*)
6
6
  ---
7
- <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.20 — written in this repository for customer accounts -->
7
+ <!-- vendored-from: @catalyst-cloud/catalyst-skills@0.16.21 — written in this repository for customer accounts -->
8
8
 
9
9
  # What's happening
10
10
 
@@ -1,6 +1,6 @@
1
1
  # Coding accounts
2
2
 
3
- snapshot.mjs --accounts omits credentials/emails. An owner/admin enrols, pauses, removes or replaces credentials at `<their cloud>/settings/coding-accounts`; no command does these yet. `catalyst accounts` reads them.
3
+ snapshot.mjs --accounts omits credentials/emails. An owner/admin enrols, pauses, removes or replaces credentials at `<their cloud>/settings/coding-accounts`; no command does these yet. `catalyst accounts` reads them. It leaves out removed accounts (revoked, or paid access that ended). They are kept for history, never take work again and take no new credential, so never suggest reviving one. `catalyst accounts --all` lists them.
4
4
 
5
5
  Slots identify credentials, not emails. Claude/GLM/Qwen use Claude CLI, Codex uses Codex; GLM/Qwen also use OpenCode. Routing names the model.
6
6