@integrity-labs/agt-cli 0.28.906 → 0.28.907
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/bin/agt.js
CHANGED
|
@@ -40,7 +40,7 @@ import {
|
|
|
40
40
|
success,
|
|
41
41
|
table,
|
|
42
42
|
warn
|
|
43
|
-
} from "../chunk-
|
|
43
|
+
} from "../chunk-GBQRH5RE.js";
|
|
44
44
|
import {
|
|
45
45
|
getProjectDir,
|
|
46
46
|
isSessionResumeDisabled,
|
|
@@ -5467,7 +5467,7 @@ import { execFileSync, execSync } from "child_process";
|
|
|
5467
5467
|
import { existsSync as existsSync11, realpathSync as realpathSync2 } from "fs";
|
|
5468
5468
|
import chalk18 from "chalk";
|
|
5469
5469
|
import ora16 from "ora";
|
|
5470
|
-
var cliVersion = true ? "0.28.
|
|
5470
|
+
var cliVersion = true ? "0.28.907" : "dev";
|
|
5471
5471
|
async function fetchLatestVersion() {
|
|
5472
5472
|
const host2 = getHost();
|
|
5473
5473
|
if (!host2) return null;
|
|
@@ -6682,7 +6682,7 @@ function handleError(err) {
|
|
|
6682
6682
|
}
|
|
6683
6683
|
|
|
6684
6684
|
// src/bin/agt.ts
|
|
6685
|
-
var cliVersion2 = true ? "0.28.
|
|
6685
|
+
var cliVersion2 = true ? "0.28.907" : "dev";
|
|
6686
6686
|
var program = new Command();
|
|
6687
6687
|
program.name("agt").description("Augmented CLI \u2014 agent provisioning and management").version(cliVersion2).option("--json", "Emit machine-readable JSON output (suppress spinners and colors)").option("--skip-update-check", "Skip the automatic update check on startup");
|
|
6688
6688
|
program.hook("preAction", async (thisCommand, actionCommand) => {
|
|
@@ -6841,7 +6841,7 @@ function exchangeFailureKind(err) {
|
|
|
6841
6841
|
}
|
|
6842
6842
|
|
|
6843
6843
|
// src/lib/api-client.ts
|
|
6844
|
-
var agtCliVersion = true ? "0.28.
|
|
6844
|
+
var agtCliVersion = true ? "0.28.907" : "dev";
|
|
6845
6845
|
var lastConfigHash = null;
|
|
6846
6846
|
function setConfigHash(hash) {
|
|
6847
6847
|
lastConfigHash = hash && hash.length > 0 ? hash : null;
|
|
@@ -11451,4 +11451,4 @@ export {
|
|
|
11451
11451
|
managerInstallSystemUnitCommand,
|
|
11452
11452
|
managerUninstallSystemUnitCommand
|
|
11453
11453
|
};
|
|
11454
|
-
//# sourceMappingURL=chunk-
|
|
11454
|
+
//# sourceMappingURL=chunk-GBQRH5RE.js.map
|
|
@@ -63,7 +63,7 @@ import {
|
|
|
63
63
|
safeWriteJsonAtomic,
|
|
64
64
|
setConfigHash,
|
|
65
65
|
tripClass
|
|
66
|
-
} from "../chunk-
|
|
66
|
+
} from "../chunk-GBQRH5RE.js";
|
|
67
67
|
import {
|
|
68
68
|
getProjectDir as getProjectDir2,
|
|
69
69
|
getReadyTasks,
|
|
@@ -13721,7 +13721,7 @@ var agentRestartTimezoneInputs = /* @__PURE__ */ new Map();
|
|
|
13721
13721
|
var lastVersionCheckAt = 0;
|
|
13722
13722
|
var VERSION_CHECK_INTERVAL_MS = 5 * 60 * 1e3;
|
|
13723
13723
|
var lastResponsivenessProbeAt = 0;
|
|
13724
|
-
var agtCliVersion = true ? "0.28.
|
|
13724
|
+
var agtCliVersion = true ? "0.28.907" : "dev";
|
|
13725
13725
|
function resolveBrewPath(execFileSync2) {
|
|
13726
13726
|
try {
|
|
13727
13727
|
const out = execFileSync2("which", ["brew"], { timeout: 5e3 }).toString().trim();
|
|
@@ -21877,7 +21877,7 @@ server.registerTool(
|
|
|
21877
21877
|
);
|
|
21878
21878
|
server.registerTool(
|
|
21879
21879
|
"debug_query_audit_log",
|
|
21880
|
-
{ description: 'Read recent audit events to troubleshoot why/when agents bounced \u2014 primarily restart events. Defaults to the "agent.restart" action: each event returns { id, created_at, action, actor_kind, user_id, agent_id, organization_id, source, reason, detail, code_name, impersonated, impersonated_by_user_id, impersonated_agent_id, impersonation_session_id } \u2014 `user_id` is the identity the action was performed AS, `agent_id` the agent it was performed ON, `impersonated_by_user_id` the operator who was actually driving a user-impersonation session, and `impersonated_agent_id` the agent identity an operator was driving in the agent-impersonation flow (the two flows are distinct and a row carries at most one). `source` is the restart trigger (agent-self-request, channel-command, maintenance-window, stale-mcp, hot-reload-mcp, mcp-presence-reaper, day-rollover, auth-tuple-change, \u2026) and `reason` is the free-text rationale when one was given (e.g. the agent\'s own words for a request_restart). `detail` (ENG-8293) is the structured "what changed?" payload, null for sources that don\'t emit one. For `auth-tuple-change` it is { auth_tuple: { changed[], unchanged[], components[] } } naming WHICH credential/identity component moved and its before/after fingerprint \u2014 the auth tuple is deliberately NOT keyed on the rotating access token, so an auth-tuple-change is always a genuine credential or identity change, and `detail.auth_tuple.changed` is how you tell which one. Comparing `components[].to` across agents answers whether a restart WAVE was one control-plane push (same new value everywhere) or coincidental per-agent rotations. Two modes: (1) pass { agent_id } to scope to ONE agent (fails closed if you\'re not authorized for its org) \u2014 use when a specific agent went quiet. (2) OMIT agent_id for a CROSS-AGENT sweep across every org you\'re authorized for (optionally narrow with { org_id }) \u2014 use to spot fleet-wide restart storms or compare agents. Filter the action with `action` (pass "all" to drop the action filter and read every event type), and bound with { since_hours?, limit? }. Cross-agent results are org-walled in SQL; unauthorized orgs are invisible. ENG-9079 \u2014 IMPERSONATION: `user_id` is the identity an action was performed AS, which is not always who performed it. When `impersonated` is true an Integrity Labs operator was driving: `impersonated_by_user_id` is that operator and `impersonation_session_id` joins every action in the same session. `actor_kind` does NOT distinguish these \u2014 an impersonated user action still reads `user`, so read `impersonated`, not `actor_kind`, to answer "was this really the customer?".
|
|
21880
|
+
{ description: 'Read recent audit events to troubleshoot why/when agents bounced \u2014 primarily restart events. Defaults to the "agent.restart" action: each event returns { id, created_at, action, actor_kind, user_id, agent_id, organization_id, source, reason, detail, code_name, impersonated, impersonated_by_user_id, impersonated_agent_id, impersonation_session_id } \u2014 `user_id` is the identity the action was performed AS, `agent_id` the agent it was performed ON, `impersonated_by_user_id` the operator who was actually driving a user-impersonation session, and `impersonated_agent_id` the agent identity an operator was driving in the agent-impersonation flow (the two flows are distinct and a row carries at most one). `source` is the restart trigger (agent-self-request, channel-command, maintenance-window, stale-mcp, hot-reload-mcp, mcp-presence-reaper, day-rollover, auth-tuple-change, \u2026) and `reason` is the free-text rationale when one was given (e.g. the agent\'s own words for a request_restart). `detail` (ENG-8293) is the structured "what changed?" payload, null for sources that don\'t emit one. For `auth-tuple-change` it is { auth_tuple: { changed[], unchanged[], components[] } } naming WHICH credential/identity component moved and its before/after fingerprint \u2014 the auth tuple is deliberately NOT keyed on the rotating access token, so an auth-tuple-change is always a genuine credential or identity change, and `detail.auth_tuple.changed` is how you tell which one. Comparing `components[].to` across agents answers whether a restart WAVE was one control-plane push (same new value everywhere) or coincidental per-agent rotations. Two modes: (1) pass { agent_id } to scope to ONE agent (fails closed if you\'re not authorized for its org) \u2014 use when a specific agent went quiet. (2) OMIT agent_id for a CROSS-AGENT sweep across every org you\'re authorized for (optionally narrow with { org_id }) \u2014 use to spot fleet-wide restart storms or compare agents. Filter the action with `action` (pass "all" to drop the action filter and read every event type), and bound with { since_hours?, limit? }. Cross-agent results are org-walled in SQL; unauthorized orgs are invisible. ENG-9079 \u2014 IMPERSONATION: `user_id` is the identity an action was performed AS, which is not always who performed it. When `impersonated` is true an Integrity Labs operator was driving: `impersonated_by_user_id` is that operator and `impersonation_session_id` joins every action in the same session. `actor_kind` does NOT distinguish these \u2014 an impersonated user action still reads `user`, so read `impersonated`, not `actor_kind`, to answer "was this really the customer?". One caveat an investigator must hold: rows written before ENG-9018 shipped (17 Aug 06:04Z) carry NULL because the information was never captured, so absence there is not evidence of a genuine customer action. From ENG-9210 (13 Sep) every audit writer REACHABLE during an impersonation session is threaded, so on a row written after that, `impersonated: false` means the action was genuinely not impersonated. Writers that remain unthreaded are all classified `unreachable` \u2014 they cannot execute during an impersonation session at all (host-JWT and agent-MCP paths), so a NULL from them is correct rather than merely unrecorded.', inputSchema: queryAuditLogSchema },
|
|
21881
21881
|
async (args) => {
|
|
21882
21882
|
try {
|
|
21883
21883
|
const result = await client.queryAuditLog(args);
|
package/package.json
CHANGED
|
File without changes
|