@madarco/agentbox 0.31.3 → 0.32.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.
Files changed (732) hide show
  1. package/CHANGELOG.md +47 -0
  2. package/README.md +2 -0
  3. package/dist/_cloud-attach-6RKS3MAP.js +31 -0
  4. package/dist/{chunk-E2RPG54S.js → chunk-27S7QLDF.js} +3 -3
  5. package/dist/{chunk-EZPCCJPE.js → chunk-2APGFWEU.js} +24 -24
  6. package/dist/{chunk-7PDYVJ2Q.js → chunk-3AYSA62C.js} +3 -3
  7. package/dist/{chunk-SHFU2KSY.js → chunk-3ISG5THX.js} +3 -3
  8. package/dist/{chunk-D67Q5MNA.js → chunk-3L2DIPRM.js} +2 -2
  9. package/dist/{chunk-GYUOXSUX.js → chunk-4FOXMGJ7.js} +4 -4
  10. package/dist/{chunk-VIB2FMJJ.js → chunk-5OKDSI6M.js} +44 -44
  11. package/dist/{chunk-QWUZJCF5.js → chunk-66GAYIJZ.js} +3253 -937
  12. package/dist/chunk-66GAYIJZ.js.map +1 -0
  13. package/dist/{chunk-Q3BHXL47.js → chunk-6XMOBI5V.js} +4 -4
  14. package/dist/{chunk-VNXWOWQ7.js → chunk-7QTBRHB7.js} +4 -4
  15. package/dist/{chunk-UWKJ3HIA.js → chunk-ANSPBIYG.js} +4 -4
  16. package/dist/{chunk-7N3CJNR5.js → chunk-AWFTAHGF.js} +20 -7
  17. package/dist/chunk-AWFTAHGF.js.map +1 -0
  18. package/dist/{chunk-EHLPIWRR.js → chunk-AWI2TSWS.js} +2 -2
  19. package/dist/{chunk-GZHJVCBG.js → chunk-CDRKQ5BH.js} +9 -9
  20. package/dist/{chunk-W7P2HHFI.js → chunk-CXAWPWGZ.js} +6 -6
  21. package/dist/{chunk-V5IMDVV5.js → chunk-EDJ6O6CI.js} +6 -6
  22. package/dist/{chunk-PYPIECDD.js → chunk-GSMQL4IJ.js} +17 -17
  23. package/dist/chunk-GVNKIACA.js +223 -0
  24. package/dist/chunk-GVNKIACA.js.map +1 -0
  25. package/dist/{chunk-DKUSSE5G.js → chunk-JWQYZ6V4.js} +2 -2
  26. package/dist/{chunk-WMILLMJZ.js → chunk-KOTW7QQW.js} +5 -5
  27. package/dist/{chunk-XHCGVCSA.js → chunk-L4KBYI3I.js} +5 -5
  28. package/dist/{chunk-BMZOMC6X.js → chunk-M2DWTQRF.js} +3 -3
  29. package/dist/{chunk-XLFQXROC.js → chunk-MB2K74BI.js} +165 -3
  30. package/dist/chunk-MB2K74BI.js.map +1 -0
  31. package/dist/{chunk-MKZHCLFJ.js → chunk-MI3V2MAE.js} +4 -4
  32. package/dist/{chunk-ZMNLEZJB.js → chunk-MO3QJTVS.js} +7 -7
  33. package/dist/{chunk-MBFN2XNU.js → chunk-MPTE57BZ.js} +6 -6
  34. package/dist/{chunk-ZK6KD7ME.js → chunk-PE5LPD23.js} +68 -25
  35. package/dist/chunk-PE5LPD23.js.map +1 -0
  36. package/dist/{chunk-RNYH5465.js → chunk-QBVRWGXD.js} +3 -3
  37. package/dist/{chunk-VEO6ZYQY.js → chunk-RIXW4HSE.js} +6 -6
  38. package/dist/{chunk-QER5WHBC.js → chunk-S7LPQXR5.js} +6 -6
  39. package/dist/{chunk-JS5DLUUX.js → chunk-TAZYSVLT.js} +26 -22
  40. package/dist/{chunk-JS5DLUUX.js.map → chunk-TAZYSVLT.js.map} +1 -1
  41. package/dist/{chunk-QTMUJETE.js → chunk-TDPHZWJI.js} +4 -4
  42. package/dist/{chunk-M42UQWVO.js → chunk-WLEGSKKE.js} +4 -4
  43. package/dist/{chunk-UENVVGWE.js → chunk-WTOG3CC6.js} +4 -4
  44. package/dist/{chunk-QB7XVOYW.js → chunk-X6CO4WIX.js} +4 -4
  45. package/dist/{chunk-744IB5WM.js → chunk-XLJ4D4FI.js} +4 -4
  46. package/dist/{chunk-FVBEUPVM.js → chunk-XNZ6UHTM.js} +27 -5
  47. package/dist/chunk-XNZ6UHTM.js.map +1 -0
  48. package/dist/{chunk-SZTHLJ5J.js → chunk-XTNAIM7X.js} +6 -6
  49. package/dist/{chunk-S3SJIWSU.js → chunk-YNAJUTYC.js} +7 -7
  50. package/dist/{chunk-6GJDU3FN.js → chunk-YSACCMUB.js} +13 -13
  51. package/dist/{chunk-6RREIUAE.js → chunk-ZKOLV4ZN.js} +39 -4
  52. package/dist/chunk-ZKOLV4ZN.js.map +1 -0
  53. package/dist/{cli-JNOPYAUM.js → cli-IFXU5XNZ.js} +9 -9
  54. package/dist/{cli-I6TXLNRQ.js → cli-MZSWFSTW.js} +9 -9
  55. package/dist/{cli-VU2ALT6L.js → cli-O3WXOFNS.js} +8 -8
  56. package/dist/{cli-YYXO4WX5.js → cli-RQJUQJEP.js} +8 -8
  57. package/dist/{cli-W2WNV64V.js → cli-ZGYSHJP7.js} +9 -9
  58. package/dist/cloud-backends.js +5 -5
  59. package/dist/{control-plane-JUAINN2X.js → control-plane-3TII2JGM.js} +20 -20
  60. package/dist/{cp-hub-upload-VHU5TBHQ.js → cp-hub-upload-3W7Z4BMT.js} +7 -7
  61. package/dist/{custody-client-5OHF3SEX.js → custody-client-KYEZET6C.js} +5 -5
  62. package/dist/{deploy-hetzner-RTQW3B7P.js → deploy-hetzner-EO5PFKBG.js} +9 -9
  63. package/dist/{dist-H4FFY5TX.js → dist-3AR6L5MF.js} +8 -8
  64. package/dist/{dist-5HJBDLJP.js → dist-4GHNQ2AK.js} +8 -8
  65. package/dist/{dist-H72NQCKO.js → dist-BFH537FO.js} +9 -9
  66. package/dist/{dist-MBPDLQUR.js → dist-BUCKUE4V.js} +2 -2
  67. package/dist/{dist-64YIP2AZ.js → dist-ETGTZQUT.js} +256 -6
  68. package/dist/{dist-UGI5L7BN.js → dist-H2CSUDEI.js} +8 -8
  69. package/dist/{dist-7IANPBF4.js → dist-IABCQB5D.js} +8 -8
  70. package/dist/{dist-EDCGUXVI.js → dist-JJZ3NZRO.js} +10 -6
  71. package/dist/{dist-7RMVQOWJ.js → dist-RPBA2EL5.js} +8 -8
  72. package/dist/{dist-NJOKYHDI.js → dist-URWWHI3X.js} +9 -3
  73. package/dist/{dist-XWDFVTFR.js → dist-V224SH3Z.js} +7 -7
  74. package/dist/{host-reach-drainer-GTNLQWWM.js → host-reach-drainer-NYN3YXHG.js} +2 -2
  75. package/dist/host-session-YP5RKV6T.js +29 -0
  76. package/dist/hub-OWUC4IGW.js +39 -0
  77. package/dist/{hub-adopt-TVDMOZSP.js → hub-adopt-HYXFUPPO.js} +7 -7
  78. package/dist/{hub-api-client-RISAC6GB.js → hub-api-client-BI3E37CF.js} +4 -4
  79. package/dist/{hub-docker-target-QEALUMIZ.js → hub-docker-target-6ODSK7ZE.js} +14 -14
  80. package/dist/index.js +1224 -230
  81. package/dist/index.js.map +1 -1
  82. package/dist/{plugin-update-LG45ZFCU.js → plugin-update-LI3QDA4K.js} +5 -5
  83. package/dist/prepare-MYFNDJPP.js +45 -0
  84. package/dist/prepared-custody-WSHX6XTQ.js +39 -0
  85. package/dist/{prepared-state-FO74QUCP-SW3QMBW5.js → prepared-state-FO74QUCP-M4Q2X3KN.js} +4 -4
  86. package/dist/{publish-credentials-T7DDJVC4.js → publish-credentials-FCEQSIPE.js} +9 -9
  87. package/dist/{registry-UCFNYOAU.js → registry-GG23NEBF.js} +5 -5
  88. package/dist/relay-YUOIK3HN.js +22 -0
  89. package/dist/{remote-docker-share-SY7CWW5R.js → remote-docker-share-4Z4VVUPG.js} +11 -11
  90. package/dist/remote-docker-share-4Z4VVUPG.js.map +1 -0
  91. package/dist/{tool-grant-push-OJHLVAPZ.js → tool-grant-push-A2JYLJVF.js} +3 -3
  92. package/package.json +1 -1
  93. package/runtime/_shared/ctl.cjs +1046 -316
  94. package/runtime/digitalocean/ctl.cjs +1046 -316
  95. package/runtime/docker/packages/ctl/dist/bin.cjs +1046 -316
  96. package/runtime/e2b/ctl.cjs +1046 -316
  97. package/runtime/hetzner/ctl.cjs +1046 -316
  98. package/runtime/hub/apps/hub/.next/BUILD_ID +1 -1
  99. package/runtime/hub/apps/hub/.next/app-path-routes-manifest.json +24 -0
  100. package/runtime/hub/apps/hub/.next/build-manifest.json +3 -3
  101. package/runtime/hub/apps/hub/.next/routes-manifest.json +188 -0
  102. package/runtime/hub/apps/hub/.next/server/app/(auth)/signin/page_client-reference-manifest.js +1 -1
  103. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/approvals/[id]/answer/route.js +2 -2
  104. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/approvals/[id]/answer/route.js.nft.json +1 -1
  105. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/approvals/route.js.nft.json +1 -1
  106. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/[action]/route.js +4 -4
  107. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/[action]/route.js.nft.json +1 -1
  108. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/agent/route.js.nft.json +1 -1
  109. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/backup/route.js +2 -2
  110. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/backup/route.js.nft.json +1 -1
  111. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/branches/route.js.nft.json +1 -1
  112. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/checkpoint/route.js +2 -2
  113. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/checkpoint/route.js.nft.json +1 -1
  114. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/clone/route.js +2 -2
  115. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/clone/route.js.nft.json +1 -1
  116. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/git/[op]/route.js +4 -4
  117. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/git/[op]/route.js.nft.json +1 -1
  118. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/git/route.js.nft.json +1 -1
  119. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/logs/route.js.nft.json +1 -1
  120. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/open/route.js +2 -2
  121. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/open/route.js.nft.json +1 -1
  122. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/rename/route.js +2 -2
  123. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/rename/route.js.nft.json +1 -1
  124. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/route.js.nft.json +1 -1
  125. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/services/restart/route.js +2 -2
  126. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/services/restart/route.js.nft.json +1 -1
  127. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/services/route.js.nft.json +1 -1
  128. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/upload/route.js +2 -2
  129. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/upload/route.js.nft.json +1 -1
  130. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/vnc/route.js.nft.json +1 -1
  131. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/[id]/web/route.js.nft.json +1 -1
  132. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/route.js +4 -4
  133. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/boxes/route.js.nft.json +1 -1
  134. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/checkpoints/route.js.nft.json +1 -1
  135. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/custody/[...path]/route.js +3 -3
  136. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/hosts/[alias]/bake/route.js.nft.json +1 -1
  137. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/hosts/[alias]/route.js.nft.json +1 -1
  138. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/hosts/route.js +2 -2
  139. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/hosts/route.js.nft.json +1 -1
  140. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/jobs/[id]/login-code/route.js +2 -2
  141. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/jobs/[id]/login-code/route.js.nft.json +1 -1
  142. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/jobs/[id]/logs/route.js.nft.json +1 -1
  143. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/jobs/[id]/route.js.nft.json +1 -1
  144. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/jobs/route.js.nft.json +1 -1
  145. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route/app-paths-manifest.json +3 -0
  146. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route/build-manifest.json +9 -0
  147. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route/server-reference-manifest.json +4 -0
  148. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route.js +9 -0
  149. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route.js.map +5 -0
  150. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route.js.nft.json +1 -0
  151. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/attach/route_client-reference-manifest.js +3 -0
  152. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route/app-paths-manifest.json +3 -0
  153. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route/build-manifest.json +9 -0
  154. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route/server-reference-manifest.json +4 -0
  155. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route.js +10 -0
  156. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route.js.map +5 -0
  157. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route.js.nft.json +1 -0
  158. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/message/route_client-reference-manifest.js +3 -0
  159. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route/app-paths-manifest.json +3 -0
  160. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route/build-manifest.json +9 -0
  161. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route/server-reference-manifest.json +4 -0
  162. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route.js +10 -0
  163. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route.js.map +5 -0
  164. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route.js.nft.json +1 -0
  165. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/notes/route_client-reference-manifest.js +3 -0
  166. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route/app-paths-manifest.json +3 -0
  167. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route/build-manifest.json +9 -0
  168. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route/server-reference-manifest.json +4 -0
  169. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route.js +9 -0
  170. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route.js.map +5 -0
  171. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route.js.nft.json +1 -0
  172. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/resume/route_client-reference-manifest.js +3 -0
  173. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route/app-paths-manifest.json +3 -0
  174. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route/build-manifest.json +9 -0
  175. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route/server-reference-manifest.json +4 -0
  176. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route.js +10 -0
  177. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route.js.map +5 -0
  178. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route.js.nft.json +1 -0
  179. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/route_client-reference-manifest.js +3 -0
  180. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route/app-paths-manifest.json +3 -0
  181. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route/build-manifest.json +9 -0
  182. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route/server-reference-manifest.json +4 -0
  183. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route.js +9 -0
  184. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route.js.map +5 -0
  185. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route.js.nft.json +1 -0
  186. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/[id]/stop/route_client-reference-manifest.js +3 -0
  187. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route/app-paths-manifest.json +3 -0
  188. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route/build-manifest.json +9 -0
  189. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route/server-reference-manifest.json +4 -0
  190. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route.js +10 -0
  191. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route.js.map +5 -0
  192. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route.js.nft.json +1 -0
  193. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/detect/route_client-reference-manifest.js +3 -0
  194. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route/app-paths-manifest.json +3 -0
  195. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route/build-manifest.json +9 -0
  196. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route/server-reference-manifest.json +4 -0
  197. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route.js +10 -0
  198. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route.js.map +5 -0
  199. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route.js.nft.json +1 -0
  200. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/managers/route_client-reference-manifest.js +3 -0
  201. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/open-targets/route.js.nft.json +1 -1
  202. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/bots/route.js.nft.json +1 -1
  203. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/branches/route.js.nft.json +1 -1
  204. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/create-preflight/route.js +2 -2
  205. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/create-preflight/route.js.nft.json +1 -1
  206. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/restore/route.js +2 -2
  207. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/restore/route.js.nft.json +1 -1
  208. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/route.js.nft.json +1 -1
  209. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/[id]/seed/route.js.nft.json +1 -1
  210. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/route.js +2 -2
  211. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/projects/route.js.nft.json +1 -1
  212. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/[id]/credentials/route.js +2 -2
  213. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/[id]/credentials/route.js.nft.json +1 -1
  214. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/[id]/prepare/route.js +2 -2
  215. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/[id]/prepare/route.js.nft.json +1 -1
  216. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/[id]/size-check/route.js +2 -2
  217. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/[id]/size-check/route.js.nft.json +1 -1
  218. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/providers/route.js.nft.json +1 -1
  219. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/prune/route.js +2 -2
  220. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/prune/route.js.nft.json +1 -1
  221. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/system/route.js.nft.json +1 -1
  222. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route/app-paths-manifest.json +3 -0
  223. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route/build-manifest.json +9 -0
  224. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route/server-reference-manifest.json +4 -0
  225. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route.js +10 -0
  226. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route.js.map +5 -0
  227. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route.js.nft.json +1 -0
  228. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/tasks/route_client-reference-manifest.js +3 -0
  229. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route/app-paths-manifest.json +3 -0
  230. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route/build-manifest.json +9 -0
  231. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route/server-reference-manifest.json +4 -0
  232. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route.js +9 -0
  233. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route.js.map +5 -0
  234. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route.js.nft.json +1 -0
  235. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/route_client-reference-manifest.js +3 -0
  236. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route/app-paths-manifest.json +3 -0
  237. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route/build-manifest.json +9 -0
  238. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route/server-reference-manifest.json +4 -0
  239. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route.js +9 -0
  240. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route.js.map +5 -0
  241. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route.js.nft.json +1 -0
  242. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route_client-reference-manifest.js +3 -0
  243. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route/app-paths-manifest.json +3 -0
  244. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route/build-manifest.json +9 -0
  245. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route/server-reference-manifest.json +4 -0
  246. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route.js +10 -0
  247. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route.js.map +5 -0
  248. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route.js.nft.json +1 -0
  249. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route_client-reference-manifest.js +3 -0
  250. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route/app-paths-manifest.json +3 -0
  251. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route/build-manifest.json +9 -0
  252. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route/server-reference-manifest.json +4 -0
  253. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route.js +10 -0
  254. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route.js.map +5 -0
  255. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route.js.nft.json +1 -0
  256. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rename/route_client-reference-manifest.js +3 -0
  257. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route/app-paths-manifest.json +3 -0
  258. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route/build-manifest.json +9 -0
  259. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route/server-reference-manifest.json +4 -0
  260. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route.js +9 -0
  261. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route.js.map +5 -0
  262. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route.js.nft.json +1 -0
  263. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/rescan/route_client-reference-manifest.js +3 -0
  264. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route/app-paths-manifest.json +3 -0
  265. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route/build-manifest.json +9 -0
  266. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route/server-reference-manifest.json +4 -0
  267. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route.js +10 -0
  268. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route.js.map +5 -0
  269. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route.js.nft.json +1 -0
  270. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/route_client-reference-manifest.js +3 -0
  271. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route/app-paths-manifest.json +3 -0
  272. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route/build-manifest.json +9 -0
  273. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route/server-reference-manifest.json +4 -0
  274. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route.js +10 -0
  275. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route.js.map +5 -0
  276. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route.js.nft.json +1 -0
  277. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route_client-reference-manifest.js +3 -0
  278. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route/app-paths-manifest.json +3 -0
  279. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route/build-manifest.json +9 -0
  280. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route/server-reference-manifest.json +4 -0
  281. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route.js +9 -0
  282. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route.js.map +5 -0
  283. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route.js.nft.json +1 -0
  284. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route_client-reference-manifest.js +3 -0
  285. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route/app-paths-manifest.json +3 -0
  286. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route/build-manifest.json +9 -0
  287. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route/server-reference-manifest.json +4 -0
  288. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route.js +10 -0
  289. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route.js.map +5 -0
  290. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route.js.nft.json +1 -0
  291. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route_client-reference-manifest.js +3 -0
  292. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route/app-paths-manifest.json +3 -0
  293. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route/build-manifest.json +9 -0
  294. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route/server-reference-manifest.json +4 -0
  295. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route.js +9 -0
  296. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route.js.map +5 -0
  297. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route.js.nft.json +1 -0
  298. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route_client-reference-manifest.js +3 -0
  299. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route/app-paths-manifest.json +3 -0
  300. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route/build-manifest.json +9 -0
  301. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route/server-reference-manifest.json +4 -0
  302. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route.js +10 -0
  303. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route.js.map +5 -0
  304. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route.js.nft.json +1 -0
  305. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route_client-reference-manifest.js +3 -0
  306. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route/app-paths-manifest.json +3 -0
  307. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route/build-manifest.json +9 -0
  308. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route/server-reference-manifest.json +4 -0
  309. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route.js +10 -0
  310. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route.js.map +5 -0
  311. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route.js.nft.json +1 -0
  312. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route_client-reference-manifest.js +3 -0
  313. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route/app-paths-manifest.json +3 -0
  314. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route/build-manifest.json +9 -0
  315. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route/server-reference-manifest.json +4 -0
  316. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route.js +10 -0
  317. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route.js.map +5 -0
  318. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route.js.nft.json +1 -0
  319. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/tasks/route_client-reference-manifest.js +3 -0
  320. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route/app-paths-manifest.json +3 -0
  321. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route/build-manifest.json +9 -0
  322. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route/server-reference-manifest.json +4 -0
  323. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route.js +10 -0
  324. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route.js.map +5 -0
  325. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route.js.nft.json +1 -0
  326. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/[id]/timeline/route_client-reference-manifest.js +3 -0
  327. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route/app-paths-manifest.json +3 -0
  328. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route/build-manifest.json +9 -0
  329. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route/server-reference-manifest.json +4 -0
  330. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route.js +10 -0
  331. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route.js.map +5 -0
  332. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route.js.nft.json +1 -0
  333. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/api/v1/workspaces/route_client-reference-manifest.js +3 -0
  334. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/approvals/page.js.nft.json +1 -1
  335. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/approvals/page_client-reference-manifest.js +1 -1
  336. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/boxes/[id]/page.js.nft.json +1 -1
  337. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/boxes/[id]/page_client-reference-manifest.js +1 -1
  338. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/boxes/[id]/vnc/route.js.nft.json +1 -1
  339. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/boxes/[id]/web/route.js.nft.json +1 -1
  340. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/custody/page.js.nft.json +1 -1
  341. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/custody/page_client-reference-manifest.js +1 -1
  342. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/page.js.nft.json +1 -1
  343. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/page_client-reference-manifest.js +1 -1
  344. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/projects/[id]/page.js.nft.json +1 -1
  345. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/projects/[id]/page_client-reference-manifest.js +1 -1
  346. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/settings/page.js.nft.json +1 -1
  347. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/settings/page_client-reference-manifest.js +1 -1
  348. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/system/page.js.nft.json +1 -1
  349. package/runtime/hub/apps/hub/.next/server/app/(dashboard)/system/page_client-reference-manifest.js +1 -1
  350. package/runtime/hub/apps/hub/.next/server/app/[...path]/route.js +1 -1
  351. package/runtime/hub/apps/hub/.next/server/app/[...path]/route.js.nft.json +1 -1
  352. package/runtime/hub/apps/hub/.next/server/app/_global-error/page_client-reference-manifest.js +1 -1
  353. package/runtime/hub/apps/hub/.next/server/app/_global-error.html +1 -1
  354. package/runtime/hub/apps/hub/.next/server/app/_global-error.rsc +1 -1
  355. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/__PAGE__.segment.rsc +1 -1
  356. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_full.segment.rsc +1 -1
  357. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_head.segment.rsc +1 -1
  358. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_index.segment.rsc +1 -1
  359. package/runtime/hub/apps/hub/.next/server/app/_global-error.segments/_tree.segment.rsc +1 -1
  360. package/runtime/hub/apps/hub/.next/server/app/_not-found/page_client-reference-manifest.js +1 -1
  361. package/runtime/hub/apps/hub/.next/server/app-paths-manifest.json +24 -0
  362. package/runtime/hub/apps/hub/.next/server/chunks/00je_(dashboard)_api_v1_workspaces_[id]_tasks_[taskId]_assign_route_actions_1sufsej.js +3 -0
  363. package/runtime/hub/apps/hub/.next/server/chunks/00je_(dashboard)_api_v1_workspaces_[id]_tasks_[taskId]_done_route_actions_216dixx.js +3 -0
  364. package/runtime/hub/apps/hub/.next/server/chunks/044u_hub__next-internal_server_app_(dashboard)_api_v1_managers_route_actions_1_vtgih.js +3 -0
  365. package/runtime/hub/apps/hub/.next/server/chunks/044u_hub__next-internal_server_app_(dashboard)_api_v1_tasks_route_actions_1h8tg_m.js +3 -0
  366. package/runtime/hub/apps/hub/.next/server/chunks/05v5_app_(dashboard)_api_v1_workspaces_[id]_managers_sessions_route_actions_16dksub.js +3 -0
  367. package/runtime/hub/apps/hub/.next/server/chunks/05v5_app_(dashboard)_api_v1_workspaces_[id]_managers_start_route_actions_1g-vmis.js +3 -0
  368. package/runtime/hub/apps/hub/.next/server/chunks/05v5_app_(dashboard)_api_v1_workspaces_[id]_tasks_[taskId]_route_actions_03oih6y.js +3 -0
  369. package/runtime/hub/apps/hub/.next/server/chunks/05v5_app_(dashboard)_api_v1_workspaces_[id]_tasks_assign_route_actions_196zwo9.js +3 -0
  370. package/runtime/hub/apps/hub/.next/server/chunks/05v5_app_(dashboard)_api_v1_workspaces_[id]_tasks_reorder_route_actions_1zkcfk-.js +3 -0
  371. package/runtime/hub/apps/hub/.next/server/chunks/0ssw__next-internal_server_app_(dashboard)_api_v1_workspaces_route_actions_12a7_y8.js +3 -0
  372. package/runtime/hub/apps/hub/.next/server/chunks/0web_next-internal_server_app_(dashboard)_api_v1_managers_[id]_route_actions_07cpyb_.js +3 -0
  373. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_managers_[id]_attach_route_actions_0o-khw8.js +3 -0
  374. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_managers_[id]_message_route_actions_0rjcqe5.js +3 -0
  375. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_managers_[id]_notes_route_actions_1-mf4r_.js +3 -0
  376. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_managers_[id]_resume_route_actions_0-cm1mu.js +3 -0
  377. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_managers_[id]_stop_route_actions_16nrl1r.js +3 -0
  378. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_managers_detect_route_actions_1sdbs-_.js +3 -0
  379. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_workspaces_[id]_managers_route_actions_1sxymv0.js +3 -0
  380. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_workspaces_[id]_rename_route_actions_0df5zi2.js +3 -0
  381. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_workspaces_[id]_rescan_route_actions_1yra_w8.js +3 -0
  382. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_workspaces_[id]_route_actions_1f56n_0.js +3 -0
  383. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_workspaces_[id]_tasks_route_actions_1t-6quw.js +3 -0
  384. package/runtime/hub/apps/hub/.next/server/chunks/1jcg_server_app_(dashboard)_api_v1_workspaces_[id]_timeline_route_actions_0pbxblt.js +3 -0
  385. package/runtime/hub/apps/hub/.next/server/chunks/1viy_api_v1_workspaces_[id]_tasks_[taskId]_unassign_route_actions_18a1p_r.js +3 -0
  386. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0-c97gb._.js +1 -1
  387. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__0spnud2._.js → [root-of-the-server]__0-kl55b._.js} +1 -1
  388. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__074mxl5._.js → [root-of-the-server]__0-xlf9z._.js} +2 -2
  389. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__028ifqb._.js → [root-of-the-server]__0004tsz._.js} +2 -2
  390. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__00bupbc._.js +1 -1
  391. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__1cpr4qy._.js → [root-of-the-server]__0126167._.js} +1 -1
  392. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__01fy5q0._.js +1 -1
  393. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__02c077x._.js +3 -0
  394. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__1ta1gr1._.js → [root-of-the-server]__02sueng._.js} +1 -1
  395. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__0nndlre._.js → [root-of-the-server]__04-gm8c._.js} +2 -2
  396. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__05uinnp._.js +1 -1
  397. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__06wy8zz._.js +3 -0
  398. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__071c-t4._.js +3 -0
  399. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__08jg8w8._.js +1 -1
  400. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__09059m-._.js +1 -1
  401. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__092y7_z._.js +1 -1
  402. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__09ti2-t._.js +3 -0
  403. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__09y4pdw._.js +3 -0
  404. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0_mog_h._.js +1 -1
  405. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0a689u5._.js +3 -0
  406. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0a8ere2._.js +3 -0
  407. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0bzqrje._.js +3 -0
  408. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0c_r3oe._.js +3 -0
  409. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0cdoz9i._.js +1 -1
  410. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0cmu4sk._.js +1 -1
  411. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0cxjxz0._.js +1 -1
  412. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0d27tlu._.js +3 -0
  413. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0d3fx1z._.js +3 -0
  414. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0dm5oqm._.js +1 -1
  415. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0dy5g2k._.js +1 -1
  416. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0e1uaxg._.js +1 -1
  417. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0e6_t-d._.js +3 -0
  418. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0ets4cd._.js +1 -1
  419. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0f2u0ul._.js +1 -1
  420. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0f9p_4f._.js +1 -1
  421. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0f_jmq2._.js +1 -1
  422. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0fksz_r._.js +1 -1
  423. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0fpygqn._.js +3 -0
  424. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0gym-rp._.js +1 -1
  425. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0hhlb2_._.js +1 -1
  426. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0i9phow._.js +1 -1
  427. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0ikyoac._.js +1 -1
  428. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0j72bti._.js +1 -1
  429. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0jb371p._.js +1 -1
  430. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0jq6cdw._.js +3 -0
  431. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0jt1d2s._.js +3 -0
  432. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0kcw8t0._.js +1 -1
  433. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0kdt9-i._.js +1 -1
  434. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0l27vs0._.js +1 -1
  435. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0lc-j_n._.js +3 -0
  436. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0lna-vq._.js +3 -0
  437. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0m5woxc._.js +1 -1
  438. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0mi9xib._.js +3 -0
  439. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0muy7eg._.js +3 -0
  440. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0nn0_b5._.js +3 -0
  441. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0no30or._.js +3 -0
  442. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0o3sjtx._.js +1 -1
  443. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0onk5r0._.js +1 -1
  444. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0pik2ie._.js +3 -0
  445. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0qde3vr._.js +1 -1
  446. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0qt_r6a._.js +3 -0
  447. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0ry8baf._.js +1 -1
  448. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0sg4y_2._.js +3 -0
  449. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0sgjn2j._.js +1 -1
  450. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0st6oln._.js +1 -1
  451. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0t0p64l._.js +1 -1
  452. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0tbl11-._.js +3 -0
  453. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0ve_tqz._.js +1 -1
  454. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0w4smfx._.js +3 -0
  455. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0wo4sqj._.js +1 -1
  456. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0wujjkl._.js +3 -0
  457. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0xbu3yj._.js +3 -0
  458. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0xl1-w6._.js +1 -1
  459. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0yct1tu._.js +1 -1
  460. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0yg67t0._.js +1 -1
  461. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__0ykw5oe._.js +3 -0
  462. package/runtime/hub/apps/hub/.next/server/chunks/{[root-of-the-server]__1c1rcl-._.js → [root-of-the-server]__0zznyx2._.js} +2 -2
  463. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1--u2xl._.js +3 -0
  464. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1-8sj4i._.js +1 -1
  465. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__10kmcrt._.js +3 -0
  466. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__10l_-cd._.js +3 -0
  467. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__10yfcvu._.js +1 -1
  468. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__112hqrh._.js +3 -0
  469. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__11c-21i._.js +3 -0
  470. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__11qbpq8._.js +3 -0
  471. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__11s1mrd._.js +1 -1
  472. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__128w1nz._.js +3 -0
  473. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__12b2kuv._.js +1 -1
  474. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__12gbq5m._.js +1 -1
  475. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__13nfpq5._.js +3 -0
  476. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__13vl4-h._.js +1 -1
  477. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__153b7kv._.js +1 -1
  478. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__157kmse._.js +1 -1
  479. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__16695dw._.js +1 -1
  480. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__166_uek._.js +3 -0
  481. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__16o0ij7._.js +1 -1
  482. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__175lucf._.js +1 -1
  483. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__17p53e3._.js +3 -0
  484. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__17y9pmx._.js +3 -0
  485. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__18ec5_t._.js +3 -0
  486. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__18xpvkc._.js +1 -1
  487. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1925hyw._.js +3 -0
  488. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__19ew1r2._.js +3 -0
  489. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__19grunx._.js +1 -1
  490. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1_4v0mh._.js +3 -0
  491. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1_cbcl1._.js +1 -1
  492. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1_wb2uh._.js +3 -0
  493. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1_xgm2e._.js +3 -0
  494. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1an6-yb._.js +3 -0
  495. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1c0ex8m._.js +1 -1
  496. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1c1e08-._.js +3 -0
  497. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1c9f4uu._.js +1 -1
  498. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1ci8hc2._.js +1 -1
  499. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1cs6d52._.js +3 -0
  500. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1d60scp._.js +3 -0
  501. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1dicjoc._.js +3 -0
  502. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1diipl4._.js +3 -0
  503. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1dp2exz._.js +1 -1
  504. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1epnstn._.js +1 -1
  505. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1fjnz2l._.js +3 -0
  506. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1g5wnt2._.js +1 -1
  507. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1g9v7bq._.js +1 -1
  508. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1gon0_4._.js +3 -0
  509. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1h_59cs._.js +1 -1
  510. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1h_q3sn._.js +3 -0
  511. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1hlugb4._.js +1 -1
  512. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1hux-70._.js +1 -1
  513. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1i-7bnu._.js +3 -0
  514. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1i_el2y._.js +3 -0
  515. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1j6clag._.js +1 -1
  516. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1k6q17t._.js +3 -0
  517. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1khvg39._.js +1 -1
  518. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1lx9lyn._.js +3 -0
  519. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1m36v6k._.js +1 -1
  520. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1mgu19x._.js +3 -0
  521. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1mhyrr5._.js +3 -0
  522. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1mk_lpu._.js +3 -0
  523. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1mt32fu._.js +1 -1
  524. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1n1_2tw._.js +1 -1
  525. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1na4sdw._.js +3 -0
  526. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1ntihlm._.js +3 -0
  527. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1odu62n._.js +3 -0
  528. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1q6xrlt._.js +2 -2
  529. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1r4x1-y._.js +3 -0
  530. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1rjs_x0._.js +1 -1
  531. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1rxud0j._.js +1 -1
  532. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1s5app0._.js +1 -1
  533. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1sjz59l._.js +3 -0
  534. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1slo4q_._.js +1 -1
  535. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1thrazp._.js +3 -0
  536. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1twtnwr._.js +1 -1
  537. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1txvsbk._.js +3 -0
  538. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1uch-60._.js +1 -1
  539. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1um2jum._.js +3 -0
  540. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1vnnuo1._.js +1 -1
  541. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1wegvep._.js +3 -0
  542. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1wi5roz._.js +1 -1
  543. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1xa9oiv._.js +3 -0
  544. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1ypmy86._.js +3 -0
  545. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1zml9me._.js +1 -1
  546. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1zrf_a6._.js +1 -1
  547. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__2019yzl._.js +3 -0
  548. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__20jyxyo._.js +2 -2
  549. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__20ybhif._.js +1 -1
  550. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__20zl5fr._.js +1 -1
  551. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__212dyoi._.js +1 -1
  552. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__218oup-._.js +1 -1
  553. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__21abvx9._.js +3 -0
  554. package/runtime/hub/apps/hub/.next/server/chunks/_0907rw0._.js +2 -1
  555. package/runtime/hub/apps/hub/.next/server/chunks/_0mcxq5g._.js +1 -1
  556. package/runtime/hub/apps/hub/.next/server/chunks/_0vg6gvw._.js +41 -41
  557. package/runtime/hub/apps/hub/.next/server/chunks/apps_hub_app_(dashboard)_api_v1_lib_openapi_ts_1yokmzt._.js +1 -1
  558. package/runtime/hub/apps/hub/.next/server/chunks/apps_hub_app_(dashboard)_api_v1_lib_validate_ts_16dhbzz._.js +1 -1
  559. package/runtime/hub/apps/hub/.next/server/chunks/packages_agent-registry_dist_index_1ze3mqq.js +28 -19
  560. package/runtime/hub/apps/hub/.next/server/chunks/packages_relay_dist_control-plane_03a-9aj.js +6 -6
  561. package/runtime/hub/apps/hub/.next/server/chunks/ssr/[root-of-the-server]__03-x9xy._.js +1 -1
  562. package/runtime/hub/apps/hub/.next/server/chunks/ssr/[root-of-the-server]__1jqga8h._.js +1 -1
  563. package/runtime/hub/apps/hub/.next/server/chunks/ssr/_0r2xlss._.js +2 -1
  564. package/runtime/hub/apps/hub/.next/server/chunks/ssr/_14-qzbg._.js +26 -26
  565. package/runtime/hub/apps/hub/.next/server/chunks/ssr/packages_agent-registry_dist_index_0z476w4.js +26 -17
  566. package/runtime/hub/apps/hub/.next/server/chunks/ssr/packages_relay_dist_control-plane_0ve-wz4.js +1 -1
  567. package/runtime/hub/apps/hub/.next/server/functions-config-manifest.json +24 -0
  568. package/runtime/hub/apps/hub/.next/server/middleware-build-manifest.js +3 -3
  569. package/runtime/hub/apps/hub/.next/server/pages/500.html +1 -1
  570. package/runtime/hub/apps/hub/.next/static/chunks/{31e1wjin30i__.css → 03_fxfc3849ms.css} +1 -1
  571. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/boxes/[id]/[action]/route.ts +4 -2
  572. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/boxes/[id]/git/[op]/route.ts +6 -4
  573. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/boxes/route.ts +2 -1
  574. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/lib/actor.ts +48 -0
  575. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/lib/envelope.ts +5 -2
  576. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/lib/openapi.ts +1687 -52
  577. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/lib/validate.ts +527 -1
  578. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/[id]/attach/route.ts +26 -0
  579. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/[id]/message/route.ts +34 -0
  580. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/[id]/notes/route.ts +26 -0
  581. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/[id]/resume/route.ts +26 -0
  582. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/[id]/route.ts +34 -0
  583. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/[id]/stop/route.ts +23 -0
  584. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/detect/route.ts +33 -0
  585. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/managers/route.ts +27 -0
  586. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/tasks/route.ts +30 -0
  587. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/managers/route.ts +19 -0
  588. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/managers/sessions/route.ts +22 -0
  589. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/managers/start/route.ts +61 -0
  590. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/rename/route.ts +25 -0
  591. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/rescan/route.ts +20 -0
  592. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/route.ts +34 -0
  593. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/assign/route.ts +33 -0
  594. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/done/route.ts +23 -0
  595. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/route.ts +54 -0
  596. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/[taskId]/unassign/route.ts +25 -0
  597. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/assign/route.ts +34 -0
  598. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/reorder/route.ts +33 -0
  599. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/tasks/route.ts +59 -0
  600. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/[id]/timeline/route.ts +25 -0
  601. package/runtime/hub/apps/hub/app/(dashboard)/api/v1/workspaces/route.ts +31 -0
  602. package/runtime/hub/apps/hub/{chunk-FQY5OEWX.js → chunk-2LE76CT3.js} +19 -6
  603. package/runtime/hub/apps/hub/{chunk-MIETKCV4.js → chunk-BR4WVGWJ.js} +3 -3
  604. package/runtime/hub/apps/hub/{chunk-KTWFE5BB.js → chunk-EVB2OTLU.js} +3312 -1032
  605. package/runtime/hub/apps/hub/{chunk-IDL7RJBP.js → chunk-FBNAIUXZ.js} +38 -3
  606. package/runtime/hub/apps/hub/{chunk-ORTYCJ2U.js → chunk-G2AEPH7C.js} +4 -4
  607. package/runtime/hub/apps/hub/{chunk-VNLPJ45F.js → chunk-JX5JUFSR.js} +9 -9
  608. package/runtime/hub/apps/hub/{chunk-PM2365RW.js → chunk-MD2UNTZR.js} +6 -6
  609. package/runtime/hub/apps/hub/{dist-4DVVLHK2.js → dist-3LDUYWPK.js} +8 -2
  610. package/runtime/hub/apps/hub/{dist-RWN4Z57N.js → dist-CJ6QFUFV.js} +5 -5
  611. package/runtime/hub/apps/hub/{dist-FM26NQ4V.js → dist-D36FTGG6.js} +1 -1
  612. package/runtime/hub/apps/hub/{dist-VF56FSKH.js → dist-GGLWLMY6.js} +6 -6
  613. package/runtime/hub/apps/hub/{dist-WA2LO2DU.js → dist-HLLYJGIT.js} +6 -6
  614. package/runtime/hub/apps/hub/{dist-OAS6A7E4.js → dist-IIQU4I42.js} +5 -5
  615. package/runtime/hub/apps/hub/{dist-3IYYT3II.js → dist-UFMCOK3W.js} +5 -5
  616. package/runtime/hub/apps/hub/{dist-LMXU56B2.js → dist-XUNBQ4WM.js} +5 -5
  617. package/runtime/hub/apps/hub/{dist-LOZYEDXA.js → dist-Y2263LMY.js} +8 -4
  618. package/runtime/hub/apps/hub/{dist-UPKSCLZ2.js → dist-YV4M6NJO.js} +5 -5
  619. package/runtime/hub/apps/hub/{hub-worker-6JAWRLP2.js → hub-worker-LJYEEAJL.js} +7 -7
  620. package/runtime/hub/apps/hub/lib/backend/background.ts +19 -0
  621. package/runtime/hub/apps/hub/lib/backend/box-facts.ts +97 -0
  622. package/runtime/hub/apps/hub/lib/backend/box-prs.ts +213 -0
  623. package/runtime/hub/apps/hub/lib/backend/deps.ts +99 -0
  624. package/runtime/hub/apps/hub/lib/backend/errors.ts +7 -0
  625. package/runtime/hub/apps/hub/lib/backend/github-prs.ts +302 -0
  626. package/runtime/hub/apps/hub/lib/backend/managers.ts +748 -0
  627. package/runtime/hub/apps/hub/lib/backend/timeline-lanes.ts +150 -0
  628. package/runtime/hub/apps/hub/lib/backend/timeline.ts +611 -0
  629. package/runtime/hub/apps/hub/lib/backend/workspaces.ts +439 -0
  630. package/runtime/hub/apps/hub/lib/boxes/backend-types.ts +355 -10
  631. package/runtime/hub/apps/hub/lib/boxes/postgres-source.ts +3 -0
  632. package/runtime/hub/apps/hub/lib/boxes/source.ts +18 -1
  633. package/runtime/hub/apps/hub/lib/boxes/types.ts +66 -0
  634. package/runtime/hub/apps/hub/lib/hub-backend.ts +114 -7
  635. package/runtime/hub/apps/hub/{prepared-state-FO74QUCP-QR6ZNI3Q.js → prepared-state-FO74QUCP-75UBPW5I.js} +3 -3
  636. package/runtime/hub/apps/hub/server.js +2033 -164
  637. package/runtime/hub/apps/hub/test/backend-managers-background.test.ts +336 -0
  638. package/runtime/hub/apps/hub/test/backend-managers.test.ts +493 -0
  639. package/runtime/hub/apps/hub/test/backend-workspaces.test.ts +208 -0
  640. package/runtime/hub/apps/hub/test/box-prs.test.ts +198 -0
  641. package/runtime/hub/apps/hub/test/timeline-lanes.test.ts +261 -0
  642. package/runtime/hub/apps/hub/test/timeline.test.ts +1185 -0
  643. package/runtime/hub/apps/hub/test/validate.test.ts +252 -0
  644. package/runtime/hub/apps/hub/tsconfig.tsbuildinfo +1 -1
  645. package/runtime/relay/bin.cjs +1419 -623
  646. package/runtime/vercel/ctl.cjs +1046 -316
  647. package/share/host-skills/agentbox-info/SKILL.md +25 -4
  648. package/dist/_cloud-attach-QB72ZV7T.js +0 -31
  649. package/dist/chunk-6RREIUAE.js.map +0 -1
  650. package/dist/chunk-7N3CJNR5.js.map +0 -1
  651. package/dist/chunk-FVBEUPVM.js.map +0 -1
  652. package/dist/chunk-QWUZJCF5.js.map +0 -1
  653. package/dist/chunk-XLFQXROC.js.map +0 -1
  654. package/dist/chunk-ZK6KD7ME.js.map +0 -1
  655. package/dist/hub-C5B3CRP6.js +0 -39
  656. package/dist/prepare-6JLTXX65.js +0 -45
  657. package/dist/prepared-custody-YVVTL2ZM.js +0 -39
  658. package/dist/relay-W73AIA35.js +0 -22
  659. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__00o_3sf._.js +0 -3
  660. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__08xwxyo._.js +0 -3
  661. package/runtime/hub/apps/hub/.next/server/chunks/[root-of-the-server]__1-mtsr6._.js +0 -3
  662. /package/dist/{_cloud-attach-QB72ZV7T.js.map → _cloud-attach-6RKS3MAP.js.map} +0 -0
  663. /package/dist/{chunk-E2RPG54S.js.map → chunk-27S7QLDF.js.map} +0 -0
  664. /package/dist/{chunk-EZPCCJPE.js.map → chunk-2APGFWEU.js.map} +0 -0
  665. /package/dist/{chunk-7PDYVJ2Q.js.map → chunk-3AYSA62C.js.map} +0 -0
  666. /package/dist/{chunk-SHFU2KSY.js.map → chunk-3ISG5THX.js.map} +0 -0
  667. /package/dist/{chunk-D67Q5MNA.js.map → chunk-3L2DIPRM.js.map} +0 -0
  668. /package/dist/{chunk-GYUOXSUX.js.map → chunk-4FOXMGJ7.js.map} +0 -0
  669. /package/dist/{chunk-VIB2FMJJ.js.map → chunk-5OKDSI6M.js.map} +0 -0
  670. /package/dist/{chunk-Q3BHXL47.js.map → chunk-6XMOBI5V.js.map} +0 -0
  671. /package/dist/{chunk-VNXWOWQ7.js.map → chunk-7QTBRHB7.js.map} +0 -0
  672. /package/dist/{chunk-UWKJ3HIA.js.map → chunk-ANSPBIYG.js.map} +0 -0
  673. /package/dist/{chunk-EHLPIWRR.js.map → chunk-AWI2TSWS.js.map} +0 -0
  674. /package/dist/{chunk-GZHJVCBG.js.map → chunk-CDRKQ5BH.js.map} +0 -0
  675. /package/dist/{chunk-W7P2HHFI.js.map → chunk-CXAWPWGZ.js.map} +0 -0
  676. /package/dist/{chunk-V5IMDVV5.js.map → chunk-EDJ6O6CI.js.map} +0 -0
  677. /package/dist/{chunk-PYPIECDD.js.map → chunk-GSMQL4IJ.js.map} +0 -0
  678. /package/dist/{chunk-DKUSSE5G.js.map → chunk-JWQYZ6V4.js.map} +0 -0
  679. /package/dist/{chunk-WMILLMJZ.js.map → chunk-KOTW7QQW.js.map} +0 -0
  680. /package/dist/{chunk-XHCGVCSA.js.map → chunk-L4KBYI3I.js.map} +0 -0
  681. /package/dist/{chunk-BMZOMC6X.js.map → chunk-M2DWTQRF.js.map} +0 -0
  682. /package/dist/{chunk-MKZHCLFJ.js.map → chunk-MI3V2MAE.js.map} +0 -0
  683. /package/dist/{chunk-ZMNLEZJB.js.map → chunk-MO3QJTVS.js.map} +0 -0
  684. /package/dist/{chunk-MBFN2XNU.js.map → chunk-MPTE57BZ.js.map} +0 -0
  685. /package/dist/{chunk-RNYH5465.js.map → chunk-QBVRWGXD.js.map} +0 -0
  686. /package/dist/{chunk-VEO6ZYQY.js.map → chunk-RIXW4HSE.js.map} +0 -0
  687. /package/dist/{chunk-QER5WHBC.js.map → chunk-S7LPQXR5.js.map} +0 -0
  688. /package/dist/{chunk-QTMUJETE.js.map → chunk-TDPHZWJI.js.map} +0 -0
  689. /package/dist/{chunk-M42UQWVO.js.map → chunk-WLEGSKKE.js.map} +0 -0
  690. /package/dist/{chunk-UENVVGWE.js.map → chunk-WTOG3CC6.js.map} +0 -0
  691. /package/dist/{chunk-QB7XVOYW.js.map → chunk-X6CO4WIX.js.map} +0 -0
  692. /package/dist/{chunk-744IB5WM.js.map → chunk-XLJ4D4FI.js.map} +0 -0
  693. /package/dist/{chunk-SZTHLJ5J.js.map → chunk-XTNAIM7X.js.map} +0 -0
  694. /package/dist/{chunk-S3SJIWSU.js.map → chunk-YNAJUTYC.js.map} +0 -0
  695. /package/dist/{chunk-6GJDU3FN.js.map → chunk-YSACCMUB.js.map} +0 -0
  696. /package/dist/{cli-I6TXLNRQ.js.map → cli-IFXU5XNZ.js.map} +0 -0
  697. /package/dist/{cli-JNOPYAUM.js.map → cli-MZSWFSTW.js.map} +0 -0
  698. /package/dist/{cli-VU2ALT6L.js.map → cli-O3WXOFNS.js.map} +0 -0
  699. /package/dist/{cli-W2WNV64V.js.map → cli-RQJUQJEP.js.map} +0 -0
  700. /package/dist/{cli-YYXO4WX5.js.map → cli-ZGYSHJP7.js.map} +0 -0
  701. /package/dist/{control-plane-JUAINN2X.js.map → control-plane-3TII2JGM.js.map} +0 -0
  702. /package/dist/{cp-hub-upload-VHU5TBHQ.js.map → cp-hub-upload-3W7Z4BMT.js.map} +0 -0
  703. /package/dist/{custody-client-5OHF3SEX.js.map → custody-client-KYEZET6C.js.map} +0 -0
  704. /package/dist/{deploy-hetzner-RTQW3B7P.js.map → deploy-hetzner-EO5PFKBG.js.map} +0 -0
  705. /package/dist/{dist-64YIP2AZ.js.map → dist-3AR6L5MF.js.map} +0 -0
  706. /package/dist/{dist-5HJBDLJP.js.map → dist-4GHNQ2AK.js.map} +0 -0
  707. /package/dist/{dist-7IANPBF4.js.map → dist-BFH537FO.js.map} +0 -0
  708. /package/dist/{dist-EDCGUXVI.js.map → dist-BUCKUE4V.js.map} +0 -0
  709. /package/dist/{dist-H4FFY5TX.js.map → dist-ETGTZQUT.js.map} +0 -0
  710. /package/dist/{dist-H72NQCKO.js.map → dist-H2CSUDEI.js.map} +0 -0
  711. /package/dist/{dist-MBPDLQUR.js.map → dist-IABCQB5D.js.map} +0 -0
  712. /package/dist/{dist-NJOKYHDI.js.map → dist-JJZ3NZRO.js.map} +0 -0
  713. /package/dist/{dist-7RMVQOWJ.js.map → dist-RPBA2EL5.js.map} +0 -0
  714. /package/dist/{dist-UGI5L7BN.js.map → dist-URWWHI3X.js.map} +0 -0
  715. /package/dist/{dist-XWDFVTFR.js.map → dist-V224SH3Z.js.map} +0 -0
  716. /package/dist/{host-reach-drainer-GTNLQWWM.js.map → host-reach-drainer-NYN3YXHG.js.map} +0 -0
  717. /package/dist/{hub-C5B3CRP6.js.map → host-session-YP5RKV6T.js.map} +0 -0
  718. /package/dist/{hub-adopt-TVDMOZSP.js.map → hub-OWUC4IGW.js.map} +0 -0
  719. /package/dist/{hub-api-client-RISAC6GB.js.map → hub-adopt-HYXFUPPO.js.map} +0 -0
  720. /package/dist/{prepare-6JLTXX65.js.map → hub-api-client-BI3E37CF.js.map} +0 -0
  721. /package/dist/{hub-docker-target-QEALUMIZ.js.map → hub-docker-target-6ODSK7ZE.js.map} +0 -0
  722. /package/dist/{plugin-update-LG45ZFCU.js.map → plugin-update-LI3QDA4K.js.map} +0 -0
  723. /package/dist/{prepared-custody-YVVTL2ZM.js.map → prepare-MYFNDJPP.js.map} +0 -0
  724. /package/dist/{prepared-state-FO74QUCP-SW3QMBW5.js.map → prepared-custody-WSHX6XTQ.js.map} +0 -0
  725. /package/dist/{registry-UCFNYOAU.js.map → prepared-state-FO74QUCP-M4Q2X3KN.js.map} +0 -0
  726. /package/dist/{publish-credentials-T7DDJVC4.js.map → publish-credentials-FCEQSIPE.js.map} +0 -0
  727. /package/dist/{relay-W73AIA35.js.map → registry-GG23NEBF.js.map} +0 -0
  728. /package/dist/{remote-docker-share-SY7CWW5R.js.map → relay-YUOIK3HN.js.map} +0 -0
  729. /package/dist/{tool-grant-push-OJHLVAPZ.js.map → tool-grant-push-A2JYLJVF.js.map} +0 -0
  730. /package/runtime/hub/apps/hub/.next/static/{kg0mtyaaNMvU3P8p7nLPa → QDhlg7V_fEVGv_NfM2cEJ}/_buildManifest.js +0 -0
  731. /package/runtime/hub/apps/hub/.next/static/{kg0mtyaaNMvU3P8p7nLPa → QDhlg7V_fEVGv_NfM2cEJ}/_clientMiddlewareManifest.js +0 -0
  732. /package/runtime/hub/apps/hub/.next/static/{kg0mtyaaNMvU3P8p7nLPa → QDhlg7V_fEVGv_NfM2cEJ}/_ssgManifest.js +0 -0
