@agenticmail/cli 0.8.19 → 0.8.22
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 +18 -2
- package/dist/cli.js +48 -21
- package/dist/public/index.html +1284 -0
- package/package.json +3 -2
package/README.md
CHANGED
|
@@ -23,6 +23,19 @@ It bundles a setup wizard, API server launcher, and a full interactive shell wit
|
|
|
23
23
|
>
|
|
24
24
|
> Zero prompts, ~2 minutes, fully autonomous. Then tell the user to restart Claude Code. Full agent-facing runbook — including verification, common failures, and "what if Node < 22" — is at [`AGENTS.md`](https://github.com/agenticmail/agenticmail/blob/main/AGENTS.md) in the repo (the [agents.md](https://agents.md) convention).
|
|
25
25
|
|
|
26
|
+
## ✨ What's new in 0.8.19
|
|
27
|
+
|
|
28
|
+
- **🌐 Gmail-style web UI** — open every agent's inbox in your browser with `agenticmail web`. Three-pane layout, full markdown rendering, real-time SSE updates, compose + reply with the new `wake` parameter as a first-class field.
|
|
29
|
+
- **`wake: ["alice", "bob"]`** on `send_email` / `reply_email` / `forward_email` / `template_send` / `manage_drafts(send)` tells the dispatcher to give a Claude turn only to named agents — the biggest token saver on large threads.
|
|
30
|
+
- **`[FINAL]` / `[DONE]` / `[CLOSED]` / `[WRAP]` in a subject** closes a thread — the dispatcher stops waking workers on any further reply to it.
|
|
31
|
+
- **`check_activity` MCP tool** — see which agents the dispatcher has woken right now and how long they've been running.
|
|
32
|
+
- **Comprehensive markdown rendering** in the shell's email viewer — bold, italic, headings, lists, task lists, tables, fenced code, links, images, HTML entities, depth-colored quote stripes.
|
|
33
|
+
- **LLM-tolerant inputs** — `batch_mark_read({ uids: "[1,2,3]" })` and other common stringification mistakes now just work.
|
|
34
|
+
- **Wake-budget circuit breaker** — caps per-(agent, thread) wakes at 10/24h to stop reply loops and storms.
|
|
35
|
+
- **Inbox refresh keybind** — press `r` in the shell inbox navigator to refresh without leaving.
|
|
36
|
+
|
|
37
|
+
Full release notes in [CHANGELOG.md](https://github.com/agenticmail/agenticmail/blob/main/CHANGELOG.md).
|
|
38
|
+
|
|
26
39
|
## Install
|
|
27
40
|
|
|
28
41
|
```bash
|
|
@@ -107,6 +120,7 @@ All commands are available via `agenticmail <command>` or `npx @agenticmail/cli@
|
|
|
107
120
|
| `agenticmail setup` | **Run the setup wizard.** Walks you through system checks, account creation, service startup, email connection, phone number setup, and OpenClaw integration. Safe to re-run anytime. |
|
|
108
121
|
| `agenticmail start` | **Start the server and open the interactive shell.** Ensures Docker is running, Stalwart is up, and the API server is reachable. Automatically installs the auto-start service. |
|
|
109
122
|
| `agenticmail shell` | **Drop into the interactive shell against the already-running server.** Use this when the server is already up (started by `agenticmail start`, `agenticmail bootstrap`, or the auto-start service) and you want to monitor every agent's inbox, send mail on their behalf, watch the dispatcher event feed, or run any of the 44+ shell commands. Exits cleanly with `/exit` — the server keeps running. |
|
|
123
|
+
| `agenticmail web` | 🌐 **Open the lightweight Gmail-style web UI in your browser.** Three-pane layout (agents / inbox / message), real-time SSE updates, full markdown rendering, compose + reply with the `wake` parameter surfaced as a field. Same master key as the API. Available at `http://127.0.0.1:3829/` whenever the API is running. |
|
|
110
124
|
| `agenticmail stop` | **Stop the server.** Kills the background API server process. If auto-start is enabled, it will restart on next boot. |
|
|
111
125
|
| `agenticmail status` | **Show what's running.** Displays Docker, Stalwart, API server, email connection, and auto-start service status. |
|
|
112
126
|
|
|
@@ -523,7 +537,7 @@ import {
|
|
|
523
537
|
type ParsedEmail,
|
|
524
538
|
type Agent,
|
|
525
539
|
type GatewayConfig,
|
|
526
|
-
} from 'agenticmail';
|
|
540
|
+
} from '@agenticmail/cli';
|
|
527
541
|
```
|
|
528
542
|
|
|
529
543
|
See the [@agenticmail/core README](https://github.com/agenticmail/agenticmail/tree/main/packages/core) for complete SDK documentation.
|
|
@@ -610,12 +624,14 @@ Errors return JSON: `400` (missing `name`/`columns`), `409` (table already exist
|
|
|
610
624
|
|
|
611
625
|
### `agenticmail: command not found`
|
|
612
626
|
|
|
613
|
-
If you installed locally with `npm install agenticmail`, use `npx agenticmail` instead. For a global install:
|
|
627
|
+
If you installed locally with `npm install @agenticmail/cli`, use `npx agenticmail` instead. For a global install:
|
|
614
628
|
|
|
615
629
|
```bash
|
|
616
630
|
npm install -g @agenticmail/cli
|
|
617
631
|
```
|
|
618
632
|
|
|
633
|
+
> Note: the unscoped `agenticmail` package on npm is a zero-dependency redirect stub (since v0.8.20). The real CLI is `@agenticmail/cli`. If you accidentally installed `agenticmail` without the scope, run `npm uninstall -g agenticmail` and then `npm install -g @agenticmail/cli@latest`.
|
|
634
|
+
|
|
619
635
|
---
|
|
620
636
|
|
|
621
637
|
## License
|
package/dist/cli.js
CHANGED
|
@@ -4224,7 +4224,7 @@ ${c.dim(boxChar.bl + boxChar.h.repeat(bWidth) + boxChar.br)}`);
|
|
|
4224
4224
|
info(`Current version: ${c.bold(currentVersion)}`);
|
|
4225
4225
|
let latestVersion = "unknown";
|
|
4226
4226
|
try {
|
|
4227
|
-
latestVersion = execSync("npm view agenticmail version", { encoding: "utf-8", timeout: 15e3 }).trim();
|
|
4227
|
+
latestVersion = execSync("npm view @agenticmail/cli version", { encoding: "utf-8", timeout: 15e3 }).trim();
|
|
4228
4228
|
} catch {
|
|
4229
4229
|
fail("Could not check npm for latest version. Check your internet connection.");
|
|
4230
4230
|
return;
|
|
@@ -4247,7 +4247,7 @@ ${c.dim(boxChar.bl + boxChar.h.repeat(bWidth) + boxChar.br)}`);
|
|
|
4247
4247
|
if (hasOpenClaw) {
|
|
4248
4248
|
info(`OpenClaw detected: ${c.bold(openClawVersion)}`);
|
|
4249
4249
|
try {
|
|
4250
|
-
const peerDeps = execSync(`npm view agenticmail@${latestVersion} peerDependencies --json 2>/dev/null`, { encoding: "utf-8", timeout: 15e3 }).trim();
|
|
4250
|
+
const peerDeps = execSync(`npm view @agenticmail/cli@${latestVersion} peerDependencies --json 2>/dev/null`, { encoding: "utf-8", timeout: 15e3 }).trim();
|
|
4251
4251
|
if (peerDeps) {
|
|
4252
4252
|
const deps = JSON.parse(peerDeps);
|
|
4253
4253
|
if (deps.openclaw) {
|
|
@@ -4283,12 +4283,19 @@ ${c.dim(boxChar.bl + boxChar.h.repeat(bWidth) + boxChar.br)}`);
|
|
|
4283
4283
|
}
|
|
4284
4284
|
let isGlobal = false;
|
|
4285
4285
|
try {
|
|
4286
|
-
const globalList = execSync(`${pm
|
|
4287
|
-
if (globalList.includes("agenticmail")) isGlobal = true;
|
|
4286
|
+
const globalList = execSync(`${pm} list -g @agenticmail/cli 2>/dev/null`, { encoding: "utf-8", timeout: 1e4 });
|
|
4287
|
+
if (globalList.includes("@agenticmail/cli")) isGlobal = true;
|
|
4288
4288
|
} catch {
|
|
4289
4289
|
}
|
|
4290
|
+
if (!isGlobal) {
|
|
4291
|
+
try {
|
|
4292
|
+
const globalList = execSync(`${pm} list -g agenticmail 2>/dev/null`, { encoding: "utf-8", timeout: 1e4 });
|
|
4293
|
+
if (globalList.includes("agenticmail")) isGlobal = true;
|
|
4294
|
+
} catch {
|
|
4295
|
+
}
|
|
4296
|
+
}
|
|
4290
4297
|
const scope = isGlobal ? "-g" : "";
|
|
4291
|
-
const installCmd = pm === "bun" ? `bun add ${scope} agenticmail@latest` : `${pm} install ${scope} agenticmail@latest`;
|
|
4298
|
+
const installCmd = pm === "bun" ? `bun add ${scope} @agenticmail/cli@latest` : `${pm} install ${scope} @agenticmail/cli@latest`;
|
|
4292
4299
|
info(`Running: ${c.dim(installCmd)}`);
|
|
4293
4300
|
execSync(installCmd, { stdio: "inherit", timeout: 12e4 });
|
|
4294
4301
|
if (hasOpenClaw) {
|
|
@@ -4309,12 +4316,12 @@ ${c.dim(boxChar.bl + boxChar.h.repeat(bWidth) + boxChar.br)}`);
|
|
|
4309
4316
|
}
|
|
4310
4317
|
}
|
|
4311
4318
|
log("");
|
|
4312
|
-
ok(`Updated to agenticmail@${latestVersion}`);
|
|
4319
|
+
ok(`Updated to @agenticmail/cli@${latestVersion}`);
|
|
4313
4320
|
info("Restart the shell to use the new version.");
|
|
4314
4321
|
log("");
|
|
4315
4322
|
} catch (err) {
|
|
4316
4323
|
fail(`Update failed: ${err.message}`);
|
|
4317
|
-
info(`Try manually: ${c.green("npm install -g agenticmail@latest")}`);
|
|
4324
|
+
info(`Try manually: ${c.green("npm install -g @agenticmail/cli@latest")}`);
|
|
4318
4325
|
log("");
|
|
4319
4326
|
}
|
|
4320
4327
|
}
|
|
@@ -6932,7 +6939,14 @@ async function cmdWeb() {
|
|
|
6932
6939
|
log2("");
|
|
6933
6940
|
return;
|
|
6934
6941
|
}
|
|
6935
|
-
const { apiUrl
|
|
6942
|
+
const { apiUrl } = readApiUrlFromConfig();
|
|
6943
|
+
let masterKey = "";
|
|
6944
|
+
try {
|
|
6945
|
+
const cfg = JSON.parse(readFileSync2(configPath, "utf-8"));
|
|
6946
|
+
if (typeof cfg?.masterKey === "string") masterKey = cfg.masterKey;
|
|
6947
|
+
} catch {
|
|
6948
|
+
}
|
|
6949
|
+
const url = masterKey ? `${apiUrl}/?key=${encodeURIComponent(masterKey)}` : apiUrl;
|
|
6936
6950
|
let alive = false;
|
|
6937
6951
|
try {
|
|
6938
6952
|
const resp = await fetch(`${url}/api/agenticmail/health`, { signal: AbortSignal.timeout(2e3) });
|
|
@@ -6945,14 +6959,20 @@ async function cmdWeb() {
|
|
|
6945
6959
|
log2("");
|
|
6946
6960
|
return;
|
|
6947
6961
|
}
|
|
6948
|
-
log2(` ${c2.green("\u2713")} API server is running at ${c2.cyan(
|
|
6949
|
-
log2("");
|
|
6950
|
-
log2(` ${c2.bold("Open the web UI in your browser:")}`);
|
|
6951
|
-
log2("");
|
|
6952
|
-
log2(` ${c2.green(url)}`);
|
|
6962
|
+
log2(` ${c2.green("\u2713")} API server is running at ${c2.cyan(apiUrl)}`);
|
|
6953
6963
|
log2("");
|
|
6954
|
-
|
|
6955
|
-
|
|
6964
|
+
if (masterKey) {
|
|
6965
|
+
log2(` ${c2.bold("Opening the web UI \u2014 you'll be signed in automatically.")}`);
|
|
6966
|
+
log2("");
|
|
6967
|
+
log2(` ${c2.dim(apiUrl)}`);
|
|
6968
|
+
} else {
|
|
6969
|
+
log2(` ${c2.yellow("!")} ${c2.bold("Master key not found in config; you'll need to paste it manually.")}`);
|
|
6970
|
+
log2("");
|
|
6971
|
+
log2(` ${c2.green(apiUrl)}`);
|
|
6972
|
+
log2("");
|
|
6973
|
+
log2(` ${c2.dim("When prompted:")}`);
|
|
6974
|
+
log2(` ${c2.dim("cat ~/.agenticmail/config.json | grep masterKey")}`);
|
|
6975
|
+
}
|
|
6956
6976
|
log2("");
|
|
6957
6977
|
const platform = process.platform;
|
|
6958
6978
|
const opener = platform === "darwin" ? "open" : platform === "win32" ? "start" : "xdg-open";
|
|
@@ -7280,7 +7300,7 @@ async function cmdUpdate() {
|
|
|
7280
7300
|
info2(`Current version: ${c2.bold(currentVersion)}`);
|
|
7281
7301
|
let latestVersion = "unknown";
|
|
7282
7302
|
try {
|
|
7283
|
-
latestVersion = execSync("npm view agenticmail version", { encoding: "utf-8", timeout: 15e3 }).trim();
|
|
7303
|
+
latestVersion = execSync("npm view @agenticmail/cli version", { encoding: "utf-8", timeout: 15e3 }).trim();
|
|
7284
7304
|
} catch {
|
|
7285
7305
|
fail2("Could not check npm. Check your internet connection.");
|
|
7286
7306
|
process.exit(1);
|
|
@@ -7314,19 +7334,26 @@ async function cmdUpdate() {
|
|
|
7314
7334
|
}
|
|
7315
7335
|
let isGlobal = false;
|
|
7316
7336
|
try {
|
|
7317
|
-
const list = execSync(`npm list -g agenticmail 2>/dev/null`, { encoding: "utf-8", timeout: 1e4 });
|
|
7318
|
-
if (list.includes("agenticmail@")) isGlobal = true;
|
|
7337
|
+
const list = execSync(`npm list -g @agenticmail/cli 2>/dev/null`, { encoding: "utf-8", timeout: 1e4 });
|
|
7338
|
+
if (list.includes("@agenticmail/cli@")) isGlobal = true;
|
|
7319
7339
|
} catch {
|
|
7320
7340
|
}
|
|
7341
|
+
if (!isGlobal) {
|
|
7342
|
+
try {
|
|
7343
|
+
const list = execSync(`npm list -g agenticmail 2>/dev/null`, { encoding: "utf-8", timeout: 1e4 });
|
|
7344
|
+
if (list.includes("agenticmail@")) isGlobal = true;
|
|
7345
|
+
} catch {
|
|
7346
|
+
}
|
|
7347
|
+
}
|
|
7321
7348
|
const scope = isGlobal ? "-g" : "";
|
|
7322
|
-
const installCmd = pm === "bun" ? `bun add ${scope} agenticmail@latest`.trim() : `${pm} install ${scope} agenticmail@latest`.trim();
|
|
7349
|
+
const installCmd = pm === "bun" ? `bun add ${scope} @agenticmail/cli@latest`.trim() : `${pm} install ${scope} @agenticmail/cli@latest`.trim();
|
|
7323
7350
|
info2(`Running: ${c2.dim(installCmd)}`);
|
|
7324
7351
|
try {
|
|
7325
7352
|
execSync(installCmd, { stdio: "inherit", timeout: 12e4 });
|
|
7326
|
-
ok2(`Updated to agenticmail@${latestVersion}`);
|
|
7353
|
+
ok2(`Updated to @agenticmail/cli@${latestVersion}`);
|
|
7327
7354
|
} catch (err) {
|
|
7328
7355
|
fail2(`Update failed: ${err.message}`);
|
|
7329
|
-
info2(`Try: ${c2.green("npm install -g agenticmail@latest")}`);
|
|
7356
|
+
info2(`Try: ${c2.green("npm install -g @agenticmail/cli@latest")}`);
|
|
7330
7357
|
process.exit(1);
|
|
7331
7358
|
}
|
|
7332
7359
|
if (hasOpenClaw) {
|