@chibitek/chibi 0.1.197 → 0.1.199
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/assets/{TerminalPanel--bJ8KdIX.js → TerminalPanel-BD8tgP0L.js} +1 -1
- package/dist/assets/{abnfDiagram-O67JEVCF-B9FTFZ6n.js → abnfDiagram-O67JEVCF-nJPyKFj_.js} +1 -1
- package/dist/assets/{arc-CVbauXMY.js → arc-B27uNTWr.js} +1 -1
- package/dist/assets/{architectureDiagram-NJMV4G6O-R_L6cEaF.js → architectureDiagram-NJMV4G6O-1g_zkN0g.js} +1 -1
- package/dist/assets/{blockDiagram-BEXU5L5S-BXc2RYLr.js → blockDiagram-BEXU5L5S-B94wHtES.js} +1 -1
- package/dist/assets/{c4Diagram-YGBWAQC7-Bii05url.js → c4Diagram-YGBWAQC7-BURkZEQS.js} +1 -1
- package/dist/assets/channel-BBCt_i2t.js +1 -0
- package/dist/assets/{chunk-2Q5K7J3B-YimysqOo.js → chunk-2Q5K7J3B-CwYChOa9.js} +1 -1
- package/dist/assets/{chunk-3FUC2YCW-CrHKZRq7.js → chunk-3FUC2YCW-D2NA_sYk.js} +2 -2
- package/dist/assets/{chunk-5VM5RSS4-3y2fUHet.js → chunk-5VM5RSS4-7v_eBXTK.js} +1 -1
- package/dist/assets/{chunk-GTNCS2PH-YSoI0G8B.js → chunk-GTNCS2PH-Ck73ze4k.js} +1 -1
- package/dist/assets/{chunk-GWA4HPMP-DsIbENvB.js → chunk-GWA4HPMP-BsOQoPsv.js} +1 -1
- package/dist/assets/{chunk-JWPE2WC7-6s37yBqm.js → chunk-JWPE2WC7-DjQCd7nq.js} +1 -1
- package/dist/assets/{chunk-NETBCI7D-ezv6I2Jw.js → chunk-NETBCI7D-jsNR61zL.js} +1 -1
- package/dist/assets/{chunk-WEXAMYUT-BYg3YNuR.js → chunk-WEXAMYUT-iYv-JXOK.js} +1 -1
- package/dist/assets/{chunk-XXDRQBXY-ia5t27ll.js → chunk-XXDRQBXY-6hDTxNh3.js} +1 -1
- package/dist/assets/{classDiagram-v2-NBCMYWYE-CjKSkyGp.js → classDiagram-v2-NBCMYWYE-CqYfoIdc.js} +1 -1
- package/dist/assets/{cose-bilkent-JH36ORCC-CG8y2L2j.js → cose-bilkent-JH36ORCC-BFoBUYoI.js} +1 -1
- package/dist/assets/{cynefin-OW5HDTMX-DZkEKzBB.js → cynefin-OW5HDTMX-C8beDmoE.js} +1 -1
- package/dist/assets/{cynefinDiagram-VND7K2PF-DnowKsJ-.js → cynefinDiagram-VND7K2PF-B14Y6q3s.js} +1 -1
- package/dist/assets/{dagre-6A5THRUB-CMtfQGlI.js → dagre-6A5THRUB-Bxfl4ARR.js} +1 -1
- package/dist/assets/{diagram-22UHCM2B-Bk94047z.js → diagram-22UHCM2B-C0Y9Gxes.js} +1 -1
- package/dist/assets/{diagram-3UASUU5V-Ui5qVUoC.js → diagram-3UASUU5V-CT665UIR.js} +1 -1
- package/dist/assets/{diagram-ATOU4E4O-C2yF8mt5.js → diagram-ATOU4E4O-DGXaVJI8.js} +1 -1
- package/dist/assets/{diagram-CDSNMT55-Csj1m-Qs.js → diagram-CDSNMT55-B-k11v8T.js} +1 -1
- package/dist/assets/{diagram-MLGK6HIB-W3uwKf9S.js → diagram-MLGK6HIB-DQd_tGlF.js} +1 -1
- package/dist/assets/{diagram-MPIPVDR6-CrF8_LWl.js → diagram-MPIPVDR6-CookmvAU.js} +1 -1
- package/dist/assets/{ebnfDiagram-ZINNZB2B-FG0V0Pck.js → ebnfDiagram-ZINNZB2B-koVtdZMh.js} +1 -1
- package/dist/assets/{elk-276RUBZZ-BnptZiPT.js → elk-276RUBZZ-CCULrKTu.js} +1 -1
- package/dist/assets/{erDiagram-OPXOYQCR-DQ9QNt66.js → erDiagram-OPXOYQCR-7tX_DN1F.js} +1 -1
- package/dist/assets/{flowDiagram-KWPJA3E3-BSQCaJJS.js → flowDiagram-KWPJA3E3-BP9lx54W.js} +1 -1
- package/dist/assets/{ganttDiagram-FUAMR5RP-DNhPCPBz.js → ganttDiagram-FUAMR5RP-DrD3pdCf.js} +1 -1
- package/dist/assets/{gitGraphDiagram-X574FWY7-Bwziujo8.js → gitGraphDiagram-X574FWY7-CGoBra5o.js} +1 -1
- package/dist/assets/{index-kIcmWTVM.js → index-0ryDWs_U.js} +1 -1
- package/dist/assets/{index-C1MRa2jb.js → index-DUPDb_l5.js} +189 -189
- package/dist/assets/{infoDiagram-VRGFBTTK-BoeGC6R0.js → infoDiagram-VRGFBTTK-TBE6eo6e.js} +1 -1
- package/dist/assets/{ishikawaDiagram-OU5B5YK6-MqJALuN6.js → ishikawaDiagram-OU5B5YK6-CXFR0VYe.js} +1 -1
- package/dist/assets/{journeyDiagram-ZHPQQLJL-CDmYfmBD.js → journeyDiagram-ZHPQQLJL-0i24WNpp.js} +1 -1
- package/dist/assets/{kanban-definition-PNTS6WVX-BncCNuev.js → kanban-definition-PNTS6WVX-BVO7zH5N.js} +1 -1
- package/dist/assets/{linear-D7y9LlCy.js → linear-CJa9b6Jv.js} +1 -1
- package/dist/assets/{mermaid.core-C-8HBWdK.js → mermaid.core-Cr_zJcfI.js} +5 -5
- package/dist/assets/{mindmap-definition-NLK3R4M7-CVY8yI8k.js → mindmap-definition-NLK3R4M7-DGOtBRni.js} +1 -1
- package/dist/assets/{pegDiagram-GJSIUBJH-RAHytJwr.js → pegDiagram-GJSIUBJH-a4X1U2M6.js} +1 -1
- package/dist/assets/{pieDiagram-5QR66LMP-DVdUiz7U.js → pieDiagram-5QR66LMP-C6YKVkOM.js} +1 -1
- package/dist/assets/{quadrantDiagram-O4NWA36T-BgrtWShT.js → quadrantDiagram-O4NWA36T-tthWiJZV.js} +1 -1
- package/dist/assets/{railroadDiagram-XR7U4H2S-DipM2y3J.js → railroadDiagram-XR7U4H2S-BaCi4bjC.js} +1 -1
- package/dist/assets/{requirementDiagram-PLB6GJNP-hS3TxvWM.js → requirementDiagram-PLB6GJNP-B1gkcVzT.js} +1 -1
- package/dist/assets/{sankeyDiagram-IPEJSGJF-BC280MpB.js → sankeyDiagram-IPEJSGJF-Q6NzlkZ1.js} +1 -1
- package/dist/assets/{sequenceDiagram-PO4LG4MO-ewNIiNrD.js → sequenceDiagram-PO4LG4MO-DXkHQxwi.js} +1 -1
- package/dist/assets/{sizeCapture-INFHLROL-MhMinfv2.js → sizeCapture-INFHLROL-DFiBxWwr.js} +1 -1
- package/dist/assets/{stateDiagram-v2-GCMORJYK-BDlA_ZR7.js → stateDiagram-v2-GCMORJYK-CWi-jeEW.js} +1 -1
- package/dist/assets/{swimlanes-2SLR337P-H8P8RCKC.js → swimlanes-2SLR337P-DEMqxNj4.js} +1 -1
- package/dist/assets/swimlanesDiagram-TC7HE7FX-BebBq0sX.js +8 -0
- package/dist/assets/{timeline-definition-EJHVYXUP-DMyIeQ7T.js → timeline-definition-EJHVYXUP-CutULAnt.js} +1 -1
- package/dist/assets/{usecaseDiagram-POWQR4AR-DRvphcF6.js → usecaseDiagram-POWQR4AR-Dbvwnx98.js} +1 -1
- package/dist/assets/{vennDiagram-UO4OBE2U-m4Q4kbA5.js → vennDiagram-UO4OBE2U-HSO7dMBn.js} +1 -1
- package/dist/assets/{wardleyDiagram-VNRHLVJA-CeX5n3Zi.js → wardleyDiagram-VNRHLVJA-ShLPdgOQ.js} +1 -1
- package/dist/assets/{xychartDiagram-PMCCYNJV-CpJZkSHf.js → xychartDiagram-PMCCYNJV-DCdsZ7i5.js} +1 -1
- package/dist/index.html +1 -1
- package/dist-server/companion/src/routes.js +13 -5
- package/dist-server/container-mcp.js +4 -4
- package/dist-server/index.js +273 -265
- package/dist-server/openmausbot.js +77 -32
- package/dist-server/pair-cli.js +77 -32
- package/dist-server/server/approval-grants.js +1 -1
- package/dist-server/server/atomic-engine-release.js +9 -16
- package/dist-server/server/config.js +7 -7
- package/dist-server/server/drivers/claude.js +1 -19
- package/dist-server/server/drivers/session-allow-key.js +27 -0
- package/dist-server/server/index.js +1 -1
- package/dist-server/server/oauth-account-tools.js +1 -1
- package/dist-server/server/routes/accounts.js +1 -1
- package/dist-server/server/system-prompt.js +1 -1
- package/dist-server/shared/oauth-account-grants.js +4 -4
- package/dist-server/vps-container-mcp.js +4 -4
- package/package.json +1 -1
- package/dist/assets/channel-NejqmlD6.js +0 -1
- package/dist/assets/swimlanesDiagram-TC7HE7FX-0B8do8GC.js +0 -8
|
@@ -17941,7 +17941,7 @@ function saveConfig(patch, options = {}) {
|
|
|
17941
17941
|
const before = configSaveListeners.size ? structuredClone(disk) : disk;
|
|
17942
17942
|
const storedProfiles = storedBrowserProfilesSchema.safeParse(disk.browserProfiles);
|
|
17943
17943
|
if (storedProfiles.success) disk.browserProfiles = storedProfiles.data;
|
|
17944
|
-
for (const key of ["xai", "anthropic", "mistral", "ollamaCloud", "openaiCompat", "box", "opencodeGo", "tts", "imageGen", "profile", "icm", "nexusMemory", "paw", "rooms", "threads", "context", "localVm", "features", "addons", "budgets", "billing", "decisions", "onboarding", "browserEngine", "newBots"]) {
|
|
17944
|
+
for (const key of ["xai", "anthropic", "mistral", "ollamaCloud", "openaiCompat", "box", "opencodeGo", "tts", "imageGen", "profile", "icm", "nexusMemory", "paw", "rooms", "threads", "context", "localVm", "features", "addons", "budgets", "billing", "decisions", "onboarding", "browserEngine", "newBots", "oauthAccounts"]) {
|
|
17945
17945
|
const section = checkedPatch[key];
|
|
17946
17946
|
if (!section) continue;
|
|
17947
17947
|
const current = jsonObjectSchema.safeParse(disk[key]);
|
|
@@ -18539,10 +18539,10 @@ var init_config = __esm({
|
|
|
18539
18539
|
* outrank it. Written only through /api/hipaa, never a generic config patch. */
|
|
18540
18540
|
hipaa: external_exports.object({ enabled: external_exports.boolean().optional() }).optional(),
|
|
18541
18541
|
/** How company bots receive Google and Microsoft accounts connected under
|
|
18542
|
-
* Settings → Accounts.
|
|
18543
|
-
*
|
|
18544
|
-
*
|
|
18545
|
-
* touches how refresh tokens are stored. */
|
|
18542
|
+
* Settings → Accounts. Default is all-company-bots (Erick 2026-10-15):
|
|
18543
|
+
* every non-personal connected account works for every company bot, while
|
|
18544
|
+
* an explicit bot.accounts list still restricts. "opt-in" keeps the legacy
|
|
18545
|
+
* per-bot Access toggle. Never touches how refresh tokens are stored. */
|
|
18546
18546
|
oauthAccounts: external_exports.object({
|
|
18547
18547
|
botGrant: external_exports.enum(["opt-in", "all-company-bots"]).optional()
|
|
18548
18548
|
}).strict().optional(),
|
|
@@ -30322,6 +30322,56 @@ var init_boxagent = __esm({
|
|
|
30322
30322
|
}
|
|
30323
30323
|
});
|
|
30324
30324
|
|
|
30325
|
+
// server/approval-grants.ts
|
|
30326
|
+
function toolName(tool2) {
|
|
30327
|
+
return tool2.trim().replace(/^mcp__.+?__/i, "");
|
|
30328
|
+
}
|
|
30329
|
+
function bareTool(tool2) {
|
|
30330
|
+
return toolName(tool2).toLowerCase();
|
|
30331
|
+
}
|
|
30332
|
+
function collapse(text6) {
|
|
30333
|
+
return text6.trim().replace(/\s+/g, " ");
|
|
30334
|
+
}
|
|
30335
|
+
function isShellTool(tool2) {
|
|
30336
|
+
return SHELL_TOOL.test(bareTool(tool2));
|
|
30337
|
+
}
|
|
30338
|
+
function commandPrefix(summary) {
|
|
30339
|
+
const command = collapse(summary).replace(/^\$\s*/, "");
|
|
30340
|
+
if (!command || SHELL_META.test(command)) return null;
|
|
30341
|
+
const [program, sub] = command.split(" ");
|
|
30342
|
+
if (!program) return null;
|
|
30343
|
+
return sub && /^[a-z][\w-]*$/.test(sub) ? `${program} ${sub}` : program;
|
|
30344
|
+
}
|
|
30345
|
+
var ONCE_GRANT_TTL_MS, ALWAYS_GRANT_TTL_MS, SHELL_TOOL, SHELL_META;
|
|
30346
|
+
var init_approval_grants = __esm({
|
|
30347
|
+
"server/approval-grants.ts"() {
|
|
30348
|
+
"use strict";
|
|
30349
|
+
init_atomic();
|
|
30350
|
+
init_contracts();
|
|
30351
|
+
ONCE_GRANT_TTL_MS = 60 * 6e4;
|
|
30352
|
+
ALWAYS_GRANT_TTL_MS = 8 * 60 * 6e4;
|
|
30353
|
+
SHELL_TOOL = /(?:^|_)(?:bash|shell|sh|zsh|terminal|exec|exec_command|run_terminal_cmd|run_shell_command|local_shell|command|execute)$/i;
|
|
30354
|
+
SHELL_META = /[;&|`<>\n\r]|\$\(|\$\{/;
|
|
30355
|
+
}
|
|
30356
|
+
});
|
|
30357
|
+
|
|
30358
|
+
// server/drivers/session-allow-key.ts
|
|
30359
|
+
function sessionAllowKey(ask) {
|
|
30360
|
+
const tool2 = typeof ask.tool === "string" ? ask.tool.trim() : "";
|
|
30361
|
+
if (!tool2) return null;
|
|
30362
|
+
if (tool2.startsWith("mcp__")) return JSON.stringify(["tool", tool2]);
|
|
30363
|
+
const command = isShellTool(tool2) && typeof ask.input?.command === "string" ? commandPrefix(ask.input.command) : null;
|
|
30364
|
+
if (command) return JSON.stringify(["command", tool2, command]);
|
|
30365
|
+
const stable = (value) => Array.isArray(value) ? value.map(stable) : value && typeof value === "object" ? Object.fromEntries(Object.keys(value).sort().map((key) => [key, stable(value[key])])) : value;
|
|
30366
|
+
return JSON.stringify(["input", tool2, stable(ask.input ?? {})]);
|
|
30367
|
+
}
|
|
30368
|
+
var init_session_allow_key = __esm({
|
|
30369
|
+
"server/drivers/session-allow-key.ts"() {
|
|
30370
|
+
"use strict";
|
|
30371
|
+
init_approval_grants();
|
|
30372
|
+
}
|
|
30373
|
+
});
|
|
30374
|
+
|
|
30325
30375
|
// server/plan-policy.ts
|
|
30326
30376
|
function planToolAllowed(tool2) {
|
|
30327
30377
|
return typeof tool2 === "string" && PLAN_READ_TOOLS.includes(tool2);
|
|
@@ -31295,13 +31345,6 @@ function removePrivateTempDir(filePath) {
|
|
|
31295
31345
|
return false;
|
|
31296
31346
|
}
|
|
31297
31347
|
}
|
|
31298
|
-
function sessionAllowKey(ask) {
|
|
31299
|
-
const tool2 = typeof ask.tool === "string" ? ask.tool.trim() : "";
|
|
31300
|
-
if (!tool2) return null;
|
|
31301
|
-
if (tool2.startsWith("mcp__")) return JSON.stringify(["tool", tool2]);
|
|
31302
|
-
const stable = (value) => Array.isArray(value) ? value.map(stable) : value && typeof value === "object" ? Object.fromEntries(Object.keys(value).sort().map((key) => [key, stable(value[key])])) : value;
|
|
31303
|
-
return JSON.stringify(["input", tool2, stable(ask.input ?? {})]);
|
|
31304
|
-
}
|
|
31305
31348
|
function systemEndedReply(kind) {
|
|
31306
31349
|
return kind === "question" ? { behavior: "answer", message: "Atomic: the turn is ending \u2014 wrap up." } : { behavior: "deny", message: "Atomic: the turn ended" };
|
|
31307
31350
|
}
|
|
@@ -31560,6 +31603,7 @@ var CONNECTOR_CACHE_MS, CLAUDE_ACCOUNT_ENV_KEYS, DEFAULT_AUTOCOMPACT_TOKENS, CLA
|
|
|
31560
31603
|
var init_claude = __esm({
|
|
31561
31604
|
"server/drivers/claude.ts"() {
|
|
31562
31605
|
"use strict";
|
|
31606
|
+
init_session_allow_key();
|
|
31563
31607
|
init_plan_policy();
|
|
31564
31608
|
init_claude_message();
|
|
31565
31609
|
init_config();
|
|
@@ -50513,25 +50557,18 @@ var init_atomic_engine_release = __esm({
|
|
|
50513
50557
|
"use strict";
|
|
50514
50558
|
ASSETS = [
|
|
50515
50559
|
{
|
|
50516
|
-
version: "0.21.4-
|
|
50560
|
+
version: "0.21.4-68432dd",
|
|
50517
50561
|
platform: "darwin-arm64",
|
|
50518
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-
|
|
50519
|
-
bytes:
|
|
50520
|
-
sha512: "
|
|
50562
|
+
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-68432dd-darwin-arm64.tar.gz",
|
|
50563
|
+
bytes: 115629976,
|
|
50564
|
+
sha512: "b62d873aadd43655bd3f51af4027104a54462e74774182276783ba55d1824b05b193e839765cd5523b6f2bbe4fe3f47f780da32c2be94ac51b46d25f1fa3a83c"
|
|
50521
50565
|
},
|
|
50522
50566
|
{
|
|
50523
|
-
version: "0.21.4-
|
|
50567
|
+
version: "0.21.4-68432dd",
|
|
50524
50568
|
platform: "win32-x64",
|
|
50525
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-
|
|
50526
|
-
bytes:
|
|
50527
|
-
sha512: "
|
|
50528
|
-
},
|
|
50529
|
-
{
|
|
50530
|
-
version: "0.21.4-4cc340e",
|
|
50531
|
-
platform: "darwin-x64",
|
|
50532
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-4cc340e-darwin-x64.tar.gz",
|
|
50533
|
-
bytes: 92883251,
|
|
50534
|
-
sha512: "eec5fcbbcdbe44db76f938cb3dd98fedfc6c644cc054c75d0ad3daaf66e39f60dc6b75fa3f8cdbbc2cc3760a2ea7d3fc608a1cf7a42c4a020e6cd4d6dc823df0"
|
|
50569
|
+
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-68432dd-win32-x64.tar.gz",
|
|
50570
|
+
bytes: 103356325,
|
|
50571
|
+
sha512: "a2bb1c23194ca63168a855daee719a851d5213c79b6db083ca676b0aaff26ac55f0e2086e36395f86a677379e8cc0cf53113122b6695b841e12e3619857fc08c"
|
|
50535
50572
|
}
|
|
50536
50573
|
];
|
|
50537
50574
|
}
|
|
@@ -62235,13 +62272,21 @@ var ALLOWED = [
|
|
|
62235
62272
|
{ method: "GET", path: /^\/api\/threads\/[\w-]+\/export$/ },
|
|
62236
62273
|
{ method: "POST", path: /^\/api\/threads\/[\w-]+\/respond$/ },
|
|
62237
62274
|
{ method: "GET", path: /^\/api\/search$/ },
|
|
62238
|
-
// Team Rooms through the paired computer
|
|
62239
|
-
// Section 8): read
|
|
62240
|
-
//
|
|
62241
|
-
//
|
|
62275
|
+
// Team Rooms and Channels through the paired computer
|
|
62276
|
+
// (docs/chibitek/team-room-plan.md, Section 8): read, reply, keep the read
|
|
62277
|
+
// position, make a room or channel, invite links, join from a link, add or
|
|
62278
|
+
// remove bots, remove people, leave or close, save to Nexus. The computer's
|
|
62279
|
+
// Chibitek sign-in does every one of these and the server checks who may.
|
|
62280
|
+
// A bot's share settings stay on the computer, like the rest of a bot's
|
|
62281
|
+
// settings; approvals are the bot's own cards, answered through /respond.
|
|
62242
62282
|
{ method: "GET", path: /^\/api\/team-rooms$/ },
|
|
62283
|
+
{ method: "POST", path: /^\/api\/team-rooms$/ },
|
|
62284
|
+
{ method: "POST", path: /^\/api\/team-rooms\/join(?:\/preview)?$/ },
|
|
62285
|
+
{ method: "DELETE", path: /^\/api\/team-rooms\/(?:invites|bots)\/[0-9a-f-]{36}$/ },
|
|
62243
62286
|
{ method: "GET", path: /^\/api\/team-rooms\/[0-9a-f-]{36}$/ },
|
|
62244
|
-
{ method: "POST", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/(?:messages|read)$/ },
|
|
62287
|
+
{ method: "POST", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/(?:messages|read|archive|leave|invites|bots|save-to-nexus)$/ },
|
|
62288
|
+
{ method: "GET", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/invites$/ },
|
|
62289
|
+
{ method: "DELETE", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/members\/[0-9a-f-]{36}$/ },
|
|
62245
62290
|
// App-owned profile images. Upload is image-only and capped at 10 MB by
|
|
62246
62291
|
// the harness; GET is a single bare generated filename, never a path.
|
|
62247
62292
|
{ method: "POST", path: /^\/api\/attachments$/ },
|
package/dist-server/pair-cli.js
CHANGED
|
@@ -17941,7 +17941,7 @@ function saveConfig(patch, options = {}) {
|
|
|
17941
17941
|
const before = configSaveListeners.size ? structuredClone(disk) : disk;
|
|
17942
17942
|
const storedProfiles = storedBrowserProfilesSchema.safeParse(disk.browserProfiles);
|
|
17943
17943
|
if (storedProfiles.success) disk.browserProfiles = storedProfiles.data;
|
|
17944
|
-
for (const key of ["xai", "anthropic", "mistral", "ollamaCloud", "openaiCompat", "box", "opencodeGo", "tts", "imageGen", "profile", "icm", "nexusMemory", "paw", "rooms", "threads", "context", "localVm", "features", "addons", "budgets", "billing", "decisions", "onboarding", "browserEngine", "newBots"]) {
|
|
17944
|
+
for (const key of ["xai", "anthropic", "mistral", "ollamaCloud", "openaiCompat", "box", "opencodeGo", "tts", "imageGen", "profile", "icm", "nexusMemory", "paw", "rooms", "threads", "context", "localVm", "features", "addons", "budgets", "billing", "decisions", "onboarding", "browserEngine", "newBots", "oauthAccounts"]) {
|
|
17945
17945
|
const section = checkedPatch[key];
|
|
17946
17946
|
if (!section) continue;
|
|
17947
17947
|
const current = jsonObjectSchema.safeParse(disk[key]);
|
|
@@ -18539,10 +18539,10 @@ var init_config = __esm({
|
|
|
18539
18539
|
* outrank it. Written only through /api/hipaa, never a generic config patch. */
|
|
18540
18540
|
hipaa: external_exports.object({ enabled: external_exports.boolean().optional() }).optional(),
|
|
18541
18541
|
/** How company bots receive Google and Microsoft accounts connected under
|
|
18542
|
-
* Settings → Accounts.
|
|
18543
|
-
*
|
|
18544
|
-
*
|
|
18545
|
-
* touches how refresh tokens are stored. */
|
|
18542
|
+
* Settings → Accounts. Default is all-company-bots (Erick 2026-10-15):
|
|
18543
|
+
* every non-personal connected account works for every company bot, while
|
|
18544
|
+
* an explicit bot.accounts list still restricts. "opt-in" keeps the legacy
|
|
18545
|
+
* per-bot Access toggle. Never touches how refresh tokens are stored. */
|
|
18546
18546
|
oauthAccounts: external_exports.object({
|
|
18547
18547
|
botGrant: external_exports.enum(["opt-in", "all-company-bots"]).optional()
|
|
18548
18548
|
}).strict().optional(),
|
|
@@ -30322,6 +30322,56 @@ var init_boxagent = __esm({
|
|
|
30322
30322
|
}
|
|
30323
30323
|
});
|
|
30324
30324
|
|
|
30325
|
+
// server/approval-grants.ts
|
|
30326
|
+
function toolName(tool2) {
|
|
30327
|
+
return tool2.trim().replace(/^mcp__.+?__/i, "");
|
|
30328
|
+
}
|
|
30329
|
+
function bareTool(tool2) {
|
|
30330
|
+
return toolName(tool2).toLowerCase();
|
|
30331
|
+
}
|
|
30332
|
+
function collapse(text6) {
|
|
30333
|
+
return text6.trim().replace(/\s+/g, " ");
|
|
30334
|
+
}
|
|
30335
|
+
function isShellTool(tool2) {
|
|
30336
|
+
return SHELL_TOOL.test(bareTool(tool2));
|
|
30337
|
+
}
|
|
30338
|
+
function commandPrefix(summary) {
|
|
30339
|
+
const command = collapse(summary).replace(/^\$\s*/, "");
|
|
30340
|
+
if (!command || SHELL_META.test(command)) return null;
|
|
30341
|
+
const [program, sub] = command.split(" ");
|
|
30342
|
+
if (!program) return null;
|
|
30343
|
+
return sub && /^[a-z][\w-]*$/.test(sub) ? `${program} ${sub}` : program;
|
|
30344
|
+
}
|
|
30345
|
+
var ONCE_GRANT_TTL_MS, ALWAYS_GRANT_TTL_MS, SHELL_TOOL, SHELL_META;
|
|
30346
|
+
var init_approval_grants = __esm({
|
|
30347
|
+
"server/approval-grants.ts"() {
|
|
30348
|
+
"use strict";
|
|
30349
|
+
init_atomic();
|
|
30350
|
+
init_contracts();
|
|
30351
|
+
ONCE_GRANT_TTL_MS = 60 * 6e4;
|
|
30352
|
+
ALWAYS_GRANT_TTL_MS = 8 * 60 * 6e4;
|
|
30353
|
+
SHELL_TOOL = /(?:^|_)(?:bash|shell|sh|zsh|terminal|exec|exec_command|run_terminal_cmd|run_shell_command|local_shell|command|execute)$/i;
|
|
30354
|
+
SHELL_META = /[;&|`<>\n\r]|\$\(|\$\{/;
|
|
30355
|
+
}
|
|
30356
|
+
});
|
|
30357
|
+
|
|
30358
|
+
// server/drivers/session-allow-key.ts
|
|
30359
|
+
function sessionAllowKey(ask) {
|
|
30360
|
+
const tool2 = typeof ask.tool === "string" ? ask.tool.trim() : "";
|
|
30361
|
+
if (!tool2) return null;
|
|
30362
|
+
if (tool2.startsWith("mcp__")) return JSON.stringify(["tool", tool2]);
|
|
30363
|
+
const command = isShellTool(tool2) && typeof ask.input?.command === "string" ? commandPrefix(ask.input.command) : null;
|
|
30364
|
+
if (command) return JSON.stringify(["command", tool2, command]);
|
|
30365
|
+
const stable = (value) => Array.isArray(value) ? value.map(stable) : value && typeof value === "object" ? Object.fromEntries(Object.keys(value).sort().map((key) => [key, stable(value[key])])) : value;
|
|
30366
|
+
return JSON.stringify(["input", tool2, stable(ask.input ?? {})]);
|
|
30367
|
+
}
|
|
30368
|
+
var init_session_allow_key = __esm({
|
|
30369
|
+
"server/drivers/session-allow-key.ts"() {
|
|
30370
|
+
"use strict";
|
|
30371
|
+
init_approval_grants();
|
|
30372
|
+
}
|
|
30373
|
+
});
|
|
30374
|
+
|
|
30325
30375
|
// server/plan-policy.ts
|
|
30326
30376
|
function planToolAllowed(tool2) {
|
|
30327
30377
|
return typeof tool2 === "string" && PLAN_READ_TOOLS.includes(tool2);
|
|
@@ -31295,13 +31345,6 @@ function removePrivateTempDir(filePath) {
|
|
|
31295
31345
|
return false;
|
|
31296
31346
|
}
|
|
31297
31347
|
}
|
|
31298
|
-
function sessionAllowKey(ask) {
|
|
31299
|
-
const tool2 = typeof ask.tool === "string" ? ask.tool.trim() : "";
|
|
31300
|
-
if (!tool2) return null;
|
|
31301
|
-
if (tool2.startsWith("mcp__")) return JSON.stringify(["tool", tool2]);
|
|
31302
|
-
const stable = (value) => Array.isArray(value) ? value.map(stable) : value && typeof value === "object" ? Object.fromEntries(Object.keys(value).sort().map((key) => [key, stable(value[key])])) : value;
|
|
31303
|
-
return JSON.stringify(["input", tool2, stable(ask.input ?? {})]);
|
|
31304
|
-
}
|
|
31305
31348
|
function systemEndedReply(kind) {
|
|
31306
31349
|
return kind === "question" ? { behavior: "answer", message: "Atomic: the turn is ending \u2014 wrap up." } : { behavior: "deny", message: "Atomic: the turn ended" };
|
|
31307
31350
|
}
|
|
@@ -31560,6 +31603,7 @@ var CONNECTOR_CACHE_MS, CLAUDE_ACCOUNT_ENV_KEYS, DEFAULT_AUTOCOMPACT_TOKENS, CLA
|
|
|
31560
31603
|
var init_claude = __esm({
|
|
31561
31604
|
"server/drivers/claude.ts"() {
|
|
31562
31605
|
"use strict";
|
|
31606
|
+
init_session_allow_key();
|
|
31563
31607
|
init_plan_policy();
|
|
31564
31608
|
init_claude_message();
|
|
31565
31609
|
init_config();
|
|
@@ -50513,25 +50557,18 @@ var init_atomic_engine_release = __esm({
|
|
|
50513
50557
|
"use strict";
|
|
50514
50558
|
ASSETS = [
|
|
50515
50559
|
{
|
|
50516
|
-
version: "0.21.4-
|
|
50560
|
+
version: "0.21.4-68432dd",
|
|
50517
50561
|
platform: "darwin-arm64",
|
|
50518
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-
|
|
50519
|
-
bytes:
|
|
50520
|
-
sha512: "
|
|
50562
|
+
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-68432dd-darwin-arm64.tar.gz",
|
|
50563
|
+
bytes: 115629976,
|
|
50564
|
+
sha512: "b62d873aadd43655bd3f51af4027104a54462e74774182276783ba55d1824b05b193e839765cd5523b6f2bbe4fe3f47f780da32c2be94ac51b46d25f1fa3a83c"
|
|
50521
50565
|
},
|
|
50522
50566
|
{
|
|
50523
|
-
version: "0.21.4-
|
|
50567
|
+
version: "0.21.4-68432dd",
|
|
50524
50568
|
platform: "win32-x64",
|
|
50525
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-
|
|
50526
|
-
bytes:
|
|
50527
|
-
sha512: "
|
|
50528
|
-
},
|
|
50529
|
-
{
|
|
50530
|
-
version: "0.21.4-4cc340e",
|
|
50531
|
-
platform: "darwin-x64",
|
|
50532
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-4cc340e-darwin-x64.tar.gz",
|
|
50533
|
-
bytes: 92883251,
|
|
50534
|
-
sha512: "eec5fcbbcdbe44db76f938cb3dd98fedfc6c644cc054c75d0ad3daaf66e39f60dc6b75fa3f8cdbbc2cc3760a2ea7d3fc608a1cf7a42c4a020e6cd4d6dc823df0"
|
|
50569
|
+
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-68432dd-win32-x64.tar.gz",
|
|
50570
|
+
bytes: 103356325,
|
|
50571
|
+
sha512: "a2bb1c23194ca63168a855daee719a851d5213c79b6db083ca676b0aaff26ac55f0e2086e36395f86a677379e8cc0cf53113122b6695b841e12e3619857fc08c"
|
|
50535
50572
|
}
|
|
50536
50573
|
];
|
|
50537
50574
|
}
|
|
@@ -62235,13 +62272,21 @@ var ALLOWED = [
|
|
|
62235
62272
|
{ method: "GET", path: /^\/api\/threads\/[\w-]+\/export$/ },
|
|
62236
62273
|
{ method: "POST", path: /^\/api\/threads\/[\w-]+\/respond$/ },
|
|
62237
62274
|
{ method: "GET", path: /^\/api\/search$/ },
|
|
62238
|
-
// Team Rooms through the paired computer
|
|
62239
|
-
// Section 8): read
|
|
62240
|
-
//
|
|
62241
|
-
//
|
|
62275
|
+
// Team Rooms and Channels through the paired computer
|
|
62276
|
+
// (docs/chibitek/team-room-plan.md, Section 8): read, reply, keep the read
|
|
62277
|
+
// position, make a room or channel, invite links, join from a link, add or
|
|
62278
|
+
// remove bots, remove people, leave or close, save to Nexus. The computer's
|
|
62279
|
+
// Chibitek sign-in does every one of these and the server checks who may.
|
|
62280
|
+
// A bot's share settings stay on the computer, like the rest of a bot's
|
|
62281
|
+
// settings; approvals are the bot's own cards, answered through /respond.
|
|
62242
62282
|
{ method: "GET", path: /^\/api\/team-rooms$/ },
|
|
62283
|
+
{ method: "POST", path: /^\/api\/team-rooms$/ },
|
|
62284
|
+
{ method: "POST", path: /^\/api\/team-rooms\/join(?:\/preview)?$/ },
|
|
62285
|
+
{ method: "DELETE", path: /^\/api\/team-rooms\/(?:invites|bots)\/[0-9a-f-]{36}$/ },
|
|
62243
62286
|
{ method: "GET", path: /^\/api\/team-rooms\/[0-9a-f-]{36}$/ },
|
|
62244
|
-
{ method: "POST", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/(?:messages|read)$/ },
|
|
62287
|
+
{ method: "POST", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/(?:messages|read|archive|leave|invites|bots|save-to-nexus)$/ },
|
|
62288
|
+
{ method: "GET", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/invites$/ },
|
|
62289
|
+
{ method: "DELETE", path: /^\/api\/team-rooms\/[0-9a-f-]{36}\/members\/[0-9a-f-]{36}$/ },
|
|
62245
62290
|
// App-owned profile images. Upload is image-only and capped at 10 MB by
|
|
62246
62291
|
// the harness; GET is a single bare generated filename, never a path.
|
|
62247
62292
|
{ method: "POST", path: /^\/api\/attachments$/ },
|
|
@@ -65,7 +65,7 @@ function words(tool) {
|
|
|
65
65
|
function collapse(text) {
|
|
66
66
|
return text.trim().replace(/\s+/g, " ");
|
|
67
67
|
}
|
|
68
|
-
function isShellTool(tool) {
|
|
68
|
+
export function isShellTool(tool) {
|
|
69
69
|
return SHELL_TOOL.test(bareTool(tool));
|
|
70
70
|
}
|
|
71
71
|
/** Why no grant may ever answer this request, or null. Checked when a grant
|
|
@@ -5,28 +5,21 @@
|
|
|
5
5
|
// download whose size or SHA-512 differs from the pin below.
|
|
6
6
|
//
|
|
7
7
|
// Generated by scripts/release-engine.mjs. Do not edit by hand.
|
|
8
|
-
export const ATOMIC_ENGINE_VERSION = "0.21.4-
|
|
8
|
+
export const ATOMIC_ENGINE_VERSION = "0.21.4-68432dd";
|
|
9
9
|
const ASSETS = [
|
|
10
10
|
{
|
|
11
|
-
version: "0.21.4-
|
|
11
|
+
version: "0.21.4-68432dd",
|
|
12
12
|
platform: "darwin-arm64",
|
|
13
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-
|
|
14
|
-
bytes:
|
|
15
|
-
sha512: "
|
|
13
|
+
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-68432dd-darwin-arm64.tar.gz",
|
|
14
|
+
bytes: 115629976,
|
|
15
|
+
sha512: "b62d873aadd43655bd3f51af4027104a54462e74774182276783ba55d1824b05b193e839765cd5523b6f2bbe4fe3f47f780da32c2be94ac51b46d25f1fa3a83c",
|
|
16
16
|
},
|
|
17
17
|
{
|
|
18
|
-
version: "0.21.4-
|
|
18
|
+
version: "0.21.4-68432dd",
|
|
19
19
|
platform: "win32-x64",
|
|
20
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-
|
|
21
|
-
bytes:
|
|
22
|
-
sha512: "
|
|
23
|
-
},
|
|
24
|
-
{
|
|
25
|
-
version: "0.21.4-4cc340e",
|
|
26
|
-
platform: "darwin-x64",
|
|
27
|
-
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-4cc340e-darwin-x64.tar.gz",
|
|
28
|
-
bytes: 92883251,
|
|
29
|
-
sha512: "eec5fcbbcdbe44db76f938cb3dd98fedfc6c644cc054c75d0ad3daaf66e39f60dc6b75fa3f8cdbbc2cc3760a2ea7d3fc608a1cf7a42c4a020e6cd4d6dc823df0",
|
|
20
|
+
url: "https://ugmbfkqvogfuvufzjxtb.supabase.co/storage/v1/object/public/atomic-updates/atomic/K_5FMcrZFZ5AE2K-Lydn-Tis/atomic-engine-0.21.4-68432dd-win32-x64.tar.gz",
|
|
21
|
+
bytes: 103356325,
|
|
22
|
+
sha512: "a2bb1c23194ca63168a855daee719a851d5213c79b6db083ca676b0aaff26ac55f0e2086e36395f86a677379e8cc0cf53113122b6695b841e12e3619857fc08c",
|
|
30
23
|
},
|
|
31
24
|
];
|
|
32
25
|
/** The package for this computer, or null when none is published for it. */
|
|
@@ -531,10 +531,10 @@ const appConfigSchema = z.object({
|
|
|
531
531
|
* outrank it. Written only through /api/hipaa, never a generic config patch. */
|
|
532
532
|
hipaa: z.object({ enabled: z.boolean().optional() }).optional(),
|
|
533
533
|
/** How company bots receive Google and Microsoft accounts connected under
|
|
534
|
-
* Settings → Accounts.
|
|
535
|
-
*
|
|
536
|
-
*
|
|
537
|
-
* touches how refresh tokens are stored. */
|
|
534
|
+
* Settings → Accounts. Default is all-company-bots (Erick 2026-10-15):
|
|
535
|
+
* every non-personal connected account works for every company bot, while
|
|
536
|
+
* an explicit bot.accounts list still restricts. "opt-in" keeps the legacy
|
|
537
|
+
* per-bot Access toggle. Never touches how refresh tokens are stored. */
|
|
538
538
|
oauthAccounts: z.object({
|
|
539
539
|
botGrant: z.enum(["opt-in", "all-company-bots"]).optional(),
|
|
540
540
|
}).strict().optional(),
|
|
@@ -732,9 +732,9 @@ export function teamRoomsEnabled(cfg) {
|
|
|
732
732
|
* the person switched it on under Plugins → MCP servers; the Claude driver
|
|
733
733
|
* then omits --strict-mcp-config while keeping skills, hooks and the
|
|
734
734
|
* personal CLAUDE.md out. */
|
|
735
|
-
/** How company bots receive connected Google/Microsoft accounts.
|
|
735
|
+
/** How company bots receive connected Google/Microsoft accounts. Default all-company-bots; "opt-in" keeps the legacy per-bot toggle. */
|
|
736
736
|
export function accountBotGrantPolicy(cfg) {
|
|
737
|
-
return cfg.oauthAccounts?.botGrant === "
|
|
737
|
+
return cfg.oauthAccounts?.botGrant === "opt-in" ? "opt-in" : "all-company-bots";
|
|
738
738
|
}
|
|
739
739
|
export function claudeUserMcpEnabled(cfg) {
|
|
740
740
|
return cfg.features?.claudeUserMcp === true;
|
|
@@ -1134,7 +1134,7 @@ export function saveConfig(patch, options = {}) {
|
|
|
1134
1134
|
const storedProfiles = storedBrowserProfilesSchema.safeParse(disk.browserProfiles);
|
|
1135
1135
|
if (storedProfiles.success)
|
|
1136
1136
|
disk.browserProfiles = storedProfiles.data;
|
|
1137
|
-
for (const key of ["xai", "anthropic", "mistral", "ollamaCloud", "openaiCompat", "box", "opencodeGo", "tts", "imageGen", "profile", "icm", "nexusMemory", "paw", "rooms", "threads", "context", "localVm", "features", "addons", "budgets", "billing", "decisions", "onboarding", "browserEngine", "newBots"]) {
|
|
1137
|
+
for (const key of ["xai", "anthropic", "mistral", "ollamaCloud", "openaiCompat", "box", "opencodeGo", "tts", "imageGen", "profile", "icm", "nexusMemory", "paw", "rooms", "threads", "context", "localVm", "features", "addons", "budgets", "billing", "decisions", "onboarding", "browserEngine", "newBots", "oauthAccounts"]) {
|
|
1138
1138
|
const section = checkedPatch[key];
|
|
1139
1139
|
if (!section)
|
|
1140
1140
|
continue;
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { sessionAllowKey } from "./session-allow-key.js";
|
|
1
2
|
import { claudePlanHook, planToolAllowed, PLAN_REFUSAL } from "../plan-policy.js";
|
|
2
3
|
import { firstText } from "./claude-message.js";
|
|
3
4
|
// Claude driver — upstream ClaudeDriver skeleton over agentcal's
|
|
@@ -431,25 +432,6 @@ function removePrivateTempDir(filePath) {
|
|
|
431
432
|
const DENY_TIMEOUT_NOTE = "Atomic: nobody answered this permission request in time. Skip this action and finish what you can without it.";
|
|
432
433
|
const QUESTION_TIMEOUT_NOTE = "Atomic: nobody answered in time. Use your best judgment and continue.";
|
|
433
434
|
const DUPLICATE_ASK_ID_NOTE = "Atomic: duplicate ask id — skipping this request.";
|
|
434
|
-
/** What "this action" means for "Always allow this session". The claude CLI
|
|
435
|
-
* calls --permission-prompt-tool with only tool_name, input and tool_use_id,
|
|
436
|
-
* never its own suggested rules, so the harness keeps the allow itself. An
|
|
437
|
-
* MCP tool is allowed by name, the rule Claude would have suggested for it;
|
|
438
|
-
* every other tool (Bash, Edit, WebFetch...) only for this exact input, keys
|
|
439
|
-
* sorted so two identical asks key alike. null when the ask names no tool. */
|
|
440
|
-
export function sessionAllowKey(ask) {
|
|
441
|
-
const tool = typeof ask.tool === "string" ? ask.tool.trim() : "";
|
|
442
|
-
if (!tool)
|
|
443
|
-
return null;
|
|
444
|
-
if (tool.startsWith("mcp__"))
|
|
445
|
-
return JSON.stringify(["tool", tool]);
|
|
446
|
-
const stable = (value) => Array.isArray(value)
|
|
447
|
-
? value.map(stable)
|
|
448
|
-
: value && typeof value === "object"
|
|
449
|
-
? Object.fromEntries(Object.keys(value).sort().map((key) => [key, stable(value[key])]))
|
|
450
|
-
: value;
|
|
451
|
-
return JSON.stringify(["input", tool, stable(ask.input ?? {})]);
|
|
452
|
-
}
|
|
453
435
|
/** The system-source reply for an ask that outlives the turn — used both to
|
|
454
436
|
* drain in-flight `pending` asks on close() and to answer one that arrives
|
|
455
437
|
* on an already-closed broker (see the `closed` branch below). */
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
import { commandPrefix, isShellTool } from "../approval-grants.js";
|
|
2
|
+
/** What "this action" means for "Always allow this session". The claude CLI
|
|
3
|
+
* calls --permission-prompt-tool with only tool_name, input and tool_use_id,
|
|
4
|
+
* never its own suggested rules, so the harness keeps the allow itself. An
|
|
5
|
+
* MCP tool is allowed by name, the rule Claude would have suggested for it.
|
|
6
|
+
* A shell command is allowed by its program and subcommand (`git push`,
|
|
7
|
+
* `pnpm test`), the same scope a delegated Always allow covers
|
|
8
|
+
* (approval-grants commandPrefix); a command that chains or redirects keeps
|
|
9
|
+
* to its exact text. Every other tool (Edit, WebFetch...) only for this
|
|
10
|
+
* exact input, keys sorted so two identical asks key alike. null when the
|
|
11
|
+
* ask names no tool. */
|
|
12
|
+
export function sessionAllowKey(ask) {
|
|
13
|
+
const tool = typeof ask.tool === "string" ? ask.tool.trim() : "";
|
|
14
|
+
if (!tool)
|
|
15
|
+
return null;
|
|
16
|
+
if (tool.startsWith("mcp__"))
|
|
17
|
+
return JSON.stringify(["tool", tool]);
|
|
18
|
+
const command = isShellTool(tool) && typeof ask.input?.command === "string" ? commandPrefix(ask.input.command) : null;
|
|
19
|
+
if (command)
|
|
20
|
+
return JSON.stringify(["command", tool, command]);
|
|
21
|
+
const stable = (value) => Array.isArray(value)
|
|
22
|
+
? value.map(stable)
|
|
23
|
+
: value && typeof value === "object"
|
|
24
|
+
? Object.fromEntries(Object.keys(value).sort().map((key) => [key, stable(value[key])]))
|
|
25
|
+
: value;
|
|
26
|
+
return JSON.stringify(["input", tool, stable(ask.input ?? {})]);
|
|
27
|
+
}
|
|
@@ -16004,7 +16004,7 @@ if (process.env.OMB_MODEL_LEVELS_REFRESH !== "0")
|
|
|
16004
16004
|
setTimeout(() => void describeInstances().catch(() => { }), 0).unref?.();
|
|
16005
16005
|
// Settings → Accounts: Google and Microsoft sign-in (server/routes/accounts.ts).
|
|
16006
16006
|
ROUTES.push(createAccountRoutes({
|
|
16007
|
-
accounts: oauthAccounts,
|
|
16007
|
+
accounts: oauthAccounts, grantPolicy: () => accountBotGrantPolicy(cfg),
|
|
16008
16008
|
removedFromBots: (accountId) => {
|
|
16009
16009
|
for (const bot of store.bots) {
|
|
16010
16010
|
const ids = botAccountIds(bot);
|
|
@@ -415,7 +415,7 @@ export async function runAccountTool(ctx, name, rawArgs) {
|
|
|
415
415
|
missing: missingFamilies(account.provider, account.scopes),
|
|
416
416
|
})),
|
|
417
417
|
...(!ctx.allowed.length ? {
|
|
418
|
-
guidance: "
|
|
418
|
+
guidance: "This bot cannot use any Google or Microsoft account right now. If none is connected, ask the person to connect one in Settings → Accounts; a connected account works in every bot by default. If one is connected but this bot still sees none, the bot's own Settings → Access list is restricting it. Do not use an LLM account’s connectors instead.",
|
|
419
419
|
} : {}),
|
|
420
420
|
}),
|
|
421
421
|
isError: false,
|
|
@@ -16,7 +16,7 @@ export function createAccountRoutes(deps) {
|
|
|
16
16
|
if (path === "/api/accounts") {
|
|
17
17
|
if (method !== "GET")
|
|
18
18
|
return json(res, 405, { error: "method not allowed" });
|
|
19
|
-
return json(res, 200, deps.accounts.status());
|
|
19
|
+
return json(res, 200, { ...deps.accounts.status(), botGrant: deps.grantPolicy() });
|
|
20
20
|
}
|
|
21
21
|
if (path === "/api/accounts/connect") {
|
|
22
22
|
if (method !== "POST")
|
|
@@ -109,7 +109,7 @@ export function computerPrompt(kind) {
|
|
|
109
109
|
* bot reaches for them and passes the right one, or explains missing grants. */
|
|
110
110
|
export function accountsPrompt(emails) {
|
|
111
111
|
if (emails.length === 0)
|
|
112
|
-
return " Use atomic_accounts.list_accounts for Google and Microsoft access status. No
|
|
112
|
+
return " Use atomic_accounts.list_accounts for Google and Microsoft access status. No account is available to this bot right now: if none is connected, ask the person to connect one in Settings → Accounts (a connected account works in every bot by default); if one is connected, the person's restriction on this bot's Settings → Access list is in effect. Do not use LLM account connectors for these services.";
|
|
113
113
|
const list = emails.map((email) => `"${email}"`).join(", ");
|
|
114
114
|
return ` You can use the user's ${emails.length === 1 ? "account" : "accounts"} ${list} through atomic_accounts (mail, calendar and files). Use list_accounts to check granted permissions. Do not use LLM account connectors for Google or Microsoft services. Pass the email as \`account\` when more than one account of that provider is listed. Save messages as drafts and send only when the user asked you to send.`;
|
|
115
115
|
}
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// How company bots receive Google and Microsoft accounts from Settings → Accounts.
|
|
2
2
|
// Does not touch token storage: only which account ids a bot may use.
|
|
3
3
|
import { ACCOUNT_ID, botAccountIds } from "./oauth-providers.js";
|
|
4
|
-
/**
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
*
|
|
4
|
+
/** all-company-bots (default, decided by Erick 2026-10-15): every company bot
|
|
5
|
+
* may use every non-personal connected account unless that bot set an explicit
|
|
6
|
+
* allowlist. opt-in: the legacy per-bot Access toggle, kept as a workspace
|
|
7
|
+
* escape hatch. Private bots stay opt-in among accounts marked Personal. */
|
|
8
8
|
export const ACCOUNT_BOT_GRANT_POLICIES = ["opt-in", "all-company-bots"];
|
|
9
9
|
export function isAccountBotGrantPolicy(value) {
|
|
10
10
|
return typeof value === "string" && ACCOUNT_BOT_GRANT_POLICIES.includes(value);
|
|
@@ -17140,10 +17140,10 @@ var appConfigSchema = external_exports.object({
|
|
|
17140
17140
|
* outrank it. Written only through /api/hipaa, never a generic config patch. */
|
|
17141
17141
|
hipaa: external_exports.object({ enabled: external_exports.boolean().optional() }).optional(),
|
|
17142
17142
|
/** How company bots receive Google and Microsoft accounts connected under
|
|
17143
|
-
* Settings → Accounts.
|
|
17144
|
-
*
|
|
17145
|
-
*
|
|
17146
|
-
* touches how refresh tokens are stored. */
|
|
17143
|
+
* Settings → Accounts. Default is all-company-bots (Erick 2026-10-15):
|
|
17144
|
+
* every non-personal connected account works for every company bot, while
|
|
17145
|
+
* an explicit bot.accounts list still restricts. "opt-in" keeps the legacy
|
|
17146
|
+
* per-bot Access toggle. Never touches how refresh tokens are stored. */
|
|
17147
17147
|
oauthAccounts: external_exports.object({
|
|
17148
17148
|
botGrant: external_exports.enum(["opt-in", "all-company-bots"]).optional()
|
|
17149
17149
|
}).strict().optional(),
|
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{U as a,C as n}from"./mermaid.core-C-8HBWdK.js";const t=(r,o)=>a.lang.round(n.parse(r)[o]);export{t as c};
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import{c as r,s as e}from"./flowDiagram-KWPJA3E3-BSQCaJJS.js";import{_ as a}from"./mermaid.core-C-8HBWdK.js";import"./chunk-5VM5RSS4-3y2fUHet.js";import"./chunk-XXDRQBXY-ia5t27ll.js";import"./chunk-WEXAMYUT-BYg3YNuR.js";import"./chunk-GWA4HPMP-DsIbENvB.js";import"./channel-NejqmlD6.js";import"./index-C1MRa2jb.js";var o=a(t=>`${e(t)}
|
|
2
|
-
.swimlane.cluster:not([data-color-id]) rect {
|
|
3
|
-
stroke: ${t.clusterBorder} !important;
|
|
4
|
-
}
|
|
5
|
-
[data-look="neo"].cluster rect {
|
|
6
|
-
filter: none;
|
|
7
|
-
}
|
|
8
|
-
`,"getStyles"),s=o,u=r({styles:s});export{u as diagram};
|