@botpress/adk-cli 1.19.0-beta.4 → 1.19.0-beta.6
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/{dist/index-a3ZL0_Jr-q145h35p.js → assets/ui-dist/assets/index-BC_iUF2d.js} +2 -2
- package/assets/ui-dist/assets/index-BxpvDT_K.css +1 -0
- package/{dist/index-BESZeTO5-2rpmcefa.js → assets/ui-dist/assets/index-C7gAokRv.js} +2 -2
- package/assets/ui-dist/assets/{index-B3b7PPgV.js → index-exyr_Djl.js} +424 -424
- package/assets/ui-dist/assets/jetbrains-mono-cyrillic-wght-normal-D73BlboJ.woff2 +0 -0
- package/assets/ui-dist/assets/jetbrains-mono-greek-wght-normal-Bw9x6K1M.woff2 +0 -0
- package/assets/ui-dist/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2 +0 -0
- package/assets/ui-dist/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2 +0 -0
- package/assets/ui-dist/assets/jetbrains-mono-vietnamese-wght-normal-Bt-aOZkq.woff2 +0 -0
- package/assets/ui-dist/index.html +2 -2
- package/dist/{README-wjb7z7f0.md → README-824wa4jj.md} +1 -1
- package/dist/SKILL-75ym6tcj.md +257 -0
- package/dist/SKILL-chnwzmt1.md +548 -0
- package/dist/SKILL-d4bs53y3.md +244 -0
- package/dist/SKILL-h4b2f1n9.md +114 -0
- package/dist/SKILL-hbw5nt95.md +111 -0
- package/dist/actions-h7hxxvxr.md +823 -0
- package/dist/adk-build-emhwd0tg.md +39 -0
- package/dist/adk-debug-yrrdtpmb.md +23 -0
- package/dist/adk-dev-console-7z9rtjpy.md +17 -0
- package/dist/adk-document-ras6zzzh.md +68 -0
- package/dist/adk-eval-vx76dwq0.md +17 -0
- package/dist/adk-explain-fcsaw852.md +22 -0
- package/dist/adk-init-9kmxmbbe.md +30 -0
- package/dist/adk-ship-dybzn884.md +29 -0
- package/dist/adk-test-xq67savs.md +27 -0
- package/dist/adk-validate-1p4skv4m.md +31 -0
- package/dist/advanced-patterns-z86m9h1a.md +669 -0
- package/dist/agent-config-1aqvkrgf.md +450 -0
- package/dist/agent-steps-zj4c1n9t.md +115 -0
- package/dist/assets-q7jt8r2q.md +237 -0
- package/dist/autonomous-execution-fymc12e5.md +747 -0
- package/dist/cli-c31e06yr.md +1334 -0
- package/dist/cli.js +4241 -6449
- package/dist/commands.json +25 -4
- package/dist/common-failures-ht29w2db.md +231 -0
- package/dist/component-registry-bbpw0see.md +43 -0
- package/dist/context-api-760cvh0h.md +461 -0
- package/dist/conversation-analysis-8ka4nrm4.md +420 -0
- package/dist/conversation-lifecycle-4seqqjc1.md +311 -0
- package/dist/conversations-gwfvxaee.md +1111 -0
- package/dist/custom-components-y5wdgpey.md +167 -0
- package/dist/debug-workflow-vz84q80v.md +239 -0
- package/dist/desk-k54ktvsd.md +852 -0
- package/dist/doc-standards-ck6ax2jd.md +124 -0
- package/dist/eval-format-7n9brja4.md +354 -0
- package/dist/evals-y1zcr1mc.md +11 -0
- package/dist/explain-config-1yaq3zzd.md +424 -0
- package/dist/files-dzt0wxn3.md +918 -0
- package/dist/{index-3t354nbw.html → index-0qts7wfk.html} +2 -2
- package/{assets/ui-dist/assets/index-a3ZL0_Jr.js → dist/index-BC_iUF2d-3h9mqazs.js} +2 -2
- package/dist/index-BxpvDT_K-62864175.css +1 -0
- package/{assets/ui-dist/assets/index-BESZeTO5.js → dist/index-C7gAokRv-zr7dzkba.js} +2 -2
- package/dist/{index-B3b7PPgV-zetkb01w.js → index-exyr_Djl-ksys08wc.js} +424 -424
- package/dist/integration-actions-xang7tma.md +659 -0
- package/dist/integrations-k5ss07f4.md +266 -0
- package/dist/interfaces-6t0bpxs4.md +97 -0
- package/dist/jetbrains-mono-cyrillic-wght-normal-D73BlboJ-6vpq1jfh.woff2 +0 -0
- package/dist/jetbrains-mono-greek-wght-normal-Bw9x6K1M-jv5dqe09.woff2 +0 -0
- package/dist/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a-h2ysfc3f.woff2 +0 -0
- package/dist/jetbrains-mono-latin-wght-normal-B9CIFXIH-hj2e42wt.woff2 +0 -0
- package/dist/jetbrains-mono-vietnamese-wght-normal-Bt-aOZkq-wttk1pwp.woff2 +0 -0
- package/dist/knowledge-bases-20rg8p5c.md +456 -0
- package/dist/llm-debugging-76ng8rzm.md +209 -0
- package/dist/mcp-server-n1asyzhv.md +112 -0
- package/dist/messages-gkkg0b54.md +769 -0
- package/dist/model-configuration-f273kgd0.md +201 -0
- package/dist/multi-agent-dashboard-1mdfjdts.md +70 -0
- package/dist/pages-xn18xn73.md +273 -0
- package/dist/patterns-mistakes-5vb99dhf.md +469 -0
- package/dist/plugins-ttnx8f49.md +280 -0
- package/dist/tables-x45t36dd.md +1136 -0
- package/dist/tags-46td3qrg.md +516 -0
- package/dist/test-patterns-hj47w4nc.md +355 -0
- package/dist/testing-workflow-2vkp932f.md +225 -0
- package/dist/tools-wk7bq24z.md +581 -0
- package/dist/trace-summarization-hdyx1c2e.md +313 -0
- package/dist/traces-and-logs-f2kjfh19.md +203 -0
- package/dist/triggers-4j2cc86x.md +719 -0
- package/dist/ui-server-entry.js +1839 -791
- package/dist/workflow-steps-mrdrf1c5.md +851 -0
- package/dist/workflows-gadx3s69.md +1408 -0
- package/dist/zai-agent-reference-e6644aad.md +454 -0
- package/dist/zai-complete-guide-mnna5d6f.md +1408 -0
- package/package.json +4 -4
- package/assets/ui-dist/assets/index-DIFGtVmI.css +0 -1
- package/dist/index-DIFGtVmI-d4dhjg97.css +0 -1
|
@@ -0,0 +1,1334 @@
|
|
|
1
|
+
# CLI Reference
|
|
2
|
+
|
|
3
|
+
Command-line interface for building AI agents with the Botpress ADK.
|
|
4
|
+
|
|
5
|
+
## Quick Start
|
|
6
|
+
|
|
7
|
+
```bash
|
|
8
|
+
# 1. Log in non-interactively when possible
|
|
9
|
+
export BOTPRESS_TOKEN=pat_abc123
|
|
10
|
+
adk login --token "$BOTPRESS_TOKEN"
|
|
11
|
+
|
|
12
|
+
# 2. Create a new agent with defaults
|
|
13
|
+
adk init my-bot --yes --skip-link
|
|
14
|
+
cd my-bot
|
|
15
|
+
|
|
16
|
+
# 3. Link explicitly when you know the IDs
|
|
17
|
+
adk link --workspace ws_123 --bot bot_456
|
|
18
|
+
|
|
19
|
+
# 4. Start development (CI/agent mode: NDJSON events, no TUI)
|
|
20
|
+
adk dev --non-interactive
|
|
21
|
+
|
|
22
|
+
# 5. Deploy
|
|
23
|
+
adk deploy --yes
|
|
24
|
+
```
|
|
25
|
+
|
|
26
|
+
## Commands
|
|
27
|
+
|
|
28
|
+
### adk init
|
|
29
|
+
|
|
30
|
+
Create a new ADK agent project.
|
|
31
|
+
|
|
32
|
+
```bash
|
|
33
|
+
adk init [name]
|
|
34
|
+
```
|
|
35
|
+
|
|
36
|
+
**Options:**
|
|
37
|
+
|
|
38
|
+
- `name` - Project name (optional, prompts if omitted)
|
|
39
|
+
- `-t, --template <template>` - Template to use: `blank` or `hello-world`
|
|
40
|
+
- `-y, --yes` - Skip prompts and use sensible defaults
|
|
41
|
+
- `--defaults` - Alias for `--yes`
|
|
42
|
+
- `--skip-link` - Skip the linking step after project creation
|
|
43
|
+
|
|
44
|
+
**Defaults when using `--yes` / `--defaults`:**
|
|
45
|
+
|
|
46
|
+
- Project name: `my-agent` (if omitted)
|
|
47
|
+
- Template: `hello-world` (if omitted)
|
|
48
|
+
- Linking: skipped unless you run `adk link` later
|
|
49
|
+
|
|
50
|
+
**Examples:**
|
|
51
|
+
|
|
52
|
+
```bash
|
|
53
|
+
adk init customer-support
|
|
54
|
+
|
|
55
|
+
# Non-interactive setup for AI agents and CI
|
|
56
|
+
adk init customer-support --yes --skip-link
|
|
57
|
+
|
|
58
|
+
# Use the current hello-world template
|
|
59
|
+
adk init customer-support --template hello-world
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
**Automation notes:**
|
|
63
|
+
|
|
64
|
+
- `adk init` installs dependencies automatically after scaffolding.
|
|
65
|
+
- The CLI auto-selects a package manager based on lockfiles when possible, otherwise it falls back to the first available manager.
|
|
66
|
+
- If authentication is missing, `adk init` may still invoke login first.
|
|
67
|
+
- The non-interactive path only works after login has already been completed.
|
|
68
|
+
- For unattended setup, log in first with `adk login --token "$BOTPRESS_TOKEN"`, then run `adk init <name> --yes --skip-link`.
|
|
69
|
+
|
|
70
|
+
**Creates:**
|
|
71
|
+
|
|
72
|
+
```
|
|
73
|
+
my-agent/
|
|
74
|
+
├── agent.config.ts # Agent configuration
|
|
75
|
+
└── src/
|
|
76
|
+
├── actions/ # Functions
|
|
77
|
+
├── conversations/ # Conversation handlers
|
|
78
|
+
├── knowledge/ # Knowledge bases
|
|
79
|
+
├── tables/ # Data storage
|
|
80
|
+
├── triggers/ # Event subscriptions
|
|
81
|
+
└── workflows/ # Long-running processes
|
|
82
|
+
```
|
|
83
|
+
|
|
84
|
+
**Note:** Additional directories like `tools/`, `assets/`, etc. can be created manually as needed.
|
|
85
|
+
|
|
86
|
+
### adk login
|
|
87
|
+
|
|
88
|
+
Authenticate with Botpress.
|
|
89
|
+
|
|
90
|
+
```bash
|
|
91
|
+
adk login [options]
|
|
92
|
+
```
|
|
93
|
+
|
|
94
|
+
**Options:**
|
|
95
|
+
|
|
96
|
+
- `--token <token>` - Personal access token
|
|
97
|
+
- `--profile <name>` - Profile name (default: "default")
|
|
98
|
+
- `--api-url <url>` - API URL (default: https://api.botpress.cloud)
|
|
99
|
+
|
|
100
|
+
**Examples:**
|
|
101
|
+
|
|
102
|
+
```bash
|
|
103
|
+
# Interactive login
|
|
104
|
+
adk login
|
|
105
|
+
|
|
106
|
+
# Non-interactive with token
|
|
107
|
+
adk login --token pat_abc123
|
|
108
|
+
|
|
109
|
+
# Non-interactive with environment variable
|
|
110
|
+
export BOTPRESS_TOKEN=pat_abc123
|
|
111
|
+
adk login --token "$BOTPRESS_TOKEN"
|
|
112
|
+
|
|
113
|
+
# Multiple profiles
|
|
114
|
+
adk login --profile staging
|
|
115
|
+
adk login --profile production
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
**Automation notes:**
|
|
119
|
+
|
|
120
|
+
- Preferred AI/CI path: `adk login --token <token>`.
|
|
121
|
+
- `BOTPRESS_TOKEN` is best used as `adk login --token "$BOTPRESS_TOKEN"`.
|
|
122
|
+
- Bare `BOTPRESS_TOKEN` is only auto-used in non-interactive or no-TTY contexts.
|
|
123
|
+
- Without a token, `adk login` falls back to the interactive browser/manual flow.
|
|
124
|
+
|
|
125
|
+
**Profile Management:**
|
|
126
|
+
|
|
127
|
+
```bash
|
|
128
|
+
adk profiles list # List all profiles
|
|
129
|
+
adk profiles set staging # Switch profile
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
### adk logout
|
|
133
|
+
|
|
134
|
+
Remove ADK credentials for the current or a named profile.
|
|
135
|
+
|
|
136
|
+
```bash
|
|
137
|
+
adk logout [options]
|
|
138
|
+
```
|
|
139
|
+
|
|
140
|
+
**Options:**
|
|
141
|
+
|
|
142
|
+
- `--profile <profile>` - Profile to remove (defaults to the active profile)
|
|
143
|
+
- `--format <format>` - Output format (`json`)
|
|
144
|
+
|
|
145
|
+
```bash
|
|
146
|
+
adk logout
|
|
147
|
+
adk logout --profile staging
|
|
148
|
+
```
|
|
149
|
+
|
|
150
|
+
### adk dev
|
|
151
|
+
|
|
152
|
+
Start development mode with hot reloading.
|
|
153
|
+
|
|
154
|
+
```bash
|
|
155
|
+
adk dev [options]
|
|
156
|
+
```
|
|
157
|
+
|
|
158
|
+
**Options:**
|
|
159
|
+
|
|
160
|
+
- `-p, --port <port>` - Bot port (default: 3000)
|
|
161
|
+
- `--port-console <port>` - UI console port (default: 3001)
|
|
162
|
+
- `--non-interactive` - Emit structured NDJSON events to stdout without the Ink/TUI (CI/agent-friendly)
|
|
163
|
+
- `-v, --verbose` - Show additional details (project path, log file)
|
|
164
|
+
- `--otlp` - Enable OTLP trace export to an external collector (default port 4318)
|
|
165
|
+
- `--port-otlp <port>` - Port for the OTLP collector endpoint (Jaeger, otel-tui, etc.)
|
|
166
|
+
|
|
167
|
+
**What it does:**
|
|
168
|
+
|
|
169
|
+
1. Generates bot project in `.adk/bot/`
|
|
170
|
+
2. Creates/restores development bot
|
|
171
|
+
3. Syncs tables
|
|
172
|
+
4. Checks integrations
|
|
173
|
+
5. Registers the agent with the shared Dev Console (starts the singleton if needed)
|
|
174
|
+
6. Dev Console available at http://localhost:3001
|
|
175
|
+
7. Watches files and hot-reloads
|
|
176
|
+
|
|
177
|
+
Running `adk dev` in multiple project directories registers each agent with the same Dev Console. Switch between agents in the sidebar. See the [Dev Console multi-agent dashboard](../../adk-dev-console/references/multi-agent-dashboard.md) for details.
|
|
178
|
+
|
|
179
|
+
**Example:**
|
|
180
|
+
|
|
181
|
+
```bash
|
|
182
|
+
adk dev
|
|
183
|
+
|
|
184
|
+
# CI / agent mode — NDJSON events to stdout, no TUI
|
|
185
|
+
adk dev --non-interactive
|
|
186
|
+
|
|
187
|
+
# Custom ports in non-interactive mode
|
|
188
|
+
adk dev --non-interactive --port 4000 --port-console 4001
|
|
189
|
+
```
|
|
190
|
+
|
|
191
|
+
In `--non-interactive` mode the `lifecycle.ready` event includes `serverPort`, `botPort`, `agentPath`, `healthUrl`, and `botUrl`, so scripts don't need to parse log lines to find them. To discover an already-running Dev Console from a separate process, read `~/.adk/console.port` or run `adk dashboard --no-browser --format json` / `adk ps --format json`.
|
|
192
|
+
|
|
193
|
+
**Automation notes:**
|
|
194
|
+
|
|
195
|
+
- `--non-interactive` is the most AI-friendly mode, but `adk dev` is not fully headless.
|
|
196
|
+
- Dev can still hit interactive flows such as preflight, knowledge-base sync, or config prompts depending on project state.
|
|
197
|
+
- Treat `adk dev` as CI-friendly rather than guaranteed prompt-free.
|
|
198
|
+
- Event-driven integrations are not always perfectly mirrored in local dev; if an event flow behaves strangely, verify it against a deployed bot too.
|
|
199
|
+
|
|
200
|
+
### adk deploy
|
|
201
|
+
|
|
202
|
+
Deploy agent to Botpress Cloud.
|
|
203
|
+
|
|
204
|
+
```bash
|
|
205
|
+
adk deploy [options]
|
|
206
|
+
```
|
|
207
|
+
|
|
208
|
+
**Options:**
|
|
209
|
+
|
|
210
|
+
- `-e, --env <environment>` - Target environment (default: "production")
|
|
211
|
+
- `-y, --yes` - Auto-approve non-destructive deploy-plan changes without prompting
|
|
212
|
+
- `--confirm-storage-changes` - Explicitly confirm destructive table/KB/asset deletions
|
|
213
|
+
- `--dry-run` - Compute the deploy plan without applying changes
|
|
214
|
+
- `--format <format>` - Output format (`json`; requires `--yes` or `--dry-run`)
|
|
215
|
+
|
|
216
|
+
**What it does:**
|
|
217
|
+
|
|
218
|
+
1. Runs `adk build`
|
|
219
|
+
2. Validates configuration
|
|
220
|
+
3. Runs preflight checks
|
|
221
|
+
4. Deploys bot to Botpress Cloud
|
|
222
|
+
5. Syncs knowledge bases
|
|
223
|
+
6. Syncs tables
|
|
224
|
+
7. Syncs assets
|
|
225
|
+
|
|
226
|
+
**Requires:**
|
|
227
|
+
|
|
228
|
+
- Logged in (`adk login`)
|
|
229
|
+
- `agent.json` with botId and workspaceId
|
|
230
|
+
|
|
231
|
+
**Example:**
|
|
232
|
+
|
|
233
|
+
```bash
|
|
234
|
+
adk deploy
|
|
235
|
+
|
|
236
|
+
# Auto-approve non-destructive deploy-plan changes
|
|
237
|
+
adk deploy --yes
|
|
238
|
+
|
|
239
|
+
# Preview deploy plan without applying it
|
|
240
|
+
adk deploy --dry-run
|
|
241
|
+
adk deploy --dry-run --format json
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
**Automation notes:**
|
|
245
|
+
|
|
246
|
+
- `--yes` auto-approves non-destructive deploy-plan changes.
|
|
247
|
+
- Destructive table, KB, or asset deletions still require `--confirm-storage-changes`.
|
|
248
|
+
- JSON output requires either `--yes` or `--dry-run`.
|
|
249
|
+
- Deploy still validates configuration and may require interaction if config values are missing.
|
|
250
|
+
- Do not assume `adk deploy --yes` is fully non-interactive.
|
|
251
|
+
|
|
252
|
+
### adk build
|
|
253
|
+
|
|
254
|
+
Build agent for production.
|
|
255
|
+
|
|
256
|
+
```bash
|
|
257
|
+
adk build
|
|
258
|
+
```
|
|
259
|
+
|
|
260
|
+
Generates types, bundles code, validates configuration.
|
|
261
|
+
|
|
262
|
+
### adk link
|
|
263
|
+
|
|
264
|
+
Link local agent to existing remote bot.
|
|
265
|
+
|
|
266
|
+
```bash
|
|
267
|
+
adk link [options]
|
|
268
|
+
```
|
|
269
|
+
|
|
270
|
+
**Options:**
|
|
271
|
+
|
|
272
|
+
- `--workspace <id>` - Workspace ID
|
|
273
|
+
- `--bot <id>` - Bot ID
|
|
274
|
+
- `--dev <id>` - Dev bot ID (optional)
|
|
275
|
+
- `--api-url <url>` - Botpress API URL (e.g., https://api.botpress.cloud)
|
|
276
|
+
- `-f, --force` - Overwrite existing agent.json if present
|
|
277
|
+
|
|
278
|
+
**Example:**
|
|
279
|
+
|
|
280
|
+
```bash
|
|
281
|
+
# Interactive (recommended)
|
|
282
|
+
adk link
|
|
283
|
+
|
|
284
|
+
# Scriptable when you already know the IDs
|
|
285
|
+
adk link --workspace ws_123 --bot bot_456
|
|
286
|
+
```
|
|
287
|
+
|
|
288
|
+
Creates `agent.json` with bot and workspace IDs.
|
|
289
|
+
|
|
290
|
+
Current project scaffolds do not add `agent.json` to `.gitignore` automatically, so add that manually if your team does not want it committed.
|
|
291
|
+
|
|
292
|
+
**Automation notes:**
|
|
293
|
+
|
|
294
|
+
- `adk link --workspace <id> --bot <id>` is the best AI-driven path.
|
|
295
|
+
- If only one workspace exists, `adk link` may auto-select it.
|
|
296
|
+
- Even with flags, the command still uses the interactive Ink flow internally, so do not assume it is safe in every no-TTY environment.
|
|
297
|
+
|
|
298
|
+
### adk chat
|
|
299
|
+
|
|
300
|
+
Chat with your **local development bot**.
|
|
301
|
+
|
|
302
|
+
> ⚠️ `adk chat` (and `adk chat --single`) targets the linked dev bot — the one started by `adk dev` and identified by `devId`. It does **not** hit the deployed production bot. Never use it as a post-deploy smoke test or as any kind of "did the deploy work?" verification: a `--single` round-trip can pass against the dev bot while production is broken. For deployed bots, use `adk status --format json` for metadata and direct the user to the Dev Console for live verification.
|
|
303
|
+
|
|
304
|
+
```bash
|
|
305
|
+
adk chat [options]
|
|
306
|
+
```
|
|
307
|
+
|
|
308
|
+
**Options:**
|
|
309
|
+
|
|
310
|
+
- `--single <message>` - Send one message, print the response, and exit
|
|
311
|
+
- `--format <format>` - Output format (`json`)
|
|
312
|
+
- `--conversation-id <id>` - Continue an existing conversation (use `--format json` to capture the ID from a prior turn)
|
|
313
|
+
- `--timeout <duration>` - Max wait duration: `500ms`, `30s`, `1m`, `5m` (default: `60s`)
|
|
314
|
+
|
|
315
|
+
```bash
|
|
316
|
+
adk chat # interactive
|
|
317
|
+
adk chat --single "<message>" # one-shot
|
|
318
|
+
adk chat --single "<message>" --format json
|
|
319
|
+
adk chat --single "Run the full analysis" --timeout 30s
|
|
320
|
+
adk chat --single "Follow up" --conversation-id <id>
|
|
321
|
+
```
|
|
322
|
+
|
|
323
|
+
**Requires:**
|
|
324
|
+
|
|
325
|
+
- `adk dev` running (also creates the `devId` on first run). Conversation continuation requires the dev server to be running — the user token is persisted automatically.
|
|
326
|
+
|
|
327
|
+
**Example:**
|
|
328
|
+
|
|
329
|
+
```bash
|
|
330
|
+
adk chat
|
|
331
|
+
|
|
332
|
+
# Output:
|
|
333
|
+
> Hello!
|
|
334
|
+
Bot: Hi! How can I help you today?
|
|
335
|
+
```
|
|
336
|
+
|
|
337
|
+
### adk check
|
|
338
|
+
|
|
339
|
+
Offline validation of the project — schema correctness, ADK convention compliance, integration availability — without contacting Botpress Cloud. Use before `adk dev`, before `adk deploy`, and after any code change.
|
|
340
|
+
|
|
341
|
+
```bash
|
|
342
|
+
adk check [options]
|
|
343
|
+
```
|
|
344
|
+
|
|
345
|
+
**Options:**
|
|
346
|
+
|
|
347
|
+
- `--format <format>` - Output format: `text` (default) or `json`
|
|
348
|
+
|
|
349
|
+
**Examples:**
|
|
350
|
+
|
|
351
|
+
```bash
|
|
352
|
+
adk check
|
|
353
|
+
adk check --format json # machine-readable for automation
|
|
354
|
+
```
|
|
355
|
+
|
|
356
|
+
### adk status
|
|
357
|
+
|
|
358
|
+
Report the project's current link state (workspace + bot), deployed version metadata, and any pending sync issues. Read-only.
|
|
359
|
+
|
|
360
|
+
```bash
|
|
361
|
+
adk status [options]
|
|
362
|
+
```
|
|
363
|
+
|
|
364
|
+
**Options:**
|
|
365
|
+
|
|
366
|
+
- `--format <format>` - Output format: `text` or `json`
|
|
367
|
+
|
|
368
|
+
### adk ps
|
|
369
|
+
|
|
370
|
+
List running ADK dev processes (Dev Console + agents).
|
|
371
|
+
|
|
372
|
+
```bash
|
|
373
|
+
adk ps [options]
|
|
374
|
+
```
|
|
375
|
+
|
|
376
|
+
**Options:**
|
|
377
|
+
|
|
378
|
+
- `--watch [seconds]` - Continuous refresh (default interval: 2s, not supported with `--format json`)
|
|
379
|
+
- `--cloud` - Include Cloud Dev Console prod selections in the listing
|
|
380
|
+
- `--wide` - Show all columns (runtime, both PIDs, path)
|
|
381
|
+
- `--format <format>` - `text` (default) or `json`
|
|
382
|
+
|
|
383
|
+
Shows PID, status, uptime, and ports for each process. If none is running, it prints a friendly empty result instead of starting one.
|
|
384
|
+
|
|
385
|
+
**Example:**
|
|
386
|
+
|
|
387
|
+
```bash
|
|
388
|
+
adk ps
|
|
389
|
+
adk ps --wide
|
|
390
|
+
adk ps --watch
|
|
391
|
+
adk ps --format json
|
|
392
|
+
```
|
|
393
|
+
|
|
394
|
+
### adk dashboard
|
|
395
|
+
|
|
396
|
+
Open the Dev Console in standalone mode — no agent project required.
|
|
397
|
+
|
|
398
|
+
```bash
|
|
399
|
+
adk dashboard [options]
|
|
400
|
+
```
|
|
401
|
+
|
|
402
|
+
Starts the Dev Console UI server and opens the browser. Useful for connecting to Cloud bots or waiting for agents to register. The standalone Dev Console stays alive even with an empty agent registry.
|
|
403
|
+
|
|
404
|
+
**Options:**
|
|
405
|
+
|
|
406
|
+
- `--port-console <port>` - Starting port for the console server (default: 3001)
|
|
407
|
+
- `--no-browser` - Do not open the dashboard in a browser (ensures the singleton is running and prints the URL)
|
|
408
|
+
- `--format <format>` - Output format (`json`) — emits `{ port, url, wasSpawned }`
|
|
409
|
+
|
|
410
|
+
```bash
|
|
411
|
+
adk dashboard # open in browser
|
|
412
|
+
adk dashboard --no-browser --format json # script-friendly: discover the running URL
|
|
413
|
+
```
|
|
414
|
+
|
|
415
|
+
### adk kill
|
|
416
|
+
|
|
417
|
+
Gracefully stop agents or the entire Dev Console.
|
|
418
|
+
|
|
419
|
+
```bash
|
|
420
|
+
adk kill [agents...] [options]
|
|
421
|
+
```
|
|
422
|
+
|
|
423
|
+
**Options:**
|
|
424
|
+
|
|
425
|
+
- `--all` - Stop all agents and the Dev Console singleton
|
|
426
|
+
- `--current` - Stop the agent in the current working directory
|
|
427
|
+
- `--pid <pid>` - Stop a specific process by PID
|
|
428
|
+
- `--force` - Escalate to SIGKILL if graceful shutdown fails
|
|
429
|
+
- `--dry-run` - Preview what would be stopped without acting
|
|
430
|
+
|
|
431
|
+
**Examples:**
|
|
432
|
+
|
|
433
|
+
```bash
|
|
434
|
+
adk kill --all # stop everything
|
|
435
|
+
adk kill --current # stop agent in cwd
|
|
436
|
+
adk kill my-agent # stop by name
|
|
437
|
+
adk kill --pid 12345 # stop by PID
|
|
438
|
+
adk kill --all --dry-run # preview
|
|
439
|
+
```
|
|
440
|
+
|
|
441
|
+
### adk logs
|
|
442
|
+
|
|
443
|
+
Read recent log entries from the linked bot.
|
|
444
|
+
|
|
445
|
+
```bash
|
|
446
|
+
adk logs [level] [options]
|
|
447
|
+
```
|
|
448
|
+
|
|
449
|
+
**Options:**
|
|
450
|
+
|
|
451
|
+
- `level` - Filter by severity: `error`, `warning`, `info` (positional, optional)
|
|
452
|
+
- `--format <format>` - `text` or `json`
|
|
453
|
+
- `--follow` - Stream live
|
|
454
|
+
- `since=<duration>` - Filter to a recent window (e.g., `since=1h`)
|
|
455
|
+
|
|
456
|
+
**Examples:**
|
|
457
|
+
|
|
458
|
+
```bash
|
|
459
|
+
adk logs # recent entries, all levels
|
|
460
|
+
adk logs error --format json # errors as JSON
|
|
461
|
+
adk logs --follow --format json # stream live
|
|
462
|
+
adk logs warning since=1h # last hour of warnings
|
|
463
|
+
```
|
|
464
|
+
|
|
465
|
+
### adk traces
|
|
466
|
+
|
|
467
|
+
Read execution traces — tool calls, action invocations, LLM steps, error context — for understanding *what happened* during a turn, beyond what `adk logs` reports. Reads from the local SQLite trace store under `.adk/`.
|
|
468
|
+
|
|
469
|
+
```bash
|
|
470
|
+
adk traces [tokens...] [options]
|
|
471
|
+
```
|
|
472
|
+
|
|
473
|
+
**Filter tokens** (positional, space-separated):
|
|
474
|
+
|
|
475
|
+
- `error` — only traces that contain errors
|
|
476
|
+
- `workflow=<name>` — filter by workflow name (comma-separated for multiple)
|
|
477
|
+
- `action=<name>` — filter by action/tool name
|
|
478
|
+
- `trigger=<name>` — filter by trigger name
|
|
479
|
+
- `conversation=<id>` — filter by conversation id
|
|
480
|
+
- `trace=<id>` — drill into a specific trace (shows the full span tree)
|
|
481
|
+
- `since=<duration>` / `until=<duration>` — e.g. `30s`, `5m`, `1h`, `2d`, `1w`
|
|
482
|
+
- `limit=<n>` — max traces to show (default: 20)
|
|
483
|
+
|
|
484
|
+
**Options:**
|
|
485
|
+
|
|
486
|
+
- `-f, --follow` — stream new traces as they complete
|
|
487
|
+
- `--include-llm` — include LLM instructions, code, and tools in drill-in mode
|
|
488
|
+
- `--format <format>` — `json` only (omit for default text output)
|
|
489
|
+
|
|
490
|
+
**Examples:**
|
|
491
|
+
|
|
492
|
+
```bash
|
|
493
|
+
adk traces # recent traces
|
|
494
|
+
adk traces error # error traces only
|
|
495
|
+
adk traces workflow=onboarding # traces for a workflow
|
|
496
|
+
adk traces conversation=<id> --format json
|
|
497
|
+
adk traces trace=<id> --include-llm # drill into one trace with LLM content
|
|
498
|
+
adk traces since=1h limit=50 --format json
|
|
499
|
+
adk traces error --follow # stream errors live
|
|
500
|
+
```
|
|
501
|
+
|
|
502
|
+
### adk workflows
|
|
503
|
+
|
|
504
|
+
Inspect workflow definitions and runs on the linked dev bot. All `adk workflows ...` commands target the dev bot (same credentials path as `adk dev`) and only accept `--format json` — any other `--format` value is rejected.
|
|
505
|
+
|
|
506
|
+
**Subcommands:**
|
|
507
|
+
|
|
508
|
+
- `adk workflows` / `adk workflows list` — list discovered workflow definitions
|
|
509
|
+
- `adk workflows inspect <name>` — show one workflow's schema and metadata (input schema, schedule, timeout)
|
|
510
|
+
- `adk workflows run <name> [payload]` — kick off a run, optionally waiting for it to finish
|
|
511
|
+
- `adk workflows runs [tokens...|<wrkflow_id>]` — list runs with filters, or dump status + state + steps for one run by id
|
|
512
|
+
|
|
513
|
+
#### adk workflows list
|
|
514
|
+
|
|
515
|
+
```bash
|
|
516
|
+
adk workflows # list (default)
|
|
517
|
+
adk workflows list --format json
|
|
518
|
+
```
|
|
519
|
+
|
|
520
|
+
#### adk workflows inspect
|
|
521
|
+
|
|
522
|
+
```bash
|
|
523
|
+
adk workflows inspect <name> [--format json]
|
|
524
|
+
```
|
|
525
|
+
|
|
526
|
+
Prints the workflow's input schema, description, schedule (if any), and timeout. Use this before `adk workflows run` to see what payload shape it expects.
|
|
527
|
+
|
|
528
|
+
#### adk workflows run
|
|
529
|
+
|
|
530
|
+
```bash
|
|
531
|
+
adk workflows run <name> [payload] [--wait] [--timeout <duration>] [--format json]
|
|
532
|
+
```
|
|
533
|
+
|
|
534
|
+
**Options:**
|
|
535
|
+
|
|
536
|
+
- `[payload]` — JSON string, or pipe via stdin (`echo '{...}' | adk workflows run …`)
|
|
537
|
+
- `--wait` — block until the run reaches a terminal state
|
|
538
|
+
- `--timeout <duration>` — `500ms`, `30s`, `1m`, `5m`; implies `--wait`
|
|
539
|
+
- `--format <format>` — only `json` is accepted; any other value is rejected (defaults to `json` if omitted, unlike sibling commands which default to text)
|
|
540
|
+
|
|
541
|
+
**Examples:**
|
|
542
|
+
|
|
543
|
+
```bash
|
|
544
|
+
adk workflows run onboarding '{"userId":"123"}'
|
|
545
|
+
adk workflows run onboarding '{"userId":"123"}' --wait --timeout 30s
|
|
546
|
+
echo '{"userId":"123"}' | adk workflows run onboarding --wait
|
|
547
|
+
```
|
|
548
|
+
|
|
549
|
+
#### adk workflows runs
|
|
550
|
+
|
|
551
|
+
Diagnose durable workflows beyond what `adk logs` and `adk traces` show — list recent runs with filters, or pull the full status + `workflowState` + `workflowSteps` payloads for one run by id.
|
|
552
|
+
|
|
553
|
+
```bash
|
|
554
|
+
adk workflows runs [tokens...|<wrkflow_id>] [--format json]
|
|
555
|
+
```
|
|
556
|
+
|
|
557
|
+
**List filters** (passed as `key=value` tokens):
|
|
558
|
+
|
|
559
|
+
- `name=<workflowName>` — filter by workflow definition name
|
|
560
|
+
- `status=<s1[,s2,...]>` — `pending`, `in_progress`, `failed`, `completed`, `listening`, `paused`, `timedout`, `cancelled`
|
|
561
|
+
- `limit=<n>` — cap returned rows
|
|
562
|
+
- `nextToken=<token>` — fetch the next page
|
|
563
|
+
|
|
564
|
+
**Show mode:** pass a workflow instance id (starts with `wrkflow_`) to print one run's metadata plus its `workflowState` and `workflowSteps` payloads. File-swapped payloads are resolved automatically.
|
|
565
|
+
|
|
566
|
+
**Examples:**
|
|
567
|
+
|
|
568
|
+
```bash
|
|
569
|
+
adk workflows runs # recent runs
|
|
570
|
+
adk workflows runs name=onboarding # filter by definition name
|
|
571
|
+
adk workflows runs status=failed limit=5 # latest 5 failed runs
|
|
572
|
+
adk workflows runs nextToken=<token> # next page
|
|
573
|
+
adk workflows runs wrkflow_01KSF... # one run (status + state + steps)
|
|
574
|
+
```
|
|
575
|
+
|
|
576
|
+
### adk conversations
|
|
577
|
+
|
|
578
|
+
List and inspect conversations from the local trace store. Use this to find a conversation id before drilling into it with `adk traces` or `adk conversations show`.
|
|
579
|
+
|
|
580
|
+
```bash
|
|
581
|
+
adk conversations [list] [tokens...] [--format json]
|
|
582
|
+
adk conversations show <id> [--include-llm] [--format json]
|
|
583
|
+
```
|
|
584
|
+
|
|
585
|
+
**`list`** (default subcommand) — recent conversations, filtered by positional `key=value` tokens:
|
|
586
|
+
|
|
587
|
+
- `limit=<n>` - max conversations to show (default: 20)
|
|
588
|
+
- `since=<duration>` - only conversations newer than a duration (e.g. `30s`, `5m`, `1h`, `2d`)
|
|
589
|
+
|
|
590
|
+
**`show <id>`** — full timeline and details for one conversation:
|
|
591
|
+
|
|
592
|
+
- `--include-llm` - include LLM reasoning spans
|
|
593
|
+
- `--format <format>` - output format (`json`)
|
|
594
|
+
|
|
595
|
+
**Examples:**
|
|
596
|
+
|
|
597
|
+
```bash
|
|
598
|
+
adk conversations # recent conversations (list is default)
|
|
599
|
+
adk conversations list limit=5
|
|
600
|
+
adk conversations list since=1h --format json
|
|
601
|
+
adk conversations show <id> # full timeline
|
|
602
|
+
adk conversations show <id> --include-llm --format json
|
|
603
|
+
```
|
|
604
|
+
|
|
605
|
+
**Requires:** `adk dev` run at least once (populates the local trace store).
|
|
606
|
+
|
|
607
|
+
### adk evals
|
|
608
|
+
|
|
609
|
+
Run automated conversation tests defined under `evals/`.
|
|
610
|
+
|
|
611
|
+
```bash
|
|
612
|
+
adk evals [name] [options]
|
|
613
|
+
```
|
|
614
|
+
|
|
615
|
+
**Options:**
|
|
616
|
+
|
|
617
|
+
- `name` - Run a specific eval by name (positional, optional)
|
|
618
|
+
- `--tag <tag>` - Filter by tag
|
|
619
|
+
- `--type <type>` - Filter by type (e.g., `regression`)
|
|
620
|
+
- `--verbose` / `-v` - Show all assertions
|
|
621
|
+
- `--format <format>` - `text` (default) or `json`
|
|
622
|
+
|
|
623
|
+
**Subcommands:**
|
|
624
|
+
|
|
625
|
+
- `adk evals runs` - List recent runs
|
|
626
|
+
- `adk evals runs --latest` - Most recent run
|
|
627
|
+
- `adk evals runs --latest -v` - Most recent run with full details
|
|
628
|
+
|
|
629
|
+
**Examples:**
|
|
630
|
+
|
|
631
|
+
```bash
|
|
632
|
+
adk evals # run all evals
|
|
633
|
+
adk evals checkout # one eval by name
|
|
634
|
+
adk evals --tag smoke
|
|
635
|
+
adk evals --format json # for CI
|
|
636
|
+
adk evals runs --latest -v
|
|
637
|
+
```
|
|
638
|
+
|
|
639
|
+
### adk integrations
|
|
640
|
+
|
|
641
|
+
Manage integrations, plugins, and interfaces. All subcommands support `--target <env>` (dev or prod, default: dev) and `--format <format>` (text or json).
|
|
642
|
+
|
|
643
|
+
> **Deprecated aliases:** The old flat commands (`adk add`, `adk remove`, `adk search`, `adk list`, `adk info`, `adk upgrade`) still work as shims but emit deprecation warnings.
|
|
644
|
+
|
|
645
|
+
#### Discovery
|
|
646
|
+
|
|
647
|
+
```bash
|
|
648
|
+
adk integrations search <query> # Search by keyword
|
|
649
|
+
adk integrations list --available # Browse all Hub integrations
|
|
650
|
+
adk integrations list # Show installed dependencies
|
|
651
|
+
adk integrations info <name> # Full integration details
|
|
652
|
+
```
|
|
653
|
+
|
|
654
|
+
**`adk integrations search` options:**
|
|
655
|
+
- `--format json` - Machine-readable output
|
|
656
|
+
- `--limit <n>` - Max results (default: 20)
|
|
657
|
+
|
|
658
|
+
**`adk integrations list` options:**
|
|
659
|
+
- `--available` - Browse Hub instead of installed
|
|
660
|
+
- `--format json` - Machine-readable output
|
|
661
|
+
- `--verbose` - Show config details
|
|
662
|
+
- `--limit <n>` - Max results (default: 50)
|
|
663
|
+
|
|
664
|
+
**`adk integrations info` options:**
|
|
665
|
+
- `--actions` - Show only actions
|
|
666
|
+
- `--channels` - Show only channels
|
|
667
|
+
- `--events` - Show only events
|
|
668
|
+
- `--full` - Show all sections
|
|
669
|
+
- `--format json` - Machine-readable output
|
|
670
|
+
|
|
671
|
+
#### Mutations
|
|
672
|
+
|
|
673
|
+
```bash
|
|
674
|
+
adk integrations add <name>@<version> # Install integration
|
|
675
|
+
adk integrations remove <alias> # Uninstall integration
|
|
676
|
+
adk integrations upgrade <alias> # Upgrade to latest version
|
|
677
|
+
adk integrations enable <alias> # Enable a disabled integration
|
|
678
|
+
adk integrations disable <alias> # Disable without removing
|
|
679
|
+
adk integrations configure <alias> # Set/unset config values
|
|
680
|
+
```
|
|
681
|
+
|
|
682
|
+
**`adk integrations add` options:**
|
|
683
|
+
- `--alias <name>` - Custom alias for code access
|
|
684
|
+
- `--target <env>` - Environment (dev/prod)
|
|
685
|
+
- `--config key=value` - Set config at install time (repeatable)
|
|
686
|
+
- `--format json`
|
|
687
|
+
|
|
688
|
+
**`adk integrations configure` options:**
|
|
689
|
+
- `--set key=value` - Set config values (repeatable)
|
|
690
|
+
- `--unset key` - Remove config keys (repeatable)
|
|
691
|
+
- `--target <env>` - Environment (dev/prod)
|
|
692
|
+
|
|
693
|
+
**Examples:**
|
|
694
|
+
|
|
695
|
+
```bash
|
|
696
|
+
# Add with version pin
|
|
697
|
+
adk integrations add slack@3.0.0
|
|
698
|
+
|
|
699
|
+
# Add with alias
|
|
700
|
+
adk integrations add openai@1.0.0 --alias ai
|
|
701
|
+
|
|
702
|
+
# Configure
|
|
703
|
+
adk integrations configure slack --set replyBehaviour=start-conversation
|
|
704
|
+
|
|
705
|
+
# Use env substitution for secrets
|
|
706
|
+
adk integrations configure slack --set apiSecret='${env:SLACK_SECRET}'
|
|
707
|
+
|
|
708
|
+
# Enable
|
|
709
|
+
adk integrations enable slack
|
|
710
|
+
|
|
711
|
+
# Remove
|
|
712
|
+
adk integrations remove slack
|
|
713
|
+
```
|
|
714
|
+
|
|
715
|
+
#### State Management
|
|
716
|
+
|
|
717
|
+
```bash
|
|
718
|
+
adk integrations pull-lock # Pull cloud state into lock file
|
|
719
|
+
adk integrations push-lock # Push lock file to cloud
|
|
720
|
+
adk integrations copy # Copy state between environments
|
|
721
|
+
adk integrations diff # Show lock vs cloud differences
|
|
722
|
+
```
|
|
723
|
+
|
|
724
|
+
`adk pull-lock` and `adk push-lock` (no subcommand) run pull/push for both integrations and plugins at once.
|
|
725
|
+
|
|
726
|
+
**`adk integrations pull-lock` options:**
|
|
727
|
+
- `--dry-run` - Preview without writing the lock file
|
|
728
|
+
|
|
729
|
+
**`adk integrations push-lock` options:**
|
|
730
|
+
- `--dry-run` - Preview without applying
|
|
731
|
+
- `--yes` - Skip confirmation
|
|
732
|
+
|
|
733
|
+
### adk plugins
|
|
734
|
+
|
|
735
|
+
Manage plugins (reusable agent extensions). Mirrors the `adk integrations` subcommand structure. All subcommands support `--target <env>` and `--format <format>`.
|
|
736
|
+
|
|
737
|
+
```bash
|
|
738
|
+
adk plugins search <query> # Search by keyword
|
|
739
|
+
adk plugins list # Show installed plugins
|
|
740
|
+
adk plugins info <name> # Full plugin details
|
|
741
|
+
adk plugins add <name>@<version> # Install plugin
|
|
742
|
+
adk plugins remove <alias> # Uninstall plugin
|
|
743
|
+
adk plugins upgrade <alias> # Upgrade version
|
|
744
|
+
adk plugins enable <alias> # Enable a disabled plugin
|
|
745
|
+
adk plugins disable <alias> # Disable without removing
|
|
746
|
+
adk plugins configure <alias> # Set config and interface mappings
|
|
747
|
+
adk plugins pull-lock # Pull cloud state into lock file
|
|
748
|
+
adk plugins push-lock # Push lock file to cloud
|
|
749
|
+
adk plugins copy # Copy state between environments
|
|
750
|
+
adk plugins diff # Show lock vs cloud differences
|
|
751
|
+
```
|
|
752
|
+
|
|
753
|
+
**Plugin-specific flags:**
|
|
754
|
+
- `adk plugins add --dep iface=alias` - Wire interface dependency (repeatable)
|
|
755
|
+
- `adk plugins configure --map iface=alias` - Remap interface dependency
|
|
756
|
+
|
|
757
|
+
**Shared with `adk integrations upgrade`:**
|
|
758
|
+
- `--to <version>` - Target specific version
|
|
759
|
+
|
|
760
|
+
Plugins require interfaces implemented by installed integrations. The CLI auto-resolves dependencies when unambiguous. See **[Plugins](./plugins.md)** for details.
|
|
761
|
+
|
|
762
|
+
### adk self-upgrade
|
|
763
|
+
|
|
764
|
+
Upgrade the ADK CLI itself to the latest version.
|
|
765
|
+
|
|
766
|
+
```bash
|
|
767
|
+
adk self-upgrade
|
|
768
|
+
```
|
|
769
|
+
|
|
770
|
+
**Aliases:** `adk self-update`
|
|
771
|
+
|
|
772
|
+
**What it does:**
|
|
773
|
+
|
|
774
|
+
1. Checks npm registry for latest version
|
|
775
|
+
2. Downloads binary from GitHub releases
|
|
776
|
+
3. Replaces current CLI executable
|
|
777
|
+
4. Verifies installation
|
|
778
|
+
|
|
779
|
+
**Example:**
|
|
780
|
+
|
|
781
|
+
```bash
|
|
782
|
+
adk self-upgrade
|
|
783
|
+
|
|
784
|
+
# Output:
|
|
785
|
+
📦 Current version: 1.13.10
|
|
786
|
+
📦 Latest version: 1.13.16
|
|
787
|
+
📥 Downloading adk v1.13.16 for darwin-arm64...
|
|
788
|
+
✅ Successfully upgraded!
|
|
789
|
+
|
|
790
|
+
v1.13.10 → v1.13.16
|
|
791
|
+
|
|
792
|
+
Run adk --version to verify
|
|
793
|
+
```
|
|
794
|
+
|
|
795
|
+
**Note:** The ADK automatically checks for updates every 24 hours and shows a notification when a new version is available. On Windows, you may need to restart your terminal after upgrading.
|
|
796
|
+
|
|
797
|
+
**This is different from `adk upgrade`** which upgrades integrations, not the CLI itself.
|
|
798
|
+
|
|
799
|
+
### adk kb
|
|
800
|
+
|
|
801
|
+
Manage knowledge bases and synchronization.
|
|
802
|
+
|
|
803
|
+
```bash
|
|
804
|
+
adk kb sync [options]
|
|
805
|
+
```
|
|
806
|
+
|
|
807
|
+
**Commands:**
|
|
808
|
+
|
|
809
|
+
- `adk kb sync` - Sync knowledge base sources with remote
|
|
810
|
+
|
|
811
|
+
**Options:**
|
|
812
|
+
|
|
813
|
+
- `--dev` - Sync with development bot (required: must use --dev or --prod)
|
|
814
|
+
- `--prod` - Sync with production bot (required: must use --dev or --prod)
|
|
815
|
+
- `--dry-run` - Preview changes without applying them
|
|
816
|
+
- `-y, --yes` - Skip confirmation prompts
|
|
817
|
+
- `--confirm-storage-changes` - Confirm destructive storage changes (KB deletions)
|
|
818
|
+
- `--force` - Force re-sync all knowledge bases
|
|
819
|
+
- `--format <format>` - Output format (`json`; requires `--yes`)
|
|
820
|
+
|
|
821
|
+
**What it does:**
|
|
822
|
+
|
|
823
|
+
1. Detects knowledge bases defined in your project
|
|
824
|
+
2. Identifies sources (directories, websites, tables)
|
|
825
|
+
3. Syncs content to Botpress Cloud
|
|
826
|
+
4. Handles orphaned sources (sources removed from code)
|
|
827
|
+
|
|
828
|
+
**Example:**
|
|
829
|
+
|
|
830
|
+
```bash
|
|
831
|
+
# Sync to development bot
|
|
832
|
+
adk kb sync --dev
|
|
833
|
+
|
|
834
|
+
# Sync to production bot
|
|
835
|
+
adk kb sync --prod
|
|
836
|
+
|
|
837
|
+
# Auto-confirm sync
|
|
838
|
+
adk kb sync --dev -y
|
|
839
|
+
adk kb sync --dev -y --format json
|
|
840
|
+
|
|
841
|
+
# Preview changes without applying
|
|
842
|
+
adk kb sync --dev --dry-run
|
|
843
|
+
|
|
844
|
+
# Force re-sync all knowledge bases
|
|
845
|
+
adk kb sync --dev --force
|
|
846
|
+
```
|
|
847
|
+
|
|
848
|
+
**Source Types:**
|
|
849
|
+
|
|
850
|
+
- `Directory` - Local files from a directory
|
|
851
|
+
- `Website` - Pages from sitemap or URLs
|
|
852
|
+
- `Table` - Data from bot tables
|
|
853
|
+
|
|
854
|
+
**Note:** KB sync is also run automatically during `adk dev` and `adk deploy`.
|
|
855
|
+
|
|
856
|
+
### adk assets sync
|
|
857
|
+
|
|
858
|
+
Sync assets with remote storage.
|
|
859
|
+
|
|
860
|
+
```bash
|
|
861
|
+
adk assets sync [options]
|
|
862
|
+
```
|
|
863
|
+
|
|
864
|
+
**Options:**
|
|
865
|
+
|
|
866
|
+
- `--dry-run` - Preview changes
|
|
867
|
+
- `-y, --yes` - Skip confirmation
|
|
868
|
+
- `--bail-on-failure` - Stop on first error
|
|
869
|
+
- `--force` - Force re-upload all files
|
|
870
|
+
- `--format <format>` - Output format (`json`; requires `--yes`)
|
|
871
|
+
|
|
872
|
+
**Example:**
|
|
873
|
+
|
|
874
|
+
```bash
|
|
875
|
+
# Interactive
|
|
876
|
+
adk assets sync
|
|
877
|
+
|
|
878
|
+
# Auto-confirm
|
|
879
|
+
adk assets sync -y
|
|
880
|
+
adk assets sync -y --format json
|
|
881
|
+
```
|
|
882
|
+
|
|
883
|
+
**Other asset commands:**
|
|
884
|
+
|
|
885
|
+
```bash
|
|
886
|
+
adk assets list # List all assets
|
|
887
|
+
adk assets status # Show sync status
|
|
888
|
+
adk assets pull # Download remote assets to local directory
|
|
889
|
+
```
|
|
890
|
+
|
|
891
|
+
### adk assets list
|
|
892
|
+
|
|
893
|
+
List all asset files.
|
|
894
|
+
|
|
895
|
+
```bash
|
|
896
|
+
adk assets list [options]
|
|
897
|
+
```
|
|
898
|
+
|
|
899
|
+
**Options:**
|
|
900
|
+
|
|
901
|
+
- `--local` - Show only local assets
|
|
902
|
+
- `--remote` - Show only remote assets
|
|
903
|
+
- `--format <format>` - Output format (`json`)
|
|
904
|
+
|
|
905
|
+
### adk assets status
|
|
906
|
+
|
|
907
|
+
Show asset synchronization status.
|
|
908
|
+
|
|
909
|
+
```bash
|
|
910
|
+
adk assets status [--format json]
|
|
911
|
+
```
|
|
912
|
+
|
|
913
|
+
### adk assets pull
|
|
914
|
+
|
|
915
|
+
Download remote assets to local directory.
|
|
916
|
+
|
|
917
|
+
```bash
|
|
918
|
+
adk assets pull
|
|
919
|
+
```
|
|
920
|
+
|
|
921
|
+
### adk mcp
|
|
922
|
+
|
|
923
|
+
Start the MCP (Model Context Protocol) server for AI assistant integration.
|
|
924
|
+
|
|
925
|
+
```bash
|
|
926
|
+
adk mcp [--cwd <path>]
|
|
927
|
+
```
|
|
928
|
+
|
|
929
|
+
The MCP server provides tools for AI assistants (Claude Code, Cursor, VS Code) to debug, test, and manage your ADK project. See **[MCP Server](./mcp-server.md)** for details.
|
|
930
|
+
|
|
931
|
+
### adk mcp:init
|
|
932
|
+
|
|
933
|
+
Generate MCP configuration files for AI assistants.
|
|
934
|
+
|
|
935
|
+
```bash
|
|
936
|
+
adk mcp:init [options]
|
|
937
|
+
```
|
|
938
|
+
|
|
939
|
+
**Options:**
|
|
940
|
+
|
|
941
|
+
- `--all` - Generate for all supported tools
|
|
942
|
+
- `--tool <name>` - Generate for specific tool (claude-code, vscode, cursor)
|
|
943
|
+
- `--force` - Overwrite existing config
|
|
944
|
+
- `--project-dir <path>` - ADK project subdirectory (for monorepos)
|
|
945
|
+
|
|
946
|
+
**Example:**
|
|
947
|
+
|
|
948
|
+
```bash
|
|
949
|
+
adk mcp:init --all
|
|
950
|
+
```
|
|
951
|
+
|
|
952
|
+
See **[MCP Server](./mcp-server.md)** for monorepo setup and troubleshooting.
|
|
953
|
+
|
|
954
|
+
### adk profiles
|
|
955
|
+
|
|
956
|
+
Manage authentication profiles.
|
|
957
|
+
|
|
958
|
+
```bash
|
|
959
|
+
adk profiles [command]
|
|
960
|
+
```
|
|
961
|
+
|
|
962
|
+
**Commands:**
|
|
963
|
+
|
|
964
|
+
- `adk profiles list` - List all configured profiles
|
|
965
|
+
- `adk profiles set [profile]` - Switch to a different profile
|
|
966
|
+
|
|
967
|
+
**Example:**
|
|
968
|
+
|
|
969
|
+
```bash
|
|
970
|
+
# List all profiles
|
|
971
|
+
adk profiles list
|
|
972
|
+
|
|
973
|
+
# Switch to a different profile
|
|
974
|
+
adk profiles set staging
|
|
975
|
+
```
|
|
976
|
+
|
|
977
|
+
### adk config
|
|
978
|
+
|
|
979
|
+
Configure agent settings interactively.
|
|
980
|
+
|
|
981
|
+
```bash
|
|
982
|
+
adk config [options]
|
|
983
|
+
```
|
|
984
|
+
|
|
985
|
+
**Options:**
|
|
986
|
+
|
|
987
|
+
- `--prod` - Use production configuration
|
|
988
|
+
|
|
989
|
+
**Subcommands:**
|
|
990
|
+
|
|
991
|
+
- `adk config:get <key>` - Get a configuration value
|
|
992
|
+
- `adk config:set <key> <value>` - Set a configuration value
|
|
993
|
+
|
|
994
|
+
Both subcommands support `--prod` flag for production configuration.
|
|
995
|
+
|
|
996
|
+
**Example:**
|
|
997
|
+
|
|
998
|
+
```bash
|
|
999
|
+
# Interactive configuration
|
|
1000
|
+
adk config
|
|
1001
|
+
|
|
1002
|
+
# Get a config value
|
|
1003
|
+
adk config:get botId
|
|
1004
|
+
|
|
1005
|
+
# Set a config value
|
|
1006
|
+
adk config:set botId bot_123
|
|
1007
|
+
|
|
1008
|
+
# Use production configuration
|
|
1009
|
+
adk config --prod
|
|
1010
|
+
adk config:get botId --prod
|
|
1011
|
+
```
|
|
1012
|
+
|
|
1013
|
+
**Note:** This replaces the legacy `adk agent` command.
|
|
1014
|
+
|
|
1015
|
+
### adk secret
|
|
1016
|
+
|
|
1017
|
+
Manage the bot's secrets in the local store. `adk secret` (no subcommand) shows the declared secrets and whether each is set.
|
|
1018
|
+
|
|
1019
|
+
```bash
|
|
1020
|
+
adk secret [options] # show declared secrets + status
|
|
1021
|
+
adk secret:set <key> <value> [options] # set a secret value
|
|
1022
|
+
adk secret:delete <key> [options] # delete a secret
|
|
1023
|
+
```
|
|
1024
|
+
|
|
1025
|
+
**Options (all three):**
|
|
1026
|
+
|
|
1027
|
+
- `--prod` - Target the production bot (default: dev)
|
|
1028
|
+
- `--format <format>` - Output format (`json`)
|
|
1029
|
+
|
|
1030
|
+
`<key>` is `SCREAMING_SNAKE_CASE`. `secret:set` never echoes the value back.
|
|
1031
|
+
|
|
1032
|
+
```bash
|
|
1033
|
+
adk secret # list declared secrets and set/unset status
|
|
1034
|
+
adk secret --prod --format json
|
|
1035
|
+
adk secret:set OPENAI_API_KEY sk-... # set on the dev bot
|
|
1036
|
+
adk secret:delete OPENAI_API_KEY --prod # delete on the prod bot
|
|
1037
|
+
```
|
|
1038
|
+
|
|
1039
|
+
### adk models
|
|
1040
|
+
|
|
1041
|
+
List the Cognitive models available to the current bot, grouped by integration (including aliases like `fast` and `best`). Useful when configuring model selection or diagnosing a model-not-found error.
|
|
1042
|
+
|
|
1043
|
+
```bash
|
|
1044
|
+
adk models [--format json]
|
|
1045
|
+
```
|
|
1046
|
+
|
|
1047
|
+
### adk telemetry
|
|
1048
|
+
|
|
1049
|
+
Manage telemetry preferences.
|
|
1050
|
+
|
|
1051
|
+
```bash
|
|
1052
|
+
adk telemetry [options]
|
|
1053
|
+
```
|
|
1054
|
+
|
|
1055
|
+
**Options:**
|
|
1056
|
+
|
|
1057
|
+
- `--status` - Show telemetry status
|
|
1058
|
+
- `--enable` - Enable telemetry
|
|
1059
|
+
- `--disable` - Disable telemetry
|
|
1060
|
+
|
|
1061
|
+
**Example:**
|
|
1062
|
+
|
|
1063
|
+
```bash
|
|
1064
|
+
# Check telemetry status
|
|
1065
|
+
adk telemetry --status
|
|
1066
|
+
|
|
1067
|
+
# Enable telemetry
|
|
1068
|
+
adk telemetry --enable
|
|
1069
|
+
|
|
1070
|
+
# Disable telemetry
|
|
1071
|
+
adk telemetry --disable
|
|
1072
|
+
```
|
|
1073
|
+
|
|
1074
|
+
### adk run
|
|
1075
|
+
|
|
1076
|
+
Run a TypeScript script with full ADK runtime context.
|
|
1077
|
+
|
|
1078
|
+
```bash
|
|
1079
|
+
adk run <script> [args...] [options]
|
|
1080
|
+
```
|
|
1081
|
+
|
|
1082
|
+
**Options:**
|
|
1083
|
+
|
|
1084
|
+
- `--force` - Force regeneration of the bot project
|
|
1085
|
+
- `--prod` - Use production bot ID instead of dev bot ID
|
|
1086
|
+
|
|
1087
|
+
**Description:**
|
|
1088
|
+
|
|
1089
|
+
Executes a TypeScript script with access to the full ADK runtime, including:
|
|
1090
|
+
- Bot client with authentication
|
|
1091
|
+
- All tables, workflows, and actions from your project
|
|
1092
|
+
- Type-safe access to your bot's configuration
|
|
1093
|
+
|
|
1094
|
+
**Use Cases:**
|
|
1095
|
+
|
|
1096
|
+
- One-off data migrations
|
|
1097
|
+
- Manual sync operations
|
|
1098
|
+
- Testing specific functionality
|
|
1099
|
+
- Admin scripts
|
|
1100
|
+
|
|
1101
|
+
**Example Scripts:**
|
|
1102
|
+
|
|
1103
|
+
```typescript
|
|
1104
|
+
// scripts/migrate-users.ts
|
|
1105
|
+
import { UsersTable } from "../src/tables/Users";
|
|
1106
|
+
|
|
1107
|
+
const { rows } = await UsersTable.findRows({ limit: 100 });
|
|
1108
|
+
|
|
1109
|
+
for (const user of rows) {
|
|
1110
|
+
await UsersTable.updateRows({
|
|
1111
|
+
rows: [{ id: user.id, migrated: true }]
|
|
1112
|
+
});
|
|
1113
|
+
console.log(`Migrated user: ${user.id}`);
|
|
1114
|
+
}
|
|
1115
|
+
|
|
1116
|
+
console.log(`✅ Migrated ${rows.length} users`);
|
|
1117
|
+
```
|
|
1118
|
+
|
|
1119
|
+
**Examples:**
|
|
1120
|
+
|
|
1121
|
+
```bash
|
|
1122
|
+
# Run a migration script
|
|
1123
|
+
adk run scripts/migrate-users.ts
|
|
1124
|
+
|
|
1125
|
+
# Run with production bot
|
|
1126
|
+
adk run scripts/sync-data.ts --prod
|
|
1127
|
+
|
|
1128
|
+
# Force regenerate types before running
|
|
1129
|
+
adk run scripts/fix-data.ts --force
|
|
1130
|
+
|
|
1131
|
+
# Pass arguments to your script
|
|
1132
|
+
adk run scripts/process.ts arg1 arg2
|
|
1133
|
+
```
|
|
1134
|
+
|
|
1135
|
+
**Requirements:**
|
|
1136
|
+
|
|
1137
|
+
- Must be logged in (`adk login`)
|
|
1138
|
+
- Must have linked bot (`adk link`)
|
|
1139
|
+
- Script must be a TypeScript file
|
|
1140
|
+
|
|
1141
|
+
### Global Options
|
|
1142
|
+
|
|
1143
|
+
```bash
|
|
1144
|
+
adk --no-cache <command> # Disable cache
|
|
1145
|
+
adk --version # Show version
|
|
1146
|
+
adk --help # Show help
|
|
1147
|
+
adk # In agent directory: runs 'adk dev', otherwise: shows welcome
|
|
1148
|
+
```
|
|
1149
|
+
|
|
1150
|
+
## Common Workflows
|
|
1151
|
+
|
|
1152
|
+
### New Project
|
|
1153
|
+
|
|
1154
|
+
```bash
|
|
1155
|
+
adk init my-bot
|
|
1156
|
+
cd my-bot
|
|
1157
|
+
bun install
|
|
1158
|
+
adk login
|
|
1159
|
+
adk dev
|
|
1160
|
+
```
|
|
1161
|
+
|
|
1162
|
+
### Daily Development
|
|
1163
|
+
|
|
1164
|
+
```bash
|
|
1165
|
+
# Start dev
|
|
1166
|
+
adk dev
|
|
1167
|
+
|
|
1168
|
+
# Make changes (auto-reload)
|
|
1169
|
+
|
|
1170
|
+
# Test
|
|
1171
|
+
adk chat
|
|
1172
|
+
|
|
1173
|
+
# Deploy when ready
|
|
1174
|
+
adk deploy
|
|
1175
|
+
```
|
|
1176
|
+
|
|
1177
|
+
### Working with Existing Bot
|
|
1178
|
+
|
|
1179
|
+
```bash
|
|
1180
|
+
git clone <repo>
|
|
1181
|
+
cd my-bot
|
|
1182
|
+
bun install
|
|
1183
|
+
adk login
|
|
1184
|
+
adk link --workspace ws_123 --bot bot_456
|
|
1185
|
+
adk dev
|
|
1186
|
+
```
|
|
1187
|
+
|
|
1188
|
+
### Managing Integrations
|
|
1189
|
+
|
|
1190
|
+
```bash
|
|
1191
|
+
# Search for integrations
|
|
1192
|
+
adk integrations search slack
|
|
1193
|
+
|
|
1194
|
+
# List all available integrations
|
|
1195
|
+
adk integrations list --available
|
|
1196
|
+
|
|
1197
|
+
# Get detailed info about an integration
|
|
1198
|
+
adk integrations info slack
|
|
1199
|
+
|
|
1200
|
+
# Add
|
|
1201
|
+
adk integrations add slack@3.0.0
|
|
1202
|
+
|
|
1203
|
+
# Configure
|
|
1204
|
+
adk integrations configure slack --set replyBehaviour=start-conversation
|
|
1205
|
+
|
|
1206
|
+
# Enable and start dev server for OAuth
|
|
1207
|
+
adk integrations enable slack
|
|
1208
|
+
adk dev # Complete OAuth in Dev Console at localhost:3001
|
|
1209
|
+
|
|
1210
|
+
# List installed
|
|
1211
|
+
adk integrations list
|
|
1212
|
+
|
|
1213
|
+
# Remove
|
|
1214
|
+
adk integrations remove slack
|
|
1215
|
+
```
|
|
1216
|
+
|
|
1217
|
+
## Best Practices
|
|
1218
|
+
|
|
1219
|
+
**DO:**
|
|
1220
|
+
|
|
1221
|
+
- Use `adk dev` for development (hot reload)
|
|
1222
|
+
- Keep `agent.config.ts` in git
|
|
1223
|
+
- Use `.env` for secrets
|
|
1224
|
+
- Run `adk chat` for quick testing
|
|
1225
|
+
|
|
1226
|
+
**DON'T:**
|
|
1227
|
+
|
|
1228
|
+
- Don't edit `.adk/` directory (auto-generated) — **except** `.adk/scratch/`, which is reserved for disposable user/agent files (one-off runners, throwaway probes). `adk dev` does not touch `.adk/scratch/`. Production code, persistent helpers, and anything you'd commit belong outside `.adk/`.
|
|
1229
|
+
- Don't commit `agent.json` (add to .gitignore)
|
|
1230
|
+
- Don't commit `.env` files
|
|
1231
|
+
- Don't skip integration configuration in UI
|
|
1232
|
+
|
|
1233
|
+
## Quick Reference
|
|
1234
|
+
|
|
1235
|
+
```bash
|
|
1236
|
+
# Lifecycle
|
|
1237
|
+
adk init <name> # Create project
|
|
1238
|
+
adk login # Authenticate
|
|
1239
|
+
adk link # Link to remote bot
|
|
1240
|
+
adk dev # Start development
|
|
1241
|
+
adk chat # Test interactively
|
|
1242
|
+
adk deploy # Deploy to production
|
|
1243
|
+
adk run <script> # Run script with ADK runtime
|
|
1244
|
+
|
|
1245
|
+
# Multi-Agent / Dev Console
|
|
1246
|
+
adk ps # List running agents and processes
|
|
1247
|
+
adk dashboard # Open Dev Console standalone (no agent needed)
|
|
1248
|
+
adk kill --all # Stop all agents + Dev Console
|
|
1249
|
+
|
|
1250
|
+
# Diagnostics (local trace store)
|
|
1251
|
+
adk logs # Recent log entries
|
|
1252
|
+
adk traces # Execution traces
|
|
1253
|
+
adk conversations # List recent conversations
|
|
1254
|
+
adk conversations show <id> # Inspect one conversation timeline
|
|
1255
|
+
|
|
1256
|
+
# Workflows
|
|
1257
|
+
adk workflows # List discovered workflows
|
|
1258
|
+
adk workflows inspect <name> # Inspect workflow schema
|
|
1259
|
+
adk workflows run <name> # Start a workflow
|
|
1260
|
+
adk workflows runs # List or inspect workflow runs
|
|
1261
|
+
|
|
1262
|
+
# Dependencies (integrations, plugins, interfaces)
|
|
1263
|
+
adk integrations search <query> # Search for integrations
|
|
1264
|
+
adk integrations list # List installed dependencies
|
|
1265
|
+
adk integrations list --available # List all available integrations
|
|
1266
|
+
adk integrations info <name> # Show integration details
|
|
1267
|
+
adk integrations add <name>@<ver> # Add integration
|
|
1268
|
+
adk integrations remove <alias> # Remove integration
|
|
1269
|
+
adk integrations upgrade [alias] # Upgrade dependency
|
|
1270
|
+
adk integrations enable <alias> # Enable integration
|
|
1271
|
+
adk integrations disable <alias> # Disable integration
|
|
1272
|
+
adk integrations configure <alias> # Set/unset config values
|
|
1273
|
+
adk integrations pull-lock # Pull cloud state to lock file
|
|
1274
|
+
adk integrations push-lock # Push lock file to cloud
|
|
1275
|
+
|
|
1276
|
+
# Plugins
|
|
1277
|
+
adk plugins search <query> # Search for plugins
|
|
1278
|
+
adk plugins list # List installed plugins
|
|
1279
|
+
adk plugins add <name>@<version> # Add plugin
|
|
1280
|
+
adk plugins remove <alias> # Remove plugin
|
|
1281
|
+
adk plugins configure <alias> # Set config / remap interfaces
|
|
1282
|
+
adk plugins pull-lock # Pull cloud state to lock file
|
|
1283
|
+
adk plugins push-lock # Push lock file to cloud
|
|
1284
|
+
|
|
1285
|
+
# Lock file (both integrations + plugins at once)
|
|
1286
|
+
adk pull-lock # Pull cloud state for both
|
|
1287
|
+
adk push-lock # Push lock files to cloud for both
|
|
1288
|
+
|
|
1289
|
+
# MCP (AI Assistant Integration)
|
|
1290
|
+
adk mcp # Start MCP server
|
|
1291
|
+
adk mcp:init --all # Generate MCP config files
|
|
1292
|
+
|
|
1293
|
+
# CLI Management
|
|
1294
|
+
adk self-upgrade # Upgrade ADK CLI itself
|
|
1295
|
+
adk telemetry # Manage telemetry preferences
|
|
1296
|
+
|
|
1297
|
+
# Authentication
|
|
1298
|
+
adk profiles list # List profiles
|
|
1299
|
+
adk profiles set # Switch profile
|
|
1300
|
+
adk logout # Remove credentials for a profile
|
|
1301
|
+
|
|
1302
|
+
# Configuration
|
|
1303
|
+
adk config # Configure agent settings
|
|
1304
|
+
adk config:get <key> # Get config value
|
|
1305
|
+
adk config:set <key> <value> # Set config value
|
|
1306
|
+
adk secret # Show declared secrets + status
|
|
1307
|
+
adk secret:set <k> <v> # Set a secret
|
|
1308
|
+
adk models # List available Cognitive models
|
|
1309
|
+
|
|
1310
|
+
# Workflows (dev bot only; --format json only)
|
|
1311
|
+
adk workflows # List workflow definitions
|
|
1312
|
+
adk workflows inspect <name> # Show one workflow's schema + metadata
|
|
1313
|
+
adk workflows run <name> [json] # Run a workflow (add --wait to block)
|
|
1314
|
+
adk workflows runs # List recent workflow runs
|
|
1315
|
+
adk workflows runs <wrkflow_id> # Inspect one run (status + state + steps)
|
|
1316
|
+
|
|
1317
|
+
# Knowledge Bases
|
|
1318
|
+
adk kb sync --dev # Sync KB to development bot
|
|
1319
|
+
adk kb sync --prod # Sync KB to production bot
|
|
1320
|
+
|
|
1321
|
+
# Assets
|
|
1322
|
+
adk assets sync # Sync assets
|
|
1323
|
+
adk assets list # List all assets
|
|
1324
|
+
adk assets status # Check sync status
|
|
1325
|
+
adk assets pull # Download remote assets
|
|
1326
|
+
```
|
|
1327
|
+
|
|
1328
|
+
## See Also
|
|
1329
|
+
|
|
1330
|
+
- **[Agent Configuration](./agent-config.md)** - agent.config.ts, agent.json, environment variables, and project files
|
|
1331
|
+
- **[MCP Server](./mcp-server.md)** - AI assistant integration (Claude Code, Cursor, VS Code)
|
|
1332
|
+
- **[Conversations](./conversations.md)** - Conversation handlers
|
|
1333
|
+
- **[Workflows](./workflows.md)** - Long-running processes
|
|
1334
|
+
- **[Patterns & Mistakes](./patterns-mistakes.md)** - Best practices
|