nolo-cli 0.259.0-alpha.1 → 0.261.0-alpha.1

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.
Files changed (320) hide show
  1. package/README.md +1 -1
  2. package/{_executeModel-MTM4BJK3.js → _executeModel-PODMRXJJ.js} +97 -83
  3. package/accountResolver-NGICIMEE.js +1 -1
  4. package/{action-C6IQAKN4.js → action-NJTYNXXR.js} +12 -10
  5. package/{addContentAction-53364YDW.js → addContentAction-RUPXLROG.js} +14 -13
  6. package/{addDialogAgentAction-U5DD5EN5.js → addDialogAgentAction-57EJ2UBC.js} +20 -24
  7. package/{agentDeleteCommand-53NN3VSK.js → agentDeleteCommand-DRFCOTYP.js} +185 -147
  8. package/{agentEmailCommands-KOGGIT6I.js → agentEmailCommands-FHENHUBF.js} +143 -127
  9. package/{agentGrantCommands-L6O2HVJI.js → agentGrantCommands-BMVKNYIY.js} +9 -6
  10. package/{agentListCommands-62UYUQDI.js → agentListCommands-W66W5K3V.js} +88 -69
  11. package/{agentMachineCommands-W6TNJXEA.js → agentMachineCommands-C3BUBCXU.js} +69 -60
  12. package/{agentProviderCommands-QLTABYR7.js → agentProviderCommands-VIWKP7DM.js} +11 -8
  13. package/{agentPullCommand-2EYJ5ENC.js → agentPullCommand-5SNSXOY7.js} +10 -7
  14. package/agentRecordCommands-DYMHWTID.js +210 -0
  15. package/agentRun-QVFG3CI4.js +250 -0
  16. package/agentRunCommand-YV4V5HSL.js +248 -0
  17. package/{agentRunControl-LXMADX3N.js → agentRunControl-RGBHKPKJ.js} +19 -12
  18. package/{agentRuntimeLocal-YGNJMQW3.js → agentRuntimeLocal-LVEMOYS2.js} +62 -49
  19. package/{agentSlice-3HHYUQLM.js → agentSlice-OJCM7OUX.js} +15 -18
  20. package/appConfigCommands-ZUXQLE7L.js +417 -0
  21. package/{appDeleteCommands-5COJ6CSG.js → appDeleteCommands-L5UKUMXY.js} +68 -58
  22. package/{appDeployCommands-3JPAT3XO.js → appDeployCommands-KX2BRQUW.js} +74 -59
  23. package/{appDeployStatusCommands-RHZKF3G4.js → appDeployStatusCommands-7LHRSWW7.js} +68 -58
  24. package/{appGetCommands-73DXOAQW.js → appGetCommands-F7SDFCUK.js} +74 -58
  25. package/{appListCommands-HD5LOQ3G.js → appListCommands-U4NJKSMZ.js} +74 -58
  26. package/appMigrateCommands-JAPOLYSW.js +230 -0
  27. package/appSourceCommands-TLXPWXUH.js +279 -0
  28. package/authCommand-AU3GZBZ2.js +65 -0
  29. package/{authCommands-T5FODCEG.js → authCommands-JKBWMUQ4.js} +20 -17
  30. package/{builtinSkillRegistry-EDHD2UHU.js → builtinSkillRegistry-6XUWMAV5.js} +8 -6
  31. package/{chromeOpsCommands-3SSTDFRF.js → chromeOpsCommands-F47WYQWF.js} +68 -18
  32. package/{chunk-5YS6QHGT.js → chunk-2FGFY72B.js} +9 -9
  33. package/{chunk-MJBLXJMP.js → chunk-2I4R6ZRV.js} +12 -9
  34. package/{chunk-FXEPZKNJ.js → chunk-2MIZHEND.js} +506 -64
  35. package/{chunk-TLE77UJ5.js → chunk-2OROOEOQ.js} +0 -1
  36. package/{chunk-6RSNVJGO.js → chunk-2ZBPWX7N.js} +4 -4
  37. package/chunk-35JIFLIG.js +30 -0
  38. package/{chunk-7OVOZRZF.js → chunk-3B7OTHDW.js} +23 -379
  39. package/{chunk-DNNPARJK.js → chunk-3QMN3T6L.js} +50 -37
  40. package/{chunk-DMPZMYH4.js → chunk-3R4AYHJR.js} +13 -1
  41. package/{chunk-XNNBXUEM.js → chunk-3TII7WCF.js} +5 -5
  42. package/{chunk-223KZUJ6.js → chunk-4HZCBA4Q.js} +18 -15
  43. package/{chunk-C5A54QS7.js → chunk-4INJGWE3.js} +18 -5
  44. package/chunk-4IVMDQBA.js +261 -0
  45. package/chunk-4Y6CZ2N4.js +82 -0
  46. package/{chunk-KZ4A7EIV.js → chunk-56OAS5RZ.js} +1 -1
  47. package/{chunk-KQHEGELM.js → chunk-63G7JWEA.js} +16 -6
  48. package/{chunk-4EACJPZI.js → chunk-6BBXJGIQ.js} +51 -42
  49. package/chunk-72VWN4VK.js +51 -0
  50. package/chunk-7LR2IFUH.js +100 -0
  51. package/{chunk-S73EPYNC.js → chunk-7LS5ATRP.js} +20 -6
  52. package/{chunk-XPETQ4MR.js → chunk-7X4BFUJV.js} +24 -10
  53. package/{chunk-KHYSFS3W.js → chunk-A454UXB6.js} +148 -73
  54. package/chunk-A4O76A6V.js +432 -0
  55. package/chunk-AMNZPQCY.js +635 -0
  56. package/{chunk-4MXYCQBS.js → chunk-AQNWWJLH.js} +2 -56
  57. package/{chunk-LHCGKAFO.js → chunk-BKP325XS.js} +184 -112
  58. package/{chunk-PENRYZ4D.js → chunk-BPB3T5EU.js} +4 -7
  59. package/{chunk-U6QNVOR5.js → chunk-BUGLH2A7.js} +130 -6
  60. package/{chunk-2JHGUL5K.js → chunk-BVYHE6QD.js} +2 -2
  61. package/{chunk-KXOPLLFP.js → chunk-CA7LGAHV.js} +69 -9
  62. package/{chunk-2FZVXOFX.js → chunk-CEIWXKHP.js} +112 -200
  63. package/{chunk-Y2TCTNUD.js → chunk-CK2LMTYO.js} +4 -4
  64. package/{chunk-AIFQKNPP.js → chunk-CL33RFD7.js} +1 -1
  65. package/{chunk-57V4PADY.js → chunk-CNYPQYXT.js} +781 -449
  66. package/{chunk-P4R5KXU7.js → chunk-CW6LRDSF.js} +5 -5
  67. package/chunk-D3ONA3FP.js +762 -0
  68. package/{chunk-PIVTQRX6.js → chunk-DDKA6V6X.js} +111 -12
  69. package/chunk-DLXL4NSL.js +1179 -0
  70. package/{chunk-EJQE5HB7.js → chunk-DSBRIUX5.js} +4 -2
  71. package/{chunk-XRGBJHZX.js → chunk-E36V7MPY.js} +9 -5
  72. package/{chunk-4YPH5KRA.js → chunk-EDKMRDET.js} +1 -1
  73. package/{chunk-DBJODIZ6.js → chunk-EQOWWSNQ.js} +19 -27
  74. package/chunk-ER6NTALN.js +34 -0
  75. package/{chunk-L4XST72F.js → chunk-ERCSHBUD.js} +16027 -17392
  76. package/chunk-EUHMI5KG.js +101 -0
  77. package/{chunk-YQLAFJRQ.js → chunk-FBNVJ2TO.js} +1 -1
  78. package/{chunk-Q2EERN52.js → chunk-FF5ZRKW7.js} +12 -7
  79. package/{chunk-6XIE5ZGI.js → chunk-FGFJUFPS.js} +5 -6
  80. package/chunk-FI4DPLR7.js +902 -0
  81. package/{chunk-HDKMVYNJ.js → chunk-FNLT7NKG.js} +7 -11
  82. package/{chunk-JCQ3WCQ3.js → chunk-FOC4TORM.js} +69 -3
  83. package/chunk-FP46RAJQ.js +58 -0
  84. package/{chunk-JPXACKSW.js → chunk-G22P2J7O.js} +30 -81
  85. package/{chunk-7WHCIA5V.js → chunk-G5IAIGGD.js} +3 -8
  86. package/{chunk-FZENZCIA.js → chunk-GEC4CHS2.js} +19 -12
  87. package/chunk-GF4LYNNZ.js +25 -0
  88. package/{chunk-IYLUK67R.js → chunk-GH6SS2DZ.js} +25 -8
  89. package/chunk-HAZ6UVH4.js +368 -0
  90. package/{chunk-OKAXQFON.js → chunk-HB4J5HA6.js} +4 -4
  91. package/{chunk-324FWHUA.js → chunk-HHXF57CL.js} +12 -3
  92. package/chunk-HJTI7RZV.js +94 -0
  93. package/{chunk-HQUGB2HM.js → chunk-HMFKYZKP.js} +62 -50
  94. package/{chunk-Q2MPKE4B.js → chunk-HVRG27HI.js} +76 -26
  95. package/{chunk-46FETNLF.js → chunk-IN4B6Z2D.js} +7 -6
  96. package/chunk-IV6VUVLJ.js +88 -0
  97. package/{chunk-LLUBUHNT.js → chunk-IWWJSSST.js} +5 -9
  98. package/{chunk-7BIJFGKS.js → chunk-J22PFCQN.js} +106 -52
  99. package/chunk-J42X32PV.js +472 -0
  100. package/{chunk-LCBAMY2M.js → chunk-JKVOKKMQ.js} +0 -7
  101. package/{chunk-KT7S7ANZ.js → chunk-JPYOHIHX.js} +9 -9
  102. package/{chunk-R7XWZDOH.js → chunk-JUMQJSQF.js} +1423 -282
  103. package/{chunk-KVMLM5VD.js → chunk-KAHYBAEN.js} +211 -472
  104. package/{chunk-KLMBM6P6.js → chunk-KALCFXQO.js} +2454 -1115
  105. package/chunk-KDDXC2IH.js +148 -0
  106. package/chunk-KGKTN2NX.js +25 -0
  107. package/chunk-KGWE224L.js +246 -0
  108. package/{chunk-OYUMJMC5.js → chunk-KSV6T4AH.js} +6 -1
  109. package/{chunk-P27E22MA.js → chunk-L43DGEPZ.js} +1 -1
  110. package/{chunk-5BIDJVNX.js → chunk-L45P4JTE.js} +180 -31
  111. package/chunk-LHCIIUCX.js +222 -0
  112. package/{chunk-CBIGMWMI.js → chunk-LHJB4BXJ.js} +1 -1
  113. package/{chunk-TRRXYFTR.js → chunk-LOFRSJX2.js} +1 -0
  114. package/{chunk-SQL7YNED.js → chunk-LPXBBC32.js} +71 -5
  115. package/{chunk-BIDSIRTS.js → chunk-LTCZOOAM.js} +11 -17
  116. package/chunk-LUTSMSIL.js +425 -0
  117. package/chunk-LXP53WGF.js +168 -0
  118. package/{chunk-2CT2J3O6.js → chunk-M7VNNPVX.js} +2493 -4055
  119. package/chunk-MDAYRIP7.js +1889 -0
  120. package/{chunk-6B2OBX5B.js → chunk-MMXHIHJZ.js} +15 -47
  121. package/{chunk-HPDLPEUG.js → chunk-MPWQI36J.js} +267 -234
  122. package/chunk-MRACVEPZ.js +7 -0
  123. package/{chunk-ZYPXOQS2.js → chunk-MSFKHPA6.js} +1 -1
  124. package/chunk-NHLLXINQ.js +8 -0
  125. package/{chunk-QXTEEEIN.js → chunk-NJCTPWJU.js} +8 -8
  126. package/chunk-NLS7F5DW.js +1697 -0
  127. package/{chunk-FP37ELBT.js → chunk-NTBTVKKB.js} +17 -25
  128. package/{chunk-JLZJL3WC.js → chunk-O77F26YB.js} +370 -39
  129. package/{chunk-LVZVSLKO.js → chunk-O7ZY6SUK.js} +5 -22
  130. package/{chunk-YN23INFZ.js → chunk-OIOMBPCA.js} +23 -2
  131. package/{chunk-CJOOF4L5.js → chunk-OSZNERNW.js} +17 -14
  132. package/{chunk-JZO7KUF3.js → chunk-P4I55ASV.js} +313 -275
  133. package/{chunk-2C5VN7NH.js → chunk-P4XAHM4B.js} +1 -1
  134. package/chunk-PL5RKESU.js +40 -0
  135. package/chunk-Q5FJJ6XI.js +103 -0
  136. package/{chunk-WS36XPJD.js → chunk-Q5IXZF3S.js} +82 -6
  137. package/{createAgentAutomationAction-GRZ6XY7Q.js → chunk-QKM55LP2.js} +3 -160
  138. package/{chunk-WSLL7VV4.js → chunk-QXWXRBOL.js} +9 -9
  139. package/{chunk-MXA54TQM.js → chunk-QZYQ3Y3G.js} +1 -1
  140. package/{chunk-FE7G6DSP.js → chunk-R72QWIFO.js} +14 -4
  141. package/{chunk-5RGU3J7P.js → chunk-REAE2SZK.js} +0 -1
  142. package/chunk-RF576RYE.js +117 -0
  143. package/chunk-RI7SXDJW.js +1317 -0
  144. package/{chunk-FEIVARWR.js → chunk-RIOAPUGV.js} +238 -25
  145. package/{chunk-BZLGPM5B.js → chunk-RNLKWUVY.js} +7 -12
  146. package/{chunk-J7JRCOIW.js → chunk-RWXHGPWJ.js} +1 -1
  147. package/{chunk-J55F3IEZ.js → chunk-SARJZIGR.js} +1 -1
  148. package/chunk-SJFL32RD.js +356 -0
  149. package/{chunk-6SOWMEAY.js → chunk-SR57FDTX.js} +2 -258
  150. package/{chunk-MPGR4ZNR.js → chunk-SRVLHMES.js} +46 -42
  151. package/{chunk-CEKRIR22.js → chunk-SU4NCTW4.js} +1 -1
  152. package/{chunk-RD3QLZQV.js → chunk-SWJRX4M5.js} +324 -2
  153. package/{chunk-R3TUHCSJ.js → chunk-T3Y2NA4H.js} +8 -3
  154. package/{chunk-53W5BXLN.js → chunk-TCOHWKDM.js} +54 -55
  155. package/{chunk-KWNVPY6M.js → chunk-TJXO66M2.js} +8 -5
  156. package/{chunk-QIGQFON2.js → chunk-TXMFSGRY.js} +1 -1
  157. package/{chunk-ADYWV732.js → chunk-U5PSCTMR.js} +264 -177
  158. package/{chunk-UUCYUN6Y.js → chunk-UB7NV7NN.js} +1 -1
  159. package/{chunk-QGFLVQ6E.js → chunk-UBOTXA3Z.js} +4 -14
  160. package/{chunk-6YX2RAQN.js → chunk-UEZL3RBG.js} +89 -164
  161. package/{chunk-NCFKHYDM.js → chunk-UJL23HBL.js} +774 -119
  162. package/chunk-ULPU4C43.js +1710 -0
  163. package/{chunk-UA3QTA2S.js → chunk-VC3MAT33.js} +4442 -2570
  164. package/{chunk-VNHZJEQN.js → chunk-VCESLFF4.js} +3 -3
  165. package/chunk-VOO3YQQP.js +17157 -0
  166. package/{chunk-Y2GWUBNS.js → chunk-VZDSNDUD.js} +279 -149
  167. package/{chunk-6BMTKYAO.js → chunk-W2Z5E2R7.js} +126 -698
  168. package/{chunk-4ZCTKB27.js → chunk-W5GKF5ZW.js} +1 -0
  169. package/chunk-WEEB2JKA.js +443 -0
  170. package/{chunk-NUHQO3RB.js → chunk-WIVVNJUS.js} +1 -1
  171. package/chunk-WMBJDXMY.js +408 -0
  172. package/chunk-WSQLCWLQ.js +201 -0
  173. package/{chunk-OOVOAG4Q.js → chunk-WY6DMHMG.js} +1 -1
  174. package/{chunk-6K32PBRY.js → chunk-XJW6SLBZ.js} +3 -3
  175. package/{chunk-MNFUKRRU.js → chunk-XKNDVHF5.js} +7 -7
  176. package/{chunk-MHKPUGPD.js → chunk-XREMPMNK.js} +20 -4
  177. package/chunk-XT6C2QZW.js +46 -0
  178. package/chunk-XUDXQT7R.js +790 -0
  179. package/{chunk-ZEZC7IIM.js → chunk-YFSM2366.js} +35 -35
  180. package/{chunk-RIWKZT7E.js → chunk-YRPIUIEQ.js} +11 -9
  181. package/{chunk-U35UUM5K.js → chunk-YVOUSIIA.js} +1 -1
  182. package/{chunk-6VEO7Z3Y.js → chunk-Z27AH6A5.js} +6 -6
  183. package/chunk-Z3KTXWWB.js +76 -0
  184. package/{chunk-UWWOWTW2.js → chunk-Z7EP5HDL.js} +1 -1
  185. package/{chunk-YFEK7ACQ.js → chunk-ZB2E724W.js} +4 -4
  186. package/{chunk-YLAHYLDQ.js → chunk-ZC3CMUKU.js} +2 -89
  187. package/{chunk-5P3PPQVP.js → chunk-ZQAADXSF.js} +1 -1
  188. package/{cliAgentConfigHelpers-BXHQ3PXP.js → cliAgentConfigHelpers-BJJEXHSZ.js} +20 -14
  189. package/{cliAuthorityBrokerClient-TFNXJLXL.js → cliAuthorityBrokerClient-3SKOA7OZ.js} +3 -1
  190. package/cliAuthorityBrokerProcess-VIJEKQSX.js +34 -0
  191. package/{cliEnvHelpers-CNMP3RDX.js → cliEnvHelpers-NDMKN4X2.js} +6 -3
  192. package/{cliExecutor-K6FDZTQ2.js → cliExecutor-Z62UBJ5S.js} +12 -6
  193. package/cliLocalAgentRecordReader-KCZS2MZU.js +113 -0
  194. package/cloudAutomationCommands-2WQUGQSW.js +310 -0
  195. package/{commandRegistry-IFYQLPGM.js → commandRegistry-C64JBZJ3.js} +288 -121
  196. package/{contentThunks-QCFCD2X3.js → contentThunks-G3HEIRXC.js} +45 -43
  197. package/{cooldownCommands-WDOI5VD7.js → cooldownCommands-FPAFS7XG.js} +1 -1
  198. package/createAgentAutomationAction-DSBL3X3A.js +172 -0
  199. package/createDialogAction-OHFUHC53.js +86 -0
  200. package/{createPageAction-QCVBMP4C.js → createPageAction-E6JZSZLU.js} +49 -45
  201. package/{db-VR74ADGC.js → db-KTQ3LL2Q.js} +3 -3
  202. package/{dbSlice-RWPSVHBC.js → dbSlice-U3GPLEL3.js} +21 -16
  203. package/deleteDbKey-DRXKWJX5.js +86 -0
  204. package/{dialogCommands-4IEQUALS.js → dialogCommands-4EX2OTIC.js} +80 -66
  205. package/{dialogMessageRecord-OAV77LT7.js → dialogMessageRecord-2HJTEXQX.js} +1 -1
  206. package/dialogNotifyCommand-4SCE2Z2R.js +44 -0
  207. package/dialogPortabilityCommands-ZSFFHRX4.js +3036 -0
  208. package/{dialogSlice-XFYID6KE.js → dialogSlice-PRZCIJCH.js} +43 -42
  209. package/{dialogTraceCommand-Y67NRFCV.js → dialogTraceCommand-RKB76OVX.js} +84 -70
  210. package/{dialogUsageCommand-WJ3U6KZU.js → dialogUsageCommand-BP7HMRYP.js} +7 -4
  211. package/{docCreateCommands-QLRIWRQE.js → docCreateCommands-JGPNGIZ7.js} +68 -59
  212. package/{docDeleteCommands-XPRYA532.js → docDeleteCommands-XRJTNRDH.js} +68 -59
  213. package/{docReadCommands-EXQI7ETH.js → docReadCommands-6GFO4ARS.js} +67 -58
  214. package/{docStore-MWFUKZL2.js → docStore-QRLIWFTU.js} +16 -17
  215. package/{docUpdateCommands-EFBFQV77.js → docUpdateCommands-W2GXMUXW.js} +68 -59
  216. package/{ebookDownloaderAgentCommand-DYSKF5ZY.js → ebookDownloaderAgentCommand-2DHPGEOQ.js} +14 -17
  217. package/{fetchMessages-TQEUZD7H.js → fetchMessages-RGPIYEPZ.js} +2 -2
  218. package/{getPricing-5BLZRPTM.js → getPricing-BK6CUBAE.js} +8 -4
  219. package/{handleSendMessageAction-GG3TR62X.js → handleSendMessageAction-DHGWURJZ.js} +265 -119
  220. package/{hostCredentialCreate-26S6DDJ5.js → hostCredentialCreate-FPUZ7RMI.js} +138 -122
  221. package/index.js +36 -22
  222. package/{keys-RWF7UCB4.js → keys-FXEGMKSG.js} +2 -2
  223. package/localAutomationCommands-ZMU22RQJ.js +198 -0
  224. package/localAutomationRuntime-MU5FGJ3V.js +60 -0
  225. package/{localDialogRead-BJJT3TF5.js → localDialogRead-W2EVXISA.js} +2 -2
  226. package/{localRuntimeAdapter-VREWZWPC.js → localRuntimeAdapter-YBXQBV4G.js} +136 -119
  227. package/localRuntimeAuthority-LDXMEDO5.js +44 -0
  228. package/{localRuntimeDb-ZJFGNHML.js → localRuntimeDb-6TQZDLNU.js} +1 -1
  229. package/{machineCommands-CL5XK5UC.js → machineCommands-57RTUYRV.js} +251 -357
  230. package/{machineInfo-LWHTEBHJ.js → machineInfo-BJIU3WQ5.js} +4 -2
  231. package/machineWsRunDispatch-VBKV3FFE.js +227 -0
  232. package/{mcpLocalAuthorizeCommand-RBXJDE6J.js → mcpLocalAuthorizeCommand-J76SOJVZ.js} +40 -22
  233. package/mcpLocalManageCommands-USETIMHB.js +212 -0
  234. package/{memberThunks-43B7UYC5.js → memberThunks-7UERUEMI.js} +102 -22
  235. package/{memoryCommands-BC6REPQB.js → memoryCommands-N7NHEE55.js} +25 -34
  236. package/{models-ZX2BYIMB.js → models-TOXYINNM.js} +3 -2
  237. package/{offlineMarxistsAgentCommand-XVXUE6G5.js → offlineMarxistsAgentCommand-WZBJBCPZ.js} +16 -22
  238. package/package.json +3 -3
  239. package/parityCommands-LYDLWSLK.js +613 -0
  240. package/{projectArchive-OC63TWTD.js → projectArchive-KCNQDVWJ.js} +49 -45
  241. package/{providerPresetApply-NTJUINI6.js → providerPresetApply-IRJ56XIZ.js} +12 -16
  242. package/{providerRegistry-W45SLUV6.js → providerRegistry-26PAUYH2.js} +3 -13
  243. package/{read-KG6INYUT.js → read-SPSQ6NLR.js} +11 -10
  244. package/{readDocTool-N3GA52JR.js → readDocTool-ENUL2GNL.js} +5 -1
  245. package/{readlineWorkspace-2NO6D6IZ.js → readlineWorkspace-MKS7TAEF.js} +927 -573
  246. package/{rememberExplicit-CPAPONSI.js → rememberExplicit-7KX4HXQC.js} +4 -4
  247. package/remove-TNNDO635.js +32 -0
  248. package/{removeDialogAgentAction-EEVSOQOJ.js → removeDialogAgentAction-POPUZ3WU.js} +22 -26
  249. package/{runAgentClientLoop-U7V32UTD.js → runAgentClientLoop-KVILXQNI.js} +117 -82
  250. package/{runtimeDoctorCommands-V3M3JTUV.js → runtimeDoctorCommands-4J2DP4LZ.js} +23 -16
  251. package/{secretCommands-KVVZS7A6.js → secretCommands-CSTQYB6T.js} +2 -2
  252. package/{setDialogExtraReferencesAction-DNO5POHA.js → setDialogExtraReferencesAction-35THMVBP.js} +16 -17
  253. package/{setPrimaryDialogAgentAction-QABBEO4C.js → setPrimaryDialogAgentAction-WLXBNIG7.js} +23 -27
  254. package/{settingThunks-DVKG4X4S.js → settingThunks-6Y5U5M5N.js} +170 -497
  255. package/{skillDiscovery-5GEGWJ6N.js → skillDiscovery-IUEZZG2B.js} +3 -3
  256. package/{spaceCommands-7QKXKBDQ.js → spaceCommands-LXNJBO2U.js} +293 -58
  257. package/spacePruneCommand-2ITUFYBM.js +233 -0
  258. package/{store-Z53ICFL3.js → store-WSAVTR32.js} +3 -1
  259. package/{streamAgentChatTurn-UAGFOXNJ.js → streamAgentChatTurn-EY6MFKCA.js} +225 -137
  260. package/{switchDialogAgentAction-KYWJSGOO.js → switchDialogAgentAction-TG6BQRDA.js} +19 -23
  261. package/{tableCommands-EFA754RE.js → tableCommands-35G34R4B.js} +28 -49
  262. package/{toolApiClient-N5PYW2R3.js → toolApiClient-MPQIFYXP.js} +15 -4
  263. package/{tools-2Q2LBDUC.js → tools-CSLTRRUR.js} +73 -63
  264. package/{tuiRestart-4QDWLHYZ.js → tuiRestart-ALR4Q3JM.js} +20 -13
  265. package/tuiSummaryLlmCaller-3Y3JEXJK.js +52 -0
  266. package/{updateCommands-GJGRS6JK.js → updateCommands-GHQVP6Z5.js} +13 -8
  267. package/{updateDialogTitleAction-GGNTTI5L.js → updateDialogTitleAction-LFAWF5EW.js} +57 -58
  268. package/{usageCommand-WI6SQOPB.js → usageCommand-5VKW6T4C.js} +6 -8
  269. package/{usageRebuildCommand-WQRLLZAT.js → usageRebuildCommand-VUQETFMW.js} +11 -15
  270. package/{windowsSelfUpdate-C7LGVWYX.js → windowsSelfUpdate-SXSVXK4X.js} +2 -2
  271. package/workContext-ZAW6VXT7.js +18 -0
  272. package/workContextQueryProjection-CACY5VFE.js +23 -0
  273. package/{workloadLifecycle-DYX5ZMAT.js → workloadLifecycle-P2SJVV3S.js} +1 -1
  274. package/agentFavoriteCommands-7LOP3HUD.js +0 -186
  275. package/agentRecordCommands-TPE7NSZ6.js +0 -194
  276. package/agentRunCommand-DMVGBPLI.js +0 -232
  277. package/authCommand-V6EOMZX6.js +0 -79
  278. package/chunk-2MBTWINN.js +0 -89
  279. package/chunk-523DITKR.js +0 -32
  280. package/chunk-BUDVRYES.js +0 -2213
  281. package/chunk-BZMDWGQQ.js +0 -47
  282. package/chunk-GAHJLSDO.js +0 -107
  283. package/chunk-GYX6XTAI.js +0 -84
  284. package/chunk-HNUWUO75.js +0 -93
  285. package/chunk-HSBHS6KT.js +0 -33401
  286. package/chunk-KG27JIG4.js +0 -136
  287. package/chunk-OB4FBZXJ.js +0 -364
  288. package/chunk-OKH74FML.js +0 -3746
  289. package/chunk-OLZBQWZU.js +0 -6
  290. package/chunk-OOV5JN25.js +0 -1317
  291. package/chunk-OQFOE4SJ.js +0 -405
  292. package/chunk-PXYBUFDB.js +0 -53
  293. package/chunk-R3FZHW4Q.js +0 -103
  294. package/chunk-R3MV2GII.js +0 -106
  295. package/chunk-SCAC3NM5.js +0 -11751
  296. package/chunk-SR4FE5VD.js +0 -9
  297. package/chunk-SYTHYBMI.js +0 -3558
  298. package/chunk-UKZX3NHN.js +0 -48
  299. package/chunk-UVLYNWIE.js +0 -74
  300. package/chunk-VQX5JJNI.js +0 -861
  301. package/chunk-X4O7FJF5.js +0 -160
  302. package/chunk-YJPK35HB.js +0 -175
  303. package/chunk-YNIYE47Z.js +0 -105
  304. package/chunk-Z4PCXPUE.js +0 -127
  305. package/chunk-ZR5IVL4N.js +0 -862
  306. package/chunk-ZTHAJU3O.js +0 -2537
  307. package/cliAuthorityBrokerProcess-5ZFBTHLB.js +0 -22
  308. package/cliLocalAgentRecordReader-34UKRBLY.js +0 -104
  309. package/createDialogAction-ZAJERW62.js +0 -82
  310. package/deleteFile-ECU6FU5C.js +0 -55
  311. package/dialogNotifyCommand-IASQGEMW.js +0 -36
  312. package/localRuntimeAuthority-UF2DAQ3F.js +0 -28
  313. package/machineWsRunDispatch-TBVOYOAH.js +0 -209
  314. package/markdownToSlate-PXYAIBVL.js +0 -8
  315. package/tuiSummaryLlmCaller-HROLGN4F.js +0 -45
  316. package/webapi-QVV65DQF.js +0 -2487
  317. package/workContext-Y3ADAPZU.js +0 -14
  318. package/{chunk-USGHJSGO.js → chunk-GX2MFKF3.js} +3 -3
  319. package/{chunk-PHREU2KZ.js → chunk-WX266G2C.js} +0 -0
  320. package/{chunk-DXWGFL2Z.js → chunk-YY7IGJMN.js} +3 -3