@@ -11445,11 +11445,11 @@ var init_base = __esm({
11445
11445
  "use strict";
11446
11446
  import_node_tty = __toESM(require("tty"), 1);
11447
11447
  hasColors = import_node_tty.default?.WriteStream?.prototype?.hasColors?.() ?? false;
11448
- format = (open4, close) => {
11448
+ format = (open5, close) => {
11449
11449
  if (!hasColors) {
11450
11450
  return (input) => input;
11451
11451
  }
11452
- const openCode = `\x1B[${open4}m`;
11452
+ const openCode = `\x1B[${open5}m`;
11453
11453
  const closeCode = `\x1B[${close}m`;
11454
11454
  return (input) => {
11455
11455
  const string = input + "";
@@ -11754,15 +11754,15 @@ var require_windows = __commonJS({
11754
11754
  }
11755
11755
  return false;
11756
11756
  }
11757
- function checkStat(stat18, path6, options) {
11758
- if (!stat18.isSymbolicLink() && !stat18.isFile()) {
11757
+ function checkStat(stat19, path6, options) {
11758
+ if (!stat19.isSymbolicLink() && !stat19.isFile()) {
11759
11759
  return false;
11760
11760
  }
11761
11761
  return checkPathExt(path6, options);
11762
11762
  }
11763
11763
  function isexe(path6, options, cb) {
11764
- fs2.stat(path6, function(er, stat18) {
11765
- cb(er, er ? false : checkStat(stat18, path6, options));
11764
+ fs2.stat(path6, function(er, stat19) {
11765
+ cb(er, er ? false : checkStat(stat19, path6, options));
11766
11766
  });
11767
11767
  }
11768
11768
  function sync(path6, options) {
@@ -11779,20 +11779,20 @@ var require_mode = __commonJS({
11779
11779
  isexe.sync = sync;
11780
11780
  var fs2 = require("fs");
11781
11781
  function isexe(path6, options, cb) {
11782
- fs2.stat(path6, function(er, stat18) {
11783
- cb(er, er ? false : checkStat(stat18, options));
11782
+ fs2.stat(path6, function(er, stat19) {
11783
+ cb(er, er ? false : checkStat(stat19, options));
11784
11784
  });
11785
11785
  }
11786
11786
  function sync(path6, options) {
11787
11787
  return checkStat(fs2.statSync(path6), options);
11788
11788
  }
11789
- function checkStat(stat18, options) {
11790
- return stat18.isFile() && checkMode(stat18, options);
11789
+ function checkStat(stat19, options) {
11790
+ return stat19.isFile() && checkMode(stat19, options);
11791
11791
  }
11792
- function checkMode(stat18, options) {
11793
- var mod = stat18.mode;
11794
- var uid = stat18.uid;
11795
- var gid = stat18.gid;
11792
+ function checkMode(stat19, options) {
11793
+ var mod = stat19.mode;
11794
+ var uid = stat19.uid;
11795
+ var gid = stat19.gid;
11796
11796
  var myUid = options.uid !== void 0 ? options.uid : process.getuid && process.getuid();
11797
11797
  var myGid = options.gid !== void 0 ? options.gid : process.getgid && process.getgid();
11798
11798
  var u2 = parseInt("100", 8);
@@ -12211,7 +12211,7 @@ var require_cross_spawn = __commonJS({
12211
12211
  var cp2 = require("child_process");
12212
12212
  var parse = require_parse();
12213
12213
  var enoent = require_enoent();
12214
- function spawn14(command, args, options) {
12214
+ function spawn15(command, args, options) {
12215
12215
  const parsed = parse(command, args, options);
12216
12216
  const spawned = cp2.spawn(parsed.command, parsed.args, parsed.options);
12217
12217
  enoent.hookChildProcess(spawned, parsed);
@@ -12223,8 +12223,8 @@ var require_cross_spawn = __commonJS({
12223
12223
  result.error = result.error || enoent.verifyENOENTSync(result.status, parsed);
12224
12224
  return result;
12225
12225
  }
12226
- module2.exports = spawn14;
12227
- module2.exports.spawn = spawn14;
12226
+ module2.exports = spawn15;
12227
+ module2.exports.spawn = spawn15;
12228
12228
  module2.exports.sync = spawnSync2;
12229
12229
  module2.exports._parse = parse;
12230
12230
  module2.exports._enoent = enoent;
@@ -21432,16 +21432,19 @@ function buildModelAuthScript() {
21432
21432
  // ingest" rather than a failed import.
21433
21433
  `if ! node -e ${sq(MODEL_AUTH_IS_CODEX_LOGIN)} "$auth"; then echo "openclaw-model-auth: $auth is not a Codex ChatGPT login"; exit 0; fi`,
21434
21434
  'seen=$(sha256sum "$auth" | cut -d" " -f1)',
21435
+ `codex_trusted() { openclaw plugins inspect codex --json 2>/dev/null | node -e ${sq(MODEL_AUTH_PLUGIN_TRUSTED)}; }`,
21436
+ // The plugin owns both the import command and the harness the default
21437
+ // model runs on. Before the marker gate, so an imported box whose plugin
21438
+ // lost its record is repaired rather than skipped. `--force` because the
21439
+ // untrusted case leaves the directory behind.
21440
+ "if ! codex_trusted; then",
21441
+ ' echo "openclaw-model-auth: installing the @openclaw/codex plugin"',
21442
+ " openclaw plugins install clawhub:@openclaw/codex --force || exit 0",
21443
+ "fi",
21435
21444
  'if [ -f "$marker" ] && [ "$(cat "$marker")" = "$seen" ]; then',
21436
21445
  ' echo "openclaw-model-auth: this Codex login is already imported"',
21437
21446
  " exit 0",
21438
21447
  "fi",
21439
- // The plugin owns both the import command and the harness the default
21440
- // model runs on.
21441
- `if [ ! -d ${sq(`${OPENCLAW_BOX_DIR}/extensions/codex`)} ]; then`,
21442
- ' echo "openclaw-model-auth: installing the @openclaw/codex plugin"',
21443
- " openclaw plugins install clawhub:@openclaw/codex || exit 0",
21444
- "fi",
21445
21448
  'echo "openclaw-model-auth: importing the Codex login into the OpenClaw auth store"',
21446
21449
  // `--no-backup --force`: the pre-migration archive would snapshot a state
21447
21450
  // dir that is fresh on the boot this runs, and the migration report is
@@ -21449,6 +21452,11 @@ function buildModelAuthScript() {
21449
21452
  `if openclaw migrate apply codex --from ${sq(home)} --include-secrets --item auth:openai --yes --no-backup --force; then`,
21450
21453
  ' printf %s "$seen" > "$marker" && chmod 600 "$marker"',
21451
21454
  "fi",
21455
+ // The one record loss observed happened across the import, not the install.
21456
+ "if ! codex_trusted; then",
21457
+ ' echo "openclaw-model-auth: the @openclaw/codex plugin lost its install record; reinstalling"',
21458
+ " openclaw plugins install clawhub:@openclaw/codex --force || true",
21459
+ "fi",
21452
21460
  "exit 0"
21453
21461
  ].join("\n");
21454
21462
  }
@@ -21764,7 +21772,7 @@ function builtinAgentIds() {
21764
21772
  function findAgentSpec(id) {
21765
21773
  return AGENT_SPECS.find((s) => s.id === id || s.aliases.includes(id));
21766
21774
  }
21767
- var import_path8, import_path9, import_path10, import_path11, import_path12, import_fs2, import_promises28, import_path13, CLAUDE_BOX_DIR, SEED_SETUP_SKILL, claudeSpec, CODEX_BOX_DIR, CODEX_HOOKS_PATH, codexSpec, EXAMPLE_BOX_DIR, exampleSpec, OPENCLAW_BOX_DIR, OPENCLAW_XDG_SUBPATH, OPENCLAW_XDG_BOX_DIR, OPENCLAW_XDG_LINK, GATEWAY_PORT, AGENTBOX_SKILLS_DIR, BAKED_SETUP_SKILL, BAKED_IDENTITY_SKILL, IDENTITY_SENTINEL, WORKSPACE_YAML, BOX_FACTS, AGENTBOX_CTX_DIR, CTX_SENTINEL, MERGE_PROGRAM_PATH, CTX_REL_PATH, OPENCLAW_CONFIG_MERGE_PROGRAM, IDENTITY_NUDGE_TEXT, MODEL_AUTH_MARKER, MODEL_AUTH_IS_CODEX_LOGIN, openclawSpec, IMPORT_JS, OPENCODE_BOX_DIR, OPENCODE_PLUGIN_PATH, opencodeSpec, PI_BOX_DIR, PI_EXTENSION_PATH, piSpec, SUPPORTED_AGENT_API_VERSIONS, AGENTS_FILE_VERSION, EMPTY, REQUIRED_SPEC_FIELDS, RECIPE_KINDS, RUN_AS, BUILTIN_AGENT_SPECS, AGENT_SPECS;
21775
+ var import_path8, import_path9, import_path10, import_path11, import_path12, import_fs2, import_promises28, import_path13, CLAUDE_BOX_DIR, SEED_SETUP_SKILL, claudeSpec, CODEX_BOX_DIR, CODEX_HOOKS_PATH, codexSpec, EXAMPLE_BOX_DIR, exampleSpec, OPENCLAW_BOX_DIR, OPENCLAW_XDG_SUBPATH, OPENCLAW_XDG_BOX_DIR, OPENCLAW_XDG_LINK, GATEWAY_PORT, AGENTBOX_SKILLS_DIR, BAKED_SETUP_SKILL, BAKED_IDENTITY_SKILL, IDENTITY_SENTINEL, WORKSPACE_YAML, BOX_FACTS, AGENTBOX_CTX_DIR, CTX_SENTINEL, MERGE_PROGRAM_PATH, CTX_REL_PATH, OPENCLAW_CONFIG_MERGE_PROGRAM, IDENTITY_NUDGE_TEXT, MODEL_AUTH_MARKER, MODEL_AUTH_PLUGIN_TRUSTED, MODEL_AUTH_IS_CODEX_LOGIN, openclawSpec, IMPORT_JS, OPENCODE_BOX_DIR, OPENCODE_PLUGIN_PATH, opencodeSpec, PI_BOX_DIR, PI_EXTENSION_PATH, piSpec, SUPPORTED_AGENT_API_VERSIONS, AGENTS_FILE_VERSION, EMPTY, REQUIRED_SPEC_FIELDS, RECIPE_KINDS, RUN_AS, BUILTIN_AGENT_SPECS, AGENT_SPECS;
21768
21776
  var init_dist3 = __esm({
21769
21777
  "../agent-registry/dist/index.js"() {
21770
21778
  "use strict";
@@ -22167,6 +22175,11 @@ process.stdout.write(
22167
22175
  ""
22168
22176
  ].join("\n");
22169
22177
  MODEL_AUTH_MARKER = `${OPENCLAW_BOX_DIR}/.agentbox-model-auth.sha256`;
22178
+ MODEL_AUTH_PLUGIN_TRUSTED = `
22179
+ let j;
22180
+ try { const s = require('fs').readFileSync(0, 'utf8'); j = JSON.parse(s.slice(s.indexOf('{'))); } catch { process.exit(1); }
22181
+ process.exit(j?.plugin?.trust?.reason === 'trusted-official' ? 0 : 1);
22182
+ `;
22170
22183
  MODEL_AUTH_IS_CODEX_LOGIN = `
22171
22184
  const j = JSON.parse(require('fs').readFileSync(process.argv[1], 'utf8'));
22172
22185
  process.exit(typeof j?.tokens?.refresh_token === 'string' && j.tokens.refresh_token.length > 0 ? 0 : 1);
@@ -22802,6 +22815,7 @@ __export(dist_exports3, {
22802
22815
  AGENTBOX_HUB_SSH_ALIAS: () => AGENTBOX_HUB_SSH_ALIAS,
22803
22816
  AGENTS_STATIC_BOX_DIR: () => AGENTS_STATIC_BOX_DIR,
22804
22817
  AGENT_SEED_MARKER: () => AGENT_SEED_MARKER,
22818
+ AGENT_SESSION_ENV_VARS: () => AGENT_SESSION_ENV_VARS,
22805
22819
  AGENT_SYNC_SPECS: () => AGENT_SYNC_SPECS,
22806
22820
  AgentInstallError: () => AgentInstallError,
22807
22821
  BACKUP_GITIGNORE_ENTRY: () => BACKUP_GITIGNORE_ENTRY,
@@ -22885,6 +22899,7 @@ __export(dist_exports3, {
22885
22899
  botDir: () => botDir,
22886
22900
  botWorkspaceRoot: () => botWorkspaceRoot,
22887
22901
  boxGitCheckout: () => boxGitCheckout,
22902
+ boxGitCurrentBranch: () => boxGitCurrentBranch,
22888
22903
  boxGitNewBranch: () => boxGitNewBranch,
22889
22904
  boxGitPull: () => boxGitPull,
22890
22905
  boxGitPush: () => boxGitPush,
@@ -23099,6 +23114,7 @@ __export(dist_exports3, {
23099
23114
  scpDownload: () => scpDownload,
23100
23115
  scpUpload: () => scpUpload,
23101
23116
  scratchBranchName: () => scratchBranchName,
23117
+ scrubAgentSessionEnv: () => scrubAgentSessionEnv,
23102
23118
  secretsEnvPath: () => secretsEnvPath,
23103
23119
  seedAgentsVolume: () => seedAgentsVolume,
23104
23120
  seedExcludeTarArgs: () => seedExcludeTarArgs,
@@ -24245,6 +24261,12 @@ function scratchBranchName(name) {
24245
24261
  function boxGitCheckout(provider, box, branch, extraArgs = []) {
24246
24262
  return run4(provider, box, ["git", "checkout", branch, ...extraArgs]);
24247
24263
  }
24264
+ async function boxGitCurrentBranch(provider, box) {
24265
+ const r = await run4(provider, box, ["git", "symbolic-ref", "--quiet", "--short", "HEAD"]).catch(
24266
+ () => void 0
24267
+ );
24268
+ return r?.exitCode === 0 ? r.stdout.trim() || void 0 : void 0;
24269
+ }
24248
24270
  function boxGitNewBranch(provider, box, name, from) {
24249
24271
  const argv = ["git", "checkout", "-b", scratchBranchName(name)];
24250
24272
  if (from && from.trim()) argv.push(from.trim());
@@ -24528,6 +24550,11 @@ function resolveCliEntry() {
24528
24550
  }
24529
24551
  return null;
24530
24552
  }
24553
+ function scrubAgentSessionEnv(env) {
24554
+ const out = { ...env };
24555
+ for (const key of [...AGENT_SESSION_ENV_VARS, "TMUX", "TMUX_PANE"]) delete out[key];
24556
+ return out;
24557
+ }
24531
24558
  function stagedRuntimeRootCandidates(self) {
24532
24559
  const candidates = [];
24533
24560
  const override2 = process.env[RUNTIME_ROOT_ENV];
@@ -24541,15 +24568,15 @@ function resolveStagedRuntimeRoot(self, marker) {
24541
24568
  }
24542
24569
  return void 0;
24543
24570
  }
24544
- function sharedRuntimeAssetPath(basename5) {
24571
+ function sharedRuntimeAssetPath(basename52) {
24545
24572
  const roots = [];
24546
24573
  const stamped = process.env[CLI_RUNTIME_DIR_ENV];
24547
24574
  if (stamped) roots.push(stamped);
24548
24575
  const self = (0, import_path24.dirname)((0, import_url3.fileURLToPath)(import_meta.url));
24549
- const found = resolveStagedRuntimeRoot(self, `_shared/${basename5}`);
24576
+ const found = resolveStagedRuntimeRoot(self, `_shared/${basename52}`);
24550
24577
  if (found) roots.push(found);
24551
24578
  for (const root of roots) {
24552
- const p = (0, import_path24.resolve)(root, "_shared", basename5);
24579
+ const p = (0, import_path24.resolve)(root, "_shared", basename52);
24553
24580
  if ((0, import_fs10.existsSync)(p)) return p;
24554
24581
  }
24555
24582
  return null;
@@ -24755,7 +24782,9 @@ async function spawnHub(hubServer, cliEntry, log, portlessEnabled, exposedEnv) {
24755
24782
  detached: true,
24756
24783
  stdio: ["ignore", logFd, logFd],
24757
24784
  env: {
24758
- ...process.env,
24785
+ // A hub started from inside an agent session must not pass that session's
24786
+ // identity to the managers it runs.
24787
+ ...scrubAgentSessionEnv(process.env),
24759
24788
  // The staged hub is a production Next build; force production so server.ts
24760
24789
  // takes the standalone path (dev mode would load webpack, which the
24761
24790
  // standalone build prunes).
@@ -26102,17 +26131,17 @@ function buildHostEnvFindArgs(patterns) {
26102
26131
  ")"
26103
26132
  ];
26104
26133
  }
26105
- async function findEnvFilesForTar(workspaceDir, patterns) {
26134
+ async function findEnvFilesForTar(workspaceDir2, patterns) {
26106
26135
  if (patterns.length === 0) return [];
26107
26136
  const found = await execa("find", buildHostEnvFindArgs(patterns).slice(1), {
26108
- cwd: workspaceDir,
26137
+ cwd: workspaceDir2,
26109
26138
  reject: false
26110
26139
  });
26111
26140
  if (found.exitCode !== 0) return [];
26112
26141
  return String(found.stdout).split("\0").filter((p) => p.length > 0);
26113
26142
  }
26114
- async function scanHostEnvFiles(workspaceDir, patterns) {
26115
- const raw = await findEnvFilesForTar(workspaceDir, patterns);
26143
+ async function scanHostEnvFiles(workspaceDir2, patterns) {
26144
+ const raw = await findEnvFilesForTar(workspaceDir2, patterns);
26116
26145
  return raw.map((p) => p.replace(/^\.\//, "")).filter((p) => p.length > 0);
26117
26146
  }
26118
26147
  async function pushEnvFiles(ctx, transport, patterns) {
@@ -26750,8 +26779,8 @@ async function resolveBotBundle(projectRoot, bot, stamp) {
26750
26779
  }
26751
26780
  const dir = (0, import_path34.join)(base, chosen);
26752
26781
  const manifest = await readBackupManifest(dir);
26753
- const workspaceDir = (0, import_path34.join)(dir, "workspace");
26754
- if (!(await (0, import_promises51.lstat)(workspaceDir).catch(() => null))?.isDirectory()) {
26782
+ const workspaceDir2 = (0, import_path34.join)(dir, "workspace");
26783
+ if (!(await (0, import_promises51.lstat)(workspaceDir2).catch(() => null))?.isDirectory()) {
26755
26784
  throw new Error(`${dir}: the backup has no workspace/ directory`);
26756
26785
  }
26757
26786
  const stateDir = (0, import_path34.join)(dir, "state");
@@ -26761,7 +26790,7 @@ async function resolveBotBundle(projectRoot, bot, stamp) {
26761
26790
  bot: manifest.bot,
26762
26791
  stamp: chosen,
26763
26792
  manifest,
26764
- workspaceDir,
26793
+ workspaceDir: workspaceDir2,
26765
26794
  ...hasState ? { stateDir } : {}
26766
26795
  };
26767
26796
  }
@@ -28418,7 +28447,7 @@ async function listAvailableSources(spec, env = process.env) {
28418
28447
  }
28419
28448
  return out;
28420
28449
  }
28421
- var import_promises29, import_os3, import_path14, import_promises30, import_promises31, import_path15, import_child_process, import_fs3, import_os4, import_path16, import_fs4, import_os5, import_path17, import_fs5, import_promises32, import_os6, import_path18, import_promises33, import_promises34, import_path19, import_promises35, import_os7, import_crypto3, import_fs6, import_promises36, import_net, import_os8, import_path20, import_fs7, import_os9, import_path21, import_fs8, import_http, import_net2, import_path22, import_promises37, import_url, import_child_process2, import_fs9, import_promises38, import_os10, import_path23, import_promises39, import_url2, import_fs10, import_path24, import_url3, import_promises40, import_os11, import_path25, import_promises41, import_os12, import_path26, import_promises42, import_promises43, import_os13, import_path27, import_promises44, import_os14, import_path28, import_promises45, import_os15, import_path29, import_os16, import_promises46, import_os17, import_path30, import_promises47, import_os18, import_path31, import_promises48, import_path32, import_promises49, import_crypto4, import_promises50, import_path33, import_promises51, import_path34, import_crypto5, import_promises52, import_path35, import_promises53, import_os19, import_path36, import_promises54, import_path37, import_promises55, import_crypto6, import_promises56, import_os20, import_path38, import_promises57, import_os21, import_path39, import_crypto7, import_fs11, import_promises58, import_os22, import_path40, import_path41, import_promises59, import_os23, import_path42, import_promises60, import_path43, import_meta, STATE_DIR2, STATE_FILE, EMPTY2, LOCK_STALE_MS2, LOCK_ACQUIRE_TIMEOUT_MS2, LOCK_RETRY_MS2, GitWorktreeError, AGENTBOX_HUB_SSH_ALIAS, INCLUDE_BEGIN, INCLUDE_END, EXPOSED_HUB_PROFILE, PLUGINS_FILE, SUPPORTED_SDK_API_VERSIONS, PLUGINS_FILE_VERSION, EMPTY22, LOCK_STALE_MS22, LOCK_ACQUIRE_TIMEOUT_MS22, LOCK_RETRY_MS22, FALLBACK_CAPABILITIES, HOST, SshTunnelManager, OPEN_INBOUND_SOURCES, BOX_WORKSPACE, activePublisher, FALLBACK_RELAY_PORT, RELAY_PORT_ENV, override, RUNTIME_ROOT_ENV, CLI_RUNTIME_DIR_ENV, activePortless, dockerContext, STATE_DIR22, HUB_PID_FILE, RELAY_PID_FILE, HUB_LOG_FILE, HUB_TOKEN_FILE, HOST2, LOOPBACK_HOST, NODE_MIN, CP_DIR, activeRefresher, AGENT_SYNC_SPECS, SEED_MARKER, CLAUDE_HOST_BACKUP, MAX_CREDENTIAL_BYTES, DEFAULT_CAPS, PULL_CATEGORIES, SKILL_EXCLUDE_PREFIXES, CONTAINER_PLUGINS_PREFIX, CLAUDE_BOX_CONFIG_DIR, CODEX_BOX_CONFIG_DIR, OPENCODE_BOX_DATA_DIR, CLAUDE_PULL_DIR_CATEGORIES, CODEX_PULL_ITEMS, OPENCODE_PULL_DATA_ITEMS, OPENCODE_PULL_CONFIG_ITEMS, CLAUDE_REGISTRY_FILES, AGENT_SEED_MARKER, AgentInstallError, DEFAULT_ENV_PATTERNS, ENV_PRUNE_DIRS, BOX_HOME2, BOX_CLAUDE_PROJECT_DIR, NON_REGULAR_TOKEN, MODULES, BOTS_DIR_REL, BACKUP_GITIGNORE_ENTRY, STAMP_RE, DEFAULT_BACKUP_KEEP, SOURCE_READ_TIMEOUT_MS, WORKSPACE_EXCLUDE_DIR_NAMES, GIT_MODE_EXCLUDE_DIRS, REMOTE_TAR, MAX_PAYLOAD_BYTES, BoxProbeError, FILELIST_NAME, BOX_WORKFLOWS_DIR, BOX_DYNAMIC_SYNC_MANIFEST, BOX_MEMORY_DIR, SET_NAMES, STAGE_WRITABLE_CHMOD, STAGE_NO_SPECIALS, AGENTS_STATIC_BOX_DIR, DOCKER_CONTEXT_FILE_MAP, BOX_IMAGE_REGISTRY, HUB_WORKER_CLONE_PREFIX, DEFAULT_CP_EXCLUDES, DENYLIST_DEST_PREFIXES, DENYLIST_DEST_EXACT, CARRY_TOPIC, CARRY_GRANT_TOPIC, CARRY_NON_INTERACTIVE_HINT, MODEL_AUTH_TOPIC, MODEL_AUTH_SETTING, MODEL_AUTH_NONE;
28450
+ var import_promises29, import_os3, import_path14, import_promises30, import_promises31, import_path15, import_child_process, import_fs3, import_os4, import_path16, import_fs4, import_os5, import_path17, import_fs5, import_promises32, import_os6, import_path18, import_promises33, import_promises34, import_path19, import_promises35, import_os7, import_crypto3, import_fs6, import_promises36, import_net, import_os8, import_path20, import_fs7, import_os9, import_path21, import_fs8, import_http, import_net2, import_path22, import_promises37, import_url, import_child_process2, import_fs9, import_promises38, import_os10, import_path23, import_promises39, import_url2, import_fs10, import_path24, import_url3, import_promises40, import_os11, import_path25, import_promises41, import_os12, import_path26, import_promises42, import_promises43, import_os13, import_path27, import_promises44, import_os14, import_path28, import_promises45, import_os15, import_path29, import_os16, import_promises46, import_os17, import_path30, import_promises47, import_os18, import_path31, import_promises48, import_path32, import_promises49, import_crypto4, import_promises50, import_path33, import_promises51, import_path34, import_crypto5, import_promises52, import_path35, import_promises53, import_os19, import_path36, import_promises54, import_path37, import_promises55, import_crypto6, import_promises56, import_os20, import_path38, import_promises57, import_os21, import_path39, import_crypto7, import_fs11, import_promises58, import_os22, import_path40, import_path41, import_promises59, import_os23, import_path42, import_promises60, import_path43, import_meta, STATE_DIR2, STATE_FILE, EMPTY2, LOCK_STALE_MS2, LOCK_ACQUIRE_TIMEOUT_MS2, LOCK_RETRY_MS2, GitWorktreeError, AGENTBOX_HUB_SSH_ALIAS, INCLUDE_BEGIN, INCLUDE_END, EXPOSED_HUB_PROFILE, PLUGINS_FILE, SUPPORTED_SDK_API_VERSIONS, PLUGINS_FILE_VERSION, EMPTY22, LOCK_STALE_MS22, LOCK_ACQUIRE_TIMEOUT_MS22, LOCK_RETRY_MS22, FALLBACK_CAPABILITIES, HOST, SshTunnelManager, OPEN_INBOUND_SOURCES, BOX_WORKSPACE, activePublisher, FALLBACK_RELAY_PORT, RELAY_PORT_ENV, override, AGENT_SESSION_ENV_VARS, RUNTIME_ROOT_ENV, CLI_RUNTIME_DIR_ENV, activePortless, dockerContext, STATE_DIR22, HUB_PID_FILE, RELAY_PID_FILE, HUB_LOG_FILE, HUB_TOKEN_FILE, HOST2, LOOPBACK_HOST, NODE_MIN, CP_DIR, activeRefresher, AGENT_SYNC_SPECS, SEED_MARKER, CLAUDE_HOST_BACKUP, MAX_CREDENTIAL_BYTES, DEFAULT_CAPS, PULL_CATEGORIES, SKILL_EXCLUDE_PREFIXES, CONTAINER_PLUGINS_PREFIX, CLAUDE_BOX_CONFIG_DIR, CODEX_BOX_CONFIG_DIR, OPENCODE_BOX_DATA_DIR, CLAUDE_PULL_DIR_CATEGORIES, CODEX_PULL_ITEMS, OPENCODE_PULL_DATA_ITEMS, OPENCODE_PULL_CONFIG_ITEMS, CLAUDE_REGISTRY_FILES, AGENT_SEED_MARKER, AgentInstallError, DEFAULT_ENV_PATTERNS, ENV_PRUNE_DIRS, BOX_HOME2, BOX_CLAUDE_PROJECT_DIR, NON_REGULAR_TOKEN, MODULES, BOTS_DIR_REL, BACKUP_GITIGNORE_ENTRY, STAMP_RE, DEFAULT_BACKUP_KEEP, SOURCE_READ_TIMEOUT_MS, WORKSPACE_EXCLUDE_DIR_NAMES, GIT_MODE_EXCLUDE_DIRS, REMOTE_TAR, MAX_PAYLOAD_BYTES, BoxProbeError, FILELIST_NAME, BOX_WORKFLOWS_DIR, BOX_DYNAMIC_SYNC_MANIFEST, BOX_MEMORY_DIR, SET_NAMES, STAGE_WRITABLE_CHMOD, STAGE_NO_SPECIALS, AGENTS_STATIC_BOX_DIR, DOCKER_CONTEXT_FILE_MAP, BOX_IMAGE_REGISTRY, HUB_WORKER_CLONE_PREFIX, DEFAULT_CP_EXCLUDES, DENYLIST_DEST_PREFIXES, DENYLIST_DEST_EXACT, CARRY_TOPIC, CARRY_GRANT_TOPIC, CARRY_NON_INTERACTIVE_HINT, MODEL_AUTH_TOPIC, MODEL_AUTH_SETTING, MODEL_AUTH_NONE;
28422
28451
  var init_dist4 = __esm({
28423
28452
  "../sandbox-core/dist/index.js"() {
28424
28453
  "use strict";
@@ -28861,6 +28890,25 @@ var init_dist4 = __esm({
28861
28890
  FALLBACK_RELAY_PORT = 8787;
28862
28891
  RELAY_PORT_ENV = "AGENTBOX_RELAY_PORT";
28863
28892
  override = null;
28893
+ AGENT_SESSION_ENV_VARS = [
28894
+ "CLAUDECODE",
28895
+ "CLAUDE_PID",
28896
+ "CLAUDE_CODE_SESSION_ID",
28897
+ "CLAUDE_CODE_BRIDGE_SESSION_ID",
28898
+ "CLAUDE_CODE_CHILD_SESSION",
28899
+ "CLAUDE_CODE_ENTRYPOINT",
28900
+ "CLAUDE_CODE_EXECPATH",
28901
+ "CLAUDE_CODE_MESSAGING_SOCKET",
28902
+ "CLAUDE_CODE_MESSAGING_TOKEN",
28903
+ "CLAUDE_CODE_SESSION_ATTENDED",
28904
+ "CLAUDE_CODE_SESSION_KIND",
28905
+ "CLAUDE_AGENTS_SELECT",
28906
+ "CLAUDE_BG_BACKEND",
28907
+ "CLAUDE_BG_SOCKET_TOKENS_PATH",
28908
+ "CODEX_THREAD_ID",
28909
+ "AGENTBOX_MANAGER",
28910
+ "AGENTBOX_WORKSPACE"
28911
+ ];
28864
28912
  RUNTIME_ROOT_ENV = "AGENTBOX_RUNTIME_ROOT";
28865
28913
  CLI_RUNTIME_DIR_ENV = "AGENTBOX_CLI_RUNTIME_DIR";
28866
28914
  STATE_DIR22 = (0, import_path23.join)((0, import_os10.homedir)(), ".agentbox");
@@ -30228,7 +30276,7 @@ var init_sql = __esm({
30228
30276
  return new SQL([new StringChunk(str)]);
30229
30277
  }
30230
30278
  sql2.raw = raw;
30231
- function join35(chunks, separator) {
30279
+ function join36(chunks, separator) {
30232
30280
  const result = [];
30233
30281
  for (const [i2, chunk] of chunks.entries()) {
30234
30282
  if (i2 > 0 && separator !== void 0) {
@@ -30238,7 +30286,7 @@ var init_sql = __esm({
30238
30286
  }
30239
30287
  return new SQL(result);
30240
30288
  }
30241
- sql2.join = join35;
30289
+ sql2.join = join36;
30242
30290
  function identifier(value) {
30243
30291
  return new Name(value);
30244
30292
  }
@@ -34399,7 +34447,7 @@ var init_select2 = __esm({
34399
34447
  const baseTableName = this.tableName;
34400
34448
  const tableName = getTableLikeName(table);
34401
34449
  for (const item of extractUsedTable(table)) this.usedTables.add(item);
34402
- if (typeof tableName === "string" && this.config.joins?.some((join35) => join35.alias === tableName)) {
34450
+ if (typeof tableName === "string" && this.config.joins?.some((join36) => join36.alias === tableName)) {
34403
34451
  throw new Error(`Alias "${tableName}" is already used in this query`);
34404
34452
  }
34405
34453
  if (!this.isPartialSelect) {
@@ -35934,7 +35982,7 @@ var init_update = __esm({
35934
35982
  createJoin(joinType) {
35935
35983
  return (table, on6) => {
35936
35984
  const tableName = getTableLikeName(table);
35937
- if (typeof tableName === "string" && this.config.joins.some((join35) => join35.alias === tableName)) {
35985
+ if (typeof tableName === "string" && this.config.joins.some((join36) => join36.alias === tableName)) {
35938
35986
  throw new Error(`Alias "${tableName}" is already used in this query`);
35939
35987
  }
35940
35988
  if (typeof on6 === "function") {
@@ -36030,10 +36078,10 @@ var init_update = __esm({
36030
36078
  const fromFields = this.getTableLikeFields(this.config.from);
36031
36079
  fields[tableName] = fromFields;
36032
36080
  }
36033
- for (const join35 of this.config.joins) {
36034
- const tableName2 = getTableLikeName(join35.table);
36035
- if (typeof tableName2 === "string" && !is(join35.table, SQL)) {
36036
- const fromFields = this.getTableLikeFields(join35.table);
36081
+ for (const join36 of this.config.joins) {
36082
+ const tableName2 = getTableLikeName(join36.table);
36083
+ if (typeof tableName2 === "string" && !is(join36.table, SQL)) {
36084
+ const fromFields = this.getTableLikeFields(join36.table);
36037
36085
  fields[tableName2] = fromFields;
36038
36086
  }
36039
36087
  }
@@ -38799,7 +38847,7 @@ var init_select3 = __esm({
38799
38847
  const baseTableName = this.tableName;
38800
38848
  const tableName = getTableLikeName(table);
38801
38849
  for (const item of extractUsedTable2(table)) this.usedTables.add(item);
38802
- if (typeof tableName === "string" && this.config.joins?.some((join35) => join35.alias === tableName)) {
38850
+ if (typeof tableName === "string" && this.config.joins?.some((join36) => join36.alias === tableName)) {
38803
38851
  throw new Error(`Alias "${tableName}" is already used in this query`);
38804
38852
  }
38805
38853
  if (!this.isPartialSelect) {
@@ -39689,7 +39737,7 @@ var init_update2 = __esm({
39689
39737
  createJoin(joinType) {
39690
39738
  return (table, on6) => {
39691
39739
  const tableName = getTableLikeName(table);
39692
- if (typeof tableName === "string" && this.config.joins.some((join35) => join35.alias === tableName)) {
39740
+ if (typeof tableName === "string" && this.config.joins.some((join36) => join36.alias === tableName)) {
39693
39741
  throw new Error(`Alias "${tableName}" is already used in this query`);
39694
39742
  }
39695
39743
  if (typeof on6 === "function") {
@@ -40721,13 +40769,13 @@ function isConnectionLevelError(err) {
40721
40769
  const msg = err instanceof Error ? err.message : String(err);
40722
40770
  return /\b(ECONNREFUSED|ENOTFOUND|EHOSTUNREACH|ECONNRESET|EPIPE)\b/.test(msg);
40723
40771
  }
40724
- var import_http2, import_https, import_promises63, BACKOFF_BASE_MS, BACKOFF_MAX_MS, REQUEST_TIMEOUT_MS, FAST_REQUEST_TIMEOUT_MS, FAST_MODE_DECAY_POLLS, STOPPED_TICK_MS, CONNECTION_LEVEL_CODES, CloudBoxPoller, CloudBoxPollers;
40772
+ var import_http2, import_https, import_promises67, BACKOFF_BASE_MS, BACKOFF_MAX_MS, REQUEST_TIMEOUT_MS, FAST_REQUEST_TIMEOUT_MS, FAST_MODE_DECAY_POLLS, STOPPED_TICK_MS, CONNECTION_LEVEL_CODES, CloudBoxPoller, CloudBoxPollers;
40725
40773
  var init_chunk_Q5KIPAZI = __esm({
40726
40774
  "../relay/dist/chunk-Q5KIPAZI.js"() {
40727
40775
  "use strict";
40728
40776
  import_http2 = require("http");
40729
40777
  import_https = require("https");
40730
- import_promises63 = require("timers/promises");
40778
+ import_promises67 = require("timers/promises");
40731
40779
  BACKOFF_BASE_MS = 1500;
40732
40780
  BACKOFF_MAX_MS = 3e4;
40733
40781
  REQUEST_TIMEOUT_MS = 25e3;
@@ -40893,12 +40941,12 @@ var init_chunk_Q5KIPAZI = __esm({
40893
40941
  if (this.currentBackoffMs === 0 && this.fastModePolls > 0) {
40894
40942
  this.fastModePolls -= 1;
40895
40943
  }
40896
- if (this.currentBackoffMs === 0) await (0, import_promises63.setTimeout)(STOPPED_TICK_MS);
40944
+ if (this.currentBackoffMs === 0) await (0, import_promises67.setTimeout)(STOPPED_TICK_MS);
40897
40945
  }
40898
40946
  }
40899
40947
  async backoff() {
40900
40948
  this.currentBackoffMs = this.currentBackoffMs === 0 ? BACKOFF_BASE_MS : Math.min(this.currentBackoffMs * 2, BACKOFF_MAX_MS);
40901
- await (0, import_promises63.setTimeout)(this.currentBackoffMs);
40949
+ await (0, import_promises67.setTimeout)(this.currentBackoffMs);
40902
40950
  }
40903
40951
  async tryRecoverPreviewUrl() {
40904
40952
  if (!this.deps.recoverPreviewUrl) return;
@@ -43500,7 +43548,7 @@ var cpCommand = new Command("cp").description(
43500
43548
  })
43501
43549
  );
43502
43550
 
43503
- // ../relay/dist/chunk-L5YPS5MX.js
43551
+ // ../relay/dist/chunk-JONRP7IU.js
43504
43552
  var import_promises61 = require("fs/promises");
43505
43553
  var import_os24 = require("os");
43506
43554
  var import_path44 = require("path");
@@ -43516,7 +43564,27 @@ var import_promises62 = require("fs/promises");
43516
43564
  var import_path45 = require("path");
43517
43565
  var import_crypto13 = require("crypto");
43518
43566
  var import_crypto14 = require("crypto");
43567
+ var import_child_process3 = require("child_process");
43568
+ var import_fs13 = require("fs");
43569
+ var import_os25 = require("os");
43570
+ init_dist4();
43519
43571
  var import_path46 = require("path");
43572
+ init_dist4();
43573
+ var import_promises63 = require("fs/promises");
43574
+ var import_path47 = require("path");
43575
+ init_dist2();
43576
+ var import_crypto15 = require("crypto");
43577
+ var import_promises64 = require("fs/promises");
43578
+ init_dist2();
43579
+ init_dist4();
43580
+ init_execa();
43581
+ var import_promises65 = require("fs/promises");
43582
+ init_dist2();
43583
+ var import_crypto16 = require("crypto");
43584
+ var import_promises66 = require("fs/promises");
43585
+ init_dist2();
43586
+ init_dist4();
43587
+ var import_path48 = require("path");
43520
43588
  init_dist2();
43521
43589
  init_dist4();
43522
43590
  init_dist();
@@ -44567,8 +44635,8 @@ async function handleRemoteBoxesRequest(req, deps) {
44567
44635
  async function reapLocalBoxState(boxId, sandboxId, log) {
44568
44636
  let removed = false;
44569
44637
  try {
44570
- const { mutateState: mutateState2, readState: readState2, boxSshDirForProvider: boxSshDirForProvider2 } = await Promise.resolve().then(() => (init_dist4(), dist_exports3));
44571
- const state = await readState2();
44638
+ const { mutateState: mutateState2, readState: readState3, boxSshDirForProvider: boxSshDirForProvider2 } = await Promise.resolve().then(() => (init_dist4(), dist_exports3));
44639
+ const state = await readState3();
44572
44640
  const record = state.boxes.find((b) => b.id === boxId);
44573
44641
  if (record) {
44574
44642
  await mutateState2((s) => ({ ...s, boxes: s.boxes.filter((b) => b.id !== boxId) }));
@@ -44817,185 +44885,6 @@ var GitHubAppLeaser = class {
44817
44885
  return { token: body.token, expiresAt: body.expires_at };
44818
44886
  }
44819
44887
  };
44820
- var QUEUE_DIR = (0, import_path46.join)(STATE_DIR2, "queue");
44821
- var TERMINAL_RETENTION_MS = 60 * 60 * 1e3;
44822
- var SWEEP_INTERVAL_MS = 60 * 1e3;
44823
- var QUEUE_LOGS_DIR = (0, import_path46.join)(STATE_DIR2, "logs");
44824
- function queueLogPath(id) {
44825
- return (0, import_path46.join)(QUEUE_LOGS_DIR, `queue-${id}.log`);
44826
- }
44827
-
44828
- // ../relay/dist/chunk-4ECL7BHW.js
44829
- init_dist();
44830
- init_pg_core();
44831
- init_sqlite_core();
44832
- var import_path47 = require("path");
44833
- init_dist2();
44834
- var import_path48 = require("path");
44835
- init_dist2();
44836
- var pgBoxes = pgTable("boxes", {
44837
- boxId: text("box_id").primaryKey(),
44838
- token: text("token").notNull(),
44839
- originUrl: text("origin_url"),
44840
- data: jsonb("data").$type().notNull(),
44841
- registeredAt: timestamp("registered_at", { withTimezone: true }).notNull()
44842
- });
44843
- var pgEvents = pgTable("events", {
44844
- id: bigint("id", { mode: "number" }).generatedAlwaysAsIdentity().primaryKey(),
44845
- boxId: text("box_id").notNull(),
44846
- type: text("type").notNull(),
44847
- ts: text("ts"),
44848
- payload: jsonb("payload"),
44849
- receivedAt: timestamp("received_at", { withTimezone: true }).notNull()
44850
- });
44851
- var pgBoxStatus = pgTable("box_status", {
44852
- boxId: text("box_id").primaryKey(),
44853
- name: text("name"),
44854
- projectIndex: integer("project_index"),
44855
- status: jsonb("status").$type().notNull(),
44856
- updatedAt: timestamp("updated_at", { withTimezone: true }).notNull()
44857
- });
44858
- var pgPrompts = pgTable("prompts", {
44859
- id: text("id").primaryKey(),
44860
- boxId: text("box_id").notNull(),
44861
- ev: jsonb("ev").$type().notNull(),
44862
- method: text("method").notNull(),
44863
- params: jsonb("params"),
44864
- status: text("status").$type().notNull(),
44865
- answer: text("answer").$type(),
44866
- cancelled: boolean("cancelled"),
44867
- result: jsonb("result").$type(),
44868
- createdAt: timestamp("created_at", { withTimezone: true }).notNull(),
44869
- expiresAt: timestamp("expires_at", { withTimezone: true })
44870
- });
44871
- var pgCreateJobs = pgTable("create_jobs", {
44872
- id: text("id").primaryKey(),
44873
- status: text("status").$type().notNull(),
44874
- request: jsonb("request").$type().notNull(),
44875
- result: jsonb("result").$type(),
44876
- claimedBy: text("claimed_by"),
44877
- createdAt: timestamp("created_at", { withTimezone: true }).notNull(),
44878
- startedAt: timestamp("started_at", { withTimezone: true }),
44879
- finishedAt: timestamp("finished_at", { withTimezone: true })
44880
- });
44881
- var sqliteBoxes = sqliteTable(
44882
- "boxes",
44883
- {
44884
- boxId: text2("box_id").primaryKey(),
44885
- token: text2("token").notNull(),
44886
- originUrl: text2("origin_url"),
44887
- data: text2("data", { mode: "json" }).$type().notNull(),
44888
- registeredAt: text2("registered_at").notNull()
44889
- },
44890
- (t) => [index("boxes_token_idx").on(t.token)]
44891
- );
44892
- var sqliteEvents = sqliteTable(
44893
- "events",
44894
- {
44895
- id: integer2("id").primaryKey({ autoIncrement: true }),
44896
- boxId: text2("box_id").notNull(),
44897
- type: text2("type").notNull(),
44898
- ts: text2("ts"),
44899
- payload: text2("payload", { mode: "json" }),
44900
- receivedAt: text2("received_at").notNull()
44901
- },
44902
- (t) => [index("events_box_idx").on(t.boxId, t.id)]
44903
- );
44904
- var sqliteBoxStatus = sqliteTable("box_status", {
44905
- boxId: text2("box_id").primaryKey(),
44906
- name: text2("name"),
44907
- projectIndex: integer2("project_index"),
44908
- status: text2("status", { mode: "json" }).$type().notNull(),
44909
- updatedAt: text2("updated_at").notNull()
44910
- });
44911
- var sqlitePrompts = sqliteTable(
44912
- "prompts",
44913
- {
44914
- id: text2("id").primaryKey(),
44915
- boxId: text2("box_id").notNull(),
44916
- ev: text2("ev", { mode: "json" }).$type().notNull(),
44917
- method: text2("method").notNull(),
44918
- params: text2("params", { mode: "json" }),
44919
- status: text2("status").$type().notNull(),
44920
- answer: text2("answer").$type(),
44921
- cancelled: integer2("cancelled", { mode: "boolean" }),
44922
- result: text2("result", { mode: "json" }).$type(),
44923
- createdAt: text2("created_at").notNull(),
44924
- expiresAt: text2("expires_at")
44925
- },
44926
- (t) => [index("prompts_box_status_idx").on(t.boxId, t.status)]
44927
- );
44928
- var sqliteCreateJobs = sqliteTable(
44929
- "create_jobs",
44930
- {
44931
- id: text2("id").primaryKey(),
44932
- status: text2("status").$type().notNull(),
44933
- request: text2("request", { mode: "json" }).$type().notNull(),
44934
- result: text2("result", { mode: "json" }).$type(),
44935
- claimedBy: text2("claimed_by"),
44936
- createdAt: text2("created_at").notNull(),
44937
- startedAt: text2("started_at"),
44938
- finishedAt: text2("finished_at")
44939
- },
44940
- (t) => [index("create_jobs_status_idx").on(t.status, t.createdAt)]
44941
- );
44942
- var DEFAULT_SQLITE_STORE_PATH = (0, import_path47.join)(STATE_DIR, "hub", "store.db");
44943
- var DEFAULT_CUSTODY_DIR = (0, import_path48.join)(STATE_DIR, "hub", "custody");
44944
-
44945
- // ../relay/dist/chunk-RG7E35UQ.js
44946
- var import_child_process3 = require("child_process");
44947
- var import_fs13 = require("fs");
44948
- var import_http3 = require("http");
44949
- init_execa();
44950
- var import_fs14 = require("fs");
44951
- var import_promises64 = require("fs/promises");
44952
- var import_os25 = require("os");
44953
- var import_path49 = require("path");
44954
- var import_url4 = require("url");
44955
- init_dist();
44956
- init_dist4();
44957
- var import_child_process4 = require("child_process");
44958
- var import_fs15 = require("fs");
44959
- var import_os26 = require("os");
44960
- init_dist4();
44961
- var import_crypto15 = require("crypto");
44962
- var import_crypto16 = require("crypto");
44963
- init_dist2();
44964
- var import_path50 = require("path");
44965
- init_dist2();
44966
- var import_child_process5 = require("child_process");
44967
- init_dist();
44968
- init_dist4();
44969
- var import_crypto17 = require("crypto");
44970
- init_dist4();
44971
- var import_crypto18 = require("crypto");
44972
- var import_crypto19 = require("crypto");
44973
- var import_child_process6 = require("child_process");
44974
- var import_fs16 = require("fs");
44975
- var import_promises65 = require("fs/promises");
44976
- var import_os27 = require("os");
44977
- var import_path51 = require("path");
44978
- var import_promises66 = require("stream/promises");
44979
- var import_crypto20 = require("crypto");
44980
- var import_child_process7 = require("child_process");
44981
- var import_fs17 = require("fs");
44982
- var import_promises67 = require("fs/promises");
44983
- var import_os28 = require("os");
44984
- var import_path52 = require("path");
44985
- var import_crypto21 = require("crypto");
44986
- init_dist4();
44987
- init_dist();
44988
- var import_crypto22 = require("crypto");
44989
- var import_promises68 = require("fs/promises");
44990
- init_dist2();
44991
- init_execa();
44992
- init_dist4();
44993
- init_dist2();
44994
- init_dist4();
44995
- init_dist2();
44996
- init_dist4();
44997
- init_dist4();
44998
- init_dist();
44999
44888
  var GH_BLOCKED = [
45000
44889
  {
45001
44890
  pattern: /^auth\s+(token|refresh)\b/i,
@@ -45213,22 +45102,22 @@ function firstNonEmptyEnv(names) {
45213
45102
  return null;
45214
45103
  }
45215
45104
  function ghRunContext(workspacePath, originUrl, args) {
45216
- if (workspacePath.length > 0 && (0, import_fs15.existsSync)(workspacePath)) {
45105
+ if (workspacePath.length > 0 && (0, import_fs13.existsSync)(workspacePath)) {
45217
45106
  return { cwd: workspacePath, args };
45218
45107
  }
45219
45108
  const origin = originUrl?.trim() ?? "";
45220
45109
  const alreadyScoped = args.some((a2) => a2 === "--repo" || a2 === "-R" || a2.startsWith("--repo="));
45221
- if (origin.length === 0 || alreadyScoped) return { cwd: (0, import_os26.tmpdir)(), args };
45110
+ if (origin.length === 0 || alreadyScoped) return { cwd: (0, import_os25.tmpdir)(), args };
45222
45111
  try {
45223
- return { cwd: (0, import_os26.tmpdir)(), args: ["--repo", repoSlugFromRemote(origin), ...args] };
45112
+ return { cwd: (0, import_os25.tmpdir)(), args: ["--repo", repoSlugFromRemote(origin), ...args] };
45224
45113
  } catch {
45225
- return { cwd: (0, import_os26.tmpdir)(), args };
45114
+ return { cwd: (0, import_os25.tmpdir)(), args };
45226
45115
  }
45227
45116
  }
45228
45117
  function runHostGh(args, cwd, opts = {}) {
45229
45118
  const timeoutMs = opts.timeoutMs ?? GH_RPC_TIMEOUT_MS;
45230
45119
  return new Promise((resolve9) => {
45231
- const child = (0, import_child_process4.spawn)("gh", args, {
45120
+ const child = (0, import_child_process3.spawn)("gh", args, {
45232
45121
  cwd,
45233
45122
  // GH_HOST is what points gh at a GitHub Enterprise Server instance; without
45234
45123
  // it gh targets github.com no matter what the repo's remote says.
@@ -45306,7 +45195,7 @@ async function checkoutGuards(hostMainRepo, registeredBranches) {
45306
45195
  }
45307
45196
  function runGitProbe(args) {
45308
45197
  return new Promise((resolve9) => {
45309
- const child = (0, import_child_process4.spawn)("git", args, { env: process.env, stdio: ["ignore", "pipe", "pipe"] });
45198
+ const child = (0, import_child_process3.spawn)("git", args, { env: process.env, stdio: ["ignore", "pipe", "pipe"] });
45310
45199
  let stdout = "";
45311
45200
  let stderr = "";
45312
45201
  child.stdout?.on("data", (c3) => {
@@ -45332,9 +45221,772 @@ function refuseCheckoutByDefault(op) {
45332
45221
  stderr: "gh pr checkout: disabled by default; set AGENTBOX_GH_PR_CHECKOUT=allow to enable\n"
45333
45222
  };
45334
45223
  }
45224
+ var WORKSPACES_DIR = (0, import_path46.join)(STATE_DIR2, "workspaces");
45225
+ var WORKSPACE_LOCK = { staleMs: 2e3, acquireTimeoutMs: 5e3 };
45226
+ function workspaceDir(id, root) {
45227
+ return (0, import_path47.join)(WORKSPACES_DIR, root ? projectDirSegment(root) : id);
45228
+ }
45229
+ function workspaceFile(dir) {
45230
+ return (0, import_path47.join)(dir, "workspace.json");
45231
+ }
45232
+ function tasksFile(dir) {
45233
+ return (0, import_path47.join)(dir, "tasks.json");
45234
+ }
45235
+ function timelineFile(dir) {
45236
+ return (0, import_path47.join)(dir, "timeline.jsonl");
45237
+ }
45238
+ function managersFile(dir) {
45239
+ return (0, import_path47.join)(dir, "managers.json");
45240
+ }
45241
+ function legacyManagerFiles(dir) {
45242
+ return { rec: (0, import_path47.join)(dir, "manager.json"), exit: (0, import_path47.join)(dir, "manager.exit") };
45243
+ }
45244
+ async function resolveWorkspaceDir(id) {
45245
+ let entries;
45246
+ try {
45247
+ entries = await (0, import_promises63.readdir)(WORKSPACES_DIR);
45248
+ } catch (err) {
45249
+ if (err.code === "ENOENT") return null;
45250
+ throw err;
45251
+ }
45252
+ for (const name of entries) {
45253
+ const m = /^([0-9a-f]{16})(?:-.+)?$/.exec(name);
45254
+ if (m && m[1] === id) return (0, import_path47.join)(WORKSPACES_DIR, name);
45255
+ }
45256
+ return null;
45257
+ }
45258
+ async function canonicalWorkspaceRoot(absPath) {
45259
+ const resolved = await (0, import_promises63.realpath)(absPath).catch(() => absPath);
45260
+ return resolved.length > 1 && resolved.endsWith("/") ? resolved.slice(0, -1) : resolved;
45261
+ }
45262
+ async function listWorkspaces() {
45263
+ let entries;
45264
+ try {
45265
+ entries = await (0, import_promises63.readdir)(WORKSPACES_DIR);
45266
+ } catch (err) {
45267
+ if (err.code === "ENOENT") return [];
45268
+ throw err;
45269
+ }
45270
+ const out = [];
45271
+ for (const name of entries) {
45272
+ if (!/^[0-9a-f]{16}(?:-.+)?$/.test(name)) continue;
45273
+ try {
45274
+ const raw = await (0, import_promises63.readFile)(workspaceFile((0, import_path47.join)(WORKSPACES_DIR, name)), "utf8");
45275
+ out.push(JSON.parse(raw));
45276
+ } catch {
45277
+ }
45278
+ }
45279
+ out.sort((a2, b) => a2.name.localeCompare(b.name));
45280
+ return out;
45281
+ }
45282
+ function findWorkspaceContaining(records, absPath) {
45283
+ const target = absPath.length > 1 && absPath.endsWith("/") ? absPath.slice(0, -1) : absPath;
45284
+ let best = null;
45285
+ for (const rec of records) {
45286
+ if (target !== rec.root && !target.startsWith(`${rec.root}/`)) continue;
45287
+ if (!best || rec.root.length > best.root.length) best = rec;
45288
+ }
45289
+ return best;
45290
+ }
45291
+ var SESSION_HEAD_BYTES = 256 * 1024;
45292
+ var SESSION_FIRST_LINE_MAX = 4 * 1024 * 1024;
45293
+ var SESSION_INDEX_BYTES = 1024 * 1024;
45294
+ var RESUME_ARGV = {
45295
+ claude: (id) => ["--resume", id],
45296
+ codex: (id) => ["resume", id]
45297
+ };
45298
+ var RESUMABLE_MANAGER_AGENTS = Object.keys(RESUME_ARGV);
45299
+ var DEFAULT_RESUMABLE_AGENT = RESUMABLE_MANAGER_AGENTS[0] ?? "claude";
45300
+ function newManagerId() {
45301
+ return (0, import_crypto15.randomBytes)(8).toString("hex");
45302
+ }
45303
+ async function dirFor(wsId) {
45304
+ return await resolveWorkspaceDir(wsId) ?? workspaceDir(wsId);
45305
+ }
45306
+ async function readManagerFile(dir) {
45307
+ try {
45308
+ const parsed = JSON.parse(await (0, import_promises64.readFile)(managersFile(dir), "utf8"));
45309
+ return Array.isArray(parsed.managers) ? parsed.managers : [];
45310
+ } catch (err) {
45311
+ if (err.code === "ENOENT") return null;
45312
+ return [];
45313
+ }
45314
+ }
45315
+ async function readLegacyManager(dir, wsId) {
45316
+ const files = legacyManagerFiles(dir);
45317
+ let legacy;
45318
+ try {
45319
+ legacy = JSON.parse(await (0, import_promises64.readFile)(files.rec, "utf8"));
45320
+ } catch {
45321
+ return null;
45322
+ }
45323
+ if (typeof legacy.agent !== "string" || typeof legacy.cwd !== "string") return null;
45324
+ let lastExit = legacy.lastExit;
45325
+ let exitConsumed = false;
45326
+ if (lastExit === void 0) {
45327
+ lastExit = await readExitFile(files.exit);
45328
+ exitConsumed = lastExit !== void 0;
45329
+ }
45330
+ const at = legacy.startedAt ?? (/* @__PURE__ */ new Date()).toISOString();
45331
+ const record = {
45332
+ id: newManagerId(),
45333
+ workspaceId: wsId,
45334
+ agent: legacy.agent,
45335
+ kind: "hub",
45336
+ cwd: legacy.cwd,
45337
+ tmuxSession: legacy.tmuxSession ?? `agentbox-manager-${wsId}`,
45338
+ ...legacy.argv ? { argv: legacy.argv } : {},
45339
+ ...legacy.sessionId ? { sessionId: legacy.sessionId } : {},
45340
+ boxIds: [],
45341
+ boxJobIds: [],
45342
+ createdAt: at,
45343
+ lastSeenAt: legacy.stoppedAt ?? at,
45344
+ startedAt: at,
45345
+ ...legacy.stoppedAt ? { stoppedAt: legacy.stoppedAt } : {},
45346
+ ...lastExit === void 0 ? {} : { lastExit }
45347
+ };
45348
+ return { record, exitConsumed };
45349
+ }
45350
+ async function readExitFile(file) {
45351
+ const raw = await (0, import_promises64.readFile)(file, "utf8").catch(() => "");
45352
+ const n2 = Number.parseInt(raw.trim(), 10);
45353
+ return Number.isNaN(n2) ? void 0 : n2;
45354
+ }
45355
+ async function writeManagerFile(dir, managers) {
45356
+ const final = managersFile(dir);
45357
+ await (0, import_promises64.mkdir)(dir, { recursive: true });
45358
+ const tmp = `${final}.tmp.${String(process.pid)}.${Date.now().toString(36)}`;
45359
+ const doc = { version: 1, managers };
45360
+ await (0, import_promises64.writeFile)(tmp, JSON.stringify(doc, null, 2) + "\n", "utf8");
45361
+ await (0, import_promises64.rename)(tmp, final);
45362
+ }
45363
+ async function updateManagers(wsId, fn) {
45364
+ const dir = await dirFor(wsId);
45365
+ return withFileLock(
45366
+ managersFile(dir),
45367
+ async () => {
45368
+ const current = await readManagerFile(dir);
45369
+ const legacy = current === null ? await readLegacyManager(dir, wsId) : null;
45370
+ const { managers, result } = await fn(current ?? (legacy ? [legacy.record] : []));
45371
+ await writeManagerFile(dir, managers);
45372
+ if (legacy) {
45373
+ const files = legacyManagerFiles(dir);
45374
+ await (0, import_promises64.rm)(files.rec, { force: true }).catch(() => {
45375
+ });
45376
+ if (legacy.exitConsumed) await (0, import_promises64.rm)(files.exit, { force: true }).catch(() => {
45377
+ });
45378
+ }
45379
+ return result;
45380
+ },
45381
+ WORKSPACE_LOCK
45382
+ );
45383
+ }
45384
+ async function readManagers(wsId) {
45385
+ const dir = await resolveWorkspaceDir(wsId);
45386
+ if (!dir) return [];
45387
+ const current = await readManagerFile(dir);
45388
+ if (current !== null) return current;
45389
+ if (await (0, import_promises64.stat)(legacyManagerFiles(dir).rec).catch(() => null) === null) return [];
45390
+ return updateManagers(wsId, (managers) => ({ managers, result: managers }));
45391
+ }
45392
+ async function allManagers() {
45393
+ const out = [];
45394
+ for (const ws of await listWorkspaces()) out.push(...await readManagers(ws.id));
45395
+ return out;
45396
+ }
45397
+ async function managerIdForTarget(target, opts = {}) {
45398
+ const hit = (await allManagers()).find(
45399
+ (m) => (opts.workspaceId === void 0 || m.workspaceId === opts.workspaceId) && ("boxId" in target ? m.boxIds.includes(target.boxId) : m.boxJobIds.includes(target.boxJobId))
45400
+ );
45401
+ return hit?.id;
45402
+ }
45403
+ var MANAGER_SEEN_WINDOW_MS = 30 * 60 * 1e3;
45404
+ var TURN_READ_CHUNK = 4 * 1024 * 1024;
45405
+ var PUSH_STAT_TIMEOUT_MS = 2e3;
45406
+ var DEFAULT_BRANCH_REFS = [
45407
+ "refs/remotes/origin/main",
45408
+ "refs/remotes/origin/master",
45409
+ "refs/heads/main",
45410
+ "refs/heads/master"
45411
+ ];
45412
+ function parseShortstat(out) {
45413
+ const num = (re) => Number(re.exec(out)?.[1] ?? 0);
45414
+ return {
45415
+ filesChanged: num(/(\d+) files? changed/u),
45416
+ additions: num(/(\d+) insertions?\(\+\)/u),
45417
+ deletions: num(/(\d+) deletions?\(-\)/u)
45418
+ };
45419
+ }
45420
+ function pushedRef(branch, opts) {
45421
+ const remote = opts.remote ?? "origin";
45422
+ if (opts.hostOnly || !/^[A-Za-z0-9._-]+$/u.test(remote)) return `refs/heads/${branch}`;
45423
+ return `refs/remotes/${remote}/${branch}`;
45424
+ }
45425
+ function gitWithin(repo, deadline) {
45426
+ return async (args) => {
45427
+ const left = deadline - Date.now();
45428
+ if (left <= 0) return void 0;
45429
+ try {
45430
+ const r = await execa("git", ["-C", repo, ...args], { reject: false, timeout: left });
45431
+ return r.exitCode === 0 ? r.stdout.trim() : void 0;
45432
+ } catch {
45433
+ return void 0;
45434
+ }
45435
+ };
45436
+ }
45437
+ function tipWith(git, ref) {
45438
+ return git(["rev-parse", "--verify", "--quiet", `${ref}^{commit}`]).then((s) => s || void 0);
45439
+ }
45440
+ function readRefTip(repo, ref, timeoutMs = PUSH_STAT_TIMEOUT_MS) {
45441
+ return tipWith(gitWithin(repo, Date.now() + timeoutMs), ref);
45442
+ }
45443
+ async function defaultBranchBase(git, tip) {
45444
+ const head = await git(["symbolic-ref", "--quiet", "refs/remotes/origin/HEAD"]);
45445
+ for (const ref of [...head ? [head] : [], ...DEFAULT_BRANCH_REFS]) {
45446
+ if (!await tipWith(git, ref)) continue;
45447
+ return git(["merge-base", ref, tip]);
45448
+ }
45449
+ return void 0;
45450
+ }
45451
+ async function isAncestor(git, before, after) {
45452
+ return await git(["merge-base", "--is-ancestor", before, after]) !== void 0;
45453
+ }
45454
+ async function pushLineStat(input) {
45455
+ const git = gitWithin(input.repo, Date.now() + (input.timeoutMs ?? PUSH_STAT_TIMEOUT_MS));
45456
+ const after = await tipWith(git, input.ref) ?? await tipWith(git, `refs/heads/${input.branch}`);
45457
+ if (!after) return void 0;
45458
+ const base = input.before && (input.before === after || await isAncestor(git, input.before, after)) ? input.before : await defaultBranchBase(git, after);
45459
+ if (!base || base === after) return void 0;
45460
+ const out = await git(["diff", "--shortstat", `${base}..${after}`]);
45461
+ if (out === void 0) return void 0;
45462
+ const { additions, deletions } = parseShortstat(out);
45463
+ return additions + deletions > 0 ? { additions, deletions } : void 0;
45464
+ }
45465
+ async function tasksPathFor(wsId, root) {
45466
+ const dir = await resolveWorkspaceDir(wsId) ?? workspaceDir(wsId, root);
45467
+ return tasksFile(dir);
45468
+ }
45469
+ async function readTasks(wsId) {
45470
+ try {
45471
+ const raw = await (0, import_promises65.readFile)(await tasksPathFor(wsId), "utf8");
45472
+ const parsed = JSON.parse(raw);
45473
+ return Array.isArray(parsed.tasks) ? parsed.tasks : [];
45474
+ } catch {
45475
+ return [];
45476
+ }
45477
+ }
45478
+ var GH_PR_JSON_FIELDS = [
45479
+ "number",
45480
+ "title",
45481
+ "url",
45482
+ "headRefName",
45483
+ "baseRefName",
45484
+ "state",
45485
+ "mergedAt",
45486
+ "closedAt",
45487
+ "createdAt",
45488
+ "additions",
45489
+ "deletions",
45490
+ "statusCheckRollup",
45491
+ "mergeStateStatus",
45492
+ "autoMergeRequest",
45493
+ "mergedBy",
45494
+ "author"
45495
+ ].join(",");
45496
+ function prEventKey(repo, number, kind) {
45497
+ return `pr:${repo}#${String(number)}:${kind}`;
45498
+ }
45499
+ function parsePrUrl(url) {
45500
+ const m = /https?:\/\/[^/\s]+\/([^/\s]+)\/([^/\s]+)\/pull\/(\d+)/u.exec(url);
45501
+ if (!m) return null;
45502
+ return { repo: `${m[1]}/${m[2]}`, number: Number(m[3]), url: m[0] };
45503
+ }
45504
+ var FAILED = /* @__PURE__ */ new Set([
45505
+ "FAILURE",
45506
+ "ERROR",
45507
+ "TIMED_OUT",
45508
+ "CANCELLED",
45509
+ "ACTION_REQUIRED",
45510
+ "STARTUP_FAILURE"
45511
+ ]);
45512
+ var PASSED = /* @__PURE__ */ new Set(["SUCCESS", "NEUTRAL", "SKIPPED"]);
45513
+ function checksOf(rollup) {
45514
+ if (!rollup || rollup.length === 0) return "none";
45515
+ let pending = false;
45516
+ for (const c3 of rollup) {
45517
+ const verdict = (c3.conclusion ?? c3.state ?? "").toUpperCase();
45518
+ if (FAILED.has(verdict)) return "fail";
45519
+ if (c3.status && c3.status.toUpperCase() !== "COMPLETED") pending = true;
45520
+ else if (!PASSED.has(verdict)) pending = true;
45521
+ }
45522
+ return pending ? "pending" : "pass";
45523
+ }
45524
+ function isPrReady(pr) {
45525
+ if (pr.state !== "OPEN") return false;
45526
+ if (checksOf(pr.statusCheckRollup) !== "pass") return false;
45527
+ return pr.mergeStateStatus === "CLEAN" || pr.mergeStateStatus === "HAS_HOOKS";
45528
+ }
45529
+ function timelinePrOf(pr, repo) {
45530
+ return {
45531
+ repo,
45532
+ number: pr.number,
45533
+ title: pr.title,
45534
+ url: pr.url,
45535
+ base: pr.baseRefName,
45536
+ head: pr.headRefName,
45537
+ ...typeof pr.additions === "number" ? { additions: pr.additions } : {},
45538
+ ...typeof pr.deletions === "number" ? { deletions: pr.deletions } : {},
45539
+ checks: checksOf(pr.statusCheckRollup),
45540
+ ...pr.mergeStateStatus ? { mergeState: pr.mergeStateStatus } : {},
45541
+ autoMerge: Boolean(pr.autoMergeRequest),
45542
+ ...pr.mergedBy?.login ? { mergedBy: pr.mergedBy.login } : {}
45543
+ };
45544
+ }
45545
+ function prTimelineEvents(pr, repo, base, nowIso = (/* @__PURE__ */ new Date()).toISOString()) {
45546
+ const tpr = timelinePrOf(pr, repo);
45547
+ const common2 = { ...base, branch: base.branch ?? pr.headRefName, pr: tpr };
45548
+ const out = [
45549
+ {
45550
+ ...common2,
45551
+ type: "pr.opened",
45552
+ at: pr.createdAt ?? nowIso,
45553
+ key: prEventKey(repo, pr.number, "opened")
45554
+ }
45555
+ ];
45556
+ if (pr.state === "MERGED") {
45557
+ out.push({
45558
+ ...common2,
45559
+ type: "pr.merged",
45560
+ at: pr.mergedAt ?? nowIso,
45561
+ key: prEventKey(repo, pr.number, "merged")
45562
+ });
45563
+ } else if (pr.state === "CLOSED") {
45564
+ out.push({
45565
+ ...common2,
45566
+ type: "pr.closed",
45567
+ at: pr.closedAt ?? nowIso,
45568
+ key: prEventKey(repo, pr.number, "closed")
45569
+ });
45570
+ } else if (isPrReady(pr)) {
45571
+ out.push({
45572
+ ...common2,
45573
+ type: "pr.ready",
45574
+ at: nowIso,
45575
+ key: prEventKey(repo, pr.number, "ready")
45576
+ });
45577
+ }
45578
+ return out;
45579
+ }
45580
+ var TIMELINE_MAX_LINES = 5e3;
45581
+ var TIMELINE_KEEP_LINES = 4e3;
45582
+ var TIMELINE_RETENTION_MS = 90 * 24 * 60 * 60 * 1e3;
45583
+ function newTimelineEventId(ms = Date.now()) {
45584
+ return `${ms.toString(36).padStart(9, "0")}-${(0, import_crypto16.randomBytes)(3).toString("hex")}`;
45585
+ }
45586
+ var indexes = /* @__PURE__ */ new Map();
45587
+ function emptyIndex(ino = 0) {
45588
+ return { ino, offset: 0, lines: 0, oldestMs: Number.POSITIVE_INFINITY, keys: /* @__PURE__ */ new Set() };
45589
+ }
45590
+ function absorb(idx, line2) {
45591
+ if (!line2.trim()) return;
45592
+ try {
45593
+ const ev = JSON.parse(line2);
45594
+ idx.lines += 1;
45595
+ const at = typeof ev.at === "string" ? Date.parse(ev.at) : Number.NaN;
45596
+ if (!Number.isNaN(at) && at < idx.oldestMs) idx.oldestMs = at;
45597
+ if (typeof ev.key === "string") idx.keys.add(ev.key);
45598
+ } catch {
45599
+ }
45600
+ }
45601
+ async function indexOf(file) {
45602
+ let st;
45603
+ try {
45604
+ st = await (0, import_promises66.stat)(file);
45605
+ } catch {
45606
+ indexes.delete(file);
45607
+ return emptyIndex();
45608
+ }
45609
+ let idx = indexes.get(file);
45610
+ if (!idx || idx.ino !== st.ino || st.size < idx.offset) {
45611
+ idx = emptyIndex(st.ino);
45612
+ indexes.set(file, idx);
45613
+ }
45614
+ if (st.size === idx.offset) return idx;
45615
+ const fh = await (0, import_promises66.open)(file, "r");
45616
+ try {
45617
+ const buf = Buffer.alloc(st.size - idx.offset);
45618
+ const { bytesRead } = await fh.read(buf, 0, buf.length, idx.offset);
45619
+ const text3 = buf.subarray(0, bytesRead).toString("utf8");
45620
+ const end = text3.lastIndexOf("\n");
45621
+ if (end === -1) return idx;
45622
+ for (const line2 of text3.slice(0, end).split("\n")) absorb(idx, line2);
45623
+ idx.offset += Buffer.byteLength(text3.slice(0, end + 1), "utf8");
45624
+ } finally {
45625
+ await fh.close();
45626
+ }
45627
+ return idx;
45628
+ }
45629
+ function parseLines(raw) {
45630
+ const out = [];
45631
+ for (const line2 of raw.split("\n")) {
45632
+ if (!line2.trim()) continue;
45633
+ try {
45634
+ const ev = JSON.parse(line2);
45635
+ if (typeof ev.id === "string" && typeof ev.at === "string" && typeof ev.type === "string") {
45636
+ out.push(ev);
45637
+ }
45638
+ } catch {
45639
+ continue;
45640
+ }
45641
+ }
45642
+ return out;
45643
+ }
45644
+ function byTime(a2, b) {
45645
+ if (a2.at !== b.at) return a2.at < b.at ? -1 : 1;
45646
+ return a2.id < b.id ? -1 : a2.id > b.id ? 1 : 0;
45647
+ }
45648
+ async function compact(file, now) {
45649
+ const raw = await (0, import_promises66.readFile)(file, "utf8").catch(() => "");
45650
+ const kept = parseLines(raw).filter((ev) => {
45651
+ const at = Date.parse(ev.at);
45652
+ return Number.isNaN(at) || now - at <= TIMELINE_RETENTION_MS;
45653
+ }).sort(byTime).slice(-TIMELINE_KEEP_LINES);
45654
+ const tmp = `${file}.tmp.${String(process.pid)}.${Date.now().toString(36)}`;
45655
+ await (0, import_promises66.writeFile)(tmp, kept.map((ev) => JSON.stringify(ev)).join("\n") + (kept.length ? "\n" : ""));
45656
+ await (0, import_promises66.rename)(tmp, file);
45657
+ indexes.delete(file);
45658
+ }
45659
+ async function fileFor(wsId) {
45660
+ const dir = await resolveWorkspaceDir(wsId);
45661
+ return dir ? timelineFile(dir) : null;
45662
+ }
45663
+ async function appendTimelineEvent(wsId, input, now = Date.now) {
45664
+ const file = await fileFor(wsId);
45665
+ if (!file) return null;
45666
+ return withFileLock(
45667
+ file,
45668
+ async () => {
45669
+ const idx = await indexOf(file);
45670
+ if (input.key && idx.keys.has(input.key)) return null;
45671
+ const ms = now();
45672
+ const ev = {
45673
+ ...input,
45674
+ id: input.id ?? newTimelineEventId(ms),
45675
+ at: input.at ?? new Date(ms).toISOString()
45676
+ };
45677
+ await (0, import_promises66.appendFile)(file, JSON.stringify(ev) + "\n", "utf8");
45678
+ const after = await indexOf(file);
45679
+ if (after.lines > TIMELINE_MAX_LINES || Number.isFinite(after.oldestMs) && ms - after.oldestMs > TIMELINE_RETENTION_MS) {
45680
+ await compact(file, ms);
45681
+ }
45682
+ return ev;
45683
+ },
45684
+ WORKSPACE_LOCK
45685
+ );
45686
+ }
45687
+ async function recordTimelineEvent(wsId, input) {
45688
+ try {
45689
+ return await appendTimelineEvent(wsId, input);
45690
+ } catch (err) {
45691
+ console.warn(
45692
+ `[timeline] could not record ${input.type} in ${wsId}: ${err instanceof Error ? err.message : String(err)}`
45693
+ );
45694
+ return null;
45695
+ }
45696
+ }
45697
+ async function workspaceForPath(path6) {
45698
+ if (!path6) return null;
45699
+ const records = await listWorkspaces();
45700
+ if (records.length === 0) return null;
45701
+ return findWorkspaceContaining(records, await canonicalWorkspaceRoot(path6));
45702
+ }
45703
+ async function boxTaskIds(wsId, boxId) {
45704
+ const tasks = await readTasks(wsId).catch(() => []);
45705
+ return tasks.filter((t) => t.boxId === boxId).map((t) => t.id);
45706
+ }
45707
+ async function recordBoxGitPush(ctx, origin, result, stat43) {
45708
+ if (result.exitCode !== 0 || origin.hostInitiated || origin.hostOnly) return;
45709
+ try {
45710
+ const ws = await workspaceForPath(ctx.hostPath);
45711
+ if (!ws) return;
45712
+ const [taskIds, managerId, diff] = await Promise.all([
45713
+ boxTaskIds(ws.id, ctx.boxId),
45714
+ managerIdForTarget({ boxId: ctx.boxId }, { workspaceId: ws.id }),
45715
+ stat43 ? pushLineStat(stat43) : void 0
45716
+ ]);
45717
+ await recordTimelineEvent(ws.id, {
45718
+ type: "git.push",
45719
+ actor: "box",
45720
+ boxId: ctx.boxId,
45721
+ ...ctx.boxName ? { boxName: ctx.boxName } : {},
45722
+ ...ctx.branch ? { branch: ctx.branch } : {},
45723
+ ...managerId ? { managerId } : {},
45724
+ ...taskIds.length ? { taskIds } : {},
45725
+ ...diff ?? {}
45726
+ });
45727
+ } catch {
45728
+ }
45729
+ }
45730
+ var MERGE_VALUE_FLAGS = /* @__PURE__ */ new Set([
45731
+ "-b",
45732
+ "--body",
45733
+ "-F",
45734
+ "--body-file",
45735
+ "-t",
45736
+ "--subject",
45737
+ "-A",
45738
+ "--author-email",
45739
+ "--match-head-commit",
45740
+ "-R",
45741
+ "--repo"
45742
+ ]);
45743
+ function prMergeTarget(rest) {
45744
+ for (let i2 = 0; i2 < rest.length; i2++) {
45745
+ const arg = rest[i2] ?? "";
45746
+ if (MERGE_VALUE_FLAGS.has(arg)) {
45747
+ i2++;
45748
+ continue;
45749
+ }
45750
+ if (!arg.startsWith("-")) return arg;
45751
+ }
45752
+ return void 0;
45753
+ }
45754
+ function prMergeRepo(rest) {
45755
+ for (let i2 = 0; i2 < rest.length; i2++) {
45756
+ const arg = rest[i2] ?? "";
45757
+ if (arg === "-R" || arg === "--repo") return rest[i2 + 1] || void 0;
45758
+ if (arg.startsWith("--repo=")) return arg.slice("--repo=".length) || void 0;
45759
+ if (arg.startsWith("-R") && arg.length > 2) return arg.slice(2);
45760
+ if (MERGE_VALUE_FLAGS.has(arg)) i2++;
45761
+ }
45762
+ return void 0;
45763
+ }
45764
+ function prViewArgs(lead, target, repo) {
45765
+ return [
45766
+ ...lead,
45767
+ "pr",
45768
+ "view",
45769
+ target,
45770
+ ...repo ? ["--repo", repo] : [],
45771
+ "--json",
45772
+ GH_PR_JSON_FIELDS
45773
+ ];
45774
+ }
45775
+ async function recordBoxGhResult(ctx, args, result) {
45776
+ if (result.exitCode !== 0) return;
45777
+ const verb = ghVerbArgv(args);
45778
+ if (verb[0] !== "pr" || verb[1] !== "create" && verb[1] !== "merge") return;
45779
+ try {
45780
+ const ws = await workspaceForPath(ctx.hostPath);
45781
+ if (!ws) return;
45782
+ const target = verb[1] === "create" ? parsePrUrl(result.stdout)?.url : prMergeTarget(verb.slice(2)) ?? ctx.branch;
45783
+ if (!target) return;
45784
+ const lead = args.slice(0, args.length - verb.length);
45785
+ const ghTarget = await resolveGhTarget(ctx.originUrl);
45786
+ if (ghTarget.error) return;
45787
+ const repo = verb[1] === "merge" ? prMergeRepo(verb.slice(2)) : void 0;
45788
+ const run5 = ghRunContext(ctx.hostPath, ctx.originUrl, prViewArgs(lead, target, repo));
45789
+ const view = await runHostGh(run5.args, run5.cwd, { host: ghTarget.host, timeoutMs: 2e4 });
45790
+ if (view.exitCode !== 0) return;
45791
+ const pr = JSON.parse(view.stdout);
45792
+ const parsed = parsePrUrl(pr.url);
45793
+ if (!parsed) return;
45794
+ const [taskIds, managerId] = await Promise.all([
45795
+ boxTaskIds(ws.id, ctx.boxId),
45796
+ managerIdForTarget({ boxId: ctx.boxId }, { workspaceId: ws.id })
45797
+ ]);
45798
+ const events = prTimelineEvents(pr, parsed.repo, {
45799
+ actor: "box",
45800
+ boxId: ctx.boxId,
45801
+ ...ctx.boxName ? { boxName: ctx.boxName } : {},
45802
+ ...managerId ? { managerId } : {},
45803
+ ...taskIds.length ? { taskIds } : {}
45804
+ });
45805
+ for (const ev of events) {
45806
+ if (ev.type === "pr.ready") continue;
45807
+ await recordTimelineEvent(ws.id, ev);
45808
+ }
45809
+ } catch {
45810
+ }
45811
+ }
45812
+ var QUEUE_DIR = (0, import_path48.join)(STATE_DIR2, "queue");
45813
+ var TERMINAL_RETENTION_MS = 60 * 60 * 1e3;
45814
+ var SWEEP_INTERVAL_MS = 60 * 1e3;
45815
+ var QUEUE_LOGS_DIR = (0, import_path48.join)(STATE_DIR2, "logs");
45816
+ function queueLogPath(id) {
45817
+ return (0, import_path48.join)(QUEUE_LOGS_DIR, `queue-${id}.log`);
45818
+ }
45819
+
45820
+ // ../relay/dist/chunk-2F65LVQC.js
45821
+ init_dist();
45822
+ init_pg_core();
45823
+ init_sqlite_core();
45824
+ var import_path49 = require("path");
45825
+ init_dist2();
45826
+ var import_path50 = require("path");
45827
+ init_dist2();
45828
+ var pgBoxes = pgTable("boxes", {
45829
+ boxId: text("box_id").primaryKey(),
45830
+ token: text("token").notNull(),
45831
+ originUrl: text("origin_url"),
45832
+ data: jsonb("data").$type().notNull(),
45833
+ registeredAt: timestamp("registered_at", { withTimezone: true }).notNull()
45834
+ });
45835
+ var pgEvents = pgTable("events", {
45836
+ id: bigint("id", { mode: "number" }).generatedAlwaysAsIdentity().primaryKey(),
45837
+ boxId: text("box_id").notNull(),
45838
+ type: text("type").notNull(),
45839
+ ts: text("ts"),
45840
+ payload: jsonb("payload"),
45841
+ receivedAt: timestamp("received_at", { withTimezone: true }).notNull()
45842
+ });
45843
+ var pgBoxStatus = pgTable("box_status", {
45844
+ boxId: text("box_id").primaryKey(),
45845
+ name: text("name"),
45846
+ projectIndex: integer("project_index"),
45847
+ status: jsonb("status").$type().notNull(),
45848
+ updatedAt: timestamp("updated_at", { withTimezone: true }).notNull()
45849
+ });
45850
+ var pgPrompts = pgTable("prompts", {
45851
+ id: text("id").primaryKey(),
45852
+ boxId: text("box_id").notNull(),
45853
+ ev: jsonb("ev").$type().notNull(),
45854
+ method: text("method").notNull(),
45855
+ params: jsonb("params"),
45856
+ status: text("status").$type().notNull(),
45857
+ answer: text("answer").$type(),
45858
+ cancelled: boolean("cancelled"),
45859
+ result: jsonb("result").$type(),
45860
+ createdAt: timestamp("created_at", { withTimezone: true }).notNull(),
45861
+ expiresAt: timestamp("expires_at", { withTimezone: true })
45862
+ });
45863
+ var pgCreateJobs = pgTable("create_jobs", {
45864
+ id: text("id").primaryKey(),
45865
+ status: text("status").$type().notNull(),
45866
+ request: jsonb("request").$type().notNull(),
45867
+ result: jsonb("result").$type(),
45868
+ claimedBy: text("claimed_by"),
45869
+ createdAt: timestamp("created_at", { withTimezone: true }).notNull(),
45870
+ startedAt: timestamp("started_at", { withTimezone: true }),
45871
+ finishedAt: timestamp("finished_at", { withTimezone: true })
45872
+ });
45873
+ var sqliteBoxes = sqliteTable(
45874
+ "boxes",
45875
+ {
45876
+ boxId: text2("box_id").primaryKey(),
45877
+ token: text2("token").notNull(),
45878
+ originUrl: text2("origin_url"),
45879
+ data: text2("data", { mode: "json" }).$type().notNull(),
45880
+ registeredAt: text2("registered_at").notNull()
45881
+ },
45882
+ (t) => [index("boxes_token_idx").on(t.token)]
45883
+ );
45884
+ var sqliteEvents = sqliteTable(
45885
+ "events",
45886
+ {
45887
+ id: integer2("id").primaryKey({ autoIncrement: true }),
45888
+ boxId: text2("box_id").notNull(),
45889
+ type: text2("type").notNull(),
45890
+ ts: text2("ts"),
45891
+ payload: text2("payload", { mode: "json" }),
45892
+ receivedAt: text2("received_at").notNull()
45893
+ },
45894
+ (t) => [index("events_box_idx").on(t.boxId, t.id)]
45895
+ );
45896
+ var sqliteBoxStatus = sqliteTable("box_status", {
45897
+ boxId: text2("box_id").primaryKey(),
45898
+ name: text2("name"),
45899
+ projectIndex: integer2("project_index"),
45900
+ status: text2("status", { mode: "json" }).$type().notNull(),
45901
+ updatedAt: text2("updated_at").notNull()
45902
+ });
45903
+ var sqlitePrompts = sqliteTable(
45904
+ "prompts",
45905
+ {
45906
+ id: text2("id").primaryKey(),
45907
+ boxId: text2("box_id").notNull(),
45908
+ ev: text2("ev", { mode: "json" }).$type().notNull(),
45909
+ method: text2("method").notNull(),
45910
+ params: text2("params", { mode: "json" }),
45911
+ status: text2("status").$type().notNull(),
45912
+ answer: text2("answer").$type(),
45913
+ cancelled: integer2("cancelled", { mode: "boolean" }),
45914
+ result: text2("result", { mode: "json" }).$type(),
45915
+ createdAt: text2("created_at").notNull(),
45916
+ expiresAt: text2("expires_at")
45917
+ },
45918
+ (t) => [index("prompts_box_status_idx").on(t.boxId, t.status)]
45919
+ );
45920
+ var sqliteCreateJobs = sqliteTable(
45921
+ "create_jobs",
45922
+ {
45923
+ id: text2("id").primaryKey(),
45924
+ status: text2("status").$type().notNull(),
45925
+ request: text2("request", { mode: "json" }).$type().notNull(),
45926
+ result: text2("result", { mode: "json" }).$type(),
45927
+ claimedBy: text2("claimed_by"),
45928
+ createdAt: text2("created_at").notNull(),
45929
+ startedAt: text2("started_at"),
45930
+ finishedAt: text2("finished_at")
45931
+ },
45932
+ (t) => [index("create_jobs_status_idx").on(t.status, t.createdAt)]
45933
+ );
45934
+ var DEFAULT_SQLITE_STORE_PATH = (0, import_path49.join)(STATE_DIR, "hub", "store.db");
45935
+ var DEFAULT_CUSTODY_DIR = (0, import_path50.join)(STATE_DIR, "hub", "custody");
45936
+
45937
+ // ../relay/dist/chunk-TPGEMVLM.js
45938
+ var import_child_process4 = require("child_process");
45939
+ var import_fs14 = require("fs");
45940
+ var import_http3 = require("http");
45941
+ init_execa();
45942
+ var import_fs15 = require("fs");
45943
+ var import_promises68 = require("fs/promises");
45944
+ var import_os26 = require("os");
45945
+ var import_path51 = require("path");
45946
+ var import_url4 = require("url");
45947
+ init_dist();
45948
+ init_dist4();
45949
+ var import_crypto17 = require("crypto");
45950
+ var import_crypto18 = require("crypto");
45951
+ init_dist2();
45952
+ var import_path52 = require("path");
45953
+ init_dist2();
45954
+ var import_child_process5 = require("child_process");
45955
+ init_dist();
45956
+ init_dist4();
45957
+ var import_crypto19 = require("crypto");
45958
+ init_dist4();
45959
+ var import_crypto20 = require("crypto");
45960
+ var import_crypto21 = require("crypto");
45961
+ var import_child_process6 = require("child_process");
45962
+ var import_fs16 = require("fs");
45963
+ var import_promises69 = require("fs/promises");
45964
+ var import_os27 = require("os");
45965
+ var import_path53 = require("path");
45966
+ var import_promises70 = require("stream/promises");
45967
+ var import_crypto22 = require("crypto");
45968
+ var import_child_process7 = require("child_process");
45969
+ var import_fs17 = require("fs");
45970
+ var import_promises71 = require("fs/promises");
45971
+ var import_os28 = require("os");
45972
+ var import_path54 = require("path");
45973
+ var import_crypto23 = require("crypto");
45974
+ init_dist4();
45975
+ init_dist();
45976
+ var import_crypto24 = require("crypto");
45977
+ var import_promises72 = require("fs/promises");
45978
+ init_dist2();
45979
+ init_execa();
45980
+ init_dist4();
45981
+ init_dist2();
45982
+ init_dist4();
45983
+ init_dist2();
45984
+ init_dist4();
45985
+ init_dist4();
45986
+ init_dist();
45335
45987
  var DEFAULT_TTL_MS = 12e4;
45336
45988
  function hashRpcParams(params) {
45337
- return (0, import_crypto15.createHash)("sha256").update(canonicalJson(params)).digest("hex");
45989
+ return (0, import_crypto17.createHash)("sha256").update(canonicalJson(params)).digest("hex");
45338
45990
  }
45339
45991
  function canonicalJson(v) {
45340
45992
  if (v === null) return "null";
@@ -45358,7 +46010,7 @@ var HostInitiatedTokens = class {
45358
46010
  * params (no current call sites use this).
45359
46011
  */
45360
46012
  mint(boxId, method, paramsHash, ttlMs = DEFAULT_TTL_MS) {
45361
- const token = (0, import_crypto15.randomBytes)(32).toString("hex");
46013
+ const token = (0, import_crypto17.randomBytes)(32).toString("hex");
45362
46014
  this.store.set(token, { boxId, method, paramsHash, expiresAt: Date.now() + ttlMs });
45363
46015
  return token;
45364
46016
  }
@@ -45457,7 +46109,7 @@ function cpCacheKeyInput(source) {
45457
46109
  return `rel:${rel}`;
45458
46110
  }
45459
46111
  function cpCacheKey(source) {
45460
- return (0, import_crypto16.createHash)("sha256").update(cpCacheKeyInput(source)).digest("hex").slice(0, 32);
46112
+ return (0, import_crypto18.createHash)("sha256").update(cpCacheKeyInput(source)).digest("hex").slice(0, 32);
45461
46113
  }
45462
46114
  function cpCacheTarPath(prefix, source) {
45463
46115
  return `${prefix}/${cpCacheKey(source)}.tar`;
@@ -45575,7 +46227,7 @@ var CREDENTIAL_ARGV_PATTERNS = [
45575
46227
  function refuseCredentialArgv(name, args, bin) {
45576
46228
  const joined = args.join(" ");
45577
46229
  const candidates = [`${name} ${joined}`];
45578
- const binName = bin ? (0, import_path50.basename)(bin) : void 0;
46230
+ const binName = bin ? (0, import_path52.basename)(bin) : void 0;
45579
46231
  if (binName && binName !== name) candidates.push(`${binName} ${joined}`);
45580
46232
  for (const re of CREDENTIAL_ARGV_PATTERNS) {
45581
46233
  if (candidates.some((c3) => re.test(c3))) {
@@ -45780,7 +46432,7 @@ var browserOpenBudget = new BrowserOpenBudget();
45780
46432
  var OPEN_LINK_TTL_MS = 9e4;
45781
46433
  async function offerBrowserOpen(deps, url) {
45782
46434
  const budget = deps.budget ?? browserOpenBudget;
45783
- const open23 = deps.openHost ?? openOnHost;
46435
+ const open24 = deps.openHost ?? openOnHost;
45784
46436
  const decision = budget.decide(deps.boxId, url, deps.autoApproveSafe);
45785
46437
  if (decision.action === "drop") return "dropped";
45786
46438
  if (decision.action === "open") budget.record(deps.boxId, url);
@@ -45795,7 +46447,7 @@ async function offerBrowserOpen(deps, url) {
45795
46447
  };
45796
46448
  if (decision.action === "open" && !deps.controlPlane && deps.subscribers.count(deps.boxId) === 0) {
45797
46449
  deps.prompts.noteAutoApprove(deps.boxId, promptEvent, decision.reason);
45798
- open23(url);
46450
+ open24(url);
45799
46451
  return "opened-locally";
45800
46452
  }
45801
46453
  if (decision.action !== "open" && deps.prompts.consumeAutoApprove(deps.boxId, promptEvent)) {
@@ -45804,10 +46456,10 @@ async function offerBrowserOpen(deps, url) {
45804
46456
  deps.log?.(`browser.open: auto-approved but nothing here can open it (control box): ${url}`);
45805
46457
  return "unclaimed";
45806
46458
  }
45807
- open23(url);
46459
+ open24(url);
45808
46460
  return "opened-locally";
45809
46461
  }
45810
- const ev = { id: (0, import_crypto17.randomUUID)(), ...promptEvent };
46462
+ const ev = { id: (0, import_crypto19.randomUUID)(), ...promptEvent };
45811
46463
  const settled = deps.prompts.add(deps.boxId, ev);
45812
46464
  const timer = setTimeout(() => {
45813
46465
  if (deps.prompts.resolve(ev.id, "n", true)) {
@@ -45829,7 +46481,7 @@ async function offerBrowserOpen(deps, url) {
45829
46481
  deps.log?.(`browser.open: approved but no client opened it (control box): ${url}`);
45830
46482
  return "unclaimed";
45831
46483
  }
45832
- open23(url);
46484
+ open24(url);
45833
46485
  return "opened-after-answer";
45834
46486
  }
45835
46487
  var cloudBackendLoader;
@@ -45942,7 +46594,21 @@ async function executeCloudAction(action, deps) {
45942
46594
  };
45943
46595
  }
45944
46596
  if (action.method === "git.push" || action.method === "git.fetch") {
45945
- return runGitRpc(action, deps);
46597
+ const push = { hostInitiated: false };
46598
+ return runGitRpc(action, deps, push).then((result) => {
46599
+ if (action.method === "git.push" && result.exitCode === 0) {
46600
+ const hostOnly = Boolean(action.params?.hostOnly);
46601
+ void cloudTimelineContext(deps).then(
46602
+ (ctx) => ctx ? recordBoxGitPush(
46603
+ ctx,
46604
+ { hostInitiated: push.hostInitiated, hostOnly },
46605
+ result,
46606
+ push.stat
46607
+ ) : void 0
46608
+ );
46609
+ }
46610
+ return result;
46611
+ });
45946
46612
  }
45947
46613
  if (action.method === "cp.toHost" || action.method === "cp.fromHost") {
45948
46614
  return runCpRpc(action, deps);
@@ -45957,7 +46623,16 @@ async function executeCloudAction(action, deps) {
45957
46623
  return runBrowserOpenMirror(action, deps);
45958
46624
  }
45959
46625
  if (action.method === "gh.exec") {
45960
- return runGhExecRpc(action, deps);
46626
+ return runGhExecRpc(action, deps).then((result) => {
46627
+ if (result.exitCode === 0) {
46628
+ const raw = action.params?.args;
46629
+ const args = Array.isArray(raw) ? raw.filter((a2) => typeof a2 === "string") : [];
46630
+ void cloudTimelineContext(deps).then(
46631
+ (ctx) => ctx ? recordBoxGhResult(ctx, args, result) : void 0
46632
+ );
46633
+ }
46634
+ return result;
46635
+ });
45961
46636
  }
45962
46637
  if (action.method.startsWith("tool.")) {
45963
46638
  return runToolRpc(action, deps);
@@ -46177,6 +46852,20 @@ function cloudHandleOf(lookup) {
46177
46852
  ...lookup.sandboxClass ? { sandboxClass: lookup.sandboxClass } : {}
46178
46853
  };
46179
46854
  }
46855
+ async function cloudTimelineContext(deps) {
46856
+ try {
46857
+ const lookup = await lookupCloudBox(deps.boxId);
46858
+ return {
46859
+ boxId: deps.boxId,
46860
+ ...deps.boxName ? { boxName: deps.boxName } : {},
46861
+ hostPath: lookup.workspacePath,
46862
+ ...lookup.sanctionedBranch ? { branch: lookup.sanctionedBranch } : {},
46863
+ ...deps.originUrl ? { originUrl: deps.originUrl } : {}
46864
+ };
46865
+ } catch {
46866
+ return null;
46867
+ }
46868
+ }
46180
46869
  async function lookupCloudBox(boxId) {
46181
46870
  const state = await readState();
46182
46871
  const hit = findBox(boxId, state);
@@ -46426,7 +47115,7 @@ function httpsOriginForScratchPush(origin) {
46426
47115
  }
46427
47116
  }
46428
47117
  async function resolveHostGitRepo(workspacePath, deps, remoteName) {
46429
- if (workspacePath.length > 0 && (0, import_fs14.existsSync)(workspacePath)) {
47118
+ if (workspacePath.length > 0 && (0, import_fs15.existsSync)(workspacePath)) {
46430
47119
  return {
46431
47120
  dir: workspacePath,
46432
47121
  remote: remoteName,
@@ -46441,20 +47130,20 @@ async function resolveHostGitRepo(workspacePath, deps, remoteName) {
46441
47130
  );
46442
47131
  }
46443
47132
  const origin = httpsOriginForScratchPush(rawOrigin);
46444
- const dir = await (0, import_promises64.mkdtemp)((0, import_path49.join)((0, import_os25.tmpdir)(), "agentbox-git-scratch-"));
47133
+ const dir = await (0, import_promises68.mkdtemp)((0, import_path51.join)((0, import_os26.tmpdir)(), "agentbox-git-scratch-"));
46445
47134
  const init = await execa("git", ["-C", dir, "init", "--quiet"], { reject: false });
46446
47135
  if ((init.exitCode ?? 1) !== 0) {
46447
- await (0, import_promises64.rm)(dir, { recursive: true, force: true });
47136
+ await (0, import_promises68.rm)(dir, { recursive: true, force: true });
46448
47137
  throw new Error(`could not initialize a scratch git repo: ${init.stderr ?? ""}`);
46449
47138
  }
46450
47139
  return {
46451
47140
  dir,
46452
47141
  remote: origin,
46453
47142
  scratch: true,
46454
- cleanup: () => (0, import_promises64.rm)(dir, { recursive: true, force: true })
47143
+ cleanup: () => (0, import_promises68.rm)(dir, { recursive: true, force: true })
46455
47144
  };
46456
47145
  }
46457
- async function runGitRpc(action, deps) {
47146
+ async function runGitRpc(action, deps, trace = { hostInitiated: false }) {
46458
47147
  const params = action.params ?? {};
46459
47148
  const lookup = await lookupCloudBox(deps.boxId);
46460
47149
  const backend = await resolveCloudBackend(deps.backendName);
@@ -46480,7 +47169,7 @@ async function runGitRpc(action, deps) {
46480
47169
  };
46481
47170
  }
46482
47171
  if (params.hostOnly) {
46483
- if (lookup.workspacePath.length === 0 || !(0, import_fs14.existsSync)(lookup.workspacePath)) {
47172
+ if (lookup.workspacePath.length === 0 || !(0, import_fs15.existsSync)(lookup.workspacePath)) {
46484
47173
  return {
46485
47174
  exitCode: 64,
46486
47175
  stdout: "",
@@ -46489,8 +47178,8 @@ async function runGitRpc(action, deps) {
46489
47178
  };
46490
47179
  }
46491
47180
  const dest = resolveLandDest(branch, params.as);
46492
- const stageSave = await (0, import_promises64.mkdtemp)((0, import_path49.join)((0, import_os25.tmpdir)(), "agentbox-git-save-"));
46493
- const hostBundleSave = (0, import_path49.join)(stageSave, "op.bundle");
47181
+ const stageSave = await (0, import_promises68.mkdtemp)((0, import_path51.join)((0, import_os26.tmpdir)(), "agentbox-git-save-"));
47182
+ const hostBundleSave = (0, import_path51.join)(stageSave, "op.bundle");
46494
47183
  const remoteBundleSave = "/tmp/agentbox-rpc-save.bundle";
46495
47184
  try {
46496
47185
  const make = await backend.exec(
@@ -46525,7 +47214,7 @@ ${landed.stdout ?? ""}`,
46525
47214
  stderr: landed.stderr ?? ""
46526
47215
  };
46527
47216
  } finally {
46528
- await (0, import_promises64.rm)(stageSave, { recursive: true, force: true });
47217
+ await (0, import_promises68.rm)(stageSave, { recursive: true, force: true });
46529
47218
  await backend.exec(handle, `rm -f ${shellQuote(remoteBundleSave)}`).catch(() => {
46530
47219
  });
46531
47220
  }
@@ -46553,6 +47242,7 @@ ${landed.stdout ?? ""}`,
46553
47242
  "git.push",
46554
47243
  incomingHashGit
46555
47244
  ) ?? false);
47245
+ trace.hostInitiated = hostInitiatedOk;
46556
47246
  if (action.method === "git.push" && !bypassPushGate && tokenClaimedGit && !hostInitiatedOk) {
46557
47247
  return {
46558
47248
  exitCode: 10,
@@ -46621,8 +47311,8 @@ ${landed.stdout ?? ""}`,
46621
47311
  `git.${action.method === "git.push" ? "push" : "fetch"}: no host checkout for box ${deps.boxId}; using a scratch repo against ${repo.remote}`
46622
47312
  );
46623
47313
  }
46624
- const stage = await (0, import_promises64.mkdtemp)((0, import_path49.join)((0, import_os25.tmpdir)(), "agentbox-git-rpc-"));
46625
- const hostBundle = (0, import_path49.join)(stage, "op.bundle");
47314
+ const stage = await (0, import_promises68.mkdtemp)((0, import_path51.join)((0, import_os26.tmpdir)(), "agentbox-git-rpc-"));
47315
+ const hostBundle = (0, import_path51.join)(stage, "op.bundle");
46626
47316
  const remoteBundle = "/tmp/agentbox-rpc.bundle";
46627
47317
  try {
46628
47318
  if (action.method === "git.push") {
@@ -46637,6 +47327,11 @@ ${landed.stdout ?? ""}`,
46637
47327
  stderr: `bundle create failed: ${make.stderr || make.stdout}`
46638
47328
  };
46639
47329
  }
47330
+ if (!repo.scratch && !trace.hostInitiated) {
47331
+ const ref = pushedRef(branch, { remote: remoteName });
47332
+ const before = await readRefTip(repo.dir, ref);
47333
+ trace.stat = { repo: repo.dir, ref, branch, ...before ? { before } : {} };
47334
+ }
46640
47335
  await backend.downloadFile(handle, remoteBundle, hostBundle);
46641
47336
  const fetch2 = await execa(
46642
47337
  "git",
@@ -46721,7 +47416,7 @@ relay: post-push in-box origin/upstream sync threw: ${err instanceof Error ? err
46721
47416
  stderr: sandboxFetch.stderr
46722
47417
  };
46723
47418
  } finally {
46724
- await (0, import_promises64.rm)(stage, { recursive: true, force: true });
47419
+ await (0, import_promises68.rm)(stage, { recursive: true, force: true });
46725
47420
  await repo.cleanup().catch(() => {
46726
47421
  });
46727
47422
  await backend.exec(handle, `rm -f ${shellQuote(remoteBundle)}`).catch(() => {
@@ -46750,7 +47445,7 @@ var HostActionQueue = class {
46750
47445
  * is open" semantics).
46751
47446
  */
46752
47447
  enqueue(boxId, method, params) {
46753
- const id = (0, import_crypto18.randomUUID)();
47448
+ const id = (0, import_crypto20.randomUUID)();
46754
47449
  const action = {
46755
47450
  id,
46756
47451
  boxId,
@@ -46849,7 +47544,7 @@ var HostReachQueue = class {
46849
47544
  * normal, expected state (a closed laptop), not an error condition.
46850
47545
  */
46851
47546
  request(boxId, method, params, opts = {}) {
46852
- const id = (0, import_crypto19.randomUUID)();
47547
+ const id = (0, import_crypto21.randomUUID)();
46853
47548
  const action = {
46854
47549
  id,
46855
47550
  boxId,
@@ -47148,7 +47843,7 @@ async function serveCpFromCache(params, resolved, deps) {
47148
47843
  }
47149
47844
  let workDir;
47150
47845
  try {
47151
- const dir = await (0, import_promises65.mkdtemp)((0, import_path51.join)((0, import_os27.tmpdir)(), "agentbox-cp-serve-"));
47846
+ const dir = await (0, import_promises69.mkdtemp)((0, import_path53.join)((0, import_os27.tmpdir)(), "agentbox-cp-serve-"));
47152
47847
  workDir = dir;
47153
47848
  const names = [];
47154
47849
  for (const entry of lookup.entries) {
@@ -47156,13 +47851,13 @@ async function serveCpFromCache(params, resolved, deps) {
47156
47851
  cpCacheTarPath(deps.cachePrefix, entry.sourcePath)
47157
47852
  );
47158
47853
  if (!found) return { exitCode: 69, stdout: "", stderr: "" };
47159
- const tarPath = (0, import_path51.join)(dir, `${names.length.toString()}.tar`);
47160
- await (0, import_promises66.pipeline)(found.data, (0, import_fs16.createWriteStream)(tarPath));
47854
+ const tarPath = (0, import_path53.join)(dir, `${names.length.toString()}.tar`);
47855
+ await (0, import_promises70.pipeline)(found.data, (0, import_fs16.createWriteStream)(tarPath));
47161
47856
  await run22("tar", ["-xf", tarPath, "-C", dir], UNTAR_TIMEOUT_MS);
47162
- await (0, import_promises65.rm)(tarPath, { force: true });
47163
- names.push((0, import_path51.basename)(entry.sourcePath));
47857
+ await (0, import_promises69.rm)(tarPath, { force: true });
47858
+ names.push((0, import_path53.basename)(entry.sourcePath));
47164
47859
  }
47165
- const staged = names.map((n2) => (0, import_path51.join)(dir, n2));
47860
+ const staged = names.map((n2) => (0, import_path53.join)(dir, n2));
47166
47861
  const absent = staged.filter((p) => !(0, import_fs16.existsSync)(p));
47167
47862
  if (absent.length > 0) {
47168
47863
  return {
@@ -47207,7 +47902,7 @@ ${age}
47207
47902
  `
47208
47903
  };
47209
47904
  } finally {
47210
- if (workDir) await (0, import_promises65.rm)(workDir, { recursive: true, force: true }).catch(() => {
47905
+ if (workDir) await (0, import_promises69.rm)(workDir, { recursive: true, force: true }).catch(() => {
47211
47906
  });
47212
47907
  }
47213
47908
  }
@@ -47262,9 +47957,9 @@ async function parkCpOutbox(sources, dest, deps) {
47262
47957
  if (!deps.custody || !deps.cliEntry) return null;
47263
47958
  let workDir;
47264
47959
  try {
47265
- const dir = await (0, import_promises67.mkdtemp)((0, import_path52.join)((0, import_os28.tmpdir)(), "agentbox-cp-outbox-"));
47960
+ const dir = await (0, import_promises71.mkdtemp)((0, import_path54.join)((0, import_os28.tmpdir)(), "agentbox-cp-outbox-"));
47266
47961
  workDir = dir;
47267
- const stage = (0, import_path52.join)(dir, "payload");
47962
+ const stage = (0, import_path54.join)(dir, "payload");
47268
47963
  await run32("mkdir", ["-p", stage], TAR_TIMEOUT_MS2);
47269
47964
  for (const src of sources) {
47270
47965
  await runNode(
@@ -47273,16 +47968,16 @@ async function parkCpOutbox(sources, dest, deps) {
47273
47968
  PULL_TIMEOUT_MS
47274
47969
  );
47275
47970
  }
47276
- const names = await (0, import_promises67.readdir)(stage);
47971
+ const names = await (0, import_promises71.readdir)(stage);
47277
47972
  if (names.length === 0) return null;
47278
- const tarPath = (0, import_path52.join)(dir, "outbox.tar");
47973
+ const tarPath = (0, import_path54.join)(dir, "outbox.tar");
47279
47974
  await run32("tar", ["-cf", tarPath, "-C", stage, ...names], TAR_TIMEOUT_MS2);
47280
- const info = await (0, import_promises67.stat)(tarPath);
47975
+ const info = await (0, import_promises71.stat)(tarPath);
47281
47976
  if (info.size > deps.maxBytes) {
47282
47977
  log(`cp outbox: ${String(info.size)} bytes exceeds the ${String(deps.maxBytes)}-byte limit`);
47283
47978
  return null;
47284
47979
  }
47285
- const id = (0, import_crypto20.randomUUID)();
47980
+ const id = (0, import_crypto22.randomUUID)();
47286
47981
  const meta = {
47287
47982
  id,
47288
47983
  boxId: deps.boxId,
@@ -47310,7 +48005,7 @@ It will land them at ${dest} \u2014 behind the usual approval \u2014 the next ti
47310
48005
  log(`cp outbox: could not park: ${err instanceof Error ? err.message : String(err)}`);
47311
48006
  return null;
47312
48007
  } finally {
47313
- if (workDir) await (0, import_promises67.rm)(workDir, { recursive: true, force: true }).catch(() => {
48008
+ if (workDir) await (0, import_promises71.rm)(workDir, { recursive: true, force: true }).catch(() => {
47314
48009
  });
47315
48010
  }
47316
48011
  }
@@ -47363,7 +48058,7 @@ var BoxNotices = class {
47363
48058
  this.entries.delete(id);
47364
48059
  }
47365
48060
  }
47366
- const ev = { id: (0, import_crypto21.randomUUID)(), kind, message };
48061
+ const ev = { id: (0, import_crypto23.randomUUID)(), kind, message };
47367
48062
  const ttl = typeof ttlMs === "number" && ttlMs > 0 ? ttlMs : DEFAULT_NOTICE_TTL_MS;
47368
48063
  const timer = setTimeout(() => {
47369
48064
  if (this.entries.delete(ev.id)) {
@@ -47403,7 +48098,7 @@ function timingSafeEqualStr4(a2, b) {
47403
48098
  const ab = Buffer.from(a2, "utf8");
47404
48099
  const bb = Buffer.from(b, "utf8");
47405
48100
  if (ab.length !== bb.length) return false;
47406
- return (0, import_crypto22.timingSafeEqual)(ab, bb);
48101
+ return (0, import_crypto24.timingSafeEqual)(ab, bb);
47407
48102
  }
47408
48103
  function adminGateAllows(isLoopback, bearer, adminToken) {
47409
48104
  if (isLoopback) return true;
@@ -47417,7 +48112,7 @@ async function readCreateJobLog(id, offset) {
47417
48112
  const path6 = queueLogPath(id);
47418
48113
  let size;
47419
48114
  try {
47420
- size = (await (0, import_promises68.stat)(path6)).size;
48115
+ size = (await (0, import_promises72.stat)(path6)).size;
47421
48116
  } catch {
47422
48117
  return { lines: [], offset: from };
47423
48118
  }
@@ -47425,7 +48120,7 @@ async function readCreateJobLog(id, offset) {
47425
48120
  if (size <= start2) return { lines: [], offset: start2 };
47426
48121
  const len = Math.min(size - start2, MAX_BYTES_PER_READ);
47427
48122
  const buf = Buffer.alloc(len);
47428
- const fh = await (0, import_promises68.open)(path6, "r");
48123
+ const fh = await (0, import_promises72.open)(path6, "r");
47429
48124
  try {
47430
48125
  await fh.read(buf, 0, len, start2);
47431
48126
  } finally {
@@ -48071,6 +48766,7 @@ data: {"ts":"${(/* @__PURE__ */ new Date()).toISOString()}"}
48071
48766
  send(res, result2.exitCode === 0 ? 200 : 500, result2);
48072
48767
  return;
48073
48768
  }
48769
+ let pushHostInitiated = false;
48074
48770
  if (body.method === "git.push") {
48075
48771
  const hostOnlyParams = body.params;
48076
48772
  if (hostOnlyParams?.hostOnly) {
@@ -48099,6 +48795,7 @@ data: {"ts":"${(/* @__PURE__ */ new Date()).toISOString()}"}
48099
48795
  const tokenClaimed = typeof params?.hostInitiated === "string";
48100
48796
  const incomingHash = hashRpcParams(params);
48101
48797
  const hostInitiatedOk = !bypassPushGate && tokenClaimed && hostInitiatedTokens.consume(params?.hostInitiated, reg.boxId, "git.push", incomingHash);
48798
+ pushHostInitiated = hostInitiatedOk;
48102
48799
  if (!bypassPushGate && tokenClaimed && !hostInitiatedOk) {
48103
48800
  send(res, 500, {
48104
48801
  exitCode: 10,
@@ -48129,11 +48826,29 @@ data: {"ts":"${(/* @__PURE__ */ new Date()).toISOString()}"}
48129
48826
  }
48130
48827
  }
48131
48828
  }
48132
- const result = await handleGitRpc(
48133
- reg,
48134
- body.method,
48135
- body.params
48136
- );
48829
+ const pushParams = body.params;
48830
+ const pushTree = body.method === "git.push" ? resolveWorktree(reg, pushParams?.path ?? "/workspace") : void 0;
48831
+ const pushBranch = pushTree ? pushTree.sanctionedBranch ?? pushTree.branch : void 0;
48832
+ const pushStat = pushTree && pushBranch && !pushHostInitiated ? {
48833
+ repo: pushTree.hostMainRepo,
48834
+ ref: pushedRef(pushBranch, { remote: resolveRemote(pushParams?.remote) }),
48835
+ branch: pushBranch
48836
+ } : void 0;
48837
+ const pushBefore = pushStat ? await readRefTip(pushStat.repo, pushStat.ref) : void 0;
48838
+ const result = await handleGitRpc(reg, body.method, pushParams);
48839
+ if (body.method === "git.push" && result.exitCode === 0 && pushTree) {
48840
+ void recordBoxGitPush(
48841
+ {
48842
+ boxId: reg.boxId,
48843
+ boxName: reg.name,
48844
+ hostPath: pushTree.hostMainRepo,
48845
+ ...pushBranch ? { branch: pushBranch } : {}
48846
+ },
48847
+ { hostInitiated: pushHostInitiated, hostOnly: Boolean(pushParams?.hostOnly) },
48848
+ result,
48849
+ pushStat ? { ...pushStat, ...pushBefore ? { before: pushBefore } : {} } : void 0
48850
+ );
48851
+ }
48137
48852
  const status2 = result.exitCode === 0 ? 200 : 500;
48138
48853
  send(res, status2, result);
48139
48854
  return;
@@ -48294,13 +49009,28 @@ data: {"ts":"${(/* @__PURE__ */ new Date()).toISOString()}"}
48294
49009
  return;
48295
49010
  }
48296
49011
  if (body.method === "gh.exec") {
49012
+ const ghParams = body.params;
48297
49013
  const result = await handleGhExecRpc(
48298
49014
  reg,
48299
- body.params,
49015
+ ghParams,
48300
49016
  prompts,
48301
49017
  subscribers,
48302
49018
  hostInitiatedTokens
48303
49019
  );
49020
+ const ghTree = result.exitCode === 0 ? resolveWorktree(reg, ghParams?.path ?? "/workspace") : void 0;
49021
+ if (ghTree) {
49022
+ void recordBoxGhResult(
49023
+ {
49024
+ boxId: reg.boxId,
49025
+ boxName: reg.name,
49026
+ hostPath: ghTree.hostMainRepo,
49027
+ branch: ghTree.sanctionedBranch ?? ghTree.branch,
49028
+ ...reg.originUrl ? { originUrl: reg.originUrl } : {}
49029
+ },
49030
+ Array.isArray(ghParams?.args) ? ghParams.args.filter((a2) => typeof a2 === "string") : [],
49031
+ result
49032
+ );
49033
+ }
48304
49034
  const status2 = result.exitCode === 0 ? 200 : 500;
48305
49035
  send(res, status2, result);
48306
49036
  return;
@@ -49116,7 +49846,7 @@ async function parkOutboundCp(args) {
49116
49846
  async function boxWorkspaceExistsHere(boxId) {
49117
49847
  try {
49118
49848
  const path6 = await boxWorkspacePath(boxId);
49119
- return typeof path6 === "string" && path6.length > 0 && (0, import_fs13.existsSync)(path6);
49849
+ return typeof path6 === "string" && path6.length > 0 && (0, import_fs14.existsSync)(path6);
49120
49850
  } catch {
49121
49851
  return false;
49122
49852
  }
@@ -49251,7 +49981,7 @@ function runHostCommand(argv, timeoutMs = GIT_RPC_TIMEOUT_MS, cwd) {
49251
49981
  resolve9({ exitCode: 64, stdout: "", stderr: "empty command" });
49252
49982
  return;
49253
49983
  }
49254
- const child = (0, import_child_process3.spawn)(cmd, rest, {
49984
+ const child = (0, import_child_process4.spawn)(cmd, rest, {
49255
49985
  env: process.env,
49256
49986
  stdio: ["ignore", "pipe", "pipe"],
49257
49987
  // Default to the relay daemon's CWD when unset (legacy behaviour); callers
@@ -49485,7 +50215,7 @@ var import_node_child_process13 = require("child_process");
49485
50215
  var import_node_crypto3 = require("crypto");
49486
50216
  var import_node_events15 = require("events");
49487
50217
  var import_node_fs10 = require("fs");
49488
- var import_promises70 = require("fs/promises");
50218
+ var import_promises74 = require("fs/promises");
49489
50219
  var import_node_path11 = require("path");
49490
50220
 
49491
50221
  // src/probe.ts
@@ -49671,7 +50401,7 @@ var RelayClient = class {
49671
50401
  };
49672
50402
 
49673
50403
  // src/web-proxy.ts
49674
- var import_promises69 = require("fs/promises");
50404
+ var import_promises73 = require("fs/promises");
49675
50405
  var import_node_net4 = require("net");
49676
50406
  var DEFAULT_LISTEN_PORT = 80;
49677
50407
  var DEFAULT_LOG = "/var/log/agentbox/web-proxy.log";
@@ -49744,7 +50474,7 @@ var WebProxy = class {
49744
50474
  }
49745
50475
  async log(msg) {
49746
50476
  try {
49747
- await (0, import_promises69.appendFile)(this.logPath, `[${(/* @__PURE__ */ new Date()).toISOString()}] ${msg}
50477
+ await (0, import_promises73.appendFile)(this.logPath, `[${(/* @__PURE__ */ new Date()).toISOString()}] ${msg}
49748
50478
  `);
49749
50479
  } catch {
49750
50480
  }
@@ -50149,7 +50879,7 @@ var TaskRunner = class extends import_node_events15.EventEmitter {
50149
50879
  return await this.runCheck(ro.command, cwd) ? "check passed" : null;
50150
50880
  }
50151
50881
  try {
50152
- const have = (await (0, import_promises70.readFile)(this.markerPath(), "utf8")).trim();
50882
+ const have = (await (0, import_promises74.readFile)(this.markerPath(), "utf8")).trim();
50153
50883
  if (have === this.commandHash(cwd)) return "marker matches";
50154
50884
  } catch {
50155
50885
  }
@@ -50158,8 +50888,8 @@ var TaskRunner = class extends import_node_events15.EventEmitter {
50158
50888
  async writeMarker(cwd) {
50159
50889
  const marker = this.markerPath();
50160
50890
  try {
50161
- await (0, import_promises70.mkdir)((0, import_node_path11.join)(this.opts.stateDir, "tasks"), { recursive: true });
50162
- await (0, import_promises70.writeFile)(marker, `${this.commandHash(cwd)}
50891
+ await (0, import_promises74.mkdir)((0, import_node_path11.join)(this.opts.stateDir, "tasks"), { recursive: true });
50892
+ await (0, import_promises74.writeFile)(marker, `${this.commandHash(cwd)}
50163
50893
  `, "utf8");
50164
50894
  } catch (err) {
50165
50895
  this.appendEvent(
@@ -50343,7 +51073,7 @@ var Supervisor = class extends import_node_events15.EventEmitter {
50343
51073
  this.webProxy.reconfigure(first ? first.port : null);
50344
51074
  }
50345
51075
  async init(cfg) {
50346
- await (0, import_promises70.mkdir)(this.opts.logDir, { recursive: true });
51076
+ await (0, import_promises74.mkdir)(this.opts.logDir, { recursive: true });
50347
51077
  this.resolvedStateDir = await this.ensureStateDir();
50348
51078
  for (const t of cfg.tasks) this.addTaskUnit(t);
50349
51079
  for (const s of cfg.services) this.addServiceUnit(s);
@@ -50703,7 +51433,7 @@ async function readLogFile(logDir, service, tail) {
50703
51433
  const path6 = (0, import_node_path11.join)(logDir, `${service}.log`);
50704
51434
  let text3;
50705
51435
  try {
50706
- text3 = await (0, import_promises70.readFile)(path6, "utf8");
51436
+ text3 = await (0, import_promises74.readFile)(path6, "utf8");
50707
51437
  } catch (err) {
50708
51438
  if (err.code === "ENOENT") return [];
50709
51439
  throw err;
@@ -50721,11 +51451,11 @@ async function readLogFile(logDir, service, tail) {
50721
51451
 
50722
51452
  // src/socket.ts
50723
51453
  var import_node_net5 = require("net");
50724
- var import_promises71 = require("fs/promises");
51454
+ var import_promises75 = require("fs/promises");
50725
51455
  var import_node_path12 = require("path");
50726
51456
  async function startServer(opts) {
50727
- await (0, import_promises71.mkdir)((0, import_node_path12.dirname)(opts.socketPath), { recursive: true });
50728
- await (0, import_promises71.unlink)(opts.socketPath).catch(() => {
51457
+ await (0, import_promises75.mkdir)((0, import_node_path12.dirname)(opts.socketPath), { recursive: true });
51458
+ await (0, import_promises75.unlink)(opts.socketPath).catch(() => {
50729
51459
  });
50730
51460
  const server = (0, import_node_net5.createServer)((sock) => {
50731
51461
  handleConnection(sock, opts).catch((err) => {
@@ -50741,7 +51471,7 @@ async function startServer(opts) {
50741
51471
  resolve9();
50742
51472
  });
50743
51473
  });
50744
- await (0, import_promises71.chmod)(opts.socketPath, 432).catch(() => {
51474
+ await (0, import_promises75.chmod)(opts.socketPath, 432).catch(() => {
50745
51475
  });
50746
51476
  return server;
50747
51477
  }
@@ -50922,7 +51652,7 @@ async function* createLineReader(sock) {
50922
51652
  }
50923
51653
 
50924
51654
  // src/tool-links.ts
50925
- var import_promises72 = require("fs/promises");
51655
+ var import_promises76 = require("fs/promises");
50926
51656
  var import_node_os6 = require("os");
50927
51657
  var import_node_path13 = require("path");
50928
51658
  var TOOL_SHIM_PATH = "/usr/local/bin/agentbox-tool-shim";
@@ -50934,10 +51664,10 @@ async function syncToolLinks(names, opts = {}) {
50934
51664
  const shim = opts.shim ?? TOOL_SHIM_PATH;
50935
51665
  const wanted = new Set(names.filter((n2) => VALID_NAME.test(n2)));
50936
51666
  const result = { added: [], removed: [], conflicts: [] };
50937
- await (0, import_promises72.mkdir)(dir, { recursive: true });
51667
+ await (0, import_promises76.mkdir)(dir, { recursive: true });
50938
51668
  let entries;
50939
51669
  try {
50940
- entries = await (0, import_promises72.readdir)(dir);
51670
+ entries = await (0, import_promises76.readdir)(dir);
50941
51671
  } catch {
50942
51672
  entries = [];
50943
51673
  }
@@ -50946,20 +51676,20 @@ async function syncToolLinks(names, opts = {}) {
50946
51676
  if (wanted.has(entry)) continue;
50947
51677
  if (prunable && !prunable.has(entry)) continue;
50948
51678
  if (await isOurLink((0, import_node_path13.join)(dir, entry), shim)) {
50949
- await (0, import_promises72.unlink)((0, import_node_path13.join)(dir, entry)).catch(() => void 0);
51679
+ await (0, import_promises76.unlink)((0, import_node_path13.join)(dir, entry)).catch(() => void 0);
50950
51680
  result.removed.push(entry);
50951
51681
  }
50952
51682
  }
50953
51683
  for (const name of wanted) {
50954
51684
  const path6 = (0, import_node_path13.join)(dir, name);
50955
- const existing = await (0, import_promises72.lstat)(path6).catch(() => null);
51685
+ const existing = await (0, import_promises76.lstat)(path6).catch(() => null);
50956
51686
  if (existing) {
50957
51687
  if (await isOurLink(path6, shim)) continue;
50958
51688
  result.conflicts.push(name);
50959
51689
  continue;
50960
51690
  }
50961
51691
  try {
50962
- await (0, import_promises72.symlink)(shim, path6);
51692
+ await (0, import_promises76.symlink)(shim, path6);
50963
51693
  result.added.push(name);
50964
51694
  } catch {
50965
51695
  result.conflicts.push(name);
@@ -50969,9 +51699,9 @@ async function syncToolLinks(names, opts = {}) {
50969
51699
  }
50970
51700
  async function isOurLink(path6, shim) {
50971
51701
  try {
50972
- const st = await (0, import_promises72.lstat)(path6);
51702
+ const st = await (0, import_promises76.lstat)(path6);
50973
51703
  if (!st.isSymbolicLink()) return false;
50974
- return await (0, import_promises72.readlink)(path6) === shim;
51704
+ return await (0, import_promises76.readlink)(path6) === shim;
50975
51705
  } catch {
50976
51706
  return false;
50977
51707
  }
@@ -50982,7 +51712,7 @@ async function listToolLinks(opts = {}) {
50982
51712
  const shim = opts.shim ?? TOOL_SHIM_PATH;
50983
51713
  let entries;
50984
51714
  try {
50985
- entries = await (0, import_promises72.readdir)(dir);
51715
+ entries = await (0, import_promises76.readdir)(dir);
50986
51716
  } catch {
50987
51717
  return [];
50988
51718
  }
@@ -51904,7 +52634,7 @@ var openCommand = new Command("open").description("Open a URL in the box's brows
51904
52634
  });
51905
52635
 
51906
52636
  // src/commands/render.ts
51907
- var import_promises73 = require("fs/promises");
52637
+ var import_promises77 = require("fs/promises");
51908
52638
  function collect(value, prev) {
51909
52639
  prev.push(value);
51910
52640
  return prev;
@@ -51916,7 +52646,7 @@ var renderCommand = new Command("render").description(
51916
52646
  "where named {{AGENTBOX_AUTO_SECRET:x}} secrets persist",
51917
52647
  DEFAULT_STATE_DIR
51918
52648
  ).action(async (src, opts) => {
51919
- const content = await (0, import_promises73.readFile)(src, "utf8");
52649
+ const content = await (0, import_promises77.readFile)(src, "utf8");
51920
52650
  const rules = [];
51921
52651
  if (opts.rules) {
51922
52652
  const refs = opts.rules.split(",").map((s) => s.trim()).filter((s) => s.length > 0);
@@ -51940,9 +52670,9 @@ var renderCommand = new Command("render").description(
51940
52670
  `)
51941
52671
  });
51942
52672
  if (opts.inPlace) {
51943
- await (0, import_promises73.writeFile)(src, result, "utf8");
52673
+ await (0, import_promises77.writeFile)(src, result, "utf8");
51944
52674
  } else if (opts.out) {
51945
- await (0, import_promises73.writeFile)(opts.out, result, "utf8");
52675
+ await (0, import_promises77.writeFile)(opts.out, result, "utf8");
51946
52676
  } else {
51947
52677
  process.stdout.write(result);
51948
52678
  }
@@ -52042,10 +52772,10 @@ var logsCommand = new Command("logs").description("Print recent log lines for a
52042
52772
  });
52043
52773
 
52044
52774
  // src/commands/validate.ts
52045
- var import_promises74 = require("fs/promises");
52775
+ var import_promises78 = require("fs/promises");
52046
52776
  var validateCommand = new Command("validate").description("Check agentbox.yaml for syntax and shape errors, without starting the daemon").argument("[path]", "path to agentbox.yaml", DEFAULT_CONFIG_PATH).action(async (path6) => {
52047
52777
  try {
52048
- await (0, import_promises74.stat)(path6);
52778
+ await (0, import_promises78.stat)(path6);
52049
52779
  } catch {
52050
52780
  process.stderr.write(`agentbox-ctl: ${path6} not found
52051
52781
  `);