very-happy-cli 0.2.191 → 0.2.193

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 (214) hide show
  1. package/dist/{AcpBackend-CCy_9AfR.mjs → AcpBackend-B4PwjqHt.mjs} +3 -3
  2. package/dist/{AcpBackend-DgrIc1vH.cjs → AcpBackend-DtJCgftG.cjs} +3 -3
  3. package/dist/{AcpSessionManager-CQnxx7gD.mjs → AcpSessionManager-BzKWgkdP.mjs} +2 -2
  4. package/dist/{AcpSessionManager-DVOzCD3P.cjs → AcpSessionManager-D4qshX_H.cjs} +2 -2
  5. package/dist/{BasePermissionHandler-C9Ag7yvs.cjs → BasePermissionHandler-5iG-cvA2.cjs} +1 -1
  6. package/dist/{BasePermissionHandler-DYLN6Ec9.mjs → BasePermissionHandler-DV6UM6e9.mjs} +1 -1
  7. package/dist/account-Dco_nGT4.mjs +297 -0
  8. package/dist/account-DvpA60oU.cjs +302 -0
  9. package/dist/accountService-Cd7bnkfd.mjs +916 -0
  10. package/dist/accountService-CuUSJDhP.cjs +921 -0
  11. package/dist/{acpSessionResume-TvP_4Zq2.cjs → acpSessionResume-Bk9mjXZ9.cjs} +1 -1
  12. package/dist/{acpSessionResume-Bi7pA1n_.mjs → acpSessionResume-TQwN9ZZE.mjs} +1 -1
  13. package/dist/{agentHome-DGv105SR.mjs → agentHome-Bep8semY.mjs} +4 -4
  14. package/dist/{agentHome-DNUKJWOY.cjs → agentHome-c2dlgcw1.cjs} +4 -4
  15. package/dist/{api-BBxZ7y2z.cjs → api-CBE_a88I.cjs} +10 -10
  16. package/dist/{api-jfeMRg5R.mjs → api-DUfunY3x.mjs} +10 -10
  17. package/dist/{apiMachine-DqyjKBZG.cjs → apiMachine-BqtG0IWm.cjs} +83 -27
  18. package/dist/{apiMachine-DRJ7y-BB.mjs → apiMachine-CU_bw5nV.mjs} +78 -22
  19. package/dist/{attachmentContent-BO2njyza.cjs → attachmentContent-B3AzuYqk.cjs} +2 -2
  20. package/dist/{attachmentContent-Dm_RIs5L.mjs → attachmentContent-KNIZxwlu.mjs} +2 -2
  21. package/dist/{auth-BYDtjVNb.mjs → auth-CZ7pKS-j.mjs} +8 -8
  22. package/dist/{auth-DnxoVkkf.cjs → auth-DCjxpI6Z.cjs} +5 -5
  23. package/dist/{auth-DLR3ksCF.cjs → auth-SJ_dPw7H.cjs} +8 -8
  24. package/dist/{auth-DC6rg8lJ.mjs → auth-jN5dNqTO.mjs} +5 -5
  25. package/dist/{auto-CwO0u8hB.cjs → auto-B_59RYH1.cjs} +23 -21
  26. package/dist/{auto-D5Jhukq1.mjs → auto-DC0Sq-qB.mjs} +23 -21
  27. package/dist/{bootstrap-rLaL3kTa.mjs → bootstrap-B3gMpU9e.mjs} +2 -2
  28. package/dist/{bootstrap-sly4qPPY.cjs → bootstrap-CoJu9VnB.cjs} +2 -2
  29. package/dist/{browser-CHpVgyni.mjs → browser-LHW2hBH8.mjs} +1 -1
  30. package/dist/{browser-BTgZ9d4i.cjs → browser-v1pdPP1E.cjs} +1 -1
  31. package/dist/claudeAccountEnv-BL1pR_37.mjs +133 -0
  32. package/dist/claudeAccountEnv-CEX_EMZr.cjs +138 -0
  33. package/dist/{claudeLocal-Bgb5GGsq.mjs → claudeLocal-BZUgA5G2.mjs} +5 -5
  34. package/dist/{claudeLocal-1vuTFcL8.cjs → claudeLocal-BrzM2RBI.cjs} +5 -5
  35. package/dist/{claudeLocalLauncher-T7EfT68h.mjs → claudeLocalLauncher-A0AQyHFi.mjs} +10 -10
  36. package/dist/{claudeLocalLauncher-DOsL6HFY.cjs → claudeLocalLauncher-XAMpXUM7.cjs} +10 -10
  37. package/dist/{claudeSessionFork-Cko4SaVi.cjs → claudeSessionFork-Mhn2fYe_.cjs} +1 -1
  38. package/dist/{claudeSessionFork-CPvi6yDX.mjs → claudeSessionFork-_GwIlmMB.mjs} +1 -1
  39. package/dist/{client-BXD66ZF5.mjs → client-7RnI9J0W.mjs} +2 -2
  40. package/dist/{client-Bi20Ka0h.mjs → client-Bde4QVIn.mjs} +4 -2
  41. package/dist/{client-C5-C0t2a.cjs → client-CJr8Pjwm.cjs} +4 -2
  42. package/dist/{client-BscskEBk.cjs → client-D2GWkd-T.cjs} +2 -2
  43. package/dist/{client-C-OdTbrU.cjs → client-DLlnmAPL.cjs} +4 -4
  44. package/dist/{client-Bh1aUPh-.mjs → client-DwbhrX6D.mjs} +4 -4
  45. package/dist/codex/happyMcpStdioBridge.cjs +16 -16
  46. package/dist/codex/happyMcpStdioBridge.mjs +16 -16
  47. package/dist/codexAccount-BDQjRbtI.cjs +1028 -0
  48. package/dist/codexAccount-NOX5pmQf.mjs +1015 -0
  49. package/dist/{codexAppServerClient-DXhAf6i-.mjs → codexAppServerClient-B3QJV6Ey.mjs} +18 -7
  50. package/dist/{codexAppServerClient-DKXeikEe.cjs → codexAppServerClient-DWEsZUC4.cjs} +18 -7
  51. package/dist/{codexCommand-DvbbpYBS.cjs → codexCommand-Bg8AmxVm.cjs} +195 -63
  52. package/dist/{codexCommand-CIaOiiOj.mjs → codexCommand-D1xlj4sT.mjs} +196 -64
  53. package/dist/{codexTermination-BszWfyk5.cjs → codexTermination-ByX9GcEJ.cjs} +1 -1
  54. package/dist/{codexTermination-BcQdEDaw.mjs → codexTermination-CaWAVQjZ.mjs} +1 -1
  55. package/dist/{config-Di3Cf6js.cjs → config-B2GGbiTv.cjs} +3 -3
  56. package/dist/{config-OCEcVVK1.mjs → config-C2XYEwXz.mjs} +3 -3
  57. package/dist/{configuration-DfPBa-9d.cjs → configuration-BBK0rmmj.cjs} +1 -1
  58. package/dist/{configuration-ECqXu34R.mjs → configuration-ThKBP_zY.mjs} +1 -1
  59. package/dist/{connect-BTfAUhk8.mjs → connect-BirnCl9q.mjs} +13 -13
  60. package/dist/{connect-BPQRuOw5.cjs → connect-C3tZs_NC.cjs} +13 -13
  61. package/dist/{context-CfgTFpCB.mjs → context-C0EFLnOg.mjs} +1 -1
  62. package/dist/{context-Co7hUaW-.cjs → context-wDp0aZBK.cjs} +1 -1
  63. package/dist/{controlClient-ClI7A0qE.mjs → controlClient-Ckl8N1MS.mjs} +14 -5
  64. package/dist/{controlClient-C13_pSKG.cjs → controlClient-DwWTns3A.cjs} +15 -4
  65. package/dist/{createSessionMetadata-Cf78KHtt.cjs → createSessionMetadata-DqZ6h02H.cjs} +2 -2
  66. package/dist/{createSessionMetadata-B0eT_Kfj.mjs → createSessionMetadata-vug4Cv8z.mjs} +2 -2
  67. package/dist/daemonAccounts-CpGDY_4k.cjs +54 -0
  68. package/dist/daemonAccounts-DwPwKxvv.mjs +30 -0
  69. package/dist/{defaultPermissionMode-oqTupStc.cjs → defaultPermissionMode-BakXiqRr.cjs} +1 -1
  70. package/dist/{defaultPermissionMode-m6z2QVyP.mjs → defaultPermissionMode-DF5AfeBb.mjs} +1 -1
  71. package/dist/{deterministicJson-BtSwbsok.mjs → deterministicJson-BzX94gi3.mjs} +13 -13
  72. package/dist/{deterministicJson-CpFFgUL_.cjs → deterministicJson-t33SsuRC.cjs} +13 -13
  73. package/dist/{doctor-BEU0_1Xv.cjs → doctor-B9ug1LZb.cjs} +7 -7
  74. package/dist/{doctor-lsxmAK4o.mjs → doctor-C1zyOSXw.mjs} +7 -7
  75. package/dist/{downloadTarget-BXqXhNF7.mjs → downloadTarget-Baslc6jW.mjs} +6 -6
  76. package/dist/{downloadTarget-CikzJv1h.cjs → downloadTarget-T1id2Gh6.cjs} +6 -6
  77. package/dist/{ensureDaemonRunning-B_9WAlbU.mjs → ensureDaemonRunning-C6ERYK-O.mjs} +5 -5
  78. package/dist/{ensureDaemonRunning-BUuH-pbE.cjs → ensureDaemonRunning-CoAg11Zi.cjs} +5 -5
  79. package/dist/{handleResumeCommand-BK9XKH_l.mjs → handleResumeCommand-CrlqDuz7.mjs} +5 -5
  80. package/dist/{handleResumeCommand-Dj7oi2KO.cjs → handleResumeCommand-DPi-sPm7.cjs} +5 -5
  81. package/dist/{index-D3c7CLot.cjs → index-B1swQJUS.cjs} +4 -4
  82. package/dist/{index-CmZusg8Q.cjs → index-B2dJA8VG.cjs} +3 -3
  83. package/dist/{index-CLUHaPU8.cjs → index-BUFrKZeQ.cjs} +205 -5
  84. package/dist/{index-BjZnpGWX.mjs → index-BbdV2mzy.mjs} +3 -3
  85. package/dist/{index-BdOJOZ6J.mjs → index-BcSPg3c5.mjs} +4 -4
  86. package/dist/{index-CauRYQKr.cjs → index-Bkslzin5.cjs} +44 -40
  87. package/dist/{index-DuK9XYbZ.mjs → index-Cn73rdtQ.mjs} +4 -4
  88. package/dist/{index-Bq8NKSCF.mjs → index-D1YnIih6.mjs} +195 -6
  89. package/dist/{index-Cxso1rg4.mjs → index-fZO4nF6e.mjs} +45 -41
  90. package/dist/{index-Dg2NAF_-.cjs → index-rocrvOYG.cjs} +4 -4
  91. package/dist/index.cjs +2 -2
  92. package/dist/index.mjs +2 -2
  93. package/dist/{install-DXllkuy0.cjs → install-CArXjPfW.cjs} +3 -3
  94. package/dist/{install-DTIveLOS.mjs → install-CChhyV2G.mjs} +3 -3
  95. package/dist/lib.cjs +12 -12
  96. package/dist/lib.d.cts +354 -0
  97. package/dist/lib.d.mts +354 -0
  98. package/dist/lib.mjs +12 -12
  99. package/dist/{lidState-CD81ryTy.mjs → lidState-B6yYKjNK.mjs} +1 -1
  100. package/dist/{lidState-C9_DoF9i.cjs → lidState-B_v6qgfE.cjs} +1 -1
  101. package/dist/{localHappyAgentAuth-Cg-m1lwm.mjs → localHappyAgentAuth-KRlg_aI0.mjs} +1 -1
  102. package/dist/{localHappyAgentAuth-CCjUvOfi.cjs → localHappyAgentAuth-jJH0n67S.cjs} +1 -1
  103. package/dist/{logger-Ct2zvaq0.cjs → logger-CX3x2eI4.cjs} +2 -2
  104. package/dist/{logger-GcbI0eg2.mjs → logger-JV7-4Q_6.mjs} +2 -2
  105. package/dist/{machineMetadata-CXRmFNOV.mjs → machineMetadata-D5-SW9kv.mjs} +3 -3
  106. package/dist/{machineMetadata-DDCVWb_x.cjs → machineMetadata-DhZuM0iB.cjs} +3 -3
  107. package/dist/{main-BHC-WIcM.cjs → main-1x1HGQEy.cjs} +92 -48
  108. package/dist/{main-omGr_ONk.mjs → main-CFOdXbPD.mjs} +92 -48
  109. package/dist/{mcp-xUzii0m8.cjs → mcp-BnKBSEh7.cjs} +18 -15
  110. package/dist/{mcp-D5hxmRAq.mjs → mcp-R6lMcFLO.mjs} +18 -15
  111. package/dist/{mirrorProtocol-Lcx20Oby.mjs → mirrorProtocol-CD4ntuZJ.mjs} +3 -3
  112. package/dist/{mirrorProtocol-Dfl8Ahyf.cjs → mirrorProtocol-DO-KtvAL.cjs} +3 -3
  113. package/dist/{package-BsUHyqWe.mjs → package-Bw3H6VLn.mjs} +7 -7
  114. package/dist/{package-9n7wd2dT.cjs → package-uzlvxa5S.cjs} +7 -7
  115. package/dist/{panels-CpEKWWbI.mjs → panels-BamhZCoZ.mjs} +5 -5
  116. package/dist/{panels-BfknEmt7.cjs → panels-C46FxjmH.cjs} +5 -5
  117. package/dist/{peerTools-CElYh-5u.cjs → peerTools-D-VNNFw-.cjs} +5 -5
  118. package/dist/{peerTools-CwCe6tmJ.mjs → peerTools-WtRgTSqG.mjs} +5 -5
  119. package/dist/{persistence-Cpw4yJs8.mjs → persistence-Cg4sfjQV.mjs} +2 -2
  120. package/dist/{persistence-A2NeERZJ.cjs → persistence-CsmAgN-C.cjs} +2 -2
  121. package/dist/{piRunnerArgs-Bqmu16He.mjs → piRunnerArgs-BbaAQvb4.mjs} +2 -2
  122. package/dist/{piRunnerArgs-BnFU0K73.cjs → piRunnerArgs-vnFygygF.cjs} +1 -1
  123. package/dist/{piRuntime-Cgn1b0OX.mjs → piRuntime-Bid7TBf5.mjs} +1 -1
  124. package/dist/{piRuntime-DpS9TAIs.cjs → piRuntime-C2uj5Ucx.cjs} +1 -1
  125. package/dist/{piTerminal-rmve-VlI.cjs → piTerminal-Ckpjfoqa.cjs} +20 -17
  126. package/dist/{piTerminal-BGdps8f3.mjs → piTerminal-CqxgrI13.mjs} +20 -17
  127. package/dist/{pushNotifications-23YSd-0l.cjs → pushNotifications-BCg7YAiu.cjs} +5 -3
  128. package/dist/{pushNotifications-XAM8__Pg.mjs → pushNotifications-BbE-qV9I.mjs} +5 -3
  129. package/dist/{query-SZcYnJoW.mjs → query-Bfr9O_62.mjs} +1 -1
  130. package/dist/{query-u2GX-I0C.cjs → query-vQ-HG394.cjs} +1 -1
  131. package/dist/{rateLimitReporter-CaTzBe3x.cjs → rateLimitReporter-BZ8x0-6-.cjs} +3 -3
  132. package/dist/{rateLimitReporter-COUkf446.mjs → rateLimitReporter-CAz7VMw4.mjs} +3 -3
  133. package/dist/{rateLimitWindows-B2Kx6L0S.cjs → rateLimitWindows-BZl6GMwQ.cjs} +1 -1
  134. package/dist/{rateLimitWindows-j_qQk0KY.mjs → rateLimitWindows-CRARnKaI.mjs} +1 -1
  135. package/dist/reconnectEnv-B31lY4nR.cjs +27 -0
  136. package/dist/reconnectEnv-DeSvHl3q.mjs +24 -0
  137. package/dist/{registerCommonHandlers-D1MiSfcB.cjs → registerCommonHandlers-CZGmrPbT.cjs} +2 -2
  138. package/dist/{registerCommonHandlers-DRRfinzK.mjs → registerCommonHandlers-Cj3Nl9y-.mjs} +2 -2
  139. package/dist/{registerKillSessionHandler-Cpug_r5C.mjs → registerKillSessionHandler-Bg9t45Ub.mjs} +6 -6
  140. package/dist/{registerKillSessionHandler-hvCsEn7b.cjs → registerKillSessionHandler-C3EDnW4F.cjs} +6 -6
  141. package/dist/{remoteSessionClient-BdnJ_n8C.mjs → remoteSessionClient--0vfA7I5.mjs} +5 -5
  142. package/dist/{remoteSessionClient-6ymeMVa4.cjs → remoteSessionClient-CcSP24Zq.cjs} +5 -5
  143. package/dist/{reportProgressTool-XgQBzxoD.mjs → reportProgressTool-DVru7jc_.mjs} +3 -3
  144. package/dist/{reportProgressTool-tzQLCLIw.cjs → reportProgressTool-Ddg1yVq2.cjs} +3 -3
  145. package/dist/{run-DYL_wuj7.cjs → run-BTrIT_jU.cjs} +347 -856
  146. package/dist/{run-Bt0AklUU.mjs → run-HtvH6BLi.mjs} +346 -855
  147. package/dist/{runClaude-C3rii_S6.mjs → runClaude-DsHTk5Bu.mjs} +62 -44
  148. package/dist/{runClaude-CBEpYO4S.cjs → runClaude-ipjwAHPI.cjs} +62 -44
  149. package/dist/{runClaudeDeps-CYuozSC6.cjs → runClaudeDeps-BKpwL6ln.cjs} +51 -42
  150. package/dist/{runClaudeDeps-DlVfMG4F.mjs → runClaudeDeps-BV3vpeyY.mjs} +56 -47
  151. package/dist/{runGemini-CEI3b90u.cjs → runGemini-B-G0_7Ab.cjs} +33 -33
  152. package/dist/{runGemini-DkYhRk9S.mjs → runGemini-DhjK6_Fp.mjs} +33 -33
  153. package/dist/{runOpenClaw-DpprWCoz.mjs → runOpenClaw-B6lawk8n.mjs} +18 -18
  154. package/dist/{runOpenClaw-BgjD6E4d.cjs → runOpenClaw-BHIo8tkn.cjs} +18 -18
  155. package/dist/{sandbox-XCDUbH72.cjs → sandbox-BAsO0ILe.cjs} +4 -4
  156. package/dist/{sandbox-DJ7A7lsy.mjs → sandbox-CKb7pCXg.mjs} +4 -4
  157. package/dist/selfCheck-CZ-t1Xzq.mjs +88 -0
  158. package/dist/{selfCheck-BYUDB1Uq.cjs → selfCheck-D4VvVZNi.cjs} +39 -37
  159. package/dist/{send-CASDBCyJ.cjs → send-Cz5m39QR.cjs} +8 -8
  160. package/dist/{send-Ba63huxv.mjs → send-D8ipLKMY.mjs} +8 -8
  161. package/dist/{server-w3W0toNd.mjs → server-CjvgT3N9.mjs} +4 -4
  162. package/dist/{server-cZoV9XRt.cjs → server-CySyJKPH.cjs} +6 -6
  163. package/dist/{sessionLock-G2PMqvsh.mjs → sessionLock-B73fhgQN.mjs} +10 -4
  164. package/dist/{sessionLock-BmLA2S8K.cjs → sessionLock-DdDCuNUs.cjs} +10 -3
  165. package/dist/{sessionOps-DPw5k8vV.mjs → sessionOps-C65Iej_C.mjs} +50 -8
  166. package/dist/{sessionOps-DXlTmS7J.cjs → sessionOps-XSEjIqNq.cjs} +50 -8
  167. package/dist/sessionProvider-CLVNkfji.mjs +110 -0
  168. package/dist/sessionProvider-Dgsty8z_.cjs +115 -0
  169. package/dist/{sessionScanner-AHjnicxi.cjs → sessionScanner-D8IVXMMH.cjs} +3 -3
  170. package/dist/{sessionScanner-BCXpdZJN.mjs → sessionScanner-MW1P9Pm9.mjs} +3 -3
  171. package/dist/{sessions-BiBXOBx0.cjs → sessions-BKz7gZqg.cjs} +10 -10
  172. package/dist/{sessions-Clk8MR5Y.mjs → sessions-Dtk_agUL.mjs} +10 -10
  173. package/dist/{setupOfflineReconnection-DI-QZGYz.mjs → setupOfflineReconnection-Bvdy-2xd.mjs} +2 -2
  174. package/dist/{setupOfflineReconnection-BKLfOd-i.cjs → setupOfflineReconnection-DxMiW7OV.cjs} +2 -2
  175. package/dist/{spawn-D5omsx1Q.cjs → spawn-DiPkJcrQ.cjs} +36 -17
  176. package/dist/{spawn-4tsp1uhh.mjs → spawn-Dm4xsZBX.mjs} +36 -17
  177. package/dist/{spawnAgents-CtkkIFHd.cjs → spawnAgents-B9olJ8xn.cjs} +1 -1
  178. package/dist/{spawnAgents-CjoU6ZOS.mjs → spawnAgents-I29H9nO8.mjs} +1 -1
  179. package/dist/{spawnHappyCLI-CF_gLi92.cjs → spawnHappyCLI-BYGOUda1.cjs} +1 -1
  180. package/dist/{spawnHappyCLI-CIA9Sc_5.mjs → spawnHappyCLI-CnMwzjWX.mjs} +1 -1
  181. package/dist/{startFileWatcher-9Stpxe7p.cjs → startFileWatcher-D14W6gn-.cjs} +1 -1
  182. package/dist/{startFileWatcher-CDO6fb2m.mjs → startFileWatcher-DePAY1T5.mjs} +1 -1
  183. package/dist/{startupSessionCreate-BtR4iYEC.mjs → startupSessionCreate-DoK0IvJG.mjs} +3 -3
  184. package/dist/{startupSessionCreate-CcF7rGGB.cjs → startupSessionCreate-rBHd4tc1.cjs} +3 -3
  185. package/dist/store-CkNa6oj4.cjs +326 -0
  186. package/dist/store-Vej_738f.mjs +305 -0
  187. package/dist/{streamRelay-BhI6jqF-.cjs → streamRelay-C0G1HOOd.cjs} +1 -1
  188. package/dist/{streamRelay-DMwOMTKf.mjs → streamRelay-C5U-C4GS.mjs} +1 -1
  189. package/dist/{sync-C0PRuTMj.mjs → sync-BP6vnxVP.mjs} +1 -1
  190. package/dist/{sync-Ba8N6xba.cjs → sync-WYBwkJvG.cjs} +1 -1
  191. package/dist/{systemPrompt-DV5IReD4.cjs → systemPrompt-BkQlCk5_.cjs} +2 -2
  192. package/dist/{systemPrompt-D0q8eyjy.mjs → systemPrompt-aRqBmkpw.mjs} +2 -2
  193. package/dist/{teams-BO3_arwM.mjs → teams-CGmC4ygu.mjs} +7 -7
  194. package/dist/{teams-z3Gp-KlV.cjs → teams-phbpwAGD.cjs} +7 -7
  195. package/dist/{template-B_5l6pkc.cjs → template-B9pLEP8v.cjs} +2 -2
  196. package/dist/{template-DLR_0hfj.mjs → template-CL9EvQLQ.mjs} +2 -2
  197. package/dist/{time-Cy0a-7YX.cjs → time-BTLcO8jp.cjs} +1 -1
  198. package/dist/{time-D0jvDRhn.mjs → time-Cw0liIqB.mjs} +1 -1
  199. package/dist/{titleGenerator-RGHWP2YL.cjs → titleGenerator-Y1_7ceJC.cjs} +17 -13
  200. package/dist/{titleGenerator-AGQsXskb.mjs → titleGenerator-h6TmFe-c.mjs} +16 -12
  201. package/dist/{todo-CzIDPLFy.cjs → todo-BxiPiCvB.cjs} +6 -6
  202. package/dist/{todo-BZ954vsz.mjs → todo-OKcTC_VC.mjs} +6 -6
  203. package/dist/{tools-Bei5i03L.mjs → tools-BR-drXZ8.mjs} +3 -2
  204. package/dist/{tools-B1x1j6tz.cjs → tools-CcebYtLj.cjs} +3 -2
  205. package/dist/{uninstall-C3cnIvz1.cjs → uninstall-CnDeCC-M.cjs} +3 -3
  206. package/dist/{uninstall-B4T_e3Mr.mjs → uninstall-D3stWKD2.mjs} +3 -3
  207. package/dist/wrapperAccount-BkufO_9g.mjs +107 -0
  208. package/dist/wrapperAccount-D2A4DuZy.cjs +113 -0
  209. package/package.json +7 -7
  210. package/dist/providerBinding-B-Qbx9W2.cjs +0 -140
  211. package/dist/providerBinding-CYubGg-Z.mjs +0 -132
  212. package/dist/selfCheck-C-rNljKV.mjs +0 -86
  213. package/dist/sessionProvider-DUn91LhJ.mjs +0 -109
  214. package/dist/sessionProvider-Dg691XQ4.cjs +0 -114