@@ -9,9 +9,9 @@ import {
9
9
  listLocalWorkspaceSkillCatalogEntries,
10
10
  parseSkillFrontmatter,
11
11
  resolveSkillByName
12
- } from "./chunk-NUHQO3RB.js";
13
- import "./chunk-YQLAFJRQ.js";
14
- import "./chunk-GYX6XTAI.js";
12
+ } from "./chunk-WIVVNJUS.js";
13
+ import "./chunk-FBNVJ2TO.js";
14
+ import "./chunk-Z3KTXWWB.js";
15
15
  import "./chunk-2SXN7LAY.js";
16
16
  import "./chunk-KHCLMKZZ.js";
17
17
  import "./chunk-U67V476Y.js";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  authRoutes
3
- } from "./chunk-OYUMJMC5.js";
3
+ } from "./chunk-KSV6T4AH.js";
4
4
  import "./chunk-BYXBJQAS.js";
5
5
  import {
6
6
  createSpaceKey,
@@ -11,107 +11,118 @@ import {
11
11
  } from "./chunk-3PVYUPXK.js";
12
12
  import {
13
13
  readLiveDbRecordAfterTombstoneMerge
14
- } from "./chunk-YFEK7ACQ.js";
14
+ } from "./chunk-ZB2E724W.js";
15
15
  import {
16
16
  readDbRecord,
17
17
  writeAgentRecord
18
- } from "./chunk-6B2OBX5B.js";
19
- import "./chunk-FP37ELBT.js";
18
+ } from "./chunk-MMXHIHJZ.js";
19
+ import "./chunk-NTBTVKKB.js";
20
20
  import "./chunk-AMWMV56B.js";
