@brainbase-labs/cli 0.22.0 → 0.24.0
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 +23 -5
- package/dist/index.js +958 -80
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -144,7 +144,7 @@ Playbook files carry a small YAML frontmatter (`title`, `description`) — the C
|
|
|
144
144
|
| `BRAINBASE_API_URL` | Legacy KLS host override. Control requests use `/api/cli`; it is also the fallback for model-proxy and registry traffic. |
|
|
145
145
|
| `BRAINBASE_PROXY_URL` | Override the model-proxy host used when enabling harness tracking. |
|
|
146
146
|
| `BRAINBASE_REGISTRY_URL` | Override the registry API host. |
|
|
147
|
-
| `BRAINBASE_TOKEN` | Use a PAT instead of the stored login session |
|
|
147
|
+
| `BRAINBASE_TOKEN` | Use a PAT instead of the stored login session. The only way a PAT authenticates a control-plane command — see [Auth](#auth). |
|
|
148
148
|
| `BRAINBASE_HOME` | Where local state lives (default: `~/.brainbase`) |
|
|
149
149
|
|
|
150
150
|
Model-proxy and registry traffic fall back through `BRAINBASE_API_URL`,
|
|
@@ -152,11 +152,29 @@ the server captured at login, and finally `https://api.v1.brainbaselabs.com`.
|
|
|
152
152
|
|
|
153
153
|
## Auth
|
|
154
154
|
|
|
155
|
-
|
|
155
|
+
Three credentials, and which ones a command considers depends on the service
|
|
156
|
+
it talks to:
|
|
156
157
|
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
158
|
+
| Commands | Credentials tried, in order |
|
|
159
|
+
|-|-|
|
|
160
|
+
| `agent`, `orchestration`, `link`, `unlink`, `sync`, `status`, `team` | `BRAINBASE_TOKEN`, then the `auth.json` session |
|
|
161
|
+
| `template`, `skill`, `token` | `BRAINBASE_TOKEN`, then the session, then `token.json` |
|
|
162
|
+
| `task create` | `BRAINBASE_TOKEN`, then the session, then `token.json` — the last only when no session is configured |
|
|
163
|
+
|
|
164
|
+
`brainbase whoami` (or `--json`) reports which one is active.
|
|
165
|
+
|
|
166
|
+
**For CI:** `brainbase token create` saves the PAT to `~/.brainbase/token.json`,
|
|
167
|
+
and control-plane commands never read that file — `brainbase agent push` needs
|
|
168
|
+
the token in `BRAINBASE_TOKEN`:
|
|
169
|
+
|
|
170
|
+
```bash
|
|
171
|
+
export BRAINBASE_TOKEN=bbpat_…
|
|
172
|
+
brainbase agent push
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
Do not bake a `~/.brainbase` directory into a build image: a leftover
|
|
176
|
+
`auth.json` outranks the stored PAT, and every control-plane command starts
|
|
177
|
+
failing once its session expires.
|
|
160
178
|
|
|
161
179
|
An explicit PAT does not inherit routing from a stored login. Set
|
|
162
180
|
`BRAINBASE_CONTROL_PLANE_URL` when using a PAT against a non-default MAS host.
|