@wirecat/zoom-cli 0.72.0 → 0.74.0
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/contracts/wirecat.json +1478 -0
- package/dist/account-removal.d.ts.map +1 -1
- package/dist/account-removal.js +0 -2
- package/dist/account-removal.js.map +1 -1
- package/dist/answers.d.ts +1 -3
- package/dist/answers.d.ts.map +1 -1
- package/dist/answers.js +0 -3
- package/dist/answers.js.map +1 -1
- package/dist/bin/main.js +13 -5
- package/dist/bin/main.js.map +1 -1
- package/dist/bin/zm.js +2 -2
- package/dist/bundle/{all-profiles-XFIPF4GF.js → all-profiles-SDOAABLC.js} +12 -12
- package/dist/bundle/answer-policy-RHS74QYY.js +110 -0
- package/dist/bundle/{anthropic-SSUBR3BC.js → anthropic-HCVY2PIN.js} +7 -7
- package/dist/bundle/{app-server-7DJHHF2F.js → app-server-V64VS6KN.js} +65 -61
- package/dist/bundle/{bun-6HBYWQIX.js → bun-EBQHHLKR.js} +2 -2
- package/dist/bundle/{bun-sqlite-4L3Q55NB.js → bun-sqlite-PVMXO2JB.js} +7 -7
- package/dist/bundle/chunk-2PNG76LV.js +707 -0
- package/dist/bundle/chunk-2PYZTRRC.js +84 -0
- package/dist/bundle/{chunk-63QXCE5Z.js → chunk-3HTJBGNP.js} +10 -10
- package/dist/bundle/{chunk-5X4IY5JH.js → chunk-3ROL6MBJ.js} +1763 -762
- package/dist/bundle/{chunk-N4QNYWWG.js → chunk-3TYNBHBK.js} +2 -2
- package/dist/bundle/{chunk-7SUWPMZG.js → chunk-4ELLWJT4.js} +8 -8
- package/dist/bundle/{chunk-PJWSGXOB.js → chunk-4EZKR6Q4.js} +7 -7
- package/dist/bundle/{chunk-UVZLK3M4.js → chunk-4RJL32PF.js} +25 -10
- package/dist/bundle/{chunk-LTWJM3ED.js → chunk-5KDBLEUF.js} +17 -17
- package/dist/bundle/{chunk-7IFO43Q5.js → chunk-5R6EBM5Z.js} +2 -2
- package/dist/bundle/{chunk-OHCLQJOV.js → chunk-6EMOZGSN.js} +3 -3
- package/dist/bundle/{chunk-D24OQAHM.js → chunk-6GPBDVQ2.js} +4 -4
- package/dist/bundle/chunk-7NE3LB7A.js +25 -0
- package/dist/bundle/{chunk-VIV64MQM.js → chunk-7R4UU65O.js} +26 -17
- package/dist/bundle/{chunk-4XQWF3U2.js → chunk-7W23N2YW.js} +6 -6
- package/dist/bundle/{chunk-RN5SU2RN.js → chunk-AFUHT7F7.js} +6 -6
- package/dist/bundle/{chunk-SXZGCD6E.js → chunk-APLV37JA.js} +3 -3
- package/dist/bundle/{chunk-LLUNHAZ7.js → chunk-BKMC4ETU.js} +4 -4
- package/dist/bundle/{chunk-IACWKZWS.js → chunk-BOGGQOVO.js} +1 -1
- package/dist/bundle/{chunk-U3NJBGLA.js → chunk-DSRG5NRF.js} +185 -34
- package/dist/bundle/{chunk-X2MP634F.js → chunk-DXZN3DU6.js} +4 -4
- package/dist/bundle/{chunk-ELJUBPY4.js → chunk-EA2OB75T.js} +1 -1
- package/dist/bundle/{chunk-ZVFYGTGJ.js → chunk-F6PUM6ZK.js} +17 -17
- package/dist/bundle/{chunk-MCPOZNWG.js → chunk-FIVFP53N.js} +1 -1
- package/dist/bundle/{chunk-WOAYHCM2.js → chunk-FL2TKSZY.js} +1 -1
- package/dist/bundle/{chunk-RZUJMAMK.js → chunk-FT7X74RT.js} +4 -4
- package/dist/bundle/{chunk-ADLS6FVG.js → chunk-FXBHOCJK.js} +1 -1
- package/dist/bundle/{chunk-I7CUMZD6.js → chunk-FY2X6U6O.js} +3 -3
- package/dist/bundle/{chunk-W3YTVEWV.js → chunk-GPGIU3OG.js} +9 -9
- package/dist/bundle/{chunk-6DCLZLGX.js → chunk-HCZYJMBP.js} +1 -1
- package/dist/bundle/{chunk-IU4DUUB3.js → chunk-HGUYJUNO.js} +325 -14
- package/dist/bundle/{chunk-S7SXSHRC.js → chunk-HNWDEDMU.js} +61 -30
- package/dist/bundle/{chunk-NMZQTYKJ.js → chunk-HZUUVNWC.js} +1 -1
- package/dist/bundle/{chunk-7S4D5SM2.js → chunk-I2D4ZZOD.js} +31 -32
- package/dist/bundle/{chunk-XPWZSW6Y.js → chunk-IJCUAKR5.js} +4 -4
- package/dist/bundle/{chunk-QQUY4MZY.js → chunk-IJONJTST.js} +1 -1
- package/dist/bundle/chunk-IS6FUZCP.js +73 -0
- package/dist/bundle/{chunk-ZW5KHKMA.js → chunk-IZUOL4Q6.js} +5 -5
- package/dist/bundle/{chunk-H53WFZBN.js → chunk-KBRIMLVN.js} +12 -12
- package/dist/bundle/{chunk-2MIBRVSV.js → chunk-KCPRTZBZ.js} +2 -2
- package/dist/bundle/chunk-KYL5FYOW.js +13 -0
- package/dist/bundle/{chunk-4SY67IUA.js → chunk-LHPYSVGP.js} +26 -35
- package/dist/bundle/{chunk-JG4MNYG2.js → chunk-LN2LWPN2.js} +1 -1
- package/dist/bundle/{chunk-CW46FWKW.js → chunk-LQR4V5EY.js} +14 -12
- package/dist/bundle/{chunk-B3SILJBU.js → chunk-LUBG5GKK.js} +30 -22
- package/dist/bundle/{chunk-3KRTEX5M.js → chunk-LZ4AVHBS.js} +3 -2
- package/dist/bundle/{chunk-RX5CJ55S.js → chunk-M4OP5ASJ.js} +1 -1
- package/dist/bundle/{chunk-FSCPQQS5.js → chunk-MAE5UGRQ.js} +150 -93
- package/dist/bundle/{chunk-KPIQXFNB.js → chunk-N7KCNMKL.js} +16 -15
- package/dist/bundle/{chunk-RLCVPECY.js → chunk-NKBMLSWK.js} +110 -64
- package/dist/bundle/{chunk-T27IMG6X.js → chunk-NV2REPY6.js} +1 -1
- package/dist/bundle/{chunk-EFF2XBHP.js → chunk-OP6HK2QL.js} +2 -2
- package/dist/bundle/{chunk-WLVG4RBZ.js → chunk-OPUGV7VW.js} +15 -2
- package/dist/bundle/{chunk-5AELTC52.js → chunk-P53CLAXD.js} +103 -102
- package/dist/bundle/{chunk-KWURWGGB.js → chunk-PKM2UKAZ.js} +32 -9
- package/dist/bundle/{chunk-7JYMGXLI.js → chunk-PMHMKZEJ.js} +47 -43
- package/dist/bundle/{chunk-23J2ANZ7.js → chunk-QAGSAOYS.js} +2 -2
- package/dist/bundle/{chunk-JZ4XNNL7.js → chunk-QLKCKTM4.js} +1 -1
- package/dist/bundle/{chunk-OP5PGE2N.js → chunk-QSWR7VDA.js} +4 -4
- package/dist/bundle/{chunk-LA6QUVGQ.js → chunk-R35YGFKQ.js} +163 -16
- package/dist/bundle/{chunk-CANRIRNZ.js → chunk-R4J4DLJV.js} +1792 -1205
- package/dist/bundle/{chunk-QW7YTRV2.js → chunk-RJJ4OYNH.js} +3 -3
- package/dist/bundle/{chunk-DOCVEKP2.js → chunk-RQJ2RXFO.js} +37 -35
- package/dist/bundle/{chunk-TF2WKPNW.js → chunk-RRW54FK6.js} +17 -17
- package/dist/bundle/{chunk-KFZL67JP.js → chunk-SKDQNYKA.js} +129 -48
- package/dist/bundle/{chunk-7GLJSJ7M.js → chunk-SPWKGRTO.js} +1 -1
- package/dist/bundle/{chunk-MSQHSW4C.js → chunk-SY4MIIWF.js} +2 -2
- package/dist/bundle/{chunk-ZHA56THL.js → chunk-TKPIDOW5.js} +927 -904
- package/dist/bundle/{chunk-WXTYYWZI.js → chunk-TLNZUPGU.js} +115 -113
- package/dist/bundle/{chunk-WZGKHTA4.js → chunk-TMCXUWTY.js} +8 -2
- package/dist/bundle/{chunk-7OD3522V.js → chunk-TN2YUZBF.js} +1192 -496
- package/dist/bundle/{chunk-JFPUYQSP.js → chunk-UGLNVUFX.js} +5 -5
- package/dist/bundle/{chunk-IFBIXU6C.js → chunk-UVWNUY3W.js} +2 -2
- package/dist/bundle/{chunk-5MGICK47.js → chunk-UW3BB2XW.js} +26 -26
- package/dist/bundle/{chunk-24OFZNRC.js → chunk-UXSTXFZQ.js} +5168 -4245
- package/dist/bundle/{chunk-U32VL3MA.js → chunk-WRRGO246.js} +3 -2
- package/dist/bundle/{chunk-QA6KIL7Q.js → chunk-WYV5IITK.js} +11 -8
- package/dist/bundle/{chunk-D5EUMWD5.js → chunk-X2FILY5F.js} +3 -3
- package/dist/bundle/{chunk-4YIGXTBP.js → chunk-XCC7R47Z.js} +3 -3
- package/dist/bundle/{chunk-37NF5CBJ.js → chunk-XFT3YIHU.js} +6 -8
- package/dist/bundle/{chunk-IXO4SCKE.js → chunk-XGEPAJBY.js} +1 -1
- package/dist/bundle/chunk-XWBPP2HX.js +2 -0
- package/dist/bundle/{chunk-RJTGENHZ.js → chunk-Y4KWWPIO.js} +4 -7
- package/dist/bundle/{chunk-DEPXZJ2V.js → chunk-YFLTHGB3.js} +17 -13
- package/dist/bundle/{chunk-JRCH4YZP.js → chunk-YM6ZATEK.js} +17 -121
- package/dist/bundle/{chunk-ADKMBXY4.js → chunk-YNI57LTZ.js} +1 -1
- package/dist/bundle/{chunk-ERJYJ36F.js → chunk-ZMHZ6CQS.js} +2 -2
- package/dist/bundle/{chunk-M3DMXDX6.js → chunk-ZYMTS3CI.js} +6 -6
- package/dist/bundle/{cli-IYYI7GAM.js → cli-5ALOQCAC.js} +152 -123
- package/dist/bundle/command-contract-WO5QJVLZ.js +41 -0
- package/dist/bundle/{command-server-entry-FXX4LJWF.js → command-server-entry-ICOMIJIH.js} +33 -33
- package/dist/bundle/config-YQA5TJ7Y.js +97 -0
- package/dist/bundle/{decode-SRGOOGBW.js → decode-7LFOROWF.js} +6 -6
- package/dist/bundle/{dispatch-OUHRPFUL.js → dispatch-EU67WGME.js} +9 -9
- package/dist/bundle/{dist-UZLNLAIO.js → dist-KJOOYNCP.js} +25 -22
- package/dist/bundle/{echarts-7CM2MCMW.js → echarts-EJXBKCJT.js} +2 -2
- package/dist/bundle/{embed-VEE56BOB.js → embed-TOZCKRRO.js} +7 -7
- package/dist/bundle/{embedder-SZFYR543.js → embedder-QKEKUCS5.js} +10 -10
- package/dist/bundle/{failure-MZBNM7M5.js → failure-CTJLEB2R.js} +3 -3
- package/dist/bundle/first-run-S7CQVGK6.js +29 -0
- package/dist/bundle/first-screen-6GW6FD6S.js +39 -0
- package/dist/bundle/folders-MSBTAPAG.js +24 -0
- package/dist/bundle/{instructions-R7OHVAWH.js → instructions-Z7GVGWXS.js} +1 -1
- package/dist/bundle/{main-EFUN2O3K.js → main-RL3GC4OX.js} +39 -26
- package/dist/bundle/{mcp-7KQUJNFN.js → mcp-TDKGDB4V.js} +2 -2
- package/dist/bundle/{meetings-5I2BDNTA.js → meetings-JCMLE5AO.js} +9 -7
- package/dist/bundle/{node-P4E63KXA.js → node-KM3CUABH.js} +9 -9
- package/dist/bundle/{node-3N2JGZ7V.js → node-L2PVEW3N.js} +2 -2
- package/dist/bundle/{node-sqlite-2UVEE2WM.js → node-sqlite-4YW3W4XI.js} +10 -10
- package/dist/bundle/{oauth-AYGD7UU3.js → oauth-NNHWAT6A.js} +8 -8
- package/dist/bundle/{open-3GUVDLGD.js → open-PF2JHJIY.js} +6 -6
- package/dist/bundle/openai-C72ADYMD.js +28 -0
- package/dist/bundle/{output-file-72JFXVHQ.js → output-file-VDOCYH2G.js} +6 -6
- package/dist/bundle/{process-YAHHUFR5.js → process-MNZTQ2DA.js} +1 -1
- package/dist/bundle/{program-OSZROCTK.js → program-FOCBZZZS.js} +146 -151
- package/dist/bundle/{prompt-HMCW4XQJ.js → prompt-RBSUKMV7.js} +6 -6
- package/dist/bundle/{recognize-VF5CA7EM.js → recognize-RM6TQKK3.js} +5 -5
- package/dist/bundle/{remote-5C6VTPR2.js → remote-UKHTU3YR.js} +11 -10
- package/dist/bundle/{rerank-ER7NEDOI.js → rerank-3LBRVESU.js} +8 -8
- package/dist/bundle/run-log-UXINNGKA.js +124 -0
- package/dist/bundle/{serve-QJWXJOM7.js → serve-OOZFTW3W.js} +10 -10
- package/dist/bundle/server-DM5ZPFZB.js +75 -0
- package/dist/bundle/{server-KCIK3Y2P.js → server-YNQPNIJD.js} +52 -50
- package/dist/bundle/{services-LQMYJQG3.js → services-SLEOMN4B.js} +61 -44
- package/dist/bundle/{speech-74GJQNQH.js → speech-FZZ6QVGU.js} +20 -20
- package/dist/bundle/sqlite-runtime-WUR4PWYB.js +20 -0
- package/dist/bundle/{state-4XDGCHDF.js → state-ET36L4TY.js} +7 -7
- package/dist/bundle/{store-5Y5HK2L2.js → store-DI6OUBXA.js} +20 -20
- package/dist/bundle/{store-Y56AHJ2Y.js → store-SQB2DOVJ.js} +34 -28
- package/dist/bundle/store-connection-M6LVRAZ5.js +90 -0
- package/dist/bundle/store-maintenance-command-B66KWG6K.js +65 -0
- package/dist/bundle/{streaming-E5CR6HSR.js → streaming-PQEXKTE5.js} +7 -7
- package/dist/bundle/tokens-SUHRRQ25.js +24 -0
- package/dist/bundle/zm.js +9 -9
- package/dist/bundle/{zoom-app-NVL7HEAX.js → zoom-app-GE4SSHOP.js} +9 -8
- package/dist/folders.d.ts +12 -2
- package/dist/folders.d.ts.map +1 -1
- package/dist/folders.js +81 -3
- package/dist/folders.js.map +1 -1
- package/dist/identity.d.ts +5 -0
- package/dist/identity.d.ts.map +1 -1
- package/dist/identity.js +14 -0
- package/dist/identity.js.map +1 -1
- package/dist/recording-schedule-setup.d.ts.map +1 -1
- package/dist/recording-schedule-setup.js +4 -7
- package/dist/recording-schedule-setup.js.map +1 -1
- package/dist/remote-http.d.ts +1 -1
- package/dist/remote-http.d.ts.map +1 -1
- package/dist/remote-http.js +21 -23
- package/dist/remote-http.js.map +1 -1
- package/dist/setup-commands.d.ts.map +1 -1
- package/dist/setup-commands.js +2 -4
- package/dist/setup-commands.js.map +1 -1
- package/dist/tokens.d.ts +17 -2
- package/dist/tokens.d.ts.map +1 -1
- package/dist/tokens.js +109 -29
- package/dist/tokens.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/dist/wcat.d.ts +3 -0
- package/dist/wcat.d.ts.map +1 -0
- package/dist/wcat.js +4 -0
- package/dist/wcat.js.map +1 -0
- package/package.json +15 -14
- package/dist/bundle/answer-policy-AT6CDEE5.js +0 -110
- package/dist/bundle/chunk-EG25AY4L.js +0 -17
- package/dist/bundle/chunk-JAEPK457.js +0 -997
- package/dist/bundle/chunk-K6HR6HCO.js +0 -32
- package/dist/bundle/chunk-OY6N2ABP.js +0 -1239
- package/dist/bundle/chunk-YVVJ6Y5C.js +0 -153
- package/dist/bundle/command-contract-TX7NSUBM.js +0 -42
- package/dist/bundle/config-YKNM33J7.js +0 -96
- package/dist/bundle/first-run-KWC7RKF2.js +0 -29
- package/dist/bundle/first-screen-DWKMNSEI.js +0 -40
- package/dist/bundle/folders-UQXRSDJJ.js +0 -16
- package/dist/bundle/openai-NHCDLWWY.js +0 -28
- package/dist/bundle/run-log-JKTLKXSK.js +0 -124
- package/dist/bundle/server-LLGFDLLJ.js +0 -75
- package/dist/bundle/store-connection-4WI32AYU.js +0 -89
- package/dist/bundle/store-maintenance-command-PCXO5AH4.js +0 -65
- package/dist/bundle/tokens-E2QNVC4F.js +0 -20
- /package/dist/bundle/{chunk-YVNHQFLC.js → chunk-7O7XM37N.js} +0 -0
|
@@ -1,26 +1,39 @@
|
|
|
1
1
|
import { createRequire as __bundleRequire } from "node:module";
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
|
+
import {
|
|
4
|
+
createRenderer,
|
|
5
|
+
fieldsOf,
|
|
6
|
+
processStreams,
|
|
7
|
+
projectFields
|
|
8
|
+
} from "./chunk-HNWDEDMU.js";
|
|
9
|
+
import {
|
|
10
|
+
COMPACT_FLAG
|
|
11
|
+
} from "./chunk-4RJL32PF.js";
|
|
3
12
|
import {
|
|
4
13
|
CliError
|
|
5
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-EA2OB75T.js";
|
|
15
|
+
import {
|
|
16
|
+
singleLine
|
|
17
|
+
} from "./chunk-HCZYJMBP.js";
|
|
6
18
|
import {
|
|
7
19
|
__name
|
|
8
20
|
} from "./chunk-ZVVMGPBJ.js";
|
|
9
21
|
|
|
10
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
22
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.659.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_2476fb045fb1ee08e5e46f4aab8c07fa/node_modules/@wirecat/cli-core/dist/sends/permissions.js
|
|
11
23
|
var LEVELS = ["deny", "readonly", "ask", "allow"];
|
|
12
24
|
var DANGEROUS = /* @__PURE__ */ new Set(["messages.delete", "bot.messages.delete", "topics.delete", "chats.delete", "chats.clear"]);
|
|
13
25
|
var skipFlagFor = /* @__PURE__ */ __name((key) => DANGEROUS.has(key) ? "--allow-dangerous" : "--yes", "skipFlagFor");
|
|
14
26
|
var DEFAULT_PERMISSIONS = {
|
|
15
|
-
|
|
27
|
+
// Owner, 2026-11-14: deleting a message does not ask; a profile that wants the question sets `ask`.
|
|
28
|
+
"messages.delete": "allow",
|
|
16
29
|
"account.sessions.end": "ask",
|
|
17
|
-
"bot.messages.delete": "
|
|
30
|
+
"bot.messages.delete": "allow",
|
|
18
31
|
"topics.enable": "ask",
|
|
19
32
|
"topics.delete": "ask",
|
|
20
33
|
"chats.delete": "ask",
|
|
21
34
|
"chats.clear": "ask",
|
|
22
|
-
// NEED-568: a rule
|
|
23
|
-
"replies.send": "
|
|
35
|
+
// Owner, 2026-11-14 (replaces NEED-568): a rule the owner enabled may send; `deny` stops every automatic reply.
|
|
36
|
+
"replies.send": "allow",
|
|
24
37
|
// NEED-1662: an agent that changes settings, schedules or recipients could lift its own limits; the owner opts in.
|
|
25
38
|
"mcp.authority": "deny",
|
|
26
39
|
// NEED-1663: writes no level stopped before, so MCP could not offer them; over MCP `ask` goes ahead.
|
|
@@ -33,6 +46,7 @@ var DEFAULT_PERMISSIONS = {
|
|
|
33
46
|
"store.clear": "ask",
|
|
34
47
|
"store.decrypt": "ask",
|
|
35
48
|
"store.copies.delete": "ask",
|
|
49
|
+
"store.recover.run": "ask",
|
|
36
50
|
"server.start": "ask",
|
|
37
51
|
"server.stop": "ask",
|
|
38
52
|
"server.restart": "ask",
|
|
@@ -92,7 +106,7 @@ var layerPermissions = /* @__PURE__ */ __name((layers) => {
|
|
|
92
106
|
for (const [from, layer] of layers) {
|
|
93
107
|
const nearer = Object.keys(levels);
|
|
94
108
|
for (const [key, level] of Object.entries(layer ?? {})) {
|
|
95
|
-
if (nearer.some((
|
|
109
|
+
if (nearer.some((named2) => key === named2 || key.startsWith(`${named2}.`)))
|
|
96
110
|
continue;
|
|
97
111
|
levels[key] = level;
|
|
98
112
|
sources[key] = from;
|
|
@@ -105,10 +119,10 @@ var ALLOWED = { level: "allow", key: null };
|
|
|
105
119
|
var ORDER = { deny: 0, readonly: 1, ask: 2, allow: 3 };
|
|
106
120
|
var nearest = /* @__PURE__ */ __name((levels, key) => {
|
|
107
121
|
for (let parts = key.split("."); parts.length > 0; parts = parts.slice(0, -1)) {
|
|
108
|
-
const
|
|
109
|
-
const level = levels[
|
|
122
|
+
const named2 = parts.join(".");
|
|
123
|
+
const level = levels[named2];
|
|
110
124
|
if (level)
|
|
111
|
-
return { level, key:
|
|
125
|
+
return { level, key: named2, depth: parts.length };
|
|
112
126
|
}
|
|
113
127
|
return void 0;
|
|
114
128
|
}, "nearest");
|
|
@@ -187,16 +201,16 @@ var keyForWrite = /* @__PURE__ */ __name((kind, action) => {
|
|
|
187
201
|
return KIND_KEYS[kind];
|
|
188
202
|
}, "keyForWrite");
|
|
189
203
|
var writeOfKey = /* @__PURE__ */ __name((key) => {
|
|
190
|
-
const account = Object.entries(ACCOUNT_KEYS).find(([,
|
|
204
|
+
const account = Object.entries(ACCOUNT_KEYS).find(([, named2]) => named2 === key)?.[0];
|
|
191
205
|
if (account)
|
|
192
206
|
return { kind: "account", action: account };
|
|
193
|
-
const kind = Object.entries(KIND_KEYS).find(([,
|
|
207
|
+
const kind = Object.entries(KIND_KEYS).find(([, named2]) => named2 === key || key.startsWith(`${named2}.`))?.[0];
|
|
194
208
|
if (kind)
|
|
195
209
|
return { kind };
|
|
196
210
|
if (key === "messages.unpin")
|
|
197
211
|
return { kind: "pin" };
|
|
198
212
|
if (key.startsWith("chats.")) {
|
|
199
|
-
const action = Object.entries(CHAT_KEYS).find(([,
|
|
213
|
+
const action = Object.entries(CHAT_KEYS).find(([, named2]) => named2 === key)?.[0] ?? key.slice("chats.".length);
|
|
200
214
|
return { kind: "chat", action };
|
|
201
215
|
}
|
|
202
216
|
return {};
|
|
@@ -322,6 +336,8 @@ var readKeysForCommand = /* @__PURE__ */ __name((path) => {
|
|
|
322
336
|
return [key, "messages"];
|
|
323
337
|
if (path[0] === "store" && ["reset", "clear", "decrypt"].includes(path[1] ?? ""))
|
|
324
338
|
return [key, "messages"];
|
|
339
|
+
if (key === "store.recover.run")
|
|
340
|
+
return [key, "messages"];
|
|
325
341
|
if (path[0] === "search") {
|
|
326
342
|
if (path[1] === "notes")
|
|
327
343
|
return [key];
|
|
@@ -395,8 +411,8 @@ var permissionOverrides = /* @__PURE__ */ __name((entries = [], shape = RESOURCE
|
|
|
395
411
|
}, "permissionOverrides");
|
|
396
412
|
var assertOverridesTighten = /* @__PURE__ */ __name((overrides, profile, defaults = DEFAULT_PERMISSIONS) => {
|
|
397
413
|
for (const [key, level] of Object.entries(overrides)) {
|
|
398
|
-
const under = Object.keys(profile).filter((
|
|
399
|
-
const lifted = [key, ...under].find((
|
|
414
|
+
const under = Object.keys(profile).filter((named2) => named2.startsWith(`${key}.`));
|
|
415
|
+
const lifted = [key, ...under].find((named2) => ORDER[level] > ORDER[levelFor(profile, named2, defaults).level]);
|
|
400
416
|
if (lifted !== void 0)
|
|
401
417
|
throw new CliError("validation_error", `--permission ${key}=${level} would loosen ${lifted} from ${levelFor(profile, lifted, defaults).level}; it only tightens \u2014 change the profile's permissions to loosen it`, { key, lifted });
|
|
402
418
|
}
|
|
@@ -408,10 +424,138 @@ var assertRetentionEvidenceRead = /* @__PURE__ */ __name((permissions) => {
|
|
|
408
424
|
}
|
|
409
425
|
}, "assertRetentionEvidenceRead");
|
|
410
426
|
|
|
427
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.659.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_2476fb045fb1ee08e5e46f4aab8c07fa/node_modules/@wirecat/cli-core/dist/cli/result-fields.js
|
|
428
|
+
var named = /* @__PURE__ */ __name((work) => {
|
|
429
|
+
try {
|
|
430
|
+
return work();
|
|
431
|
+
} catch (error) {
|
|
432
|
+
if (error instanceof CliError && error.code === "validation_error")
|
|
433
|
+
throw new CliError("validation_error", "--json takes comma-separated field paths, for example --json=id,text", {
|
|
434
|
+
param: "--json"
|
|
435
|
+
});
|
|
436
|
+
throw error;
|
|
437
|
+
}
|
|
438
|
+
}, "named");
|
|
439
|
+
var fieldsOf2 = /* @__PURE__ */ __name((value) => named(() => fieldsOf(value)), "fieldsOf");
|
|
440
|
+
var projectCommands = /* @__PURE__ */ __name((commands, fields) => commands.map((command) => ({
|
|
441
|
+
...projectFields(command, fields),
|
|
442
|
+
path: command.path,
|
|
443
|
+
name: command.name,
|
|
444
|
+
origin: command.origin,
|
|
445
|
+
effects: command.effects,
|
|
446
|
+
commands: projectCommands(command.commands, fields)
|
|
447
|
+
})), "projectCommands");
|
|
448
|
+
var projectFields2 = /* @__PURE__ */ __name((value, fields) => named(() => {
|
|
449
|
+
if (value && typeof value === "object" && "cli" in value && typeof value.cli === "string" && "contract" in value && "commands" in value && Array.isArray(value.commands))
|
|
450
|
+
return { ...value, commands: projectCommands(value.commands, fields) };
|
|
451
|
+
return projectFields(value, fields);
|
|
452
|
+
}), "projectFields");
|
|
453
|
+
|
|
454
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.659.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_2476fb045fb1ee08e5e46f4aab8c07fa/node_modules/@wirecat/cli-core/dist/output-detail.js
|
|
455
|
+
var RARELY_SET = ["editedAt", "replyTo", "forwardedFrom", "reactions"];
|
|
456
|
+
var BRIEF = ["locator", "chatTitle", "timestamp", "senderName", "excerpt", "score"];
|
|
457
|
+
var SNAKE_BRIEF = ["ref", "chat_title", "timestamp", "sender_name", "excerpt", "score"];
|
|
458
|
+
var isRecord = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null, "isRecord");
|
|
459
|
+
var isSnakeHit = /* @__PURE__ */ __name((value) => isRecord(value) && typeof value.ref === "string" && typeof value.excerpt === "string", "isSnakeHit");
|
|
460
|
+
var isHit = /* @__PURE__ */ __name((value) => isSnakeHit(value) || isRecord(value) && typeof value.locator === "string" && typeof value.text === "string", "isHit");
|
|
461
|
+
var picked = /* @__PURE__ */ __name((hit, keys) => Object.fromEntries(keys.flatMap((key) => hit[key] === void 0 || hit[key] === null ? [] : [[key, hit[key]]])), "picked");
|
|
462
|
+
var shaped = /* @__PURE__ */ __name((hit, detail) => {
|
|
463
|
+
if (isSnakeHit(hit))
|
|
464
|
+
return detail === "brief" ? picked(hit, SNAKE_BRIEF) : hit;
|
|
465
|
+
if (detail === "brief")
|
|
466
|
+
return picked(hit, BRIEF);
|
|
467
|
+
const { text, providerMetadata, ...rest } = hit;
|
|
468
|
+
for (const key of RARELY_SET)
|
|
469
|
+
if (rest[key] === null)
|
|
470
|
+
delete rest[key];
|
|
471
|
+
const metadata = rest.email ? void 0 : providerMetadata;
|
|
472
|
+
return {
|
|
473
|
+
...rest,
|
|
474
|
+
...typeof rest.excerpt === "string" ? {} : { text },
|
|
475
|
+
...metadata === void 0 ? {} : { providerMetadata: metadata }
|
|
476
|
+
};
|
|
477
|
+
}, "shaped");
|
|
478
|
+
var atDetail = /* @__PURE__ */ __name((value, detail = "default") => {
|
|
479
|
+
if (detail === "full")
|
|
480
|
+
return value;
|
|
481
|
+
if (Array.isArray(value))
|
|
482
|
+
return value.map((item) => isHit(item) ? shaped(item, detail) : item);
|
|
483
|
+
if (isHit(value))
|
|
484
|
+
return shaped(value, detail);
|
|
485
|
+
if (typeof value === "object" && value !== null && Array.isArray(value.items))
|
|
486
|
+
return { ...value, items: atDetail(value.items, detail) };
|
|
487
|
+
return value;
|
|
488
|
+
}, "atDetail");
|
|
489
|
+
|
|
490
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.659.0_@wirecat+cli-base@0.99.0_commander@15.0.0_esbuild@0.28.2_type_2476fb045fb1ee08e5e46f4aab8c07fa/node_modules/@wirecat/cli-core/dist/output.js
|
|
491
|
+
var refuseCompact = /* @__PURE__ */ __name(({ json, jsonl, fields, hitDetail }) => {
|
|
492
|
+
const other = jsonl ? "--jsonl" : fields !== void 0 ? "--json=\u2026" : json ? "--json" : hitDetail === "brief" ? "--brief" : "";
|
|
493
|
+
if (other)
|
|
494
|
+
throw new CliError("validation_error", `${COMPACT_FLAG} and ${other} ask for different output \u2014 pick one`, {
|
|
495
|
+
reason: "output.conflict",
|
|
496
|
+
param: COMPACT_FLAG
|
|
497
|
+
});
|
|
498
|
+
}, "refuseCompact");
|
|
499
|
+
var resolveOutput = /* @__PURE__ */ __name(({ json, jsonl, quiet, streams = processStreams, tty, color, fields, hitDetail, env = process.env, capture, compact } = {}) => {
|
|
500
|
+
if (compact)
|
|
501
|
+
refuseCompact({ json, jsonl, fields, hitDetail });
|
|
502
|
+
const interactive = tty ?? process.stdout.isTTY === true;
|
|
503
|
+
const format = jsonl ? "jsonl" : json || compact || !interactive ? "json" : "pretty";
|
|
504
|
+
const painted = format === "pretty" && (color ?? (env.NO_COLOR === void 0 && env.TERM !== "dumb" && !env.CI));
|
|
505
|
+
const printing = createRenderer({ format, color: painted, streams });
|
|
506
|
+
const rendered = capture ? { ...printing, result: capture, stream: /* @__PURE__ */ __name((items) => capture([...items]), "stream") } : printing;
|
|
507
|
+
const level = hitDetail ?? (fields === void 0 ? "default" : "full");
|
|
508
|
+
const standard = format === "pretty" ? rendered : {
|
|
509
|
+
...rendered,
|
|
510
|
+
result: /* @__PURE__ */ __name((value) => rendered.result(atDetail(value, level)), "result"),
|
|
511
|
+
stream: /* @__PURE__ */ __name((items) => rendered.stream(atDetail([...items], level)), "stream")
|
|
512
|
+
};
|
|
513
|
+
const created = standard;
|
|
514
|
+
const paths = fields === void 0 ? void 0 : fieldsOf2(fields);
|
|
515
|
+
const renderer = format === "pretty" ? oneLineFields(created) : paths ? {
|
|
516
|
+
...created,
|
|
517
|
+
result: /* @__PURE__ */ __name((value) => created.result(projectFields2(value, paths)), "result"),
|
|
518
|
+
stream: /* @__PURE__ */ __name((items) => created.stream([...items].map((item) => projectFields2(item, paths))), "stream")
|
|
519
|
+
} : created;
|
|
520
|
+
return {
|
|
521
|
+
format,
|
|
522
|
+
color: painted,
|
|
523
|
+
streams,
|
|
524
|
+
renderer: quiet ? silence(renderer) : renderer,
|
|
525
|
+
...compact ? { compact: true, full: hitDetail === "full" } : {}
|
|
526
|
+
};
|
|
527
|
+
}, "resolveOutput");
|
|
528
|
+
var MULTI_LINE = /* @__PURE__ */ new Set(["text", "description"]);
|
|
529
|
+
var oneLineFields = /* @__PURE__ */ __name((renderer) => ({
|
|
530
|
+
...renderer,
|
|
531
|
+
result: /* @__PURE__ */ __name((value) => renderer.result(oneLine(value)), "result"),
|
|
532
|
+
stream: /* @__PURE__ */ __name((items) => renderer.stream([...items].map((item) => oneLine(item))), "stream")
|
|
533
|
+
}), "oneLineFields");
|
|
534
|
+
var oneLine = /* @__PURE__ */ __name((value, key) => {
|
|
535
|
+
if (typeof value === "string")
|
|
536
|
+
return key !== void 0 && MULTI_LINE.has(key) ? value : singleLine(value);
|
|
537
|
+
if (Array.isArray(value))
|
|
538
|
+
return value.map((item) => oneLine(item, key));
|
|
539
|
+
if (value !== null && typeof value === "object" && Object.getPrototypeOf(value) === Object.prototype) {
|
|
540
|
+
return Object.fromEntries(Object.entries(value).map(([field, item]) => [field, oneLine(item, field)]));
|
|
541
|
+
}
|
|
542
|
+
return value;
|
|
543
|
+
}, "oneLine");
|
|
544
|
+
var silence = /* @__PURE__ */ __name((renderer) => ({
|
|
545
|
+
...renderer,
|
|
546
|
+
note: /* @__PURE__ */ __name(() => {
|
|
547
|
+
}, "note"),
|
|
548
|
+
success: /* @__PURE__ */ __name(() => {
|
|
549
|
+
}, "success"),
|
|
550
|
+
warn: /* @__PURE__ */ __name(() => {
|
|
551
|
+
}, "warn")
|
|
552
|
+
}), "silence");
|
|
553
|
+
|
|
411
554
|
export {
|
|
412
555
|
LEVELS,
|
|
413
556
|
skipFlagFor,
|
|
414
557
|
DEFAULT_PERMISSIONS,
|
|
558
|
+
KEYED_UNDER_HOUSEKEEPING,
|
|
415
559
|
AUTHORITY_KEY,
|
|
416
560
|
authorityAllowed,
|
|
417
561
|
BOT_API_KEY,
|
|
@@ -430,5 +574,8 @@ export {
|
|
|
430
574
|
COMMAND_PATH_KEY,
|
|
431
575
|
permissionOverrides,
|
|
432
576
|
assertOverridesTighten,
|
|
433
|
-
assertRetentionEvidenceRead
|
|
577
|
+
assertRetentionEvidenceRead,
|
|
578
|
+
fieldsOf2 as fieldsOf,
|
|
579
|
+
projectFields2 as projectFields,
|
|
580
|
+
resolveOutput
|
|
434
581
|
};
|