21
21
  import "./chunk-UEILX4EV.js";
22
22
  import "./chunk-GBWGPTA7.js";
23
- import "./chunk-CBIGMWMI.js";
24
- import "./chunk-57V4PADY.js";
23
+ import "./chunk-LHJB4BXJ.js";
24
+ import "./chunk-CNYPQYXT.js";
25
25
  import "./chunk-ZNFJWEN4.js";
26
- import "./chunk-LHCGKAFO.js";
27
- import "./chunk-OOV5JN25.js";
26
+ import "./chunk-BKP325XS.js";
27
+ import "./chunk-Q5FJJ6XI.js";
28
28
  import "./chunk-2E4BYAUE.js";
29
29
  import "./chunk-AL3TYDIF.js";
30
- import "./chunk-PIVTQRX6.js";
31
- import "./chunk-HNUWUO75.js";
30
+ import "./chunk-DDKA6V6X.js";
32
31
  import "./chunk-CHOZJMJS.js";
33
- import "./chunk-DMPZMYH4.js";
34
- import "./chunk-6K32PBRY.js";
32
+ import "./chunk-3R4AYHJR.js";
33
+ import "./chunk-AQNWWJLH.js";
34
+ import "./chunk-XJW6SLBZ.js";
35
35
  import "./chunk-BYXBJQAS.js";
