@konstantdotcloud/boombox 0.2.0 → 0.3.1

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/README.md CHANGED
@@ -1,83 +1,44 @@
1
1
  # @konstantdotcloud/boombox
2
2
 
3
- CLI and MCP bridge for a tenant's Boombox VM.
3
+ The command line for **Boombox** — your company's governed AI runtime.
4
4
 
5
- Boombox Cloud lives at <https://boombox.konstant.cloud>. Each tenant VM is served at `https://boombox-<tenant>.exe.xyz`. The CLI stores your tenant identity, talks to the VM, and exposes the Gary cassette runtime to Claude Desktop, Claude Code, Cursor, OpenClaw, or any MCP client.
5
+ Ask Gary (the expert inside Boombox) about your business, add files to its memory, run and share **cassettes** (reusable, governed jobs), and connect Boombox to Claude or Cursor as an MCP server.
6
+
7
+ > You need a Boombox account. The CLI signs you in, then talks to your own Boombox instance. Everything runs against your tenant; your API key stays on your machine.
6
8
 
7
9
  ## Install
8
10
 
9
11
  ```bash
10
- curl -fsSL https://boombox.konstant.cloud/install/boombox.sh | sh
12
+ npm install -g @konstantdotcloud/boombox
11
13
  ```
12
14
 
13
- The installer installs `@konstantdotcloud/boombox` and then tells you to run `boombox login`.
14
-
15
- ## Quickstart
15
+ Then sign in:
16
16
 
17
17
  ```bash
18
- boombox login # browser sign-in via boombox.konstant.cloud; writes ~/.boombox/config.toml
19
- boombox whoami # verifies tenant, user, VM URL, and key expiry
20
- boombox admin # opens the VM admin UI through a short-lived cloud grant
21
- boombox run bd_pre_meeting_brief --input meeting_uid=sample --input organizer=user@example.com --input attendees='["user@example.com"]' --input start_time=2026-06-02T15:00:00Z --input summary=Sample
18
+ boombox login
22
19
  ```
23
20
 
24
- For MCP clients, add `boombox serve --mcp` after `boombox login` succeeds. The MCP server defaults to the `advanced` profile (cassette authoring + rack verbs included); set `GARY_MCP_PROFILE=andrew` or pass `--profile` to narrow or change it.
21
+ No install needed for one-offs run any command with `npx`:
25
22
 
