@oked/sdk 0.6.21 → 0.6.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 CHANGED
@@ -5,7 +5,7 @@
5
5
 
6
6
  Programmatic approval API for AI agents. Send a sensitive action to the OKed backend, wait for a person, and continue only when they approve.
7
7
 
8
- Use this package from any Node.js agent. For drop-in integrations, see [`@oked/claude-code`](../claude-code), [`@oked/claude-agent-sdk`](../claude-agent-sdk), and [`@oked/openclaw`](../openclaw).
8
+ Use this package from any Node.js agent. For drop-in integrations, see [`@oked/claude-code`](../claude-code), [`@oked/claude-agent-sdk`](../claude-agent-sdk), [`@oked/openai-agents`](../openai-agents), [`@oked/openclaw`](../openclaw), [`@oked/langgraph`](../langgraph), and [`@oked/ai-sdk`](../ai-sdk). Python agents use [`oked`](../../python/oked) and [`oked-langgraph`](../../python/oked-langgraph). Neither is on PyPI yet. Until then, `pip install "oked @ git+https://github.com/oked-ai/oked-sdk#subdirectory=python/oked"` for the client, and `pip install "oked @ git+https://github.com/oked-ai/oked-sdk#subdirectory=python/oked" "oked-langgraph @ git+https://github.com/oked-ai/oked-sdk#subdirectory=python/oked-langgraph"` for LangGraph. Once it is on PyPI, the commands are `pip install oked` and `pip install oked-langgraph`.
9
9
 