36
- import "./chunk-BZLGPM5B.js";
37
- import "./chunk-AIFQKNPP.js";
36
+ import "./chunk-RNLKWUVY.js";
37
+ import "./chunk-CL33RFD7.js";
38
38
  import "./chunk-56GBUMO5.js";
39
- import "./chunk-ZR5IVL4N.js";
40
- import "./chunk-Q2MPKE4B.js";
39
+ import "./chunk-D3ONA3FP.js";
40
+ import "./chunk-HVRG27HI.js";
41
41
  import "./chunk-LS5KAVFQ.js";
42
- import "./chunk-FXEPZKNJ.js";
43
- import "./chunk-X4O7FJF5.js";
44
- import "./chunk-TLE77UJ5.js";
45
- import "./chunk-QIGQFON2.js";
46
- import "./chunk-KXOPLLFP.js";
47
- import "./chunk-DNNPARJK.js";
48
- import "./chunk-2MBTWINN.js";
49
- import "./chunk-7WHCIA5V.js";
42
+ import "./chunk-2MIZHEND.js";
43
+ import "./chunk-4IVMDQBA.js";
44
+ import "./chunk-2OROOEOQ.js";
45
+ import "./chunk-TXMFSGRY.js";
46
+ import "./chunk-CA7LGAHV.js";
47
+ import "./chunk-3QMN3T6L.js";
48
+ import "./chunk-LXP53WGF.js";
49
+ import "./chunk-4Y6CZ2N4.js";
50
+ import "./chunk-G5IAIGGD.js";
50
51
  import "./chunk-5ZUL4CUO.js";