@@ -0,0 +1,305 @@
1
+ import { readFileSync, existsSync, mkdirSync, chmodSync, writeFileSync, renameSync, rmSync } from 'node:fs';
2
+ import { homedir } from 'node:os';
3
+ import { join, dirname } from 'node:path';
4
+ import { t as AGENT_PROFILE_KINDS } from './index-D1YnIih6.mjs';
5
+
6
+ function providersPath(happyHomeDir) {
7
+ return join(happyHomeDir, "providers.json");
8
+ }
9
+ function sessionProvidersPath(happyHomeDir) {
10
+ return join(happyHomeDir, "session-providers.json");
11
+ }
12
+ function parseProvidersFile(raw) {
13
+ const profiles = {};
14
+ const src = raw && typeof raw === "object" ? raw.profiles : void 0;
15
+ if (src && typeof src === "object") {
16
+ for (const [id, p] of Object.entries(src)) {
17
+ if (!p || typeof p !== "object") continue;
18
+ const { name, baseUrl, apiKeyFile, models } = p;
19
+ if (typeof baseUrl !== "string" || !/^https?:\/\//.test(baseUrl) || typeof apiKeyFile !== "string" || !apiKeyFile) continue;
20
+ const ids = [];
21
+ const contextWindows = {};
22
+ for (const m of Array.isArray(models) ? models : []) {
23
+ if (typeof m === "string") ids.push(m);
24
+ else if (m && typeof m === "object" && typeof m.id === "string") {
25
+ const { id: modelId, contextWindow } = m;
26
+ ids.push(modelId);
27
+ if (typeof contextWindow === "number" && Number.isInteger(contextWindow) && contextWindow > 0) contextWindows[modelId] = contextWindow;
28
+ }
29
+ }
30
+ profiles[id] = {
31
+ ...typeof name === "string" ? { name } : {},
32
+ baseUrl: baseUrl.replace(/\/+$/, ""),
33
+ apiKeyFile,
34
+ ...Array.isArray(models) ? { models: ids } : {},
35
+ ...Object.keys(contextWindows).length > 0 ? { contextWindows } : {}
36
+ };
37
+ }
38
+ }
39
+ return { profiles };
40
+ }
41
+ function parseSessionProvidersFile(raw) {
42
+ const out = {};
43
+ if (!raw || typeof raw !== "object") return out;
44
+ for (const [sessionId, b] of Object.entries(raw)) {
45
+ if (!b || typeof b !== "object") continue;
46
+ const { profile, model } = b;
47
+ if (typeof profile === "string" && profile && typeof model === "string" && model) out[sessionId] = { profile, model };
48
+ }
49
+ return out;
50
+ }
51
+
52
+ const KIND_AGENT = {
53
+ "claude-subscription": "claude",
54
+ "claude-api": "claude",
55
+ "codex-chatgpt": "codex",
56
+ "codex-provider": "codex"
57
+ };
58
+ function isApiKind(kind) {
59
+ return kind === "claude-api" || kind === "codex-provider";
60
+ }
61
+ const SPAWN_ACCOUNT_ENV = "VH_AGENT_PROFILE_ID";
62
+ const SUBSCRIPTION_TOKEN_TTL_MS = 365 * 24 * 60 * 60 * 1e3;
63
+ const ACCOUNT_ID_PATTERN = /^[a-z0-9][a-z0-9-]{0,47}$/;
64
+ function accountsPath(home) {
65
+ return join(home, "accounts.json");
66
+ }
67
+ function accountSecretPath(home, id) {
68
+ if (!ACCOUNT_ID_PATTERN.test(id)) throw new Error(`invalid account id "${id}"`);
69
+ return join(home, "accounts", id, "secret");
70
+ }
71
+ function accountCodexHomePath(home, id) {
72
+ if (!ACCOUNT_ID_PATTERN.test(id)) throw new Error(`invalid account id "${id}"`);
73
+ return join(home, "accounts", id, "codex-home");
74
+ }
75
+ function sessionAccountsPath(home) {
76
+ return join(home, "session-accounts.json");
77
+ }
78
+ function expandHome(path, home = homedir()) {
79
+ return path === "~" ? home : path.startsWith("~/") ? join(home, path.slice(2)) : path;
80
+ }
81
+ function readJson(path) {
82
+ if (!existsSync(path)) return void 0;
83
+ try {
84
+ return JSON.parse(readFileSync(path, "utf8"));
85
+ } catch {
86
+ return void 0;
87
+ }
88
+ }
89
+ function writeJson0600(path, value) {
90
+ mkdirSync(dirname(path), { recursive: true });
91
+ const tmp = `${path}.${process.pid}.${Date.now()}.tmp`;
92
+ writeFileSync(tmp, JSON.stringify(value, null, 2) + "\n", { mode: 384 });
93
+ chmodSync(tmp, 384);
94
+ renameSync(tmp, path);
95
+ }
96
+ function parseKey(raw) {
97
+ if (!raw || typeof raw !== "object") return void 0;
98
+ const k = raw;
99
+ if (k.source === "file" && typeof k.path === "string" && k.path) return { source: "file", path: k.path };
100
+ if (k.source === "env" && typeof k.name === "string" && /^[A-Za-z_][A-Za-z0-9_]*$/.test(k.name)) return { source: "env", name: k.name };
101
+ if (k.source === "stored") return { source: "stored" };
102
+ return void 0;
103
+ }
104
+ function parseAccountsFile(raw) {
105
+ const out = { version: 2, accounts: {}, defaults: {} };
106
+ if (!raw || typeof raw !== "object") return out;
107
+ const src = raw.accounts;
108
+ if (src && typeof src === "object") {
109
+ for (const [id, value] of Object.entries(src)) {
110
+ if (!ACCOUNT_ID_PATTERN.test(id) || !value || typeof value !== "object") continue;
111
+ const a = value;
112
+ const kind = a.kind;
113
+ if (typeof a.kind !== "string" || !(a.kind in KIND_AGENT) || a.agent !== KIND_AGENT[kind]) continue;
114
+ const label = typeof a.label === "string" && a.label.trim() ? a.label.trim() : id;
115
+ const rec = { label, agent: KIND_AGENT[kind], kind, createdAt: typeof a.createdAt === "number" ? a.createdAt : 0 };
116
+ const baseUrl = typeof a.baseUrl === "string" && /^https?:\/\//.test(a.baseUrl) ? a.baseUrl.replace(/\/+$/, "") : void 0;
117
+ if (kind === "codex-provider") {
118
+ const provider = typeof a.provider === "string" && /^[A-Za-z0-9_-]{1,64}$/.test(a.provider) ? a.provider : void 0;
119
+ if (!provider && !baseUrl) continue;
120
+ if (provider) rec.provider = provider;
121
+ if (a.wireApi === "responses" || a.wireApi === "chat") rec.wireApi = a.wireApi;
122
+ }
123
+ if (kind === "codex-chatgpt") {
124
+ if (typeof a.email === "string" && a.email) rec.email = a.email;
125
+ if (typeof a.planType === "string" && a.planType) rec.planType = a.planType;
126
+ }
127
+ if (isApiKind(kind)) {
128
+ if (kind === "claude-api" && !baseUrl) continue;
129
+ const key = parseKey(a.key);
130
+ if (!key) continue;
131
+ if (baseUrl) rec.baseUrl = baseUrl;
132
+ rec.key = key;
133
+ if (Array.isArray(a.models)) rec.models = a.models.filter((m) => typeof m === "string" && m.length > 0);
134
+ if (a.contextWindows && typeof a.contextWindows === "object") {
135
+ const cw = {};
136
+ for (const [m, n] of Object.entries(a.contextWindows)) {
137
+ if (typeof n === "number" && Number.isInteger(n) && n > 0) cw[m] = n;
138
+ }
139
+ if (Object.keys(cw).length > 0) rec.contextWindows = cw;
140
+ }
141
+ }
142
+ if (typeof a.expiresAt === "number") rec.expiresAt = a.expiresAt;
143
+ if (a.check && typeof a.check === "object") {
144
+ const c = a.check;
145
+ if (typeof c.status === "string" && typeof c.at === "number") {
146
+ rec.check = { status: c.status, at: c.at, ...typeof c.detail === "string" ? { detail: c.detail } : {} };
147
+ }
148
+ }
149
+ out.accounts[id] = rec;
150
+ }
151
+ }
152
+ const defaults = raw.defaults;
153
+ if (defaults && typeof defaults === "object") {
154
+ for (const [agent, id] of Object.entries(defaults)) {
155
+ if (typeof id === "string" && id) out.defaults[agent] = id;
156
+ }
157
+ }
158
+ return out;
159
+ }
160
+ function legacyAccountsFromProviders(raw) {
161
+ const out = {};
162
+ for (const [id, p] of Object.entries(parseProvidersFile(raw).profiles)) {
163
+ if (!ACCOUNT_ID_PATTERN.test(id)) continue;
164
+ out[id] = {
165
+ label: p.name ?? id,
166
+ agent: "claude",
167
+ kind: "claude-api",
168
+ createdAt: 0,
169
+ baseUrl: p.baseUrl,
170
+ key: { source: "file", path: p.apiKeyFile },
171
+ ...p.models ? { models: p.models } : {},
172
+ ...p.contextWindows ? { contextWindows: p.contextWindows } : {},
173
+ legacy: true
174
+ };
175
+ }
176
+ return out;
177
+ }
178
+ function mergeAccounts(v2, legacy) {
179
+ return { ...v2, accounts: { ...legacy, ...v2.accounts } };
180
+ }
181
+ function readAccountsFileV2(home) {
182
+ return parseAccountsFile(readJson(accountsPath(home)));
183
+ }
184
+ function readAccounts(home) {
185
+ return mergeAccounts(readAccountsFileV2(home), legacyAccountsFromProviders(readJson(providersPath(home))));
186
+ }
187
+ function writeAccountsFile(home, file) {
188
+ const accounts = {};
189
+ for (const [id, a] of Object.entries(file.accounts)) if (!a.legacy) accounts[id] = a;
190
+ writeJson0600(accountsPath(home), { version: 2, accounts, defaults: file.defaults });
191
+ }
192
+ function mergeSessionBindings(v2Raw, v1Raw) {
193
+ const out = {};
194
+ for (const [sessionId, b] of Object.entries(parseSessionProvidersFile(v1Raw))) out[sessionId] = { account: b.profile, model: b.model };
195
+ if (v2Raw && typeof v2Raw === "object") {
196
+ for (const [sessionId, b] of Object.entries(v2Raw)) {
197
+ if (!b || typeof b !== "object") continue;
198
+ const { account, model } = b;
199
+ if (account !== null && (typeof account !== "string" || !account)) continue;
200
+ out[sessionId] = { account, ...typeof model === "string" && model ? { model } : {} };
201
+ }
202
+ }
203
+ return out;
204
+ }
205
+ function readSessionBindings(home) {
206
+ return mergeSessionBindings(readJson(sessionAccountsPath(home)), readJson(sessionProvidersPath(home)));
207
+ }
208
+ function readSessionBindingV2(home, sessionId) {
209
+ const raw = readJson(sessionAccountsPath(home));
210
+ const entry = raw && typeof raw === "object" ? raw[sessionId] : void 0;
211
+ return entry && typeof entry === "object" ? entry : void 0;
212
+ }
213
+ function writeSessionBinding(home, sessionId, binding) {
214
+ const raw = readJson(sessionAccountsPath(home));
215
+ const current = raw && typeof raw === "object" ? { ...raw } : {};
216
+ if (binding === void 0) delete current[sessionId];
217
+ else current[sessionId] = binding;
218
+ writeJson0600(sessionAccountsPath(home), current);
219
+ }
220
+ function sessionsBoundTo(bindings, accountId) {
221
+ return Object.entries(bindings).filter(([, b]) => b.account === accountId).map(([id]) => id);
222
+ }
223
+ function writeAccountSecret(home, id, secret) {
224
+ const path = accountSecretPath(home, id);
225
+ mkdirSync(dirname(path), { recursive: true, mode: 448 });
226
+ chmodSync(dirname(path), 448);
227
+ const tmp = `${path}.${process.pid}.tmp`;
228
+ writeFileSync(tmp, secret.trim() + "\n", { mode: 384 });
229
+ chmodSync(tmp, 384);
230
+ renameSync(tmp, path);
231
+ }
232
+ function removeAccountSecret(home, id) {
233
+ rmSync(dirname(accountSecretPath(home, id)), { recursive: true, force: true });
234
+ }
235
+ const KIND_ID_BASE = {
236
+ "claude-subscription": "claude-sub",
237
+ "claude-api": "claude-api",
238
+ "codex-chatgpt": "chatgpt",
239
+ "codex-provider": "codex-api"
240
+ };
241
+ function newAccountId(label, kind, taken) {
242
+ const used = new Set(taken);
243
+ const ascii = /^[\x20-\x7e]*$/.test(label);
244
+ const slug = ascii ? label.toLowerCase().replace(/[^a-z0-9]+/g, "-").replace(/^-+|-+$/g, "").slice(0, 40) : "";
245
+ const base = slug && /^[a-z0-9]/.test(slug) ? slug : KIND_ID_BASE[kind];
246
+ if (!used.has(base)) return base;
247
+ for (let n = 2; ; n++) if (!used.has(`${base}-${n}`)) return `${base}-${n}`;
248
+ }
249
+ function secretPresent(home, id, a, probe) {
250
+ if (a.kind === "codex-chatgpt") return probe.fileReadable(join(accountCodexHomePath(home, id), "auth.json"));
251
+ if (a.kind === "claude-subscription" || a.key?.source === "stored") return probe.fileReadable(accountSecretPath(home, id));
252
+ if (a.key?.source === "file") return probe.fileReadable(expandHome(a.key.path));
253
+ if (a.key?.source === "env") return !!probe.env[a.key.name]?.trim();
254
+ return false;
255
+ }
256
+ function accountStatus(home, id, a, probe, now) {
257
+ if (!secretPresent(home, id, a, probe)) return { status: "missing-secret" };
258
+ if (a.expiresAt !== void 0 && a.expiresAt <= now) return { status: "expired" };
259
+ if (a.check) return { status: a.check.status, ...a.check.detail ? { detail: a.check.detail } : {} };
260
+ return { status: "unverified" };
261
+ }
262
+ function summarizeAccount(home, id, a, probe, now) {
263
+ const { status, detail } = accountStatus(home, id, a, probe, now);
264
+ const keySource = a.kind === "claude-subscription" || a.kind === "codex-chatgpt" ? "stored" : a.key?.source;
265
+ const keyRef = a.key?.source === "file" ? a.key.path : a.key?.source === "env" ? a.key.name : void 0;
266
+ return {
267
+ id,
268
+ label: a.label,
269
+ agent: a.agent,
270
+ kind: a.kind,
271
+ status,
272
+ ...detail ? { statusDetail: detail } : {},
273
+ ...a.check ? { checkedAt: a.check.at } : {},
274
+ ...a.createdAt ? { createdAt: a.createdAt } : {},
275
+ ...a.expiresAt !== void 0 ? { expiresAt: a.expiresAt } : {},
276
+ ...a.baseUrl ? { baseUrl: a.baseUrl } : {},
277
+ ...a.models ? { models: a.models } : {},
278
+ ...keySource ? { keySource } : {},
279
+ ...keyRef ? { keyRef } : {},
280
+ ...a.legacy ? { legacy: true } : {},
281
+ ...a.provider ? { provider: a.provider } : {},
282
+ ...a.email ? { email: a.email } : {},
283
+ ...a.planType ? { planType: a.planType } : {}
284
+ };
285
+ }
286
+ function defaultSecretProbe(env = process.env) {
287
+ return {
288
+ fileReadable: (path) => {
289
+ try {
290
+ return readFileSync(path, "utf8").trim().length > 0;
291
+ } catch {
292
+ return false;
293
+ }
294
+ },
295
+ env
296
+ };
297
+ }
298
+ function buildAgentProfilesState(home, file, probe, now, daemonPid) {
299
+ const accounts = Object.entries(file.accounts).map(([id, a]) => summarizeAccount(home, id, a, probe, now)).sort((x, y) => (x.createdAt ?? 0) - (y.createdAt ?? 0) || x.id.localeCompare(y.id));
300
+ const defaults = {};
301
+ for (const [agent, id] of Object.entries(file.defaults)) if (file.accounts[id]) defaults[agent] = id;
302
+ return { daemonPid, updatedAt: now, accounts, defaults, kinds: [...AGENT_PROFILE_KINDS] };
303
+ }
304
+
305
+ export { SPAWN_ACCOUNT_ENV as S, readAccounts as a, accountSecretPath as b, readAccountsFileV2 as c, defaultSecretProbe as d, expandHome as e, writeAccountsFile as f, accountsPath as g, buildAgentProfilesState as h, writeAccountSecret as i, sessionsBoundTo as j, removeAccountSecret as k, accountCodexHomePath as l, SUBSCRIPTION_TOKEN_TTL_MS as m, newAccountId as n, readSessionBindingV2 as o, providersPath as p, readSessionBindings as r, summarizeAccount as s, writeSessionBinding as w };
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var index = require('./index-CLUHaPU8.cjs');
3
+ var index = require('./index-BUFrKZeQ.cjs');
4
4
 
5
5
  const STREAM_FLUSH_MS = 80;
6
6
  const PROGRESS_FLUSH_MS = 250;
@@ -1,4 +1,4 @@
1
- import { S as STREAM_DELTA_MAX_CHARS } from './index-Bq8NKSCF.mjs';
1
+ import { S as STREAM_DELTA_MAX_CHARS } from './index-D1YnIih6.mjs';
2
2
 
3
3
  const STREAM_FLUSH_MS = 80;
4
4
  const PROGRESS_FLUSH_MS = 250;
@@ -1,4 +1,4 @@
1
- import { b as backoff } from './time-D0jvDRhn.mjs';
1
+ import { b as backoff } from './time-Cw0liIqB.mjs';
2
2
 
3
3
  class InvalidateSync {
4
4
  _invalidated = false;
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var time = require('./time-Cy0a-7YX.cjs');
3
+ var time = require('./time-BTLcO8jp.cjs');
4
4
 
5
5
  class InvalidateSync {
6
6
  _invalidated = false;
@@ -1,10 +1,10 @@
1
1
  'use strict';
2
2
 
3
- var logger = require('./logger-Ct2zvaq0.cjs');
3
+ var logger = require('./logger-CX3x2eI4.cjs');
4
4
  var node_fs = require('node:fs');
5
5
  var path$1 = require('node:path');
6
6
  var path = require('./path-B7zW-WwE.cjs');
7
- var index = require('./index-CLUHaPU8.cjs');
7
+ var index = require('./index-BUFrKZeQ.cjs');
8
8
  var trimIdent = require('./trimIdent-4gvk9Wk6.cjs');
9
9
  var os = require('node:os');
10
10
  var agentGuidance = require('./agentGuidance-BtBx2xxE.cjs');
@@ -1,8 +1,8 @@
1
- import { l as logger } from './logger-GcbI0eg2.mjs';
1
+ import { l as logger } from './logger-JV7-4Q_6.mjs';
2
2
  import { existsSync, readFileSync } from 'node:fs';
3
3
  import { join } from 'node:path';
4
4
  import { g as getProjectPath } from './path-D2wdaNSk.mjs';
5
- import { t as BUILTIN_TODO_DISCOVERY } from './index-Bq8NKSCF.mjs';
5
+ import { w as BUILTIN_TODO_DISCOVERY } from './index-D1YnIih6.mjs';
6
6
  import { t as trimIdent } from './trimIdent-BAjmv_TG.mjs';
7
7
  import { homedir } from 'node:os';
8
8
  import { A as AGENT_GUIDANCE } from './agentGuidance-BDYt2Qy2.mjs';
@@ -2,21 +2,21 @@ import { homedir } from 'node:os';
2
2
  import { readFile } from 'node:fs/promises';
3
3
  import { z } from 'zod';
4
4
  import { randomUUID } from 'node:crypto';
5
- import { t as teamRequest, c as createTeamsClient } from './client-Bh1aUPh-.mjs';
6
- import { b as readCredentialsForConfiguredRelay } from './persistence-Cpw4yJs8.mjs';
5
+ import { t as teamRequest, c as createTeamsClient } from './client-DwbhrX6D.mjs';
6
+ import { b as readCredentialsForConfiguredRelay } from './persistence-Cg4sfjQV.mjs';
7
7
  import { a as installTeamSkill, i as installAutomationSkill } from './install-B8O1JpJH.mjs';
8
8
  import 'node:child_process';
9
9
  import 'node:util';
10
10
  import 'node:path';
11
- import './index-Bq8NKSCF.mjs';
11
+ import './index-D1YnIih6.mjs';
12
12
  import '@paralleldrive/cuid2';
13
- import './configuration-ECqXu34R.mjs';
13
+ import './configuration-ThKBP_zY.mjs';
14
14
  import 'node:fs';
15
- import './package-BsUHyqWe.mjs';
16
- import './context-CfgTFpCB.mjs';
15
+ import './package-Bw3H6VLn.mjs';
16
+ import './context-C0EFLnOg.mjs';
17
17
  import './authRelay-DhQhkBvX.mjs';
18
18
  import 'tweetnacl';
19
- import './logger-GcbI0eg2.mjs';
19
+ import './logger-JV7-4Q_6.mjs';
20
20
  import 'chalk';
21
21
  import './resources-CLP_MpK4.mjs';
22
22
 
@@ -4,21 +4,21 @@ var os = require('node:os');
4
4
  var promises = require('node:fs/promises');
5
5
  var z = require('zod');
6
6
  var node_crypto = require('node:crypto');
7
- var client = require('./client-C-OdTbrU.cjs');
8
- var persistence = require('./persistence-A2NeERZJ.cjs');
7
+ var client = require('./client-DLlnmAPL.cjs');
8
+ var persistence = require('./persistence-CsmAgN-C.cjs');
9
9
  var install = require('./install-BOHlqewf.cjs');
10
10
  require('node:child_process');
11
11
  require('node:util');
12
12
  require('node:path');
13
- require('./index-CLUHaPU8.cjs');
13
+ require('./index-BUFrKZeQ.cjs');
14
14
  require('@paralleldrive/cuid2');
15
- require('./configuration-DfPBa-9d.cjs');
15
+ require('./configuration-BBK0rmmj.cjs');
16
16
  require('node:fs');
17
- require('./package-9n7wd2dT.cjs');
18
- require('./context-Co7hUaW-.cjs');
17
+ require('./package-uzlvxa5S.cjs');
18
+ require('./context-wDp0aZBK.cjs');
19
19
  require('./authRelay-Dy1qU9td.cjs');
20
20
  require('tweetnacl');
21
- require('./logger-Ct2zvaq0.cjs');
21
+ require('./logger-CX3x2eI4.cjs');
22
22
  require('chalk');
23
23
  require('./resources-BZ_Be0qM.cjs');
24
24
 
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var index = require('./index-CLUHaPU8.cjs');
3
+ var index = require('./index-BUFrKZeQ.cjs');
4
4
 
5
5
  function payloadJson(payload) {
6
6
  if (!payload) return void 0;
@@ -143,7 +143,7 @@ function describeTrigger(trigger) {
143
143
  }
144
144
  }
145
145
  function describeAction(action) {
146
- if (action.kind === "spawn") return `spawn ${action.agent} in ${action.directory}${action.sticky ? ` (sticky ${action.sticky.key})` : ""}`;
146
+ if (action.kind === "spawn") return `spawn ${action.agent} in ${action.directory}${action.sticky ? ` (sticky ${action.sticky.key})` : ""}${action.agentProfile !== void 0 ? ` \xB7 account ${action.agentProfile === null ? "machine login" : action.agentProfile.label ?? action.agentProfile.id}` : ""}`;
147
147
  if (action.kind === "send") return `send to session ${action.sessionId}`;
148
148
  return `script ${action.command.join(" ")}`;
149
149
  }
@@ -1,4 +1,4 @@
1
- import { e as AUTOMATION_ATTENTION_REASON_MAX_CHARS, f as AUTOMATION_SUMMARY_MAX_CHARS } from './index-Bq8NKSCF.mjs';
1
+ import { h as AUTOMATION_ATTENTION_REASON_MAX_CHARS, j as AUTOMATION_SUMMARY_MAX_CHARS } from './index-D1YnIih6.mjs';
2
2
 
3
3
  function payloadJson(payload) {
4
4
  if (!payload) return void 0;
@@ -141,7 +141,7 @@ function describeTrigger(trigger) {
141
141
  }
142
142
  }
143
143
  function describeAction(action) {
144
- if (action.kind === "spawn") return `spawn ${action.agent} in ${action.directory}${action.sticky ? ` (sticky ${action.sticky.key})` : ""}`;
144
+ if (action.kind === "spawn") return `spawn ${action.agent} in ${action.directory}${action.sticky ? ` (sticky ${action.sticky.key})` : ""}${action.agentProfile !== void 0 ? ` \xB7 account ${action.agentProfile === null ? "machine login" : action.agentProfile.label ?? action.agentProfile.id}` : ""}`;
145
145
  if (action.kind === "send") return `send to session ${action.sessionId}`;
146
146
  return `script ${action.command.join(" ")}`;
147
147
  }
@@ -1,6 +1,6 @@
1
1
  'use strict';
2
2
 
3
- var logger = require('./logger-Ct2zvaq0.cjs');
3
+ var logger = require('./logger-CX3x2eI4.cjs');
4
4
 
5
5
  async function delay(ms) {
6
6
  return new Promise((resolve) => setTimeout(resolve, ms));
@@ -1,4 +1,4 @@
1
- import { l as logger } from './logger-GcbI0eg2.mjs';
1
+ import { l as logger } from './logger-JV7-4Q_6.mjs';
2
2
 
3
3
  async function delay(ms) {
4
4
  return new Promise((resolve) => setTimeout(resolve, ms));
@@ -5,15 +5,16 @@ var module$1 = require('node:module');
5
5
  var oneShotPrompts = require('./oneShotPrompts-CL0dip9C.cjs');
6
6
  var node_crypto = require('node:crypto');
7
7
  var path = require('node:path');
8
- var logger = require('./logger-Ct2zvaq0.cjs');
8
+ var logger = require('./logger-CX3x2eI4.cjs');
9
9
  var projectPath = require('./projectPath-C3ioB4Bu.cjs');
10
+ var wrapperAccount = require('./wrapperAccount-D2A4DuZy.cjs');
10
11
 
11
12
  var _documentCurrentScript = typeof document !== 'undefined' ? document.currentScript : null;
12
13
  const MAX_PROMPT_SAMPLE_CHARS = 500;
13
14
  const MAX_TITLE_CHARS = 60;
14
15
  const GENERATION_TIMEOUT_MS = 3e4;
15
16
  function loadClaudeVersionUtils() {
16
- const require$1 = module$1.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('titleGenerator-RGHWP2YL.cjs', document.baseURI).href)));
17
+ const require$1 = module$1.createRequire((typeof document === 'undefined' ? require('u' + 'rl').pathToFileURL(__filename).href : (_documentCurrentScript && _documentCurrentScript.tagName.toUpperCase() === 'SCRIPT' && _documentCurrentScript.src || new URL('titleGenerator-Y1_7ceJC.cjs', document.baseURI).href)));
17
18
  return require$1(path.resolve(path.join(projectPath.projectPath(), "scripts", "claude_version_utils.cjs")));
18
19
  }
19
20
  function resolveClaudeBinary(loadUtils = loadClaudeVersionUtils) {
@@ -61,16 +62,19 @@ function sanitizeTitle(raw) {
61
62
  if (GENERIC_TITLES.has(title.toLowerCase().replace(/\s+/g, " ").trim())) return null;
62
63
  return title;
63
64
  }
64
- const ONE_SHOT_ARGS = [
65
- "-p",
66
- "--model",
67
- "haiku",
68
- "--strict-mcp-config",
69
- "--settings",
70
- '{"disableAllHooks":true}',
71
- "--no-session-persistence",
72
- "--disable-slash-commands"
73
- ];
65
+ function oneShotArgs(accountSettings = {}) {
66
+ return [
67
+ "-p",
68
+ "--model",
69
+ "haiku",
70
+ "--strict-mcp-config",
71
+ "--settings",
72
+ JSON.stringify({ ...accountSettings, disableAllHooks: true }),
73
+ "--no-session-persistence",
74
+ "--disable-slash-commands"
75
+ ];
76
+ }
77
+ oneShotArgs();
74
78
  function runClaudeOneShot(binary, prompt) {
75
79
  return new Promise((resolve2) => {
76
80
  let settled = false;
@@ -81,7 +85,7 @@ function runClaudeOneShot(binary, prompt) {
81
85
  };
82
86
  let child;
83
87
  try {
84
- child = node_child_process.spawn(binary, [...ONE_SHOT_ARGS, prompt], {
88
+ child = node_child_process.spawn(binary, [...oneShotArgs(wrapperAccount.accountClaudeSettings()), prompt], {
85
89
  stdio: ["ignore", "pipe", "ignore"],
86
90
  // HAPPY_MANAGED=1: this claude is run BY happy. The user-wide
87
91
  // terminal-mirror SessionStart hook exits on it, so a one-shot
@@ -3,8 +3,9 @@ import { createRequire } from 'node:module';
3
3
  import { T as TITLE_PROMPT_PREFIX } from './oneShotPrompts-DT4p6RNd.mjs';
4
4
  import { randomUUID } from 'node:crypto';
5
5
  import { resolve, join } from 'node:path';
6
- import { l as logger } from './logger-GcbI0eg2.mjs';
6
+ import { l as logger } from './logger-JV7-4Q_6.mjs';
7
7
  import { p as projectPath } from './projectPath-BTBIMB57.mjs';
8
+ import { a as accountClaudeSettings } from './wrapperAccount-BkufO_9g.mjs';
8
9
 
9
10
  const MAX_PROMPT_SAMPLE_CHARS = 500;
10
11
  const MAX_TITLE_CHARS = 60;
@@ -58,16 +59,19 @@ function sanitizeTitle(raw) {
58
59
  if (GENERIC_TITLES.has(title.toLowerCase().replace(/\s+/g, " ").trim())) return null;
59
60
  return title;
60
61
  }
61
- const ONE_SHOT_ARGS = [
62
- "-p",
63
- "--model",
64
- "haiku",
65
- "--strict-mcp-config",
66
- "--settings",
67
- '{"disableAllHooks":true}',
68
- "--no-session-persistence",
69
- "--disable-slash-commands"
70
- ];
62
+ function oneShotArgs(accountSettings = {}) {
63
+ return [
64
+ "-p",
65
+ "--model",
66
+ "haiku",
67
+ "--strict-mcp-config",
68
+ "--settings",
69
+ JSON.stringify({ ...accountSettings, disableAllHooks: true }),
70
+ "--no-session-persistence",
71
+ "--disable-slash-commands"
72
+ ];
73
+ }
74
+ oneShotArgs();
71
75
  function runClaudeOneShot(binary, prompt) {
72
76
  return new Promise((resolve2) => {
73
77
  let settled = false;
@@ -78,7 +82,7 @@ function runClaudeOneShot(binary, prompt) {
78
82
  };
79
83
  let child;
80
84
  try {
81
- child = spawn(binary, [...ONE_SHOT_ARGS, prompt], {
85
+ child = spawn(binary, [...oneShotArgs(accountClaudeSettings()), prompt], {
82
86
  stdio: ["ignore", "pipe", "ignore"],
83
87
  // HAPPY_MANAGED=1: this claude is run BY happy. The user-wide
84
88
  // terminal-mirror SessionStart hook exits on it, so a one-shot
@@ -1,20 +1,20 @@
1
1
  'use strict';
2
2
 
3
- var configuration = require('./configuration-DfPBa-9d.cjs');
4
- var index = require('./index-CLUHaPU8.cjs');
5
- var persistence = require('./persistence-A2NeERZJ.cjs');
6
- var context = require('./context-Co7hUaW-.cjs');
3
+ var configuration = require('./configuration-BBK0rmmj.cjs');
4
+ var index = require('./index-BUFrKZeQ.cjs');
5
+ var persistence = require('./persistence-CsmAgN-C.cjs');
6
+ var context = require('./context-wDp0aZBK.cjs');
7
7
  require('node:fs');
8
8
  require('node:os');
9
9
  require('node:path');
10
- require('./package-9n7wd2dT.cjs');
10
+ require('./package-uzlvxa5S.cjs');
11
11
  require('node:fs/promises');
12
12
  require('zod');
13
13
  require('@paralleldrive/cuid2');
14
14
  require('./authRelay-Dy1qU9td.cjs');
15
15
  require('node:crypto');
16
16
  require('tweetnacl');
17
- require('./logger-Ct2zvaq0.cjs');
17
+ require('./logger-CX3x2eI4.cjs');
18
18
  require('chalk');
19
19
  require('node:util');
20
20
 
@@ -1,18 +1,18 @@
1
- import { c as configuration } from './configuration-ECqXu34R.mjs';
2
- import { p as createBuiltinTodoClient, B as BUILTIN_TODO_SKILL } from './index-Bq8NKSCF.mjs';
3
- import { b as readCredentialsForConfiguredRelay } from './persistence-Cpw4yJs8.mjs';
4
- import { r as readTeamScope, t as teamScopePath } from './context-CfgTFpCB.mjs';
1
+ import { c as configuration } from './configuration-ThKBP_zY.mjs';
2
+ import { q as createBuiltinTodoClient, B as BUILTIN_TODO_SKILL } from './index-D1YnIih6.mjs';
3
+ import { b as readCredentialsForConfiguredRelay } from './persistence-Cg4sfjQV.mjs';
4
+ import { r as readTeamScope, t as teamScopePath } from './context-C0EFLnOg.mjs';
5
5
  import 'node:fs';
6
6
  import 'node:os';
7
7
  import 'node:path';
8
- import './package-BsUHyqWe.mjs';
8
+ import './package-Bw3H6VLn.mjs';
9
9
  import 'node:fs/promises';
10
10
  import 'zod';
11
11
  import '@paralleldrive/cuid2';
12
12
  import './authRelay-DhQhkBvX.mjs';
13
13
  import 'node:crypto';
14
14
  import 'tweetnacl';
15
- import './logger-GcbI0eg2.mjs';
15
+ import './logger-JV7-4Q_6.mjs';
16
16
  import 'chalk';
17
17
  import 'node:util';
18
18
 
@@ -1,5 +1,5 @@
1
1
  import { z } from 'zod';
2
- import { c as createTeamsClient } from './client-Bh1aUPh-.mjs';
2
+ import { c as createTeamsClient } from './client-DwbhrX6D.mjs';
3
3
 
4
4
  const CLOSED_GOAL_CHARS = 200;
5
5
  const closed = (task) => task.status === "done" || task.status === "cancelled";
@@ -119,7 +119,8 @@ function registerTeamsTools(server, sessionId, client = createTeamsClient(sessio
119
119
  botName: id.optional(),
120
120
  directory: z.string().min(1).optional(),
121
121
  assistant: z.enum(["claude", "codex", "pi-acp"]).optional(),
122
- model: z.string().trim().min(1).max(256).optional()
122
+ model: z.string().trim().min(1).max(256).optional(),
123
+ agentProfile: z.object({ id: z.string().min(1).max(64), label: z.string().min(1).max(200).optional() }).nullable().optional().describe("Account a member spawns on (id from `very-happy account list`; null = machine login; omit = team default). Unusable \u2192 the launch is refused, never the machine login.")
123
124
  });
124
125
  action("message", "Send a persistent task-related message. Delivery does not mean the model has read or acted on it.", { taskId: id, body: text, recipientBotId: id.optional() });
125
126
  action("submit", "Submit evidence for your current attempt and goal version. The owner still has to accept it.", { taskId: id, attemptId: id, goalVersion: z.number().int().positive(), result: text });