codeam-cli 2.23.0 → 2.23.2
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/CHANGELOG.md +12 -0
- package/dist/index.js +88 -67
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,18 @@ All notable changes to `codeam-cli` are documented here.
|
|
|
4
4
|
|
|
5
5
|
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/), and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
|
|
6
6
|
|
|
7
|
+
## [2.23.1] — 2026-05-25
|
|
8
|
+
|
|
9
|
+
### Fixed
|
|
10
|
+
|
|
11
|
+
- **cli:** Payload.agentId — accept null, not just undefined (#189)
|
|
12
|
+
|
|
13
|
+
## [2.23.0] — 2026-05-25
|
|
14
|
+
|
|
15
|
+
### Added
|
|
16
|
+
|
|
17
|
+
- **cli:** AI insights — generateOneShot + handlers (PR 2 of 6) (#188)
|
|
18
|
+
|
|
7
19
|
## [2.22.1] — 2026-05-25
|
|
8
20
|
|
|
9
21
|
### Fixed
|
package/dist/index.js
CHANGED
|
@@ -441,7 +441,7 @@ var import_qrcode_terminal = __toESM(require("qrcode-terminal"));
|
|
|
441
441
|
// package.json
|
|
442
442
|
var package_default = {
|
|
443
443
|
name: "codeam-cli",
|
|
444
|
-
version: "2.23.
|
|
444
|
+
version: "2.23.2",
|
|
445
445
|
description: "Workflow-continuity bridge for AI coding agents. Wrap Claude Code or Codex in a PTY and supervise, approve, and redirect the session from any device \u2014 async. The terminal companion for CodeAgent Mobile.",
|
|
446
446
|
type: "commonjs",
|
|
447
447
|
main: "dist/index.js",
|
|
@@ -5768,7 +5768,7 @@ function readAnonId() {
|
|
|
5768
5768
|
}
|
|
5769
5769
|
function superProperties() {
|
|
5770
5770
|
return {
|
|
5771
|
-
cliVersion: true ? "2.23.
|
|
5771
|
+
cliVersion: true ? "2.23.2" : "0.0.0-dev",
|
|
5772
5772
|
nodeVersion: process.version,
|
|
5773
5773
|
platform: process.platform,
|
|
5774
5774
|
arch: process.arch,
|
|
@@ -13922,7 +13922,14 @@ var startCommandSchema = import_zod2.z.object({
|
|
|
13922
13922
|
// a narrow enum) because the web sends internal ids ('claude')
|
|
13923
13923
|
// while the auto-link backend sends public ids ('claude_code'),
|
|
13924
13924
|
// and the consuming handlers normalize themselves.
|
|
13925
|
-
|
|
13925
|
+
//
|
|
13926
|
+
// `.nullable()` — the web's session page passes the literal value
|
|
13927
|
+
// `null` when no agent has been selected yet for the session
|
|
13928
|
+
// (`currentAgentId` is null before sessionAgents populates).
|
|
13929
|
+
// Without nullable() zod rejects the whole payload, the dispatcher
|
|
13930
|
+
// logs "Ignoring malformed list_models payload" and the model
|
|
13931
|
+
// picker / context never load.
|
|
13932
|
+
agentId: import_zod2.z.string().max(64).nullable().optional(),
|
|
13926
13933
|
// `request_ai_summary` / `request_ai_insight` — backend fires
|
|
13927
13934
|
// these on turn-end (+ file selection) when LinkedAgent.
|
|
13928
13935
|
// aiInsightsEnabled is true. The CLI spawns the agent in
|
|
@@ -15445,7 +15452,7 @@ var applyFileReviewH = async (ctx, cmd, parsed) => {
|
|
|
15445
15452
|
result
|
|
15446
15453
|
);
|
|
15447
15454
|
};
|
|
15448
|
-
var requestLinkCredentialsH =
|
|
15455
|
+
var requestLinkCredentialsH = (ctx, _cmd, parsed) => {
|
|
15449
15456
|
const publicId = parsed.agentId;
|
|
15450
15457
|
if (!publicId) return;
|
|
15451
15458
|
if (!ctx.pluginAuthToken) {
|
|
@@ -15457,80 +15464,94 @@ var requestLinkCredentialsH = async (ctx, _cmd, parsed) => {
|
|
|
15457
15464
|
log.trace("auto-link", `unknown / disabled agent: ${internalId}`);
|
|
15458
15465
|
return;
|
|
15459
15466
|
}
|
|
15460
|
-
|
|
15461
|
-
|
|
15462
|
-
linkCtx
|
|
15463
|
-
|
|
15464
|
-
|
|
15465
|
-
|
|
15466
|
-
|
|
15467
|
-
|
|
15468
|
-
|
|
15469
|
-
|
|
15470
|
-
|
|
15471
|
-
|
|
15472
|
-
|
|
15473
|
-
|
|
15474
|
-
|
|
15475
|
-
|
|
15476
|
-
|
|
15477
|
-
|
|
15478
|
-
|
|
15479
|
-
|
|
15480
|
-
|
|
15481
|
-
|
|
15482
|
-
|
|
15483
|
-
|
|
15484
|
-
|
|
15485
|
-
|
|
15486
|
-
|
|
15487
|
-
|
|
15467
|
+
const pluginAuthToken = ctx.pluginAuthToken;
|
|
15468
|
+
void (async () => {
|
|
15469
|
+
let linkCtx;
|
|
15470
|
+
try {
|
|
15471
|
+
linkCtx = buildLinkContext(internalId);
|
|
15472
|
+
} catch (err) {
|
|
15473
|
+
log.trace("auto-link", "buildLinkContext threw", err);
|
|
15474
|
+
return;
|
|
15475
|
+
}
|
|
15476
|
+
const token = await linkCtx.locator.extract().catch((err) => {
|
|
15477
|
+
log.trace("auto-link", `locator.extract failed for ${publicId}`, err);
|
|
15478
|
+
return null;
|
|
15479
|
+
});
|
|
15480
|
+
if (!token) {
|
|
15481
|
+
log.trace("auto-link", `no local ${linkCtx.displayName} credentials \u2014 skipping`);
|
|
15482
|
+
return;
|
|
15483
|
+
}
|
|
15484
|
+
const result = await postLinkCredential({
|
|
15485
|
+
agentId: publicId,
|
|
15486
|
+
sessionId: ctx.sessionId,
|
|
15487
|
+
pluginId: ctx.pluginId,
|
|
15488
|
+
pluginAuthToken,
|
|
15489
|
+
method: token.method,
|
|
15490
|
+
credential: token.credential
|
|
15491
|
+
});
|
|
15492
|
+
if (result.ok) {
|
|
15493
|
+
log.trace("auto-link", `vaulted ${publicId} from ${token.source}`);
|
|
15494
|
+
} else {
|
|
15495
|
+
log.trace("auto-link", `upload failed (${result.status}): ${result.message}`);
|
|
15496
|
+
}
|
|
15497
|
+
})();
|
|
15488
15498
|
};
|
|
15489
|
-
var requestAiSummaryH =
|
|
15499
|
+
var requestAiSummaryH = (ctx, _cmd, parsed) => {
|
|
15490
15500
|
if (!ctx.pluginAuthToken) return;
|
|
15491
15501
|
if (typeof ctx.runtime.generateOneShot !== "function") return;
|
|
15492
15502
|
if (!parsed.prompt || !parsed.turnId || !parsed.stats) {
|
|
15493
15503
|
log.trace("ai-summary", "missing prompt/turnId/stats \u2014 skipping");
|
|
15494
15504
|
return;
|
|
15495
15505
|
}
|
|
15496
|
-
const
|
|
15497
|
-
|
|
15498
|
-
|
|
15499
|
-
|
|
15500
|
-
|
|
15501
|
-
|
|
15502
|
-
|
|
15503
|
-
|
|
15504
|
-
|
|
15505
|
-
|
|
15506
|
-
|
|
15507
|
-
|
|
15508
|
-
|
|
15509
|
-
|
|
15506
|
+
const prompt = parsed.prompt;
|
|
15507
|
+
const turnId = parsed.turnId;
|
|
15508
|
+
const stats = parsed.stats;
|
|
15509
|
+
const pluginAuthToken = ctx.pluginAuthToken;
|
|
15510
|
+
void (async () => {
|
|
15511
|
+
const text = await ctx.runtime.generateOneShot(prompt).catch((err) => {
|
|
15512
|
+
log.trace("ai-summary", "generateOneShot threw", err);
|
|
15513
|
+
return null;
|
|
15514
|
+
});
|
|
15515
|
+
if (!text) return;
|
|
15516
|
+
await postAiResult({
|
|
15517
|
+
sessionId: ctx.sessionId,
|
|
15518
|
+
pluginId: ctx.pluginId,
|
|
15519
|
+
pluginAuthToken,
|
|
15520
|
+
kind: "summary",
|
|
15521
|
+
turnId,
|
|
15522
|
+
summary: text,
|
|
15523
|
+
stats
|
|
15524
|
+
});
|
|
15525
|
+
})();
|
|
15510
15526
|
};
|
|
15511
|
-
var requestAiInsightH =
|
|
15527
|
+
var requestAiInsightH = (ctx, _cmd, parsed) => {
|
|
15512
15528
|
if (!ctx.pluginAuthToken) return;
|
|
15513
15529
|
if (typeof ctx.runtime.generateOneShot !== "function") return;
|
|
15514
15530
|
if (!parsed.prompt || !parsed.fileChangeId) {
|
|
15515
15531
|
log.trace("ai-insight", "missing prompt/fileChangeId \u2014 skipping");
|
|
15516
15532
|
return;
|
|
15517
15533
|
}
|
|
15518
|
-
const
|
|
15519
|
-
|
|
15520
|
-
|
|
15521
|
-
|
|
15522
|
-
|
|
15523
|
-
|
|
15524
|
-
|
|
15525
|
-
|
|
15526
|
-
|
|
15527
|
-
|
|
15528
|
-
|
|
15529
|
-
|
|
15530
|
-
|
|
15531
|
-
|
|
15532
|
-
|
|
15533
|
-
|
|
15534
|
+
const prompt = parsed.prompt;
|
|
15535
|
+
const fileChangeId = parsed.fileChangeId;
|
|
15536
|
+
const pluginAuthToken = ctx.pluginAuthToken;
|
|
15537
|
+
void (async () => {
|
|
15538
|
+
const text = await ctx.runtime.generateOneShot(prompt).catch((err) => {
|
|
15539
|
+
log.trace("ai-insight", "generateOneShot threw", err);
|
|
15540
|
+
return null;
|
|
15541
|
+
});
|
|
15542
|
+
if (!text) return;
|
|
15543
|
+
const { summary, reasoning, securityNote } = parseInsightText(text);
|
|
15544
|
+
await postAiResult({
|
|
15545
|
+
sessionId: ctx.sessionId,
|
|
15546
|
+
pluginId: ctx.pluginId,
|
|
15547
|
+
pluginAuthToken,
|
|
15548
|
+
kind: "insight",
|
|
15549
|
+
fileChangeId,
|
|
15550
|
+
summary,
|
|
15551
|
+
reasoning,
|
|
15552
|
+
securityNote
|
|
15553
|
+
});
|
|
15554
|
+
})();
|
|
15534
15555
|
};
|
|
15535
15556
|
function parseInsightText(text) {
|
|
15536
15557
|
const summaryMatch = text.match(/SUMMARY:\s*([\s\S]*?)(?=\n\s*(?:REASONING|SECURITY):|$)/i);
|
|
@@ -18283,7 +18304,7 @@ function checkChokidar() {
|
|
|
18283
18304
|
}
|
|
18284
18305
|
async function doctor(args2 = []) {
|
|
18285
18306
|
const json = args2.includes("--json");
|
|
18286
|
-
const cliVersion = true ? "2.23.
|
|
18307
|
+
const cliVersion = true ? "2.23.2" : "0.0.0-dev";
|
|
18287
18308
|
const apiBase = resolveApiBaseUrl();
|
|
18288
18309
|
const diagnosticId = (0, import_node_crypto5.randomUUID)();
|
|
18289
18310
|
log.info("doctor", `run id=${diagnosticId} cli=${cliVersion}`);
|
|
@@ -18482,7 +18503,7 @@ async function completion(args2) {
|
|
|
18482
18503
|
// src/commands/version.ts
|
|
18483
18504
|
var import_picocolors13 = __toESM(require("picocolors"));
|
|
18484
18505
|
function version2() {
|
|
18485
|
-
const v = true ? "2.23.
|
|
18506
|
+
const v = true ? "2.23.2" : "unknown";
|
|
18486
18507
|
console.log(`${import_picocolors13.default.bold("codeam-cli")} ${import_picocolors13.default.cyan(v)}`);
|
|
18487
18508
|
}
|
|
18488
18509
|
|
|
@@ -18710,7 +18731,7 @@ function checkForUpdates() {
|
|
|
18710
18731
|
if (process.env.CODEAM_DISABLE_UPDATE_CHECK === "1") return;
|
|
18711
18732
|
if (process.env.CI) return;
|
|
18712
18733
|
if (!process.stdout.isTTY) return;
|
|
18713
|
-
const current = true ? "2.23.
|
|
18734
|
+
const current = true ? "2.23.2" : null;
|
|
18714
18735
|
if (!current) return;
|
|
18715
18736
|
const cache = readCache();
|
|
18716
18737
|
const fresh = cache && Date.now() - cache.fetchedAt < TTL_MS;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "codeam-cli",
|
|
3
|
-
"version": "2.23.
|
|
3
|
+
"version": "2.23.2",
|
|
4
4
|
"description": "Workflow-continuity bridge for AI coding agents. Wrap Claude Code or Codex in a PTY and supervise, approve, and redirect the session from any device — async. The terminal companion for CodeAgent Mobile.",
|
|
5
5
|
"type": "commonjs",
|
|
6
6
|
"main": "dist/index.js",
|