51
- import "./chunk-2FZVXOFX.js";
52
+ import "./chunk-CEIWXKHP.js";
52
53
  import "./chunk-H57T64RA.js";
53
- import "./chunk-UKZX3NHN.js";
54
- import "./chunk-SR4FE5VD.js";
54
+ import "./chunk-WMBJDXMY.js";
55
55
  import "./chunk-5MMAK75Q.js";
56
- import "./chunk-USGHJSGO.js";
56
+ import "./chunk-GX2MFKF3.js";
57
57
  import "./chunk-E6A5NHDH.js";
58
58
  import "./chunk-KX6YBIHG.js";
59
- import "./chunk-MJBLXJMP.js";
59
+ import "./chunk-2I4R6ZRV.js";
60
60
  import "./chunk-HEVRQGGH.js";
61
61
  import "./chunk-EWQ3HGNZ.js";
62
62
  import "./chunk-PSCNXBYA.js";
63
63
  import "./chunk-IVK2KT3H.js";
64
64
  import "./chunk-DWLEOOGR.js";
65
65
  import "./chunk-7DPNBQSV.js";
66
- import "./chunk-OW765XBU.js";
67
- import "./chunk-YQLAFJRQ.js";
68
- import "./chunk-GYX6XTAI.js";
66
+ import "./chunk-FBNVJ2TO.js";
67
+ import "./chunk-Z3KTXWWB.js";
69
68
  import "./chunk-2SXN7LAY.js";
69
+ import "./chunk-HNMXYYJR.js";
70
+ import "./chunk-OW765XBU.js";
70
71
  import "./chunk-G7Y4GXTY.js";
71
72
  import "./chunk-6UBGXX2W.js";
72
73
  import "./chunk-BV3FLP2L.js";
73
- import "./chunk-4ZCTKB27.js";
74
- import "./chunk-KVMLM5VD.js";
74
+ import "./chunk-W5GKF5ZW.js";
75
+ import "./chunk-KAHYBAEN.js";
76
+ import "./chunk-J42X32PV.js";
75
77
  import "./chunk-EUGTFFO6.js";
76
78
  import "./chunk-AETZ7AD6.js";
77
- import "./chunk-5P3PPQVP.js";
79
+ import "./chunk-ZQAADXSF.js";
78
80
  import "./chunk-KHCLMKZZ.js";
79
- import "./chunk-SYTHYBMI.js";
81
+ import "./chunk-DLXL4NSL.js";
80
82
  import "./chunk-OJKUU3LP.js";
81
83
  import "./chunk-YZMNK53S.js";
82
- import "./chunk-QGFLVQ6E.js";
84
+ import "./chunk-UBOTXA3Z.js";
83
85
  import "./chunk-BR3GT6MR.js";
84
- import "./chunk-JCQ3WCQ3.js";
85
- import "./chunk-UUCYUN6Y.js";
86
- import "./chunk-YLAHYLDQ.js";
87
- import "./chunk-RIWKZT7E.js";
86
+ import "./chunk-FOC4TORM.js";
87
+ import "./chunk-UB7NV7NN.js";
88
+ import "./chunk-O7ZY6SUK.js";
89
+ import "./chunk-KGKTN2NX.js";
90
+ import "./chunk-BVYHE6QD.js";
91
+ import "./chunk-HJTI7RZV.js";
92
+ import "./chunk-ZC3CMUKU.js";
93
+ import "./chunk-YRPIUIEQ.js";
88
94
  import "./chunk-M2EJHDJP.js";
89
95
  import "./chunk-I42VC5KR.js";
96
+ import "./chunk-3EUW3WEO.js";
97
+ import "./chunk-WWC7I6TA.js";
90
98
  import "./chunk-U6VC4MU4.js";
99
+ import "./chunk-RI7SXDJW.js";
100
+ import "./chunk-7LR2IFUH.js";
101
+ import "./chunk-JRTNUU5Z.js";
102
+ import "./chunk-KUG52IAP.js";
91
103
  import {
92
104
  parseUserIdFromAuthToken,
93
105
  readOption,
94
106
  resolveAuthToken,
95
107
  resolveServerCandidates,
96
108
  resolveServerUrl
97
- } from "./chunk-BIDSIRTS.js";
98
- import "./chunk-OLZBQWZU.js";
99
- import "./chunk-LCBAMY2M.js";
100
- import "./chunk-4O22PGNQ.js";
101
- import "./chunk-EJQE5HB7.js";
102
- import "./chunk-6SOWMEAY.js";
103
- import "./chunk-HNMXYYJR.js";
104
- import "./chunk-LVZVSLKO.js";
105
- import "./chunk-2JHGUL5K.js";
106
- import "./chunk-3EUW3WEO.js";
107
- import "./chunk-WWC7I6TA.js";
108
- import "./chunk-OKH74FML.js";
109
- import "./chunk-JRTNUU5Z.js";
110
- import "./chunk-KUG52IAP.js";
109
+ } from "./chunk-LTCZOOAM.js";
110
+ import {
111
+ hasCliFlag
112
+ } from "./chunk-RF576RYE.js";
113
+ import "./chunk-72VWN4VK.js";
114
+ import "./chunk-JKVOKKMQ.js";
115
+ import "./chunk-IV6VUVLJ.js";
111
116
  import "./chunk-G3SUCT4W.js";