10
10
  Decisions are made in Telegram and on the [web dashboard](https://oked.ai/dashboard). The iPhone app is coming soon. [Sign up](https://oked.ai/signup) to get an API key.
11
11
 
@@ -48,11 +48,10 @@ Pass any of these to `new OKedClient(config)`. Constructor values win over envir
48
48
  | Key | Type | Default | Description |
49
49
  |---|---|---|---|
50
50
  | `apiKey` | `string` | `OKED_API_KEY`, then the config file | OKed API key. Required for `approve`. |
51
- | `backendUrl` | `string` | `https://api.oked.ai` | Backend URL. |
52
51
  | `timeout` | `number` | `630000` | How long to wait for a decision, in milliseconds. See above. |
53
52
  | `strictFailClosed` | `boolean` | `false` | When true, an unreachable backend denies every tier. When false, it denies only `high_stakes`. |
54
53
  | `requireReceipt` | `boolean` | `true` | Deny an approval that arrives without a signed receipt. A receipt that is present but invalid always denies. Set `false` (env `OKED_REQUIRE_RECEIPT=0`) only for a backend that does not sign receipts. |
55
- | `receiptKeysUrl` | `string` | `https://api.oked.ai/.well-known/oked-receipt-keys.json` | Where to fetch a receipt key the SDK has not seen. Independent of `backendUrl`. https only, except loopback. |
54
+ | `receiptKeysUrl` | `string` | `https://api.oked.ai/.well-known/oked-receipt-keys.json` | Where to fetch a receipt key the SDK has not seen. https only, except loopback. |
56
55
  | `receiptKeys` | `ReceiptKey[]` | | Verify with exactly these keys and never fetch. For self-hosted backends and tests. |
57
56
  | `rulesCacheTtlMs` | `number` | `300000` | How long the on-disk rules cache stays fresh. Env `OKED_RULES_CACHE_TTL` is in seconds. |
58
57
  | `heartbeatIntervalMs` | `number` | `86400000` | Minimum gap between presence pings. Env `OKED_HEARTBEAT_INTERVAL` is in seconds. |
@@ -84,7 +83,7 @@ Ask for a decision. Resolves when the person responds, the request times out, or
84
83
 
85
84
  ### `ping()`
86
85
 
87
- Returns `true` when `GET {backendUrl}/health` succeeds within 3 seconds.
86
+ Returns `true` when `GET https://api.oked.ai/health` succeeds within 3 seconds.
88
87
 
89
88
  ### `getRules()` and `heartbeat()`
90
89
 
@@ -92,7 +91,7 @@ Returns `true` when `GET {backendUrl}/health` succeeds within 3 seconds.
92
91
 
93
92
  ### Helpers
94
93
 
95
- - `classify(toolName, toolInput)` returns a risk tier for a tool call.
94
+ - `classify(toolName, toolInput)` returns a risk tier for a tool call. Pass `{ sandboxEnforced: false }` to ask (`review`) before an opaque runner (`cargo test`, `npm test`, `npm run`, `pytest`, `go test`, `make`, `./script.sh`, `node scripts/x.mjs`, `npx`). Omit the option, or pass `true`, and those commands stay `safe`. Claude Code sets this from sandbox settings. Other hosts omit it.
96
95
  - `describe(toolName, toolInput, ctx?)` returns a one-line description.
97
96
  - `describeFields(toolName, toolInput, ctx?)` returns the card fields.
98
97
 
@@ -103,7 +102,6 @@ Full type definitions ship in the package (`dist/index.d.ts`).
103
102
  | Var | Required | Description |
104
103
  |---|---|---|
105
104
  | `OKED_API_KEY` | yes, unless passed in code or saved by `oked init` | OKed API key. |
106
- | `OKED_BACKEND_URL` | no | Override the hosted backend URL. |
107
105
  | `OKED_STRICT_FAIL_CLOSED` | no | `1` or `true` denies every sensitive action when the backend is unreachable. |
108
106
  | `OKED_REQUIRE_RECEIPT` | no | `0` allows an approval that has no receipt. On by default. |
109
107
  | `OKED_RECEIPT_KEYS_URL` | no | Where to fetch receipt keys. Default is OKed's published set. |
@@ -1,11 +1,20 @@
1
1
  import type { RiskTier } from "./types.js";
2
- export declare function classify(toolName: string, toolInput: Record<string, unknown>): RiskTier;
2
+ /**
3
+ * `sandboxEnforced: false` asks for `review` before an opaque code runner
4
+ * (a test runner, package script, script file, or npx tool). `true` or omitted
5
+ * leaves those commands `safe`. Claude Code sets this from sandbox settings.
6
+ * Other hosts omit it and keep the previous behaviour.
7
+ */
8
+ export interface ClassifyOptions {
9
+ sandboxEnforced?: boolean;
10
+ }
11
+ export declare function classify(toolName: string, toolInput: Record<string, unknown>, options?: ClassifyOptions): RiskTier;
3
12
  /**
4
13
  * Tier of each step of a compound command, read the way the whole command is
5
14
  * read: a step sees the temp files and temp folders that earlier steps made
6
15
  * (`cat > _s.mjs <<EOF … && rm _s.mjs`). `classify` of one step alone does not.
7
16
  */
8
- export declare function classifyBashSteps(steps: string[]): RiskTier[];
17
+ export declare function classifyBashSteps(steps: string[], sandboxEnforced?: boolean): RiskTier[];
9
18
  /** Split a shell command into top-level segments on the operators that
10
19
  * sequence separate commands: `|`, `||`, `&&`, `;`, and a bare newline (a
11
20
  * newline separates commands in a multi-line script exactly like `;`).
package/dist/classify.js CHANGED
@@ -92,7 +92,7 @@ const WARNING_SESSION_TOOLS = new Set([
92
92
  "WebFetch",
93
93
  ]);
94
94
  /** Built-ins whose tier depends on their input. Returns null for other tools. */
95
- function classifySessionTool(toolName, toolInput) {
95
+ function classifySessionTool(toolName, toolInput, sandboxEnforced) {
96
96
  switch (toolName) {
97
97
  // "keep" leaves everything on disk. "remove" refuses when there is
98
98
  // unsaved work, unless discard_changes deletes it for good.
@@ -103,7 +103,7 @@ function classifySessionTool(toolName, toolInput) {
103
103
  // Monitor runs a shell command (classified like Bash) or reads a WebSocket.
104
104
  case "Monitor":
105
105
  if (typeof toolInput.command === "string")
106
- return classifyBashCommand(toolInput.command);
106
+ return classifyBashCommand(toolInput.command, new Set(), sandboxEnforced);
107
107
  return "warning";
108
108
  // Artifact: publishing puts content on claude.ai; delete is permanent;
109
109
  // read / list / open / quickstart / pin only look or arrange.
@@ -621,12 +621,13 @@ function classifyGhApiStage(stage) {
621
621
  // (silent) label, and cover the local mutations we can recognize by shape but
622
622
  // that aren't a plain file write (those are handled by extractShellWriteOps).
623
623
  //
624
- // Opaque code execution (node/npx/python/claude/test runners) is intentionally
625
- // NOT here: we can't tell whether it mutated anything, and a destructive effect
626
- // buried inside `node -e …` would slip through regardless of the label — so
627
- // logging it adds terminal noise without buying safety. It stays `safe`, just
628
- // like any other unrecognized command. A real file write it performs is a
629
- // separate Bash/Write call that gets classified on its own.
624
+ // Opaque code execution (node -e, npx, python -c, test runners, script files)
625
+ // is intentionally NOT a warning marker. A warning only adds a log line, and
626
+ // the hook still cannot see what the child process runs. When the host sandbox
627
+ // is not enforcing containment, classify() with `sandboxEnforced: false` raises
628
+ // test runners and script files to `review` (see isOpaqueCodeRunner). Other
629
+ // hosts omit that option, so those commands stay `safe`. Inline interpreter
630
+ // bodies stay unscanned as shell, because shell tokens in the body are data.
630
631
  const WARNING_COMMANDS = [
631
632
  // Local, reversible git writes — stage/commit/switch/stash. They mutate the
632
633
  // local repo but can be undone (amend, reset, checkout). Destructive git
@@ -817,7 +818,8 @@ function isSensitiveWritePath(filePath) {
817
818
  return true;
818
819
  return false;
819
820
  }
820
- export function classify(toolName, toolInput) {
821
+ export function classify(toolName, toolInput, options) {
822
+ const sandboxEnforced = options?.sandboxEnforced;
821
823
  // Check tool-level classification first
822
824
  if (SAFE_TOOLS.has(toolName))
823
825
  return "safe";
@@ -831,7 +833,7 @@ export function classify(toolName, toolInput) {
831
833
  return "safe";
832
834
  if (WARNING_SESSION_TOOLS.has(toolName))
833
835
  return "warning";
834
- const sessionTier = classifySessionTool(toolName, toolInput);
836
+ const sessionTier = classifySessionTool(toolName, toolInput, sandboxEnforced);
835
837
  if (sessionTier !== null)
836
838
  return sessionTier;
837
839
  // File-editing tools: a write/edit can't act on its own — whatever later
@@ -851,7 +853,7 @@ export function classify(toolName, toolInput) {
851
853
  return "safe";
852
854
  // Bash commands need deeper analysis
853
855
  if (toolName === "Bash") {
854
- return classifyBashCommand(toolInput.command);
856
+ return classifyBashCommand(toolInput.command, new Set(), sandboxEnforced);
855
857
  }
856
858
  // MCP tools: mcp__<server>__<tool>
857
859
  if (toolName.startsWith("mcp__")) {
@@ -862,7 +864,7 @@ export function classify(toolName, toolInput) {
862
864
  // command/cmd field. Route through bash classification.
863
865
  const shellCommand = (toolInput.command ?? toolInput.cmd);
864
866
  if (typeof shellCommand === "string") {
865
- return classifyBashCommand(shellCommand);
867
+ return classifyBashCommand(shellCommand, new Set(), sandboxEnforced);
866
868
  }
867
869
  // File-write-style tools from other agents (OpenClaw `write`, generic
868
870
  // `create_file`, `file_write`). Detect by signature: string path field
@@ -880,13 +882,13 @@ export function classify(toolName, toolInput) {
880
882
  * read: a step sees the temp files and temp folders that earlier steps made
881
883
  * (`cat > _s.mjs <<EOF … && rm _s.mjs`). `classify` of one step alone does not.
882
884
  */
883
- export function classifyBashSteps(steps) {
885
+ export function classifyBashSteps(steps, sandboxEnforced) {
884
886
  const vars = new Set();
885
887
  for (const step of steps)
886
888
  for (const stage of splitTopLevel(step))
887
889
  collectMktempVars(stage, vars);
888
890
  return steps.map((step) => {
889
- const tier = classifyBashCommand(step, vars);
891
+ const tier = classifyBashCommand(step, vars, sandboxEnforced);
890
892
  for (const stage of splitTopLevel(step))
891
893
  noteEphemeralEffects(stripHeredocBodies(stage), vars);
892
894
  return tier;
@@ -1057,7 +1059,7 @@ function isBuildOutputOnlyDeletion(command) {
1057
1059
  * values, plus any trailing command. A purely literal assignment is `safe`.
1058
1060
  * Returns null if the stage is not assignment-prefixed.
1059
1061
  */
1060
- function classifyAssignmentStage(stage) {
1062
+ function classifyAssignmentStage(stage, sandboxEnforced) {
1061
1063
  if (!/^\w+=/.test(stage))
1062
1064
  return null;
1063
1065
  const inners = [];
@@ -1112,9 +1114,9 @@ function classifyAssignmentStage(stage) {
1112
1114
  const rest = stage.slice(i).trim();
1113
1115
  let tier = "safe";
1114
1116
  for (const inner of inners)
1115
- tier = maxTier(tier, classifyBashCommand(inner));
1117
+ tier = maxTier(tier, classifyBashCommand(inner, new Set(), sandboxEnforced));
1116
1118
  if (rest)
1117
- tier = maxTier(tier, classifyBashCommand(rest));
1119
+ tier = maxTier(tier, classifyBashCommand(rest, new Set(), sandboxEnforced));
1118
1120
  return tier;
1119
1121
  }
1120
1122
  /**
@@ -1125,7 +1127,7 @@ function classifyAssignmentStage(stage) {
1125
1127
  * (quote-preserving) offset. `env` with no command just prints the environment
1126
1128
  * → safe. Returns null if the stage doesn't start with `env`.
1127
1129
  */
1128
- function classifyEnvStage(stage) {
1130
+ function classifyEnvStage(stage, sandboxEnforced) {
1129
1131
  const lead = /^env\b[ \t]*/.exec(stage);
1130
1132
  if (!lead)
1131
1133
  return null;
@@ -1176,7 +1178,7 @@ function classifyEnvStage(stage) {
1176
1178
  }
1177
1179
  if (/^\w+=/.test(tok))
1178
1180
  continue; // NAME=VALUE
1179
- return classifyBashCommand(stage.slice(start).trim()); // first real word → the command
1181
+ return classifyBashCommand(stage.slice(start).trim(), new Set(), sandboxEnforced); // first real word → the command
1180
1182
  }
1181
1183
  return "safe"; // `env` / `env -u X` with no command just prints the environment
1182
1184
  }
@@ -1194,7 +1196,7 @@ const GIT_GLOBAL_ARG_OPTS = new Set([
1194
1196
  * can define a shell command, so it gets a `review` floor. Returns null if the
1195
1197
  * stage is not a git call with global options.
1196
1198
  */
1197
- function classifyGitGlobalOptsStage(stage, ephemeralVars) {
1199
+ function classifyGitGlobalOptsStage(stage, ephemeralVars, sandboxEnforced) {
1198
1200
  const lead = /^git[ \t]+(?=-)/.exec(stage);
1199
1201
  if (!lead)
1200
1202
  return null;
@@ -1231,7 +1233,7 @@ function classifyGitGlobalOptsStage(stage, ephemeralVars) {
1231
1233
  i = readToken(i);
1232
1234
  const tok = stage.slice(start, i);
1233
1235
  if (!tok.startsWith("-")) {
1234
- const inner = classifyBashCommand(`git ${stage.slice(start).trim()}`, ephemeralVars);
1236
+ const inner = classifyBashCommand(`git ${stage.slice(start).trim()}`, ephemeralVars, sandboxEnforced);
1235
1237
  return maxTier(floor, inner);
1236
1238
  }
1237
1239
  let value = "";
@@ -1265,7 +1267,7 @@ const SSH_ARG_OPTS = new Set([
1265
1267
  * isn't an ssh invocation. Excludes `ssh-keygen`/`ssh-add`/`ssh-keyscan` (the
1266
1268
  * `^ssh\s` anchor requires whitespace, not a hyphen).
1267
1269
  */
1268
- function classifySshStage(stage) {
1270
+ function classifySshStage(stage, sandboxEnforced) {
1269
1271
  const lead = /^ssh\s+/.exec(stage);
1270
1272
  if (!lead)
1271
1273
  return null;
@@ -1323,7 +1325,7 @@ function classifySshStage(stage) {
1323
1325
  if (rest.length >= 2 && (rest[0] === '"' || rest[0] === "'") && rest[rest.length - 1] === rest[0]) {
1324
1326
  rest = rest.slice(1, -1);
1325
1327
  }
1326
- return classifyBashCommand(rest);
1328
+ return classifyBashCommand(rest, new Set(), sandboxEnforced);
1327
1329
  }
1328
1330
  return "review"; // only options / a bare host token → treat as remote access
1329
1331
  }
@@ -1335,11 +1337,11 @@ function classifySshStage(stage) {
1335
1337
  * `grep -c`) is unaffected because the stage doesn't start with a shell name.
1336
1338
  * Returns null if the stage isn't a `sh -c`-style invocation.
1337
1339
  */
1338
- function classifyShellCStage(stage) {
1340
+ function classifyShellCStage(stage, sandboxEnforced) {
1339
1341
  const m = stage.match(/^(?:bash|sh|zsh|ksh|dash)\b[^'"]*?\s-[A-Za-z]*c\s+(['"])([\s\S]*?)\1/);
1340
1342
  if (!m)
1341
1343
  return null;
1342
- return classifyBashCommand(m[2]);
1344
+ return classifyBashCommand(m[2], new Set(), sandboxEnforced);
1343
1345
  }
1344
1346
  // A curl/wget whose target host is loopback (localhost, 127.0.0.0/8, 0.0.0.0,
1345
1347
  // ::1). A request to a server on this machine is a LOCAL action, not an outward
@@ -1368,7 +1370,7 @@ function isLoopbackHttpStage(stage) {
1368
1370
  return false;
1369
1371
  return /(?:^|[\s@])(?:localhost|127(?:\.\d{1,3}){3}|0\.0\.0\.0|\[::1\])(?::\d+)?(?:[/\s'"]|$)/i.test(stage);
1370
1372
  }
1371
- function classifyBashCommand(command, ephemeralVars = new Set()) {
1373
+ function classifyBashCommand(command, ephemeralVars = new Set(), sandboxEnforced) {
1372
1374
  if (!command)
1373
1375
  return "safe";
1374
1376
  // Two views of the command:
@@ -1430,7 +1432,7 @@ function classifyBashCommand(command, ephemeralVars = new Set()) {
1430
1432
  // before the create still counts as a real delete.
1431
1433
  let worst = pipesToShell ? "review" : "safe";
1432
1434
  for (const stage of stages) {
1433
- worst = maxTier(worst, classifyBashCommand(stage, vars));
1435
+ worst = maxTier(worst, classifyBashCommand(stage, vars, sandboxEnforced));
1434
1436
  noteEphemeralEffects(stripHeredocBodies(stage), vars);
1435
1437
  }
1436
1438
  return worst;
@@ -1442,7 +1444,7 @@ function classifyBashCommand(command, ephemeralVars = new Set()) {
1442
1444
  // shell pass short-circuits to `safe` (e.g. an assignment-prefixed node -e).
1443
1445
  const sql = findSqlInCommand(intact);
1444
1446
  const sqlTier = sql ? classifySqlSeverity(sql) : "safe";
1445
- return maxTier(maxTier(sqlTier, pipesToShell ? "review" : "safe"), classifyStageShellEffects(stripped, ephemeralVars));
1447
+ return maxTier(maxTier(sqlTier, pipesToShell ? "review" : "safe"), classifyStageShellEffects(stripped, ephemeralVars, sandboxEnforced));
1446
1448
  }
1447
1449
  /**
1448
1450
  * Shell-effect classification of a SINGLE, already-body-stripped stage. No SQL
@@ -1451,10 +1453,269 @@ function classifyBashCommand(command, ephemeralVars = new Set()) {
1451
1453
  * A cloud CLI tier is a floor: it never lowers what the other detectors find
1452
1454
  * (`kubectl exec pod -- curl -X DELETE …` stays high_stakes).
1453
1455
  */
1454
- function classifyStageShellEffects(stage, ephemeralVars = new Set()) {
1455
- return maxTier(classifyCloudCliStage(stage) ?? "safe", classifyStageEffects(stage, ephemeralVars));
1456
+ // Package-manager subcommands that do not run a package script. `yarn build`
1457
+ // and `pnpm build` do: those tools treat an unknown word as a script name.
1458
+ const PM_NON_SCRIPT = new Set([
1459
+ "access", "add", "adduser", "approve-builds", "audit", "bin", "bugs", "cache", "ci", "cit",
1460
+ "completion", "config", "create", "dedupe", "deploy", "deprecate", "diff", "dist-tag", "docs",
1461
+ "doctor", "env", "explain", "explore", "fetch", "find", "fund", "get", "help", "hook", "i",
1462
+ "import", "info", "init", "install", "install-ci-test", "install-test", "it", "licenses",
1463
+ "link", "list", "ll", "login", "logout", "ls", "node", "org", "outdated", "owner", "pack",
1464
+ "patch", "ping", "pkg", "prefix", "profile", "prune", "publish", "query", "rebuild", "repo",
1465
+ "root", "search", "set", "setup", "shrinkwrap", "star", "stars", "store", "team", "token",
1466
+ "uninstall", "unlink", "unplug", "unstar", "update", "upgrade", "up", "version", "view",
1467
+ "whoami", "why",
1468
+ ]);
1469
+ /**
1470
+ * A test runner, package script, script file, or package executor. The hook
1471
+ * sees the runner command, not the processes it starts (a `cargo test` can
1472
+ * run `rm` without a second tool call). Command position only: `echo cargo
1473
+ * test` and `git commit -m "npm test"` are not runners.
1474
+ */
1475
+ function isOpaqueCodeRunner(stage) {
1476
+ const words = stripRunnerPrefixes(withoutShellRedirects(splitArgs(stage)));
1477
+ if (words.length === 0)
1478
+ return false;
1479
+ const [cmd, ...args] = words;
1480
+ if (isDirectScript(cmd))
1481
+ return true;
1482
+ const base = commandBase(cmd);
1483
+ if (base === "source" || cmd === ".")
1484
+ return args.some((w) => w !== "--" && !w.startsWith("-"));
1485
+ if (base === "bash" || base === "sh" || base === "zsh" || base === "dash" || base === "ksh")
1486
+ return shellInvokesFile(args);
1487
+ if (base === "node" || base === "nodejs" || base === "tsx" || base === "deno")
1488
+ return nodeInvokesFile(args);
1489
+ if (base === "npx" || base === "bunx")
1490
+ return npxInvokes(args);
1491
+ if (base === "bun")
1492
+ return pmInvokes(base, args) || bunInvokesFile(args);
1493
+ if (base === "npm" || base === "pnpm" || base === "yarn")
1494
+ return pmInvokes(base, args);
1495
+ if (base === "pytest" || base === "py.test")
1496
+ return true;
1497
+ if (base === "python" || base === "python3" || /^python3\.\d+$/.test(base))
1498
+ return pythonInvokes(args);
1499
+ if (base === "cargo")
1500
+ return cargoInvokesTest(args);
1501
+ if (base === "go")
1502
+ return goInvokesTest(args);
1503
+ if (base === "make" || base === "gmake")
1504
+ return makeInvokes(args);
1505
+ return false;
1506
+ }
1507
+ function commandBase(cmd) {
1508
+ const slash = Math.max(cmd.lastIndexOf("/"), cmd.lastIndexOf("\\"));
1509
+ return slash >= 0 ? cmd.slice(slash + 1) : cmd;
1510
+ }
1511
+ function isDirectScript(cmd) {
1512
+ if (cmd.startsWith("./") || cmd.startsWith("../"))
1513
+ return true;
1514
+ return cmd.includes("/") && /\.(?:sh|bash|zsh|py|rb|pl|[cm]?js|[cm]?ts|mjs|cjs|mts|cts)$/i.test(cmd);
1515
+ }
1516
+ function withoutShellRedirects(words) {
1517
+ const out = [];
1518
+ for (let i = 0; i < words.length; i++) {
1519
+ const w = words[i];
1520
+ if (w === ">" || w === ">>" || w === "<" || w === "<<" || w === ">&" || w === "&>") {
1521
+ i++;
1522
+ continue;
1523
+ }
1524
+ if (/^(?:&>>?|\d*>&?\d*|\d*>>?|[<>])\S*$/.test(w))
1525
+ continue;
1526
+ out.push(w);
1527
+ }
1528
+ return out;
1529
+ }
1530
+ function stripRunnerPrefixes(words) {
1531
+ let i = 0;
1532
+ while (i < words.length && /^[A-Za-z_][A-Za-z0-9_]*=/.test(words[i]))
1533
+ i++;
1534
+ while (i < words.length && (words[i] === "command" || words[i] === "builtin"))
1535
+ i++;
1536
+ return words.slice(i);
1537
+ }
1538
+ function shellInvokesFile(args) {
1539
+ for (let i = 0; i < args.length; i++) {
1540
+ const w = args[i];
1541
+ if (w === "--")
1542
+ return Boolean(args[i + 1]);
1543
+ // `-c` / `-lc` is inline shell. classifyShellCStage already classified a
1544
+ // quoted body. `-n` checks syntax and does not run the file.
1545
+ if (w === "-c" || w === "--command" || /^-[^-]*c/.test(w))
1546
+ return false;
1547
+ if (w === "-n" || w === "--noexec" || /^-[^-]*n/.test(w))
1548
+ return false;
1549
+ if (w.startsWith("-"))
1550
+ continue;
1551
+ return true;
1552
+ }
1553
+ return false;
1554
+ }
1555
+ function nodeInvokesFile(args) {
1556
+ const argTaking = new Set(["-r", "--require", "--import", "--loader", "--experimental-loader", "-C", "--conditions"]);
1557
+ for (let i = 0; i < args.length; i++) {
1558
+ const w = args[i];
1559
+ if (w === "--")
1560
+ return Boolean(args[i + 1]);
1561
+ if (w === "-e" || w === "--eval" || w === "-p" || w === "--print" || w === "-c" || w === "--check")
1562
+ return false;
1563
+ if (w.startsWith("--eval=") || w.startsWith("--print="))
1564
+ return false;
1565
+ if (w === "--test" || w.startsWith("--test"))
1566
+ return true;
1567
+ if (w.startsWith("-")) {
1568
+ if (argTaking.has(w) && !w.includes("="))
1569
+ i++;
1570
+ continue;
1571
+ }
1572
+ return true;
1573
+ }
1574
+ return false;
1575
+ }
1576
+ function npxInvokes(args) {
1577
+ const argTaking = new Set(["-p", "--package", "-c", "--call", "--npm", "--node-options"]);
1578
+ for (let i = 0; i < args.length; i++) {
1579
+ const w = args[i];
1580
+ if (w === "--")
1581
+ return Boolean(args[i + 1]);
1582
+ if (w === "-v" || w === "--version" || w === "-h" || w === "--help")
1583
+ return false;
1584
+ if (w.startsWith("-")) {
1585
+ if ((argTaking.has(w) || w.startsWith("--package=") || w.startsWith("--call=")) && !w.includes("="))
1586
+ i++;
1587
+ continue;
1588
+ }
1589
+ return true;
1590
+ }
1591
+ return false;
1456
1592
  }
1457
- function classifyStageEffects(stage, ephemeralVars) {
1593
+ function pmPositionals(args) {
1594
+ const skip = new Set(["--prefix", "-C", "--dir", "--workspace", "-w", "--filter", "--cwd"]);
1595
+ const out = [];
1596
+ for (let i = 0; i < args.length; i++) {
1597
+ const w = args[i];
1598
+ if (w === "--")
1599
+ break;
1600
+ if (w.startsWith("-")) {
1601
+ if (skip.has(w))
1602
+ i++;
1603
+ continue;
1604
+ }
1605
+ out.push(w);
1606
+ }
1607
+ return out;
1608
+ }
1609
+ function bunInvokesFile(args) {
1610
+ const file = pmPositionals(args)[0];
1611
+ if (!file)
1612
+ return false;
1613
+ return file.startsWith("./") || file.startsWith("../") || file.includes("/") || /\.(?:[cm]?[jt]sx?|mjs|cjs)$/i.test(file);
1614
+ }
1615
+ function pmInvokes(pm, args) {
1616
+ const pos = pmPositionals(args);
1617
+ const sub = pos[0];
1618
+ if (!sub)
1619
+ return false;
1620
+ if (sub === "test" || sub === "t" || sub === "tst" || sub === "start" || sub === "stop" || sub === "restart")
1621
+ return true;
1622
+ if ((sub === "run" || sub === "run-script") && pos[1])
1623
+ return true;
1624
+ if ((sub === "exec" || sub === "dlx") && pos[1])
1625
+ return true;
1626
+ // yarn and pnpm run a package script named by the first word (`yarn build`).
1627
+ if ((pm === "yarn" || pm === "pnpm") && !PM_NON_SCRIPT.has(sub))
1628
+ return true;
1629
+ return false;
1630
+ }
1631
+ function pythonInvokes(args) {
1632
+ const takes = new Set(["-W", "-X"]);
1633
+ for (let i = 0; i < args.length; i++) {
1634
+ const w = args[i];
1635
+ if (w === "-c" || w === "--command")
1636
+ return false;
1637
+ if (w === "-m" || w === "--module") {
1638
+ const mod = args[i + 1];
1639
+ return mod === "pytest" || mod === "unittest";
1640
+ }
1641
+ if (w.startsWith("-")) {
1642
+ if (takes.has(w))
1643
+ i++;
1644
+ continue;
1645
+ }
1646
+ return true;
1647
+ }
1648
+ return false;
1649
+ }
1650
+ function cargoInvokesTest(args) {
1651
+ let i = 0;
1652
+ if (args[0]?.startsWith("+"))
1653
+ i++;
1654
+ const takes = new Set([
1655
+ "--manifest-path", "--target", "--target-dir", "--config", "-Z", "--color",
1656
+ "--features", "-F", "--package", "-p", "--exclude", "--bin", "--example", "--test", "--bench",
1657
+ ]);
1658
+ for (; i < args.length; i++) {
1659
+ const w = args[i];
1660
+ if (w.startsWith("-")) {
1661
+ if (takes.has(w) && !w.includes("="))
1662
+ i++;
1663
+ continue;
1664
+ }
1665
+ return w === "test";
1666
+ }
1667
+ return false;
1668
+ }
1669
+ function goInvokesTest(args) {
1670
+ const takes = new Set(["-C", "-o", "-p"]);
1671
+ for (let i = 0; i < args.length; i++) {
1672
+ const w = args[i];
1673
+ if (w.startsWith("-")) {
1674
+ if ((takes.has(w) || w === "-ldflags" || w === "-gcflags") && !w.includes("="))
1675
+ i++;
1676
+ continue;
1677
+ }
1678
+ return w === "test";
1679
+ }
1680
+ return false;
1681
+ }
1682
+ function makeInvokes(args) {
1683
+ let dry = false;
1684
+ let help = false;
1685
+ const positionals = [];
1686
+ const takes = new Set([
1687
+ "-C", "--directory", "-f", "--file", "--makefile", "-I", "--include-dir",
1688
+ "-o", "--old-file", "-W", "--what-if", "--assume-new", "--eval",
1689
+ ]);
1690
+ for (let i = 0; i < args.length; i++) {
1691
+ const w = args[i];
1692
+ if (w === "-n" || w === "--dry-run" || w === "--just-print" || w === "--recon") {
1693
+ dry = true;
1694
+ continue;
1695
+ }
1696
+ if (w === "--version" || w === "-v" || w === "--help" || w === "-h") {
1697
+ help = true;
1698
+ continue;
1699
+ }
1700
+ if (w.startsWith("-")) {
1701
+ if (/^-[^-]*n/.test(w))
1702
+ dry = true;
1703
+ if (takes.has(w))
1704
+ i++;
1705
+ continue;
1706
+ }
1707
+ positionals.push(w);
1708
+ }
1709
+ if (dry)
1710
+ return false;
1711
+ if (help && positionals.length === 0)
1712
+ return false;
1713
+ return true;
1714
+ }
1715
+ function classifyStageShellEffects(stage, ephemeralVars = new Set(), sandboxEnforced) {
1716
+ return maxTier(classifyCloudCliStage(stage) ?? "safe", classifyStageEffects(stage, ephemeralVars, sandboxEnforced));
1717
+ }
1718
+ function classifyStageEffects(stage, ephemeralVars, sandboxEnforced) {
1458
1719
  // File deletion in COMMAND POSITION, per-stage so the ephemeral-temp carve-out
1459
1720
  // can win: deleting only throwaway temp files (/tmp, $TMPDIR, /var/folders, …)
1460
1721
  // → warning; any non-temp target (or the temp root itself) → high_stakes.
@@ -1464,7 +1725,7 @@ function classifyStageEffects(stage, ephemeralVars) {
1464
1725
  return "warning";
1465
1726
  // `git -C repo …` / `git -c k=v …`: classify the subcommand without the
1466
1727
  // global options, so the git patterns below and in the full scan apply.
1467
- const gitTier = classifyGitGlobalOptsStage(stage, ephemeralVars);
1728
+ const gitTier = classifyGitGlobalOptsStage(stage, ephemeralVars, sandboxEnforced);
1468
1729
  if (gitTier !== null)
1469
1730
  return gitTier;
1470
1731
  if (isBuildOutputOnlyDeletion(stage.replace(DELETE_LEAD, "")))
@@ -1524,19 +1785,19 @@ function classifyStageEffects(stage, ephemeralVars) {
1524
1785
  // / capture). Classify the command-substitution inners and any trailing
1525
1786
  // command; a purely literal assignment is safe. Dangerous substitutions were
1526
1787
  // already caught by the high-stakes/delete scans above.
1527
- const assignTier = classifyAssignmentStage(stage);
1788
+ const assignTier = classifyAssignmentStage(stage, sandboxEnforced);
1528
1789
  if (assignTier !== null)
1529
1790
  return assignTier;
1530
1791
  // `env [opts] [NAME=VAL]... cmd` runs cmd with a modified environment. Strip
1531
1792
  // the env prefix and classify the inner command (a dangerous inner was already
1532
1793
  // caught by the high-stakes full scan). Bare `env` just prints the env → safe.
1533
- const envTier = classifyEnvStage(stage);
1794
+ const envTier = classifyEnvStage(stage, sandboxEnforced);
1534
1795
  if (envTier !== null)
1535
1796
  return envTier;
1536
1797
  // ssh is a transport — classify the remote command it runs (interactive /
1537
1798
  // port-forwarding ssh has no inspectable command → review floor). scp/rsync
1538
1799
  // to a remote are file transfers and stay high_stakes (HIGH_STAKES_STAGE).
1539
- const sshTier = classifySshStage(stage);
1800
+ const sshTier = classifySshStage(stage, sandboxEnforced);
1540
1801
  if (sshTier !== null)
1541
1802
  return sshTier;
1542
1803
  // `sh -c '<shell>'` / `bash -c "<shell>"` runs the quoted argument AS shell —
@@ -1544,7 +1805,7 @@ function classifyStageEffects(stage, ephemeralVars) {
1544
1805
  // is why the command-position delete scan above can ignore quoted text: a real
1545
1806
  // shell-out like `bash -c 'rm -rf /important'` is caught HERE, by re-running
1546
1807
  // the body as a command, while `echo 'rm …'` (data) is not.
1547
- const shellCTier = classifyShellCStage(stage);
1808
+ const shellCTier = classifyShellCStage(stage, sandboxEnforced);
1548
1809
  if (shellCTier !== null)
1549
1810
  return shellCTier;
1550
1811
  // sudo: privilege escalation. A high-stakes inner command was already caught
@@ -1576,6 +1837,12 @@ function classifyStageEffects(stage, ephemeralVars) {
1576
1837
  }
1577
1838
  // Default: safe. No destructive/outward/sensitive effect was detected, so we
1578
1839
  // do NOT put a human in the loop just for "running a command".
1840
+ // Exception: an opaque runner (test runner, package script, script file, npx)
1841
+ // hides child processes from this hook. When the host sandbox is not
1842
+ // enforcing containment, that asks for review. A higher tier above already
1843
+ // returned. Other hosts leave sandboxEnforced unset and stay safe.
1844
+ if (sandboxEnforced === false && isOpaqueCodeRunner(stage))
1845
+ return "review";
1579
1846
  return "safe";
1580
1847
  }
1581
1848
  function classifySqlSeverity(sql) {
@@ -1728,13 +1995,13 @@ export function blankTextCommandArgs(command) {
1728
1995
  .join("\n");
1729
1996
  }
1730
1997
  // Interpreters whose inline `-e`/`-c`/`--eval` (and perl/deno one-liner) body is
1731
- // opaque CODE — not shell. We blank that body before the SHELL-pattern scans so
1998
+ // opaque CODE, not shell. We blank that body before the SHELL-pattern scans so
1732
1999
  // tokens embedded as code or data (`rm`, `curl -d`, a `>` redirect) don't trip a
1733
- // destructive/outward rule. This matches the documented policy that opaque code
1734
- // execution is `safe` (see the WARNING_COMMANDS note): we can't tell what a
1735
- // `node -e`/`python -c` body does, and a real destructive shell effect buried
1736
- // inside it would slip through the label regardless — so scanning the body for
1737
- // shell tokens only manufactures false positives.
2000
+ // destructive/outward rule. Inline interpreter bodies stay unscanned as shell
2001
+ // (see the WARNING_COMMANDS note): we can't tell what a `node -e`/`python -c`
2002
+ // body does, and scanning it for shell tokens only manufactures false positives.
2003
+ // A test runner or a script file is different: its body is not in the command
2004
+ // at all. Those ask for review when sandboxEnforced is false.
1738
2005
  //
1739
2006
  // NOTE: SQL is the deliberate exception. classifyBashCommand still runs SQL
1740
2007
  // detection on the body-INTACT view, so inline SQL in a `node -e`/`python -c`
@@ -2165,6 +2432,12 @@ function classifyMcpTool(toolName, toolInput = {}) {
2165
2432
  // but each push is gated on its own. Log it, no prompt.
2166
2433
  if (parts.includes("ccd_pr") && tool === "set_monitor")
2167
2434
  return "warning";
2435
+ // The PR bar's auto-merge switch. On, GitHub merges the PR when checks pass
2436
+ // and no other card comes, the same as `gh pr merge --auto`. Off only stops
2437
+ // a merge that has not happened yet: log it, no prompt.
2438
+ if (parts.includes("ccd_pr") && tool === "set_auto_merge") {
2439
+ return toolInput.enabled === false ? "warning" : "high_stakes";
2440
+ }
2168
2441
  // Start a new local Claude session, or move this task into one. Its own tool
2169
2442
  // calls are gated by OKed like this one's, so log it, no prompt. A cloud or
2170
2443
  // SSH session runs outside this machine's hook, so it stays `review`.
@@ -18,6 +18,8 @@ export interface Rendered {
18
18
  link?: string;
19
19
  kind: OperationKind;
20
20
  }
21
+ /** Shown when an opaque runner asks for review because the sandbox is off. */
22
+ export declare const OPAQUE_RUNNER_FOOTNOTE = "OKed cannot see the commands inside this run. Enable Claude Code's Bash sandbox and set allowUnsandboxedCommands to false to allow these without a prompt.";
21
23
  /** Optional caller context. `cwd` lets describers read local files (e.g. the
22
24
  * package.json behind `npm publish`) to show what an action will touch. */
23
25
  export interface DescribeContext {
@@ -25,6 +27,11 @@ export interface DescribeContext {
25
27
  /** Title of the PR the card links to, when the command does not say it.
26
28
  * `lookupPrTitle()` gets it from GitHub. */
27
29
  prTitle?: string;
30
+ /**
31
+ * `false` when the host sandbox is not enforcing containment. An opaque
32
+ * runner then gets a footnote explaining how to skip the prompt.
33
+ */
34
+ sandboxEnforced?: boolean;
28
35
  }
29
36
  export declare function describe(toolName: string, toolInput: Record<string, unknown>, ctx?: DescribeContext): string;
30
37
  export declare function describeFields(toolName: string, toolInput: Record<string, unknown>, ctx?: DescribeContext): Record<string, string> | null;
package/dist/describe.js CHANGED
@@ -15,6 +15,8 @@ import { TIER_ORDER } from "./degraded.js";
15
15
  const BODY_PREVIEW_MAX = 200;
16
16
  const COMMAND_INLINE_MAX = 50;
17
17
  const DIFF_HUNK_MAX_LINES = 10;
18
+ /** Shown when an opaque runner asks for review because the sandbox is off. */
19
+ export const OPAQUE_RUNNER_FOOTNOTE = "OKed cannot see the commands inside this run. Enable Claude Code's Bash sandbox and set allowUnsandboxedCommands to false to allow these without a prompt.";
18
20
  export function describe(toolName, toolInput, ctx = {}) {
19
21
  // Single-line consumers (audit logs, SMS) get title + target inlined.
20
22
  const r = summarize(toolName, toolInput, ctx);
@@ -54,7 +56,17 @@ export function describeFields(toolName, toolInput, ctx = {}) {
54
56
  // ───────────────────────────────────────────────────────────────────────
55
57
  function summarize(toolName, toolInput, ctx) {
56
58
  const r = summarizeTool(toolName, toolInput, ctx);
57
- return ctx.prTitle ? namePr(r, ctx.prTitle) : r;
59
+ const named = ctx.prTitle ? namePr(r, ctx.prTitle) : r;
60
+ if (ctx.sandboxEnforced !== false || named.footnote)
61
+ return named;
62
+ // The runner is the reason for the card: the same call is safe when the
63
+ // sandbox flag is omitted. A higher effect (rm, a force push) keeps its
64
+ // own text.
65
+ const plain = classify(toolName, toolInput);
66
+ const gated = classify(toolName, toolInput, { sandboxEnforced: false });
67
+ if (plain === "safe" && gated === "review")
68
+ return { ...named, footnote: OPAQUE_RUNNER_FOOTNOTE };
69
+ return named;
58
70
  }
59
71
  /**
60
72
  * "Merge PR #49 in o/r" says which PR, not what it does. Put the PR title after
@@ -73,7 +85,7 @@ function summarizeTool(toolName, toolInput, ctx) {
73
85
  const fileSizeBytes = typeof toolInput._file_size_bytes === "number" ? toolInput._file_size_bytes : undefined;
74
86
  switch (toolName) {
75
87
  case "Bash":
76
- return summarizeBash(toolInput.command || "", fileSizeBytes, ctx.cwd);
88
+ return summarizeBash(toolInput.command || "", fileSizeBytes, ctx.cwd, ctx.sandboxEnforced);
77
89
  case "Write":
78
90
  return summarizeWrite(toolInput);
79
91
  case "Edit":
@@ -96,7 +108,7 @@ function summarizeTool(toolName, toolInput, ctx) {
96
108
  // Shell-exec wrappers: signature is a string command/cmd field
97
109
  const shellCommand = (toolInput.command ?? toolInput.cmd);
98
110
  if (typeof shellCommand === "string") {
99
- return summarizeBash(shellCommand, fileSizeBytes);
111
+ return summarizeBash(shellCommand, fileSizeBytes, undefined, ctx.sandboxEnforced);
100
112
  }
101
113
  // File-write wrappers: signature is a path + content/data string
102
114
  const writePath = (toolInput.file_path ?? toolInput.path);
@@ -192,11 +204,11 @@ function extractCurlPayload(cmd) {
192
204
  const parts = [data.join("&"), json.join(""), form.join("\n")].filter(Boolean);
193
205
  return parts.length ? parts.join("\n") : undefined;
194
206
  }
195
- function summarizeBash(command, sizeBytes, cwd) {
207
+ function summarizeBash(command, sizeBytes, cwd, sandboxEnforced) {
196
208
  let cmd = (command || "").trim();
197
209
  if (!cmd)
198
210
  return { title: "Run empty command", kind: "unknown_bash" };
199
- const compound = summarizeCompoundBash(cmd, sizeBytes, cwd);
211
+ const compound = summarizeCompoundBash(cmd, sizeBytes, cwd, sandboxEnforced);
200
212
  if (compound)
201
213
  return compound;
202
214
  // SQL detection runs before shell-write detection so that inline-interpreter
@@ -458,17 +470,18 @@ function summarizeBash(command, sizeBytes, cwd) {
458
470
  * from a pattern that spans steps (`curl … | sh`): the whole-command rules
459
471
  * below describe those.
460
472
  */
461
- function summarizeCompoundBash(cmd, sizeBytes, cwd) {
473
+ function summarizeCompoundBash(cmd, sizeBytes, cwd, sandboxEnforced) {
462
474
  const steps = splitTopLevel(cmd, { pipes: false });
463
475
  if (steps.length < 2)
464
476
  return null;
465
477
  // Each step sees what earlier steps made (a temp file a later `rm` deletes),
466
478
  // as the whole command does. Alone, that `rm` would outrank the real step.
467
- const rank = classifyBashSteps(steps).map((t) => TIER_ORDER[t]);
479
+ const rank = classifyBashSteps(steps, sandboxEnforced).map((t) => TIER_ORDER[t]);
468
480
  const top = Math.max(...rank);
469
481
  if (top < TIER_ORDER.review)
470
482
  return null;
471
- if (TIER_ORDER[classify("Bash", { command: cmd })] !== top)
483
+ const whole = classify("Bash", { command: cmd }, sandboxEnforced === undefined ? undefined : { sandboxEnforced });
484
+ if (TIER_ORDER[whole] !== top)
472
485
  return null;
473
486
  const lead = rank.indexOf(top);
474
487
  // Variables set by earlier steps (`D=/dir; rm $D/x`) show as their values.
@@ -1362,6 +1375,25 @@ function summarizeDesktopApp(server, tool, input) {
1362
1375
  };
1363
1376
  }
1364
1377
  }
1378
+ if (server === "ccd_pr" && tool === "set_auto_merge") {
1379
+ // Same card as `gh pr merge --auto`: the PR, the method, and when it merges.
1380
+ const pr = str(input.url)?.match(/^https:\/\/github\.com\/([^/\s]+\/[^/\s]+)\/pull\/(\d+)/);
1381
+ const where = pr ? `PR #${pr[2]} in ${pr[1]}` : "PR";
1382
+ const link = pr ? `https://github.com/${pr[1]}/pull/${pr[2]}` : undefined;
1383
+ if (input.enabled === false) {
1384
+ return { title: `Turn off auto-merge for ${where}`, link, kind: "git_pr_write" };
1385
+ }
1386
+ return {
1387
+ title: `Merge ${where}`,
1388
+ annotation: [str(input.merge_method), "when checks pass"].filter(Boolean).join(", "),
1389
+ link,
1390
+ kind: "git_pr_merge",
1391
+ };
1392
+ }
1393
+ if (server === "ccd_session_mgmt" && tool === "send_message") {
1394
+ const message = str(input.message);
1395
+ return { title: "Send a message to another Claude session", body: message ? truncateBody(message) : undefined, kind: "agent_message" };
1396
+ }
1365
1397
  if (server === "ccd_turn" && tool === "update_plan") {
1366
1398
  return { title: "Update the task list in the Claude app", kind: "session_housekeeping" };
1367
1399
  }
package/dist/index.d.ts CHANGED
@@ -46,8 +46,9 @@ export { checkReceipt, keysFor, keysUrlAllowed, OKED_RECEIPT_KEYS_URL } from "./
46
46
  export { PINNED_RECEIPT_KEYS } from "./receipt-keys.js";
47
47
  export { verifyReceipt, verifyChain, shortReceiptId, type SignedReceipt, type ReceiptBody, type ReceiptKey, } from "@oked/receipt-core";
48
48
  export { TIER_ORDER, degradedDecision } from "./degraded.js";
49
- export { classify } from "./classify.js";
50
- export { describe, describeFields } from "./describe.js";
49
+ export { classify, splitTopLevel, type ClassifyOptions } from "./classify.js";
50
+ export { describe, describeFields, OPAQUE_RUNNER_FOOTNOTE } from "./describe.js";
51
+ export type { DescribeContext } from "./describe.js";
51
52
  export { lookupPrTitle } from "./pr-title.js";
52
53
  export { applyRules } from "./rules.js";
53
54
  export type { Rule, RuleMatch, RuleAction, RuleDecision, FieldOp, } from "./rules.js";
package/dist/index.js CHANGED
@@ -397,8 +397,8 @@ export { checkReceipt, keysFor, keysUrlAllowed, OKED_RECEIPT_KEYS_URL } from "./
397
397
  export { PINNED_RECEIPT_KEYS } from "./receipt-keys.js";
398
398
  export { verifyReceipt, verifyChain, shortReceiptId, } from "@oked/receipt-core";
399
399
  export { TIER_ORDER, degradedDecision } from "./degraded.js";
400
- export { classify } from "./classify.js";
401
- export { describe, describeFields } from "./describe.js";
400
+ export { classify, splitTopLevel } from "./classify.js";
401
+ export { describe, describeFields, OPAQUE_RUNNER_FOOTNOTE } from "./describe.js";
402
402
  export { lookupPrTitle } from "./pr-title.js";
403
403
  export { applyRules } from "./rules.js";
404
404
  export { CLASSIFIER_VERSION } from "./kinds.js";
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@oked/sdk",
3
- "version": "0.6.21",
3
+ "version": "0.6.22",
4
4
  "description": "OKed SDK - human approval layer for AI agents",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -45,11 +45,11 @@
45
45
  "access": "public"
46
46
  },
47
47
  "dependencies": {
48
- "@oked/receipt-core": "0.6.21"
48
+ "@oked/receipt-core": "0.6.22"
49
49
  },
50
50
  "devDependencies": {
51
- "@types/node": "^22.13.10",
52
- "tsx": "^4.22.0",
53
- "typescript": "^5.6.0"
51
+ "@types/node": "^26.6.5",
52
+ "tsx": "^4.23.15",
53
+ "typescript": "^7.0.2"
54
54
  }
55
55
  }