@agenticmail/claudecode 0.2.21 → 0.2.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 +14 -0
- package/dist/mail-hook.js +2 -3
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -356,6 +356,20 @@ Re-run `agenticmail claudecode` — your bridge agent's key may have been rotate
|
|
|
356
356
|
|
|
357
357
|
---
|
|
358
358
|
|
|
359
|
+
## External inbox exposure — what `setup-email` actually does to your dispatcher
|
|
360
|
+
|
|
361
|
+
> **Once the operator runs `agenticmail setup-email`, every Claude Code subagent on this machine becomes reachable from the public internet via Gmail / Outlook plus-addressing.** Worth surfacing before the operator connects a relay:
|
|
362
|
+
|
|
363
|
+
- **Plus-addresses are publicly guessable.** Anyone can hit `your-relay+secretary@gmail.com`, `your-relay+kepler@gmail.com`, … and the matching subagent's inbox receives the mail. The `+sub` part is not a secret.
|
|
364
|
+
- **External mail goes through the same `handleEvent` path as internal `@localhost` mail.** Dedup, thread-cache, and wake-budget checks all run; if they pass, the Claude Code dispatcher spawns a fresh worker turn via `@anthropic-ai/claude-agent-sdk` to process the message. Source doesn't matter to the wake path.
|
|
365
|
+
- **The bridge takes a different path on purpose.** Mail to `your-relay+claudecode@gmail.com` routes to `handleBridgeMail`, which uses the SDK's `resume` option to wake the operator's last session headlessly rather than spawning a new worker — so external mail to the bridge can wake your interactive CLI, not just background turns. If resume fails (session expired, no host CLI running), it falls through to the bridge-escalation email at `setup_operator_email`.
|
|
366
|
+
- **Spam wakes Claude turns.** A scraper that finds a plus-address can drive billable Claude invocations. Throttles available, ordered from least invasive:
|
|
367
|
+
1. The `wake-budget` guard in `dispatcher.handleEvent` (default cap per minute per agent — automatic).
|
|
368
|
+
2. Relay-level spam filtering before the SSE event publishes.
|
|
369
|
+
3. For subagents that should stay internal-only, set `metadata.host` to a value no dispatcher matches so external mail still lands in the inbox but no worker spawns.
|
|
370
|
+
|
|
371
|
+
---
|
|
372
|
+
|
|
359
373
|
## License
|
|
360
374
|
|
|
361
375
|
MIT © Ope Olatunji
|
package/dist/mail-hook.js
CHANGED
|
@@ -159,9 +159,8 @@ async function main() {
|
|
|
159
159
|
return;
|
|
160
160
|
}
|
|
161
161
|
const data = await r.json();
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
);
|
|
162
|
+
const agents = data.agents ?? [];
|
|
163
|
+
bridge = agents.find((a) => a.name === "claudecode" || a.name === "claude") ?? agents.find((a) => a.role === "bridge");
|
|
165
164
|
} catch {
|
|
166
165
|
emitAndExit("");
|
|
167
166
|
return;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@agenticmail/claudecode",
|
|
3
|
-
"version": "0.2.
|
|
3
|
+
"version": "0.2.22",
|
|
4
4
|
"description": "Claude Code integration for AgenticMail — surfaces every AgenticMail agent as a native Claude Code subagent so any Claude Code session can delegate to them with the Agent tool",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|