26
- ## Commands
27
-
28
- | Command | What it does |
29
- |-|-|
30
- | `boombox login [--tenant <tenant_id>]` | Browser sign-in through `boombox.konstant.cloud`; writes tenant id, VM URL, API key, and expiry to `~/.boombox/config.toml`. |
31
- | `boombox whoami` | Calls the VM identity endpoint and prints tenant id, user id, VM URL, key expiry, and days remaining. |
32
- | `boombox admin` | Requests a short-lived admin grant from Boombox Cloud and opens the tenant VM admin UI. |
33
- | `boombox run <cassette_name> [--input key=value ...] [--no-tail] [--json]` | Manually triggers a cassette through `/gateway/rack/run`, prompts for required missing inputs, then polls to a terminal state unless `--no-tail` is set. |
34
- | `boombox cassettes list` | Lists active cassettes available to the tenant. |
35
- | `boombox cassettes show <id> [--draft]` | Prints a cassette YAML projection. |
36
- | `boombox cassettes publish <draft_id> --name <name> [--version <n>] [--json]` | Publishes a dry-run-approved cassette draft to the tenant tier via `POST /gateway/cassette/publish`; renders gate rejections (e.g. `dry-run-not-green`) with fix guidance. |
37
- | `boombox runs list [--cassette=X] [--since=24h] [--actor=Y] [--status=completed] [--limit=20]` | Lists recent runs with run id, cassette, actor, status, duration, and start time. |
38
- | `boombox runs show <run_id>` | Shows one run: spec hash, inputs, step trace, delivery receipts, error summary, and replay ref. |
39
- | `boombox logs tail [--cassette=X]` | Tails run/step events from the VM SSE stream. |
40
- | `boombox artifacts open <artifact_id>` | Opens `<vm_url>/artifact/<artifact_id>` in the system browser. |
41
- | `boombox keys list` | Lists tenant API keys visible to the current API key authority. |
42
- | `boombox capabilities list [--kind=recipe\|tool\|artifact_template\|prompt_template] [--status=available\|missing]` | Lists registered tenant capabilities. |
43
- | `boombox status` | Checks VM health, `/v2/api/info`, and the run-event stream. |
44
- | `boombox doctor` | Checks config, VM reachability, API-key validity, and MCP boot. |
45
- | `boombox init` | Manual config fallback for provisioned credentials. Most users should prefer `boombox login`. |
46
- | `boombox enroll` | Browser enrollment flow that can write config from a provisioning payload. |
47
- | `boombox serve [--mcp] [--http] [--port <port>]` | Starts stdio MCP and/or the local HTTP proxy. MCP clients should use `--mcp`. |
48
- | `boombox reload` | Sends SIGHUP to a running local `boombox serve`. |
49
- | `boombox restart` | Stops and respawns local `boombox serve`. |
50
- | `boombox stop` | Stops a running local `boombox serve`. |
51
- | `boombox upgrade` | Self-update through npm. |
52
-
53
- ## Config file
54
-
55
- `~/.boombox/config.toml`:
56
-
57
- ```toml
58
- [konstant]
59
- tenant_id = "example"
60
- api_key = "kn_example_***"
61
- gateway_url = "https://boombox-example.exe.xyz"
62
-
63
- [runtime]
64
- default_kind = "vm"
65
- vm_url = "https://boombox-example.exe.xyz"
66
-
67
- [boombox]
68
- http_port = 8787
69
- mcp_enabled = true
70
-
71
- [admin]
23
+ ```bash
24
+ npx @konstantdotcloud/boombox ask "what changed this week?"
72
25
  ```
73
26
 
74
- `runtime.vm_url` is the preferred target. If it is present, CLI commands talk to the tenant VM. `gateway_url` remains the shared cloud fallback and login/onboarding origin.
27
+ ## First five minutes
75
28
 
76
- The file is created with mode `600`. Override the location with `BOOMBOX_HOME=/some/dir` (config lives at `$BOOMBOX_HOME/config.toml`).
29
+ ```bash
30
+ boombox login # opens a browser, signs you in, saves your config
31
+ boombox ask "what's at risk on the BNY deal this week?" # one-shot answer over your org
32
+ boombox ingest ./transcripts # add local files to your company's memory
33
+ boombox run weekly_recap # run a cassette and watch it to completion
34
+ boombox share <run_id> # get a no-login link to the result
35
+ ```
36
+
37
+ `boombox whoami` shows who you're signed in as; `boombox doctor` checks your setup if something looks off.
77
38
 
78
- ## MCP client setup
39
+ ## Connect it to Claude or Cursor (MCP)
79
40
 
80
- ### Claude Desktop / Claude Code / Cursor / OpenClaw
41
+ Add this to your MCP client's config and restart the client:
81
42
 
82
43
  ```json