117
+ import "./chunk-FI4DPLR7.js";
112
118
  import "./chunk-4SN6J65J.js";
113
119
  import "./chunk-CF7PE763.js";
114
- import "./chunk-JPXACKSW.js";
120
+ import "./chunk-4O22PGNQ.js";
121
+ import "./chunk-DSBRIUX5.js";
122
+ import "./chunk-35JIFLIG.js";
123
+ import "./chunk-SR57FDTX.js";
124
+ import "./chunk-MDAYRIP7.js";
125
+ import "./chunk-G22P2J7O.js";
115
126
  import "./chunk-QSJ3HFEF.js";
116
127
  import "./chunk-U67V476Y.js";
117
128
 
@@ -196,10 +207,10 @@ function resolveFilePageUrl(args) {
196
207
  return args.spaceId ? `${args.serverUrl}/space/${args.spaceId}/${pageKey}` : `${args.serverUrl}/${pageKey}`;
197
208
  }
198
209
  function hasHelpArg(args) {
199
- return args.includes("--help") || args.includes("-h");
210
+ return hasCliFlag(args, "--help") || hasCliFlag(args, "-h");
200
211
  }
201
212
  function hasFlag(args, flag) {
202
- return args.includes(flag);
213
+ return hasCliFlag(args, flag);
203
214
  }
204
215
  function writeOutput(deps, text) {
205
216
  (deps.output ?? process.stdout).write(text);
@@ -633,12 +644,236 @@ async function runSpaceUploadCommand(args, deps) {
633
644
  }
634
645
  return 0;
635
646
  }
647
+ async function callSpaceCrudApi(args, deps, method, path, body) {
648
+ const token = resolveAuthToken(args, deps.env);
649
+ if (!token) {
650
+ writeOutput(deps, "[nolo] Auth token required. Run `nolo login` or set AUTH_TOKEN.\n");
651
+ return { ok: false, exitCode: 1 };
652
+ }
653
+ const serverUrl = resolveServerUrl(args, deps.env);
654
+ const fetchFn = deps.fetchImpl ?? fetch;
655
+ const res = await fetchFn(`${serverUrl}${path}`, {
656
+ method,
657
+ headers: {
658
+ "Content-Type": "application/json",
659
+ Authorization: `Bearer ${token}`
660
+ },
661
+ ...body !== void 0 ? { body: JSON.stringify(body) } : {}
662
+ });
663
+ const payload = await res.json().catch(() => ({}));
664
+ if (!res.ok) {
665
+ writeOutput(deps, `[nolo] ${payload?.error || `Request failed (HTTP ${res.status})`}
666
+ `);
667
+ return { ok: false, exitCode: 1 };
668
+ }
669
+ return { ok: true, data: payload };
670
+ }
671
+ function collectPositionalArgs(args, valueFlags) {
672
+ const out = [];
673
+ for (let i = 0; i < args.length; i++) {
674
+ const cur = args[i];
675
+ if (valueFlags.has(cur)) {
676
+ i += 1;
677
+ continue;
678
+ }
679
+ if (cur.startsWith("--")) continue;
680
+ out.push(cur);
681
+ }
682
+ return out;
683
+ }
684
+ async function runSpaceUpdateCommand(args, deps) {
685
+ const positionals = collectPositionalArgs(args, /* @__PURE__ */ new Set(["--name", "--description", "--visibility", "--server", "--token"]));
686
+ const spaceId = positionals[0];
687
+ if (!spaceId) {
688
+ writeOutput(deps, "Usage: nolo space update <spaceId> [--name <name>] [--description <desc>] [--visibility private|public] [--json]\n");
689
+ return 1;
690
+ }
691
+ const body = {};
692
+ const name = readOption(args, "--name");
693
+ const description = readOption(args, "--description");
694
+ const visibility = readOption(args, "--visibility");
695
+ if (name !== void 0) body.name = name;
696
+ if (description !== void 0) body.description = description;
697
+ if (visibility !== void 0) body.visibility = visibility;
698
+ const res = await callSpaceCrudApi(args, deps, "PATCH", `/api/v1/spaces/${encodeURIComponent(normalizeSpaceId(spaceId))}`, body);
699
+ if (!res.ok) return res.exitCode;
700
+ if (hasFlag(args, "--json")) {
701
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
702
+ `);
703
+ } else {
704
+ writeOutput(deps, `Updated space ${res.data.space?.spaceId} (${(res.data.updatedFields ?? []).join(", ")})
705
+ `);
706
+ }
707
+ return 0;
708
+ }
709
+ async function runSpaceDeleteCommand(args, deps) {
710
+ const positionals = collectPositionalArgs(args, /* @__PURE__ */ new Set(["--items", "--target", "--server", "--token"]));
711
+ const spaceId = positionals[0];
712
+ if (!spaceId) {
713
+ writeOutput(deps, "Usage: nolo space delete <spaceId> [--items unlink|move|delete] [--target <spaceId>] [--dry-run] [--json]\n");
714
+ return 1;
715
+ }
716
+ const itemDisposition = readOption(args, "--items") ?? "unlink";
717
+ const targetSpaceId = readOption(args, "--target");
718
+ const dryRun = hasFlag(args, "--dry-run");
719
+ const res = await callSpaceCrudApi(args, deps, "POST", `/api/v1/spaces/${encodeURIComponent(normalizeSpaceId(spaceId))}/delete`, {
720
+ itemDisposition,
721
+ ...targetSpaceId ? { targetSpaceId } : {},
722
+ dryRun
723
+ });
724
+ if (!res.ok) return res.exitCode;
725
+ if (hasFlag(args, "--json")) {
726
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
727
+ `);
728
+ } else {
729
+ const prefix = dryRun ? "[dry-run] Would delete" : "Deleted";
730
+ writeOutput(deps, `${prefix} space ${res.data.spaceId} (${res.data.itemCount ?? 0} items, disposition: ${res.data.itemDisposition})
731
+ `);
732
+ }
733
+ return 0;
734
+ }
735
+ async function runSpaceMergeCommand(args, deps) {
736
+ const fromRaw = readOption(args, "--from");
737
+ const targetSpaceId = readOption(args, "--to");
738
+ if (!fromRaw || !targetSpaceId) {
739
+ writeOutput(deps, "Usage: nolo space merge --from <spaceId1,spaceId2> --to <targetSpaceId> [--dry-run] [--json]\n");
740
+ return 1;
741
+ }
742
+ const sourceSpaceIds = fromRaw.split(",").map((s) => s.trim()).filter(Boolean);
743
+ const dryRun = hasFlag(args, "--dry-run");
744
+ const res = await callSpaceCrudApi(args, deps, "POST", "/api/v1/spaces/merge", {
745
+ sourceSpaceIds,
746
+ targetSpaceId,
747
+ dryRun
748
+ });
749
+ if (!res.ok) return res.exitCode;
750
+ if (hasFlag(args, "--json")) {
751
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
752
+ `);
753
+ } else {
754
+ const prefix = dryRun ? "[dry-run] Would merge" : "Merged";
755
+ writeOutput(
756
+ deps,
757
+ `${prefix} ${sourceSpaceIds.join(", ")} -> ${res.data.targetSpaceId} (${res.data.itemsToMoveCount ?? res.data.itemsMovedCount ?? 0} items)
758
+ `
759
+ );
760
+ }
761
+ return 0;
762
+ }
763
+ async function runSpaceItemsListCommand(args, deps) {
764
+ const positionals = collectPositionalArgs(args, /* @__PURE__ */ new Set(["--type", "--category", "--limit", "--server", "--token"]));
765
+ const spaceId = positionals[0];
766
+ if (!spaceId) {
767
+ writeOutput(deps, "Usage: nolo space items <spaceId> [--type <type>] [--category <catId>] [--limit <n>] [--json]\n");
768
+ return 1;
769
+ }
770
+ const params = new URLSearchParams();
771
+ const type = readOption(args, "--type");
772
+ const category = readOption(args, "--category");
773
+ const limit = readOption(args, "--limit");
774
+ if (type) params.set("type", type);
775
+ if (category) params.set("categoryId", category);
776
+ if (limit) params.set("limit", limit);
777
+ const qs = params.toString() ? `?${params.toString()}` : "";
778
+ const res = await callSpaceCrudApi(args, deps, "GET", `/api/v1/spaces/${encodeURIComponent(normalizeSpaceId(spaceId))}/items${qs}`);
779
+ if (!res.ok) return res.exitCode;
780
+ if (hasFlag(args, "--json")) {
781
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
782
+ `);
783
+ } else {
784
+ const items = Array.isArray(res.data.items) ? res.data.items : [];
785
+ for (const item of items) {
786
+ writeOutput(deps, `${item.contentKey} ${item.type ?? "-"} ${item.title ?? ""}
787
+ `);
788
+ }
789
+ writeOutput(deps, `Total: ${res.data.total ?? items.length}
790
+ `);
791
+ }
792
+ return 0;
793
+ }
794
+ async function runSpaceItemsMoveCommand(args, deps) {
795
+ const positionals = collectPositionalArgs(args, /* @__PURE__ */ new Set(["--to", "--from", "--category", "--server", "--token"]));
796
+ const toRaw = readOption(args, "--to");
797
+ if (positionals.length === 0 || toRaw === void 0) {
798
+ writeOutput(deps, "Usage: nolo space move <contentKey...> --to <targetSpaceId|none> [--from <sourceSpaceId>] [--category <catId>] [--json]\n");
799
+ return 1;
800
+ }
801
+ const sourceSpaceId = readOption(args, "--from");
802
+ const categoryId = readOption(args, "--category");
803
+ const targetSpaceId = toRaw === "none" || toRaw === "null" ? null : toRaw;
804
+ const res = await callSpaceCrudApi(args, deps, "POST", "/api/v1/spaces/items/move", {
805
+ contentKeys: positionals,
806
+ ...sourceSpaceId ? { sourceSpaceId } : {},
807
+ targetSpaceId,
808
+ ...categoryId !== void 0 ? { categoryId } : {}
809
+ });
810
+ if (!res.ok) return res.exitCode;
811
+ if (hasFlag(args, "--json")) {
812
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
813
+ `);
814
+ } else {
815
+ writeOutput(deps, `Moved ${res.data.movedCount ?? positionals.length} item(s) -> ${targetSpaceId ?? "(unlinked)"}
816
+ `);
817
+ }
818
+ return 0;
819
+ }
820
+ async function runSpaceItemsUnlinkCommand(args, deps) {
821
+ const positionals = collectPositionalArgs(args, /* @__PURE__ */ new Set(["--server", "--token"]));
822
+ const [spaceId, ...contentKeys] = positionals;
823
+ if (!spaceId || contentKeys.length === 0) {
824
+ writeOutput(deps, "Usage: nolo space unlink <spaceId> <contentKey...> [--json]\n");
825
+ return 1;
826
+ }
827
+ const res = await callSpaceCrudApi(args, deps, "POST", `/api/v1/spaces/${encodeURIComponent(normalizeSpaceId(spaceId))}/items/unlink`, {
828
+ contentKeys
829
+ });
830
+ if (!res.ok) return res.exitCode;
831
+ if (hasFlag(args, "--json")) {
832
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
833
+ `);
834
+ } else {
835
+ writeOutput(deps, `Unlinked ${res.data.unlinkedCount ?? contentKeys.length} item(s) from space ${res.data.spaceId}
836
+ `);
837
+ }
838
+ return 0;
839
+ }
840
+ async function runSpaceItemsDeleteCommand(args, deps) {
841
+ const positionals = collectPositionalArgs(args, /* @__PURE__ */ new Set(["--space", "--server", "--token"]));
842
+ if (positionals.length === 0) {
843
+ writeOutput(deps, "Usage: nolo space delete-items <contentKey...> [--space <spaceId>] [--dry-run] [--json]\n");
844
+ return 1;
845
+ }
846
+ const spaceId = readOption(args, "--space");
847
+ const dryRun = hasFlag(args, "--dry-run");
848
+ const res = await callSpaceCrudApi(args, deps, "POST", "/api/v1/spaces/items/delete", {
849
+ contentKeys: positionals,
850
+ ...spaceId ? { spaceId } : {},
851
+ dryRun
852
+ });
853
+ if (!res.ok) return res.exitCode;
854
+ if (hasFlag(args, "--json")) {
855
+ writeOutput(deps, `${JSON.stringify(res.data, null, 2)}
856
+ `);
857
+ } else {
858
+ const prefix = dryRun ? "[dry-run] Would delete" : "Deleted";
859
+ writeOutput(deps, `${prefix} ${res.data.deletableCount ?? res.data.deletedCount ?? 0} item(s)
860
+ `);
861
+ }
862
+ return 0;
863
+ }
636
864
  export {
637
865
  resolveFilePageUrl,
638
866
  resolveUploadMimeType,
639
867
  resolveUploadName,
640
868
  runSpaceAcceptInviteCommand,
641
869
  runSpaceCreateCommand,
870
+ runSpaceDeleteCommand,
642
871
  runSpaceInviteCommand,
872
+ runSpaceItemsDeleteCommand,
873
+ runSpaceItemsListCommand,
874
+ runSpaceItemsMoveCommand,
875
+ runSpaceItemsUnlinkCommand,
876
+ runSpaceMergeCommand,
877
+ runSpaceUpdateCommand,
643
878
  runSpaceUploadCommand
644
879
  };
@@ -0,0 +1,233 @@
1
+ import {
2
+ createSpaceKey,
3
+ normalizeSpaceId
4
+ } from "./chunk-UAD2WT54.js";
5
+ import {
6
+ isTombstoneRecord
7
+ } from "./chunk-BV3FLP2L.js";
8
+ import "./chunk-U6VC4MU4.js";
9
+ import {
10
+ readOption,
11
+ resolveAuthToken,
12
+ resolveServerUrl
13
+ } from "./chunk-LTCZOOAM.js";
14
+ import {
15
+ hasCliFlag
16
+ } from "./chunk-RF576RYE.js";
17
+ import "./chunk-72VWN4VK.js";
18
+ import "./chunk-JKVOKKMQ.js";
19
+ import "./chunk-IV6VUVLJ.js";
20
+ import "./chunk-G3SUCT4W.js";
21
+ import "./chunk-FI4DPLR7.js";
22
+ import "./chunk-4SN6J65J.js";
23
+ import "./chunk-CF7PE763.js";
24
+ import "./chunk-U67V476Y.js";
25
+
26
+ // packages/create/space/danglingRefs.ts
27
+ function classifySpaceContentTarget(target) {
28
+ if (!target || typeof target !== "object") {
29
+ return "missing";
30
+ }
31
+ if (isTombstoneRecord(target)) {
32
+ return "tombstone";
33
+ }
34
+ return "live";
35
+ }
36
+ async function buildSpaceDanglingRefReport(args) {
37
+ const spaceId = normalizeSpaceId(args.spaceId) || args.spaceId.trim();
38
+ const spaceName = (args.spaceName ?? "").trim() || spaceId;
39
+ const rawContents = args.contents && typeof args.contents === "object" ? args.contents : {};
40
+ const entries = [];
41
+ for (const [entryKey, rawEntry] of Object.entries(rawContents)) {
42
+ if (!rawEntry || typeof rawEntry !== "object") continue;
43
+ const entry = rawEntry;
44
+ if (isTombstoneRecord(entry)) continue;
45
+ const contentKey = typeof entry.contentKey === "string" && entry.contentKey.trim() ? entry.contentKey.trim() : entryKey;
46
+ const title = typeof entry.title === "string" && entry.title.trim() ? entry.title.trim() : contentKey;
47
+ const type = typeof entry.type === "string" && entry.type.trim() ? entry.type.trim() : "unknown";
48
+ entries.push({ entryKey, contentKey, title, type });
49
+ }
50
+ const concurrency = Math.max(1, Math.min(args.concurrency ?? 8, 16));
51
+ const dangling = [];
52
+ let liveCount = 0;
53
+ let unreadableCount = 0;
54
+ let cursor = 0;
55
+ const worker = async () => {
56
+ while (cursor < entries.length) {
57
+ const idx = cursor++;
58
+ const item = entries[idx];
59
+ let outcome;
60
+ try {
61
+ outcome = await args.probeTarget(item.contentKey);
62
+ } catch {
63
+ outcome = { status: "unreadable" };
64
+ }
65
+ if (outcome.status === "live") {
66
+ liveCount += 1;
67
+ } else if (outcome.status === "tombstone" || outcome.status === "missing") {
68
+ dangling.push({
69
+ entryKey: item.entryKey,
70
+ contentKey: item.contentKey,
71
+ title: item.title,
72
+ type: item.type,
73
+ reason: outcome.status
74
+ });
75
+ } else {
76
+ unreadableCount += 1;
77
+ }
78
+ }
79
+ };
80
+ await Promise.all(
81
+ Array.from({ length: Math.min(concurrency, Math.max(1, entries.length)) }, () => worker())
82
+ );
83
+ dangling.sort((a, b) => a.entryKey.localeCompare(b.entryKey));
84
+ return {
85
+ spaceId,
86
+ spaceName,
87
+ totalRefs: entries.length,
88
+ liveCount,
89
+ unreadableCount,
90
+ dangling
91
+ };
92
+ }
93
+ function buildPruneDanglingPatch(dangling, allowedEntryKeys) {
94
+ const allowSet = allowedEntryKeys && allowedEntryKeys.length > 0 ? new Set(allowedEntryKeys.map((k) => k.trim()).filter(Boolean)) : null;
95
+ const patchContents = {};
96
+ for (const item of dangling) {
97
+ if (allowSet && !allowSet.has(item.entryKey) && !allowSet.has(item.contentKey)) {
98
+ continue;
99
+ }
100
+ patchContents[item.entryKey] = null;
101
+ }
102
+ return patchContents;
103
+ }
104
+ function formatSpaceDanglingRefReport(report, options) {
105
+ const lines = [
106
+ `Space: ${report.spaceName} (${report.spaceId})`,
107
+ `Total refs: ${report.totalRefs} | Live: ${report.liveCount} | Dangling: ${report.dangling.length} | Unreadable (skipped): ${report.unreadableCount}`
108
+ ];
109
+ if (report.dangling.length === 0) {
110
+ lines.push("No dangling references found.");
111
+ return lines.join("\n");
112
+ }
113
+ lines.push("");
114
+ for (const item of report.dangling) {
115
+ lines.push(`- [${item.reason}] ${item.type} ${item.title} (${item.entryKey})`);
116
+ }
117
+ if (options?.applied) {
118
+ lines.push("");
119
+ lines.push(`Pruned ${options.prunedCount ?? report.dangling.length} dangling reference(s).`);
120
+ } else {
121
+ lines.push("");
122
+ lines.push("Dry-run only. Re-run with --apply (or confirmedEntryKeys) to remove these dangling references.");
123
+ }
124
+ return lines.join("\n");
125
+ }
126
+
127
+ // packages/cli/spacePruneCommand.ts
128
+ function printPruneUsage(output) {
129
+ output.write(`Usage:
130
+ nolo space prune --space <spaceId> [--apply] [--json]
131
+
132
+ Options:
133
+ --space <spaceId> Target space ID to inspect (with or without space- prefix).
134
+ --apply Remove confirmed dangling (missing/tombstoned) references from space.contents.
135
+ Without --apply, runs in safe dry-run mode.
136
+ --json Emit machine-readable JSON output.
137
+ `);
138
+ }
139
+ async function runSpacePruneCommand(args, deps = {}) {
140
+ const output = deps.output ?? process.stdout;
141
+ if (hasCliFlag(args, "--help") || hasCliFlag(args, "-h")) {
142
+ printPruneUsage(output);
143
+ return 0;
144
+ }
145
+ const env = deps.env ?? process.env;
146
+ const fetchImpl = deps.fetchImpl ?? fetch;
147
+ const serverUrl = resolveServerUrl(args, env).replace(/\/+$/, "");
148
+ const authToken = resolveAuthToken(args, env);
149
+ if (!authToken) {
150
+ throw new Error("space prune requires an auth token. Pass --token or set AUTH_TOKEN.");
151
+ }
152
+ const spaceIdRaw = readOption(args, "--space");
153
+ const spaceId = spaceIdRaw ? normalizeSpaceId(spaceIdRaw) : "";
154
+ if (!spaceId) {
155
+ throw new Error("space prune requires --space <spaceId>.");
156
+ }
157
+ const apply = hasCliFlag(args, "--apply") || hasCliFlag(args, "--fix");
158
+ const jsonOutput = hasCliFlag(args, "--json");
159
+ const headers = { Authorization: `Bearer ${authToken}` };
160
+ const spaceKey = createSpaceKey.space(spaceId);
161
+ const spaceRes = await fetchImpl(
162
+ `${serverUrl}/api/v1/db/read/${encodeURIComponent(spaceKey)}`,
163
+ { headers }
164
+ );
165
+ if (spaceRes.status === 404) {
166
+ throw new Error(`Space not found: ${spaceId}`);
167
+ }
168
+ if (!spaceRes.ok) {
169
+ throw new Error(`Failed to read space ${spaceId}: HTTP ${spaceRes.status}`);
170
+ }
171
+ const spaceRecord = await spaceRes.json();
172
+ if (!spaceRecord || isTombstoneRecord(spaceRecord)) {
173
+ throw new Error(`Space is deleted or unavailable: ${spaceId}`);
174
+ }
175
+ const probeTarget = async (contentKey) => {
176
+ const res = await fetchImpl(
177
+ `${serverUrl}/api/v1/db/read/${encodeURIComponent(contentKey)}`,
178
+ { headers }
179
+ );
180
+ if (res.status === 404) {
181
+ return { status: "missing" };
182
+ }
183
+ if (!res.ok) {
184
+ return { status: "unreadable" };
185
+ }
186
+ const target = await res.json().catch(() => null);
187
+ return { status: classifySpaceContentTarget(target), record: target };
188
+ };
189
+ const report = await buildSpaceDanglingRefReport({
190
+ spaceId,
191
+ spaceName: typeof spaceRecord.name === "string" ? spaceRecord.name : spaceId,
192
+ contents: spaceRecord.contents ?? {},
193
+ probeTarget
194
+ });
195
+ let prunedCount = 0;
196
+ if (apply && report.dangling.length > 0) {
197
+ const contentsPatch = buildPruneDanglingPatch(report.dangling);
198
+ const patchRes = await fetchImpl(
199
+ `${serverUrl}/api/v1/db/patch/${encodeURIComponent(spaceKey)}`,
200
+ {
201
+ method: "PATCH",
202
+ headers: {
203
+ ...headers,
204
+ "Content-Type": "application/json"
205
+ },
206
+ body: JSON.stringify({
207
+ contents: contentsPatch,
208
+ updatedAt: Date.now()
209
+ })
210
+ }
211
+ );
212
+ if (!patchRes.ok) {
213
+ const detail = await patchRes.text().catch(() => "");
214
+ throw new Error(`Failed to prune space ${spaceId}: HTTP ${patchRes.status} ${detail}`.trim());
215
+ }
216
+ prunedCount = Object.keys(contentsPatch).length;
217
+ }
218
+ if (jsonOutput) {
219
+ output.write(
220
+ `${JSON.stringify({ ...report, applied: apply, prunedCount }, null, 2)}
221
+ `
222
+ );
223
+ return 0;
224
+ }
225
+ output.write(
226
+ `${formatSpaceDanglingRefReport(report, { applied: apply, prunedCount })}
227
+ `
228
+ );
229
+ return 0;
230
+ }
231
+ export {
232
+ runSpacePruneCommand
233
+ };