83
44
  {
@@ -90,54 +51,77 @@ The file is created with mode `600`. Override the location with `BOOMBOX_HOME=/s
90
51
  }
91
52
  ```
92
53
 
93
- After saving, restart your client. The default MCP profile exposes the chat-parity tools: `ask_gary`, `list_threads`, `clear_thread`, `artifact_fetch`, and `gary_status`. Advanced/operator profiles can expose rack, prompt, cassette, and admin verbs when explicitly enabled.
94
-
95
- ## Ops route contracts
54
+ Your AI client can then call Gary directly — ask questions, manage threads, fetch artifacts. Choose how much it can do with `--profile` (or the `GARY_MCP_PROFILE` env var): `default` (ask + threads + artifacts), `advanced` (adds cassette authoring), `operator` (adds admin).
96
55
 
97
- The ops CLI uses direct HTTP service routes with `Authorization: Bearer <tenant_api_key>`; it does not speak MCP wire format.
56
+ ## Command reference
98
57
 
99
- | CLI command | Primary route contract |
58
+ ### Ask, run, share, ingest
59
+ | Command | What it does |
100
60
  |-|-|
101
- | `whoami` | `GET /v2/api/me`. |
102
- | `status` | `GET /health`, `GET /v2/api/info`, `GET /admin/runs/stream` (fallback: `/api/admin/runs/stream`). |
103
- | `runs list` | `GET /api/admin/runs` with `cassette`, `since`, `actor`, `status`, `limit`; fallback: `GET /api/admin/cassettes/runs`. |
104
- | `runs show` | `GET /api/admin/runs/:run_id`; fallback: `GET /api/admin/cassettes/runs/:run_id/replay`. |
105
- | `logs tail` | `GET /admin/runs/stream` SSE; fallback: `GET /api/admin/runs/stream`. |
106
- | `run` | `GET /api/admin/cassettes/:id` for required input metadata, `POST /gateway/rack/run` to trigger, then `GET /api/admin/runs/:run_id` or replay fallback to poll. |
107
- | `cassettes list` | `GET /api/admin/cassettes`; the VM route currently defaults unknown status filters to `active`. |
108
- | `cassettes show` | `GET /api/admin/cassettes/:id/yaml?draft=true`; falls back to `GET /api/admin/cassettes/:id` if YAML is not wired. |
109
- | `keys list` | `GET /api/admin/keys`. |
110
- | `capabilities list` | `GET /api/admin/capabilities`. |
61
+ | `boombox ask <question>` | One-shot answer from Gary over your org. Flags: `--model auto\|fast\|reason\|explore\|premium\|opus`, `--thinking off\|…\|xhigh`, `--thread <id>`, `--fresh`, `--json`. |
62
+ | `boombox run <cassette> [--input k=v …]` | Run a cassette; prompts for missing inputs, then waits for it to finish. `--no-tail` to fire-and-exit, `--json` for raw output. |
63
+ | `boombox share <run_id>` | Mint a no-login, expiring link to a run's result. `--ttl <days>` (default 14), `--email <addr>`, `--json`. |
64
+ | `boombox ingest <path…>` | Upload files (transcripts, docs) into your company memory. `--recursive`, `--json`. |
111
65
 
112
- ## Local HTTP server
66
+ ### Cassettes
67
+ | Command | What it does |
68
+ |-|-|
69
+ | `boombox cassettes list [--status published\|draft\|all]` | List cassettes available to you. |
70
+ | `boombox cassettes show <id> [--draft]` | Print a cassette's definition (YAML). |
71
+ | `boombox cassettes validate <id> [--draft]` | Run readiness checks on a cassette. |
72
+ | `boombox cassettes dry-run <id> [--draft]` | Dry-run a draft — verdict + blockers, no durable writes. |
73
+ | `boombox cassettes publish <draft_id> --name <name>` | Publish a dry-run-approved draft. `--version <n>`, `--json`. |
113
74
 
114
- When `boombox serve --http` is running, your browser hits Hono on `localhost:8787`:
75
+ ### Runs & artifacts
76
+ | Command | What it does |
77
+ |-|-|
78
+ | `boombox runs list [--cassette <id>] [--since 24h] [--status <s>] [--limit 20]` | List recent runs. |
79
+ | `boombox runs show <run_id>` | One run in detail: inputs, step trace, receipts, errors. |
80
+ | `boombox logs tail [--cassette <id>]` | Stream live run/step events (Ctrl+C to stop). |
81
+ | `boombox artifacts open <artifact_id>` | Open an artifact in your browser. |
115
82
 
116
- - `GET http://localhost:8787/` → the bundled Boombox UI when `packages/boombox/ui/dist` exists.
117
- - `GET http://localhost:8787/api/...` proxied to the configured VM/cloud gateway with `Authorization: Bearer <api_key>` injected. The browser never sees your API key.
118
- - `GET http://localhost:8787/gateway/...` → rewritten to `/api/gateway/...` upstream.
119
- - `GET http://localhost:8787/healthz` 200 if config loaded.
83
+ ### Identity & setup
84
+ | Command | What it does |
85
+ |-|-|
86
+ | `boombox login [--tenant <id>]` | Sign in via the browser; writes `~/.boombox/config.toml`. |
87
+ | `boombox whoami` | Show who you're signed in as + key expiry. |
88
+ | `boombox doctor` | Check config, connectivity, and auth. |
89
+ | `boombox enroll` / `boombox init` | First-time enrollment / manual config (most people just use `login`). |
120
90
 
121
- If `ui/dist/` is missing, `/` and SPA routes return `503 ui_not_built`; `/healthz` and `/api/*` still work. Run `cd packages/boombox/ui && npm run build` to populate `ui/dist/`.
91
+ ### Connect your own MCP servers, capabilities, keys
92
+ | Command | What it does |
93
+ |-|-|
94
+ | `boombox mcp add --id <id> --name <name> --url <url> [--transport streamable_http\|sse] [--tools a,b]` | Register a tenant-owned MCP server your cassettes can call. |
95
+ | `boombox mcp list` / `rm <id>` / `status <id> [--enable\|--disable]` | Manage your registered MCP servers. |
96
+ | `boombox capabilities list` | List your registered recipes, tools, and templates. |
97
+ | `boombox keys list` | List your tenant API keys. |
122
98
 
123
- CORS is locked to `localhost`/`127.0.0.1` origins.
99
+ ### Serve & process control
100
+ | Command | What it does |
101
+ |-|-|
102
+ | `boombox serve [--mcp] [--http] [--port <p>] [--profile <p>]` | Start the MCP server (`--mcp`) and/or a local web UI proxy (`--http`). |
103
+ | `boombox status` | Check your Boombox instance's health. |
104
+ | `boombox reload` / `restart` / `stop` | Manage a running `boombox serve`. |
105
+ | `boombox upgrade [--check]` | Update this CLI to the latest version. |
124
106
 
125
- ## Troubleshooting
107
+ ### Admin (super-admin only)
108
+ | Command | What it does |
109
+ |-|-|
110
+ | `boombox admin ui` | Open the admin UI in your browser. |
111
+ | `boombox admin provision <tenant>` | Provision a new tenant (needs `ADMIN_API_KEY`). |
126
112
 
127
- - **`boombox doctor` says "config not found"** — run `boombox login`; use `boombox init` only when Konstant gave you raw VM credentials.
128
- - **`whoami` returns 401/403** — the API key is invalid, expired, or lacks authority. Run `boombox login` to refresh it.
129
- - **`gateway: unreachable`** — verify `runtime.vm_url` in `~/.boombox/config.toml`; the expected VM domain is `https://boombox-<tenant>.exe.xyz`.
130
- - **Run stays queued** — the VM may not have an Inngest/worker dispatcher wired for that cassette. Check `boombox runs show <run_id>` and the VM admin run trace.
131
- - **Port 8787 already in use** — pass `--port 9000` to `boombox serve --http`, or set `http_port` in config.
132
- - **MCP boot test fails** — make sure your Node version is `>= 20`.
113
+ ## Configuration
133
114
 
134
- ## Privacy & data
115
+ Your settings live in `~/.boombox/config.toml` — your tenant id, your instance URL, and your API key. It's created with `600` permissions and never leaves your machine. Point the CLI at a different file with `BOOMBOX_HOME=/some/dir`.
135
116
 
136
- The CLI stores config and API keys locally; it does not store run output, telemetry, or tenant data on disk. Runtime data, replay packets, artifacts, and events live in the tenant VM/Mongo path configured for that tenant. LLM calls route through the tenant's configured provider path.
117
+ `boombox login` writes this for you; you rarely touch it directly.
137
118
 
138
- ## Versioning
119
+ ## Troubleshooting
139
120
 
140
- `0.1.0` V1 ships with the default MCP tools plus CLI commands for login, VM status, cassette runs, run inspection, artifacts, keys, capabilities, admin, and lifecycle control. Run `boombox upgrade` to pull updates.
121
+ - **`config not found`** run `boombox login`.
122
+ - **`401` / `403`** — your key expired or is invalid; run `boombox login` again.
123
+ - **can't reach your instance** — check `boombox status`; confirm your instance URL in `~/.boombox/config.toml`.
124
+ - **MCP won't boot** — make sure you're on Node 20+.
141
125
 
142
126
  ## License
143
127