nolo-cli 0.149.0-alpha.1 → 0.151.0-alpha.3

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 (258) hide show
  1. package/{_executeModel-OW3H7ICR.js → _executeModel-T7ANHTUW.js} +134 -91
  2. package/accountResolver-7RYB4D2P.js +300 -0
  3. package/action-SXJD5N5R.js +23 -0
  4. package/{addContentAction-B2DRF7P6.js → addContentAction-ZV774PHH.js} +20 -14
  5. package/{addDialogAgentAction-2P2FLTLD.js → addDialogAgentAction-A6SMKAGH.js} +26 -22
  6. package/{agentDeleteCommand-7IDWF6E3.js → agentDeleteCommand-4L5KCKFY.js} +181 -93
  7. package/{agentEmailCommands-A6XBQZBN.js → agentEmailCommands-2IMMIRO2.js} +132 -112
  8. package/{agentGrantCommands-M3XFO6EN.js → agentGrantCommands-HOJ3JBBQ.js} +3 -3
  9. package/agentListCommands-TWFLUYIZ.js +802 -0
  10. package/{agentMachineCommands-DQPUIMAC.js → agentMachineCommands-KIWXWT6L.js} +58 -62
  11. package/{agentProviderCommands-YK2BIIXZ.js → agentProviderCommands-HL6MBLCL.js} +149 -2
  12. package/{agentPullCommand-HF4A42D4.js → agentPullCommand-FA43RBRU.js} +7 -7
  13. package/agentRecordCommands-727NPCRW.js +154 -0
  14. package/agentRunCommand-JASIG3FZ.js +183 -0
  15. package/{agentRunControl-2SKCR4SB.js → agentRunControl-IFM7IGMG.js} +10 -2
  16. package/{agentRuntimeLocal-AK2QVJHY.js → agentRuntimeLocal-KKSQJMTE.js} +47 -50
  17. package/{agentSlice-O4RUQUMT.js → agentSlice-SLV57QGU.js} +23 -16
  18. package/{appDeleteCommands-N3XEVVYC.js → appDeleteCommands-4PL4KYRN.js} +58 -59
  19. package/{appDeployCommands-AWFIXYVW.js → appDeployCommands-EEEXCEB6.js} +67 -63
  20. package/{appDeployStatusCommands-CZRON2FO.js → appDeployStatusCommands-35ZX7T66.js} +56 -56
  21. package/{appGetCommands-XQIUY4TD.js → appGetCommands-WFCHXJWF.js} +56 -56
  22. package/{appListCommands-NNG4H36Y.js → appListCommands-XY2U6DPF.js} +57 -59
  23. package/{authCommand-UBJ4EWYZ.js → authCommand-QYN47CQD.js} +371 -68
  24. package/{authCommands-H6WKKCRW.js → authCommands-77CHYBGF.js} +12 -9
  25. package/{builtinSkillRegistry-ZMF6YGNO.js → builtinSkillRegistry-TDQ6JB2E.js} +13 -11
  26. package/{chromeCommands-2N6MEWRU.js → chromeCommands-OBBNJCLS.js} +314 -13
  27. package/chromeOpsCommands-3Z34RKSE.js +472 -0
  28. package/{chunk-ALXHV7NK.js → chunk-2GGXHQIW.js} +43 -4
  29. package/{localRuntimeAuthority-5W6IJRAD.js → chunk-2IXDJNZI.js} +154 -75
  30. package/{chunk-IVZJWTDI.js → chunk-36OMEXXR.js} +89 -21
  31. package/{chunk-H6A6X4EK.js → chunk-3MZAGMYY.js} +16 -0
  32. package/chunk-3PVYUPXK.js +40 -0
  33. package/chunk-3SZA4U64.js +1192 -0
  34. package/{chunk-ID7LNBWR.js → chunk-3T4ZG6AC.js} +1920 -644
  35. package/{chunk-GNMAFAIS.js → chunk-44WXLHFI.js} +1 -1
  36. package/{chunk-AGGIDPCZ.js → chunk-4JH2UMJR.js} +6 -0
  37. package/chunk-4LCOCOR5.js +50 -0
  38. package/chunk-4YRTZIVN.js +871 -0
  39. package/{chunk-N7J63Q6C.js → chunk-56GBUMO5.js} +10 -1
  40. package/{chunk-W7XHHYWM.js → chunk-5BHQICF2.js} +5 -1
  41. package/{chunk-XUWRURDF.js → chunk-5EBLANFT.js} +1 -1
  42. package/{chunk-3AH7LNUB.js → chunk-5EMSBTQ6.js} +33 -14
  43. package/{chunk-YRRASA5Q.js → chunk-5MM7NNO6.js} +113 -52
  44. package/chunk-5MMAK75Q.js +15 -0
  45. package/{chunk-TXH4IWJL.js → chunk-626KHJNX.js} +20 -11
  46. package/{chunk-M5PVFLD4.js → chunk-64K7WX26.js} +90 -21
  47. package/{chunk-AKG5W4LG.js → chunk-6CCFTVBP.js} +76 -221
  48. package/chunk-6MJNEXUU.js +614 -0
  49. package/{chunk-62IL3KQV.js → chunk-6MXDOUMH.js} +15 -3
  50. package/{chunk-QOKAKDPE.js → chunk-6Q7UTJKR.js} +6 -94
  51. package/chunk-6QDYSCPW.js +223 -0
  52. package/{chunk-HYZIYH2H.js → chunk-74RAWNQN.js} +56 -63
  53. package/chunk-7DPNBQSV.js +9 -0
  54. package/{chunk-IAESIMK7.js → chunk-A4MW3YZL.js} +10 -14
  55. package/{chunk-OMRJYNCI.js → chunk-AG7MCDLR.js} +26 -31
  56. package/chunk-AGIM7IMJ.js +147 -0
  57. package/{chunk-7CHC4W22.js → chunk-AIZE5TDM.js} +3 -3
  58. package/chunk-AJ3G7X2K.js +7012 -0
  59. package/{chunk-5GVBDNTO.js → chunk-AU7AXHUL.js} +1 -1
  60. package/{chunk-4H22P2JV.js → chunk-AUIJZACN.js} +2073 -1275
  61. package/{chunk-CIF4X6ZM.js → chunk-AWVFQMOV.js} +25 -3
  62. package/{chunk-YAQJJDC2.js → chunk-BJEZC5RA.js} +214 -51
  63. package/{chunk-RYZINGPM.js → chunk-BPMPOFWP.js} +347 -235
  64. package/{chunk-YUNJN43V.js → chunk-BU2YQBV4.js} +215 -28
  65. package/{chunk-XPRWFQQK.js → chunk-CBHGZRCE.js} +38 -12
  66. package/{chunk-Y3PMXGLH.js → chunk-CHCS6XPJ.js} +365 -144
  67. package/chunk-CHOZJMJS.js +78 -0
  68. package/chunk-CYJWI3NH.js +119 -0
  69. package/{chunk-GBRG75BQ.js → chunk-D2MDMY2M.js} +1 -0
  70. package/{chunk-3SV7RM24.js → chunk-D2QN6CTI.js} +117 -72
  71. package/{chunk-TZZ2WRBL.js → chunk-DFDXM2Y4.js} +20 -16
  72. package/{chunk-5TEEECZM.js → chunk-E2AKSW7L.js} +10 -7
  73. package/{chunk-RSEEDUMS.js → chunk-EDX5XSJM.js} +2 -2
  74. package/{chunk-QDSINZM3.js → chunk-EUGTFFO6.js} +2 -23
  75. package/{chunk-UNYJU5L6.js → chunk-EYLGAEB4.js} +5 -1
  76. package/{chunk-CU3QB4HW.js → chunk-EYWJT7A2.js} +12 -12
  77. package/{chunk-BNGW5ASC.js → chunk-EZVK3N5L.js} +66 -18
  78. package/{chunk-6FGTMQCL.js → chunk-F32Z66T4.js} +6 -10
  79. package/{chunk-ZOVKKMF6.js → chunk-FY4SDK2E.js} +1 -1
  80. package/chunk-G6OOUQWJ.js +417 -0
  81. package/{chunk-PQWU42UQ.js → chunk-GCKHQECX.js} +6 -6
  82. package/chunk-GKXCHNTE.js +15 -0
  83. package/{chunk-P6GMCCAT.js → chunk-GQV5KHJU.js} +78 -12
  84. package/{chunk-B2XUQXQX.js → chunk-HIQ4GF53.js} +191 -68
  85. package/{chunk-GMZLP5DV.js → chunk-HNUWUO75.js} +30 -19
  86. package/{chunk-UASIEDKM.js → chunk-I2XLRXVX.js} +36 -31
  87. package/{chunk-5UTFL4QJ.js → chunk-I2ZMGXXF.js} +10 -5
  88. package/chunk-I42VC5KR.js +15 -0
  89. package/{chunk-3BXNTXYI.js → chunk-I4SN4NUQ.js} +1199 -56
  90. package/chunk-IA7TRNNR.js +11 -0
  91. package/{chunk-WIWM4FE3.js → chunk-IJERIUXS.js} +55 -748
  92. package/{chunk-BIDGLJQ3.js → chunk-IK2TSJQA.js} +45 -8
  93. package/{chunk-CPUFH46E.js → chunk-ILU2NPWY.js} +10 -10
  94. package/{chunk-SLLGJZDT.js → chunk-ISQL4V7C.js} +4 -4
  95. package/chunk-IT3ZZRJE.js +12 -0
  96. package/{chunk-DY7ANLKG.js → chunk-JKMLSTZK.js} +43 -12
  97. package/{chunk-6TPOEJMQ.js → chunk-JZX2XLKC.js} +64 -23
  98. package/{chunk-27ONFIEY.js → chunk-K2AER7RX.js} +19 -12
  99. package/{chunk-O2OWEFII.js → chunk-KFHQQ3NO.js} +1 -1
  100. package/{chunk-QXGPFY6J.js → chunk-LGN377P3.js} +27 -17
  101. package/{chunk-L36OWPP3.js → chunk-LIQJTQRN.js} +118 -139
  102. package/{chunk-BFU6C242.js → chunk-NMFV26UG.js} +1 -1
  103. package/{chunk-5J3PYNUP.js → chunk-NYYFIKHI.js} +17 -3
  104. package/{chunk-6O4IK4V2.js → chunk-OFFL4DCR.js} +1 -1
  105. package/{chunk-B6SAMB33.js → chunk-OWYYDMGJ.js} +209 -9
  106. package/{chunk-KQHGZWSV.js → chunk-OXME3PEE.js} +1 -1
  107. package/{chunk-CTUQJVQM.js → chunk-P5QACQDK.js} +1 -1
  108. package/{chunk-TB3MIBRC.js → chunk-PIDUNDFS.js} +572 -430
  109. package/{chunk-4JMDLJAD.js → chunk-PJNFNEJE.js} +114 -37
  110. package/chunk-PKZKOVA5.js +11507 -0
  111. package/{chunk-Z4CSIXYP.js → chunk-PLSVXHSA.js} +3 -3
  112. package/chunk-PWTNI4N7.js +47 -0
  113. package/chunk-QFEW2ULV.js +42 -0
  114. package/{chunk-RGNEEJ3Y.js → chunk-QLQ573SU.js} +35 -9
  115. package/chunk-QQ56R7KS.js +88 -0
  116. package/chunk-QYPE3TS3.js +43 -0
  117. package/{chunk-HTVYCXBP.js → chunk-RN2GPWN6.js} +354 -120
  118. package/{chunk-ATLTFRYJ.js → chunk-ROCUB2H2.js} +280 -98
  119. package/{chunk-4DPP773Q.js → chunk-RSHPU4PD.js} +59 -11
  120. package/chunk-RVWMAFIT.js +134 -0
  121. package/{chunk-ESHYE7WU.js → chunk-S73EPYNC.js} +10 -7
  122. package/{chunk-UQNS32WZ.js → chunk-SCMHQUMK.js} +1 -1
  123. package/chunk-SW4S4XYB.js +1794 -0
  124. package/{chunk-ZUEK6A6C.js → chunk-TTH4HOJD.js} +1973 -754
  125. package/chunk-TY3TIUJK.js +89 -0
  126. package/{chunk-X2QRZXZH.js → chunk-TYJ5XFEA.js} +4 -4
  127. package/{chunk-ALFH24P3.js → chunk-TYYRSFBG.js} +197 -155
  128. package/{chunk-MST6R3E4.js → chunk-U5GPBQDG.js} +34 -22
  129. package/chunk-U5ICMAFV.js +14110 -0
  130. package/{chunk-7KVZ5LDQ.js → chunk-UBUH2TCC.js} +18 -4
  131. package/chunk-UEILX4EV.js +15 -0
  132. package/chunk-UHTDNB5Y.js +140 -0
  133. package/{chunk-YYLHWIW6.js → chunk-UKZX3NHN.js} +1 -1
  134. package/{chunk-OHOVNO7I.js → chunk-UOKFKFPO.js} +6 -3
  135. package/{chunk-XISEYOGH.js → chunk-USHQX6VT.js} +5 -5
  136. package/chunk-UUPR3TD7.js +53 -0
  137. package/{chunk-3DAVPNFT.js → chunk-V4EE3D54.js} +122 -107
  138. package/{chunk-HDLLCBRF.js → chunk-VEA7H5FG.js} +2 -2
  139. package/chunk-VHGD6FHV.js +116 -0
  140. package/chunk-VIWDGTDA.js +8 -0
  141. package/{chunk-GOH6RW6F.js → chunk-VJXHL6MH.js} +34 -11
  142. package/{chunk-4XEYAFLY.js → chunk-VL5KOY2C.js} +623 -94
  143. package/{chunk-EADNWBAZ.js → chunk-VP3BINY7.js} +13 -0
  144. package/{chunk-DXHL7G2L.js → chunk-VWW6O2TL.js} +274 -93
  145. package/{chunk-EOARMOVD.js → chunk-W4S6OTSC.js} +6 -3
  146. package/chunk-WD4XYDYC.js +567 -0
  147. package/chunk-WJZOQR2J.js +151 -0
  148. package/{chunk-AUDNYVRC.js → chunk-XETG4RIX.js} +5 -5
  149. package/{chunk-MX574M24.js → chunk-XI7DGLUK.js} +4 -4
  150. package/{chunk-3L2WKC3W.js → chunk-XPWGOTBQ.js} +8 -1
  151. package/chunk-XRUSXPCQ.js +514 -0
  152. package/{chunk-I4OPU5TK.js → chunk-XS47QOFV.js} +273 -11
  153. package/{chunk-S5XGT6GB.js → chunk-XZNCX52W.js} +30 -9
  154. package/{chunk-5OA5HMTL.js → chunk-YLMMECCH.js} +1 -1
  155. package/{chunk-CFT5HBGW.js → chunk-YVLQXTUB.js} +448 -12
  156. package/chunk-YVPQATSC.js +709 -0
  157. package/chunk-ZEZC7IIM.js +126 -0
  158. package/{chunk-ALGORS6Y.js → chunk-ZF6526IQ.js} +43 -8
  159. package/chunk-ZIWPQEFU.js +165 -0
  160. package/chunk-ZRAU6T47.js +56 -0
  161. package/{cliExecutor-AWYR3T33.js → cliExecutor-BWBF2MTI.js} +4 -3
  162. package/{clipboardy-BX4NMYHE.js → clipboardy-GCO3GT3I.js} +3 -8
  163. package/{commandRegistry-2KBOXZQC.js → commandRegistry-NBLZEMCW.js} +183 -107
  164. package/contentThunks-6AIWNSGO.js +84 -0
  165. package/{cooldownCommands-ZLEPIB4A.js → cooldownCommands-JFKTYS2D.js} +2 -2
  166. package/{createAgentAutomationAction-5UGTB26P.js → createAgentAutomationAction-4BUS65DZ.js} +53 -44
  167. package/createDialogAction-QAIKSCG4.js +76 -0
  168. package/{createPageAction-CDLDKPRM.js → createPageAction-DXCZ334C.js} +65 -54
  169. package/cursorProvider-YGGNMVWX.js +6123 -0
  170. package/{db-VQSAOWAO.js → db-2QOTXYGH.js} +11 -5
  171. package/{dbSlice-DQ32LYTJ.js → dbSlice-J37OGIXH.js} +19 -13
  172. package/{deleteFile-NX6QHCWZ.js → deleteFile-6JWDDRVP.js} +10 -6
  173. package/dialogCommands-YZLSJB6X.js +113 -0
  174. package/{dialogSlice-N3YB65G5.js → dialogSlice-PVUSMKFW.js} +53 -39
  175. package/{docCreateCommands-ZSLGVBZT.js → docCreateCommands-JB2RRMRJ.js} +54 -57
  176. package/{docDeleteCommands-5N4GVZBG.js → docDeleteCommands-AQENULNM.js} +56 -58
  177. package/{docReadCommands-YJSAA7AV.js → docReadCommands-DYD25YLQ.js} +53 -56
  178. package/{docStore-E3CEOV5Q.js → docStore-CSEBEMKP.js} +25 -16
  179. package/{docUpdateCommands-WEMLSW6W.js → docUpdateCommands-3GVS23QL.js} +54 -57
  180. package/{fetchMessages-67MEFPZR.js → fetchMessages-IIJWQ3HR.js} +5 -4
  181. package/{getPricing-NMMFT3YI.js → getPricing-FKK3F5EJ.js} +11 -9
  182. package/{handleSendMessageAction-DQAD5ERJ.js → handleSendMessageAction-G2TLYGC4.js} +422 -118
  183. package/index.js +11 -7
  184. package/{lib-FRRS27KN.js → lib-4YTWAGY7.js} +581 -248
  185. package/{localDialogRead-EBRS242U.js → localDialogRead-FSOMOPDZ.js} +2 -2
  186. package/localRuntimeAdapter-B4TAYYA7.js +244 -0
  187. package/localRuntimeAuthority-JDAD7CB6.js +16 -0
  188. package/{localRuntimeDb-3LRMNLCM.js → localRuntimeDb-CVC62PM5.js} +1 -1
  189. package/{machineCommands-HAP75VSG.js → machineCommands-6OBFD3XF.js} +503 -161
  190. package/{machineInfo-66ZFUMLE.js → machineInfo-UKPTZO5Y.js} +2 -2
  191. package/machineWsRunDispatch-OO7N3O3Y.js +169 -0
  192. package/{memberThunks-5ZXPR63F.js → memberThunks-66DH6ABQ.js} +25 -18
  193. package/{models-ZPU5EDF4.js → models-LAS4B2B5.js} +2 -2
  194. package/package.json +1 -1
  195. package/{providerPresetApply-DD6NGWW6.js → providerPresetApply-MY66I6NT.js} +10 -10
  196. package/{providerRegistry-XDRLMYGJ.js → providerRegistry-QOE2FT57.js} +13 -9
  197. package/{read-EPTJRAEF.js → read-DC4NUGN6.js} +12 -8
  198. package/{readDocTool-W4NDXNEX.js → readDocTool-NCJ5NT25.js} +1 -1
  199. package/{readlineWorkspace-7BC66QSX.js → readlineWorkspace-UIQN7JUR.js} +5017 -915
  200. package/{removeDialogAgentAction-OSYNZRX7.js → removeDialogAgentAction-E2H3OZU6.js} +29 -28
  201. package/{runAgentClientLoop-6E6UC3CE.js → runAgentClientLoop-GS3SGG37.js} +154 -97
  202. package/{runtimeDoctorCommands-ID23PNNZ.js → runtimeDoctorCommands-GIOGC5SC.js} +17 -17
  203. package/secretCommands-ZXZRLR3R.js +700 -0
  204. package/setDialogExtraReferencesAction-SITRPMYU.js +37 -0
  205. package/{setPrimaryDialogAgentAction-WZ7KI3YA.js → setPrimaryDialogAgentAction-U7N45TGC.js} +30 -29
  206. package/{chunk-SONWNI3L.js → settingThunks-Y7SVJOMZ.js} +223 -928
  207. package/{skillDiscovery-ZBU76COE.js → skillDiscovery-QC35EQY4.js} +2 -2
  208. package/{slateUtils-RIZES3PV.js → slateUtils-NGV2NMKM.js} +1 -1
  209. package/{spaceCommands-UJOVU4XI.js → spaceCommands-ZR5BR3GX.js} +59 -59
  210. package/{streamAgentChatTurn-3UXPYFNX.js → streamAgentChatTurn-4XYC33KE.js} +309 -165
  211. package/{switchDialogAgentAction-GMR7WN3P.js → switchDialogAgentAction-OMGBD3N2.js} +26 -22
  212. package/{tableCommands-G7RV3RU3.js → tableCommands-U3QDY4L6.js} +19 -17
  213. package/{toolApiClient-CVGWM4PN.js → toolApiClient-7WSJJJBV.js} +6 -5
  214. package/tools-P77EE7Q4.js +124 -0
  215. package/tuiSummaryLlmCaller-BM3VSTBU.js +130 -0
  216. package/{updateCommands-4EHDLF5J.js → updateCommands-NQXAGFM7.js} +3 -3
  217. package/{updateDialogTitleAction-UPFV7TDT.js → updateDialogTitleAction-CIANVPZC.js} +102 -57
  218. package/workloadLifecycle-36DXRZKU.js +320 -0
  219. package/action-GI44T4DR.js +0 -31
  220. package/agentListCommands-IW3GQVUP.js +0 -427
  221. package/agentRecordCommands-VCA76W6B.js +0 -134
  222. package/agentRunCommand-YNLDKVR7.js +0 -161
  223. package/browser-image-compression-MFDTD7K6.js +0 -1763
  224. package/chatQueueReduxAdapter-TJRMXMYA.js +0 -186
  225. package/chromeOpsCommands-IXRLN57H.js +0 -289
  226. package/chunk-36KZDDO5.js +0 -2415
  227. package/chunk-ACQD6YI2.js +0 -25363
  228. package/chunk-CQ3WA2NE.js +0 -299
  229. package/chunk-CYSYR67N.js +0 -93
  230. package/chunk-JBTJAPUF.js +0 -35
  231. package/chunk-K2CSUCHJ.js +0 -620
  232. package/chunk-LTRXGFMS.js +0 -83
  233. package/chunk-M76ECQRD.js +0 -13658
  234. package/chunk-MEYIRKDN.js +0 -8967
  235. package/chunk-OCZKATRC.js +0 -129
  236. package/chunk-OTGFTBLI.js +0 -13
  237. package/chunk-PUOC4YRO.js +0 -394
  238. package/chunk-PZZTFEKK.js +0 -34
  239. package/chunk-URMS4XY2.js +0 -10
  240. package/chunk-UV6VISQJ.js +0 -20
  241. package/chunk-VJVNU77E.js +0 -83
  242. package/chunk-XYJSY4KG.js +0 -13807
  243. package/chunk-Y5GCAMGP.js +0 -9
  244. package/chunk-YPREESF4.js +0 -225
  245. package/contentThunks-BDIQRZR6.js +0 -73
  246. package/createDialogAction-B7VGVEVU.js +0 -66
  247. package/dialogCommands-G7YBVAMC.js +0 -102
  248. package/levelLazyShim-GZBKODGI.js +0 -7
  249. package/machineWsRunDispatch-L32G7C4P.js +0 -149
  250. package/serverStoreFactory-YMXDF4NI.js +0 -20
  251. package/setDialogExtraReferencesAction-M32UYNCG.js +0 -30
  252. package/settingSlice-Q6EKL7EQ.js +0 -204
  253. package/syncMapping-N6RGXGBW.js +0 -437
  254. package/tools-MKYDMWA4.js +0 -111
  255. package/tuiSummaryLlmCaller-3YFNHCTW.js +0 -128
  256. package/{chunk-SV5IJK6K.js → chunk-NBTY7YJF.js} +3 -3
  257. package/{chunk-2SYTUTLI.js → chunk-YBNHPX4S.js} +3 -3
  258. package/{offlineMarxistsAgentCommand-HGXZV4XJ.js → offlineMarxistsAgentCommand-2QTHJCHV.js} +4 -4
@@ -3,7 +3,7 @@ import {
3
3
  parseFlagWithOptionalValue,
4
4
  runCloudflareOAuthLogin,
5
5
  upsertEnvVariable
6
- } from "./chunk-X2QRZXZH.js";
6
+ } from "./chunk-TYJ5XFEA.js";
7
7
  import {
8
8
  ANTHROPIC_OAUTH_AUTHORIZE_URL,
9
9
  ANTHROPIC_OAUTH_CALLBACK_PORT,
@@ -19,6 +19,11 @@ import {
19
19
  CURSOR_POLL_MAX_CONSECUTIVE_ERRORS,
20
20
  CURSOR_POLL_MAX_DELAY_MS,
21
21
  CURSOR_POLL_URL,
22
+ WORKBUDDY_APP_VERSION,
23
+ WORKBUDDY_POLL_INTERVAL_MS,
24
+ WORKBUDDY_REQUEST_TIMEOUT_MS,
25
+ WORKBUDDY_SIGN_IN_TIMEOUT_MS,
26
+ WORKBUDDY_UA_VERSION,
22
27
  XAI_ACCESS_TOKEN_CLIENT_SKEW_MS,
23
28
  XAI_DEVICE_CODE_DEFAULT_EXPIRES_MS,
24
29
  XAI_DEVICE_CODE_DEFAULT_INTERVAL_MS,
@@ -34,7 +39,9 @@ import {
34
39
  XAI_TOKEN_REQUEST_TIMEOUT_MS,
35
40
  decodeJwtExp,
36
41
  generatePkcePair,
42
+ getWorkBuddySite,
37
43
  normalizeAnthropicTokenPayload,
44
+ normalizeWorkBuddyTokenPayload,
38
45
  readJsonBody,
39
46
  refreshAntigravityOAuthToken,
40
47
  renderDeviceCodeDisplay,
@@ -42,66 +49,74 @@ import {
42
49
  runAntigravityOAuthLogin,
43
50
  runOpenAiCodexBrowserPkce,
44
51
  runOpenAiCodexDeviceCode,
52
+ sanitizeWorkBuddyDomain,
53
+ sanitizeWorkBuddyError,
45
54
  startCallbackServer,
46
55
  validateXAIEndpoint,
47
56
  xaiOAuthDiscovery
48
- } from "./chunk-I4OPU5TK.js";
57
+ } from "./chunk-XS47QOFV.js";
58
+ import {
59
+ t
60
+ } from "./chunk-SW4S4XYB.js";
49
61
  import {
50
62
  defaultOpenBrowser
51
- } from "./chunk-IVZJWTDI.js";
52
- import "./chunk-ESHYE7WU.js";
63
+ } from "./chunk-36OMEXXR.js";
64
+ import "./chunk-TY3TIUJK.js";
65
+ import "./chunk-S73EPYNC.js";
66
+ import "./chunk-ZEZC7IIM.js";
53
67
  import {
54
68
  extractGoogleValidationLink
55
69
  } from "./chunk-BMQ2MJUK.js";
56
- import "./chunk-ZOVKKMF6.js";
57
- import "./chunk-GLKOYSRU.js";
58
- import "./chunk-JBTJAPUF.js";
70
+ import "./chunk-OW765XBU.js";
59
71
  import {
60
72
  buildDevinAuthUrl,
61
73
  buildDevinOAuthCredential,
62
74
  detectLocalDevinCredentials,
63
75
  extractDevinToken,
64
76
  fetchAntigravityCloudCodeCompletion
65
- } from "./chunk-P6GMCCAT.js";
66
- import "./chunk-GMZLP5DV.js";
77
+ } from "./chunk-GQV5KHJU.js";
78
+ import "./chunk-HNUWUO75.js";
67
79
  import "./chunk-5ZUL4CUO.js";
68
- import "./chunk-S5XGT6GB.js";
69
- import "./chunk-27ONFIEY.js";
70
- import "./chunk-7KVZ5LDQ.js";
71
- import {
72
- toErrorMessage
73
- } from "./chunk-HNMXYYJR.js";
74
- import "./chunk-3BXNTXYI.js";
75
- import "./chunk-W7XHHYWM.js";
76
- import {
77
- createOAuthTokenStore,
78
- resolveFreshAccessToken
79
- } from "./chunk-ZWQUWF6W.js";
80
- import {
81
- parseUserIdFromAuthToken
82
- } from "./chunk-A7GB5UGH.js";
83
- import "./chunk-OLZBQWZU.js";
84
- import {
85
- getProfileOAuthSync,
86
- saveProfileOAuthSync
87
- } from "./chunk-TNIX77YM.js";
88
- import "./chunk-Y3PMXGLH.js";
89
- import "./chunk-3AH7LNUB.js";
80
+ import "./chunk-5EMSBTQ6.js";
81
+ import "./chunk-I42VC5KR.js";
82
+ import "./chunk-U6VC4MU4.js";
83
+ import "./chunk-XZNCX52W.js";
90
84
  import {
91
85
  asOptionalFiniteNumber
92
86
  } from "./chunk-WWC7I6TA.js";
93
- import "./chunk-QSJ3HFEF.js";
87
+ import "./chunk-K2AER7RX.js";
88
+ import "./chunk-UBUH2TCC.js";
89
+ import "./chunk-I4SN4NUQ.js";
90
+ import "./chunk-5BHQICF2.js";
94
91
  import {
95
92
  isRecord
96
93
  } from "./chunk-KUG52IAP.js";
97
94
  import {
98
95
  asTrimmedString
99
96
  } from "./chunk-3EUW3WEO.js";
100
- import "./chunk-U6VC4MU4.js";
97
+ import {
98
+ toErrorMessage
99
+ } from "./chunk-HNMXYYJR.js";
100
+ import "./chunk-FY4SDK2E.js";
101
+ import "./chunk-GLKOYSRU.js";
102
+ import {
103
+ parseUserIdFromAuthToken
104
+ } from "./chunk-A7GB5UGH.js";
105
+ import "./chunk-OLZBQWZU.js";
101
106
  import "./chunk-LCBAMY2M.js";
102
107
  import "./chunk-4SN6J65J.js";
103
108
  import "./chunk-CF7PE763.js";
104
109
  import "./chunk-G3SUCT4W.js";
110
+ import {
111
+ getProfileOAuthSync,
112
+ saveProfileOAuthSync
113
+ } from "./chunk-TNIX77YM.js";
114
+ import "./chunk-CHCS6XPJ.js";
115
+ import "./chunk-QSJ3HFEF.js";
116
+ import {
117
+ createOAuthTokenStore,
118
+ resolveFreshAccessToken
119
+ } from "./chunk-ZWQUWF6W.js";
105
120
  import "./chunk-4VNS5WPM.js";
106
121
 
107
122
  // packages/cli/oauth/flows/xai.ts
@@ -710,6 +725,219 @@ async function runDevinOAuthLogin(deps = {}) {
710
725
  return buildDevinOAuthCredential(token);
711
726
  }
712
727
 
728
+ // packages/cli/oauth/flows/workbuddy.ts
729
+ import { randomBytes as randomBytes2 } from "node:crypto";
730
+ function validateWorkBuddyAuthUrl(site, authUrlString) {
731
+ let url;
732
+ try {
733
+ url = new URL(authUrlString);
734
+ } catch {
735
+ throw new Error(`Invalid WorkBuddy auth URL: "${authUrlString}"`);
736
+ }
737
+ if (url.protocol !== "https:") {
738
+ throw new Error(`WorkBuddy sign-in page must use https:, got ${url.protocol}`);
739
+ }
740
+ const hostname = url.hostname.toLowerCase();
741
+ if (site === "workbuddy") {
742
+ const isAllowed = hostname === "copilot.tencent.com" || hostname.endsWith(".tencent.com");
743
+ if (!isAllowed) {
744
+ throw new Error(`Untrusted authorization host for WorkBuddy: ${hostname}`);
745
+ }
746
+ } else if (site === "workbuddy-ai") {
747
+ const isAllowed = hostname === "www.workbuddy.ai" || hostname === "workbuddy.ai" || hostname.endsWith(".workbuddy.ai");
748
+ if (!isAllowed) {
749
+ throw new Error(`Untrusted authorization host for WorkBuddy AI: ${hostname}`);
750
+ }
751
+ }
752
+ return url;
753
+ }
754
+ async function callWorkBuddyApi(siteConfig, method, path, headers, body, fetchImpl) {
755
+ let response;
756
+ try {
757
+ response = await fetchImpl(`${siteConfig.endpoint}${path}`, {
758
+ method,
759
+ headers: {
760
+ "Content-Type": "application/json",
761
+ Accept: "application/json",
762
+ "User-Agent": `WorkBuddy/${WORKBUDDY_UA_VERSION}`,
763
+ ...headers
764
+ },
765
+ body: body === void 0 ? void 0 : JSON.stringify(body),
766
+ signal: AbortSignal.timeout(WORKBUDDY_REQUEST_TIMEOUT_MS)
767
+ });
768
+ } catch (error) {
769
+ throw new Error(
770
+ sanitizeWorkBuddyError(`${siteConfig.name} API request failed: ${toErrorMessage(error)}`)
771
+ );
772
+ }
773
+ let text = "";
774
+ try {
775
+ text = await response.text();
776
+ } catch {
777
+ }
778
+ let env = {};
779
+ try {
780
+ env = JSON.parse(text);
781
+ } catch {
782
+ }
783
+ const code = typeof env.code === "number" ? env.code : Number.parseInt(String(env.code ?? ""), 10) || 0;
784
+ if (!response.ok) {
785
+ const why = String(env.msg || env.message || text.slice(0, 200) || response.statusText);
786
+ const err = new Error(
787
+ sanitizeWorkBuddyError(
788
+ `${siteConfig.name}: ${why} (HTTP ${response.status}${code ? `, code ${code}` : ""})`
789
+ )
790
+ );
791
+ err.code = code;
792
+ err.status = response.status;
793
+ throw err;
794
+ }
795
+ if (code !== 0) {
796
+ const why = String(env.msg || env.message || "error");
797
+ const err = new Error(
798
+ sanitizeWorkBuddyError(`${siteConfig.name}: ${why} (${code})`)
799
+ );
800
+ err.code = code;
801
+ err.status = response.status;
802
+ throw err;
803
+ }
804
+ return env.data;
805
+ }
806
+ async function pollWorkBuddyEndpoint(siteConfig, path, headers, retryCodes, deadline, fetchImpl, sleepFn, nowFn) {
807
+ while (true) {
808
+ if (nowFn() > deadline) {
809
+ throw new Error(`${siteConfig.name} sign-in timed out. Please try again.`);
810
+ }
811
+ try {
812
+ const data = await callWorkBuddyApi(siteConfig, "GET", path, headers, void 0, fetchImpl);
813
+ if (data && typeof data === "object" && Object.keys(data).length > 0) {
814
+ return data;
815
+ }
816
+ } catch (rawError) {
817
+ const err = rawError;
818
+ const isRetryable = typeof err.code === "number" && retryCodes.includes(err.code) || err.status === 408 || err.status === 429;
819
+ if (!isRetryable) {
820
+ throw rawError;
821
+ }
822
+ }
823
+ await sleepFn(WORKBUDDY_POLL_INTERVAL_MS);
824
+ }
825
+ }
826
+ async function resolveEnterpriseId(siteConfig, accessToken, domain, who, fetchImpl) {
827
+ const own = typeof who.enterpriseId === "string" ? who.enterpriseId.trim() : "";
828
+ if (own) return own;
829
+ const type = String(who.type ?? "").trim().toLowerCase();
830
+ if (!type || type === "personal") return "";
831
+ try {
832
+ const list = await callWorkBuddyApi(
833
+ siteConfig,
834
+ "GET",
835
+ "/v2/plugin/accounts",
836
+ {
837
+ Authorization: `Bearer ${accessToken}`,
838
+ "X-Domain": domain
839
+ },
840
+ void 0,
841
+ fetchImpl
842
+ );
843
+ const mine = (list?.accounts ?? []).filter(
844
+ (x) => x?.uid === who.uid && typeof x?.enterpriseId === "string" && x.enterpriseId.trim()
845
+ );
846
+ const same = mine.filter((x) => String(x.type ?? "").trim().toLowerCase() === type);
847
+ const last = mine.filter((x) => x.lastLogin);
848
+ const pick = same.length === 1 ? same[0] : last.length === 1 ? last[0] : mine.length === 1 ? mine[0] : void 0;
849
+ return pick && typeof pick.enterpriseId === "string" ? pick.enterpriseId.trim() : "";
850
+ } catch {
851
+ return "";
852
+ }
853
+ }
854
+ async function runWorkBuddyOAuthLogin(site, deps = {}) {
855
+ const siteConfig = getWorkBuddySite(site);
856
+ const output = deps.output ?? console;
857
+ const fetchImpl = deps.fetchImpl ?? fetch;
858
+ const sleepFn = deps.sleep ?? ((ms) => new Promise((resolve) => setTimeout(resolve, ms)));
859
+ const nowFn = deps.now ?? (() => Date.now());
860
+ const stateData = await callWorkBuddyApi(
861
+ siteConfig,
862
+ "POST",
863
+ `/v2/plugin/auth/state?platform=${encodeURIComponent(siteConfig.platform)}`,
864
+ {
865
+ "X-No-Authorization": "true",
866
+ "X-No-User-Id": "true",
867
+ "X-No-Enterprise-Id": "true",
868
+ "X-No-Department-Info": "true"
869
+ },
870
+ {},
871
+ fetchImpl
872
+ );
873
+ if (!stateData?.state || !stateData?.authUrl) {
874
+ throw new Error(`${siteConfig.name} gave no sign-in page`);
875
+ }
876
+ const validatedUrl = validateWorkBuddyAuthUrl(site, stateData.authUrl);
877
+ validatedUrl.searchParams.set("version", WORKBUDDY_APP_VERSION);
878
+ validatedUrl.searchParams.set("loginSessionId", randomBytes2(16).toString("hex"));
879
+ const finalAuthUrl = validatedUrl.toString();
880
+ output.log(
881
+ `
882
+ Open this URL in your browser to authorize ${siteConfig.name}:
883
+ ${finalAuthUrl}
884
+
885
+ Waiting for browser authentication...`
886
+ );
887
+ if (deps.openBrowser) {
888
+ try {
889
+ await deps.openBrowser(finalAuthUrl);
890
+ } catch {
891
+ }
892
+ }
893
+ const deadline = nowFn() + WORKBUDDY_SIGN_IN_TIMEOUT_MS;
894
+ const qState = encodeURIComponent(stateData.state);
895
+ const token = await pollWorkBuddyEndpoint(
896
+ siteConfig,
897
+ `/v2/plugin/auth/token?state=${qState}`,
898
+ {},
899
+ [11217],
900
+ deadline,
901
+ fetchImpl,
902
+ sleepFn,
903
+ nowFn
904
+ );
905
+ if (typeof token?.accessToken !== "string" || !token.accessToken.trim()) {
906
+ throw new Error(`${siteConfig.name} sent back no token`);
907
+ }
908
+ const defaultHost = new URL(siteConfig.endpoint).host;
909
+ const tokenDomain = sanitizeWorkBuddyDomain(token.domain, defaultHost);
910
+ const who = await pollWorkBuddyEndpoint(
911
+ siteConfig,
912
+ `/v2/plugin/login/account?state=${qState}`,
913
+ {
914
+ Authorization: `Bearer ${token.accessToken}`,
915
+ "X-Domain": tokenDomain,
916
+ "X-No-User-Id": "true",
917
+ "X-No-Enterprise-Id": "true"
918
+ },
919
+ [12151],
920
+ deadline,
921
+ fetchImpl,
922
+ sleepFn,
923
+ nowFn
924
+ );
925
+ const enterpriseId = await resolveEnterpriseId(
926
+ siteConfig,
927
+ token.accessToken,
928
+ tokenDomain,
929
+ who,
930
+ fetchImpl
931
+ );
932
+ const now = nowFn();
933
+ return normalizeWorkBuddyTokenPayload(site, {
934
+ ...token,
935
+ uid: who.uid,
936
+ nickname: who.nickname || who.phoneNumber,
937
+ enterpriseId: enterpriseId || who.enterpriseId
938
+ }, void 0, now);
939
+ }
940
+
713
941
  // packages/cli/oauth/authCommand.ts
714
942
  var SYNC_HELP_LINE = ` --sync-to-server After local save, push the credential to your nolo server and remember this choice.
715
943
  --no-sync-to-server Skip server sync and remember this choice (keeps credentials local only).
@@ -890,6 +1118,42 @@ Options:
890
1118
  ${SYNC_HELP_LINE}
891
1119
  --help, -h Show this help and exit.
892
1120
  `;
1121
+ var WORKBUDDY_HELP_TEXT = `Authorize nolo-cli to call WorkBuddy (China) models via your WorkBuddy account.
1122
+
1123
+ This authorizes model API access only. It does NOT log you into the Nolo
1124
+ platform. To manage agents, docs, spaces, and other Nolo resources, run
1125
+ "nolo login" first.
1126
+
1127
+ Usage: nolo auth workbuddy [--browser] [--no-browser] [--sync-to-server] [--help]
1128
+
1129
+ The flow opens https://copilot.tencent.com in your browser and polls the login status.
1130
+ After approval, tokens are stored in $NOLO_HOME/credentials/workbuddy.json (or ~/.nolo/credentials/workbuddy.json when NOLO_HOME is unset).
1131
+ Agents can reference the stored token with apiKeyRef: "workbuddy".
1132
+
1133
+ Options:
1134
+ --browser Open the login URL in your browser automatically (default).
1135
+ --no-browser Print the login URL without opening a browser.
1136
+ ${SYNC_HELP_LINE}
1137
+ --help, -h Show this help and exit.
1138
+ `;
1139
+ var WORKBUDDY_AI_HELP_TEXT = `Authorize nolo-cli to call WorkBuddy AI (International) models via your WorkBuddy AI account.
1140
+
1141
+ This authorizes model API access only. It does NOT log you into the Nolo
1142
+ platform. To manage agents, docs, spaces, and other Nolo resources, run
1143
+ "nolo login" first.
1144
+
1145
+ Usage: nolo auth workbuddy-ai [--browser] [--no-browser] [--sync-to-server] [--help]
1146
+
1147
+ The flow opens https://www.workbuddy.ai in your browser and polls the login status.
1148
+ After approval, tokens are stored in $NOLO_HOME/credentials/workbuddy-ai.json (or ~/.nolo/credentials/workbuddy-ai.json when NOLO_HOME is unset).
1149
+ Agents can reference the stored token with apiKeyRef: "workbuddy-ai".
1150
+
1151
+ Options:
1152
+ --browser Open the login URL in your browser automatically (default).
1153
+ --no-browser Print the login URL without opening a browser.
1154
+ ${SYNC_HELP_LINE}
1155
+ --help, -h Show this help and exit.
1156
+ `;
893
1157
  var HELP_BY_PROVIDER = {
894
1158
  chatgpt: CHATGPT_HELP_TEXT,
895
1159
  xai: XAI_HELP_TEXT,
@@ -897,7 +1161,9 @@ var HELP_BY_PROVIDER = {
897
1161
  claude: CLAUDE_HELP_TEXT,
898
1162
  cloudflare: CLOUDFLARE_HELP_TEXT,
899
1163
  cursor: CURSOR_HELP_TEXT,
900
- devin: DEVIN_HELP_TEXT
1164
+ devin: DEVIN_HELP_TEXT,
1165
+ workbuddy: WORKBUDDY_HELP_TEXT,
1166
+ "workbuddy-ai": WORKBUDDY_AI_HELP_TEXT
901
1167
  };
902
1168
  function markCredentialServerManaged(provider, credential, syncConfig, deps) {
903
1169
  const output = deps.output ?? console;
@@ -918,12 +1184,12 @@ function markCredentialServerManaged(provider, credential, syncConfig, deps) {
918
1184
  }
919
1185
  });
920
1186
  output.log(
921
- `[nolo] \u672C\u5730\u4E0D\u518D\u4FDD\u5B58 refresh token\uFF1A${provider} \u7531 ${syncConfig.serverOrigin} \u7EDF\u4E00\u5237\u65B0\uFF08\u7528\u5B8C\u5373\u53D6\uFF09\u3002`
1187
+ t("auth.localRefreshTokenDropped", provider, syncConfig.serverOrigin)
922
1188
  );
923
1189
  return true;
924
1190
  } catch (err) {
925
1191
  output.log(
926
- `[nolo] Warning: \u672C\u5730\u51ED\u636E\u72B6\u6001\u66F4\u65B0\u5931\u8D25\uFF08${toErrorMessage(err)}\uFF09\u3002`
1192
+ t("auth.localStateUpdateFailed", toErrorMessage(err))
927
1193
  );
928
1194
  return false;
929
1195
  }
@@ -934,7 +1200,7 @@ async function syncCredentialToServer(provider, credential, deps) {
934
1200
  const syncConfig = (deps.resolveServerSyncConfig ?? resolveServerSyncConfig)();
935
1201
  if (!syncConfig) {
936
1202
  output.log(
937
- `[nolo] Warning: server sync requires NOLO_SERVER and AUTH_TOKEN env vars, or a configured profile. Skipping server sync.`
1203
+ t("auth.syncMissingConfig")
938
1204
  );
939
1205
  return "sync_failed";
940
1206
  }
@@ -961,8 +1227,8 @@ async function syncCredentialToServer(provider, credential, deps) {
961
1227
  if (res.ok) {
962
1228
  const marked = markCredentialServerManaged(provider, credential, syncConfig, deps);
963
1229
  if (marked) {
964
- output.log(`[nolo] Synced to ${serverOrigin}`);
965
- output.log(`[nolo] \u7F51\u9875\u7AEF\u73B0\u5728\u53EF\u4EE5\u4F7F\u7528\u8BE5\u8BA2\u9605\u4E86\u3002`);
1230
+ output.log(t("auth.syncedTo", serverOrigin));
1231
+ output.log(t("auth.syncDoneWebUsable"));
966
1232
  return "ok";
967
1233
  }
968
1234
  return "mark_failed";
@@ -974,13 +1240,13 @@ async function syncCredentialToServer(provider, credential, deps) {
974
1240
  } catch {
975
1241
  }
976
1242
  output.log(
977
- `[nolo] Warning: server sync failed (${res.status}${errorDetail ? `: ${errorDetail}` : ""}). Token saved locally.`
1243
+ t("auth.syncFailed", `${res.status}${errorDetail ? `: ${errorDetail}` : ""}`)
978
1244
  );
979
1245
  return "sync_failed";
980
1246
  }
981
1247
  } catch (err) {
982
1248
  output.log(
983
- `[nolo] Warning: server sync failed (${err?.message ?? "network error"}). Token saved locally.`
1249
+ t("auth.syncFailed", err?.message ?? "network error")
984
1250
  );
985
1251
  return "sync_failed";
986
1252
  }
@@ -1008,14 +1274,17 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1008
1274
  const credential = tokenStore.read(provider);
1009
1275
  if (!credential) {
1010
1276
  error.error(
1011
- `[nolo] No local ${provider} credential. Run: nolo auth ${provider}`
1277
+ t("auth.noLocalCredential", provider)
1012
1278
  );
1013
1279
  return 1;
1014
1280
  }
1015
1281
  if (credential.serverManaged) {
1016
1282
  error.error(
1017
- `[nolo] ${provider} \u51ED\u636E\u5DF2\u7531 ${credential.serverManaged.origin} \u670D\u52A1\u7AEF\u6258\u7BA1\uFF08\u672C\u5730\u65E0 refreshToken\uFF09\u3002
1018
- \u5982\u9700\u91CD\u65B0\u540C\u6B65\uFF0C\u8BF7\u8FD0\u884C: nolo auth ${provider} --sync-to-server`
1283
+ t(
1284
+ "auth.credentialServerManaged",
1285
+ provider,
1286
+ credential.serverManaged.origin
1287
+ )
1019
1288
  );
1020
1289
  return 1;
1021
1290
  }
@@ -1024,18 +1293,16 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1024
1293
  }
1025
1294
  if (verify) {
1026
1295
  if (provider !== "antigravity") {
1027
- error.error(`[nolo] --verify is only supported for "nolo auth antigravity".`);
1296
+ error.error(t("auth.verifyUnsupported"));
1028
1297
  return 1;
1029
1298
  }
1030
1299
  const credential = tokenStore.read(provider);
1031
1300
  if (!credential?.accessToken) {
1032
- error.error(
1033
- `[nolo] No local antigravity credential. Run: nolo auth antigravity`
1034
- );
1301
+ error.error(t("auth.noLocalCredential", provider));
1035
1302
  return 1;
1036
1303
  }
1037
1304
  output.log(
1038
- `[nolo] Checking the current verification challenge (one lightweight request)...`
1305
+ t("auth.checkingVerificationChallenge")
1039
1306
  );
1040
1307
  let accessToken = null;
1041
1308
  let refreshError;
@@ -1051,7 +1318,7 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1051
1318
  refreshError
1052
1319
  )) {
1053
1320
  error.error(
1054
- `[nolo] The antigravity refresh token is no longer valid (${refreshError}). Re-run \`nolo auth antigravity\` to re-authorize this account.`
1321
+ t("auth.refreshTokenInvalid", refreshError)
1055
1322
  );
1056
1323
  return 1;
1057
1324
  }
@@ -1069,18 +1336,18 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1069
1336
  const msg = toErrorMessage(err);
1070
1337
  if (/projectId|metadata\.projectId|Re-run `nolo auth/i.test(msg)) {
1071
1338
  error.error(
1072
- `[nolo] The stored antigravity credential is incomplete (${msg}). Re-run \`nolo auth antigravity\` to re-authorize.`
1339
+ t("auth.credentialIncomplete", msg)
1073
1340
  );
1074
1341
  } else {
1075
1342
  error.error(
1076
- `[nolo] Could not reach the antigravity provider: ${msg}. Check your network and retry.`
1343
+ t("auth.providerUnreachable", msg)
1077
1344
  );
1078
1345
  }
1079
1346
  return 1;
1080
1347
  }
1081
1348
  if (result.status >= 200 && result.status < 300) {
1082
1349
  output.log(
1083
- `[nolo] \u2713 The credential is working \u2014 no verification is required right now. You can retry your agent.`
1350
+ t("auth.credentialWorking")
1084
1351
  );
1085
1352
  return 0;
1086
1353
  }
@@ -1089,18 +1356,24 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1089
1356
  );
1090
1357
  if (result.status === 403 && validationUrl) {
1091
1358
  output.log(
1092
- `[nolo] Google requires a one-time account verification for ${credential.accountId ?? "this account"}.`
1359
+ t("auth.googleVerificationRequired", credential.accountId ?? "this account")
1093
1360
  );
1094
1361
  output.log(`[nolo] ${validationUrl}`);
1095
1362
  const opener = noBrowser ? void 0 : deps.openBrowser ?? defaultOpenBrowser;
1096
1363
  const opened = opener ? await opener(validationUrl) : false;
1097
1364
  output.log(
1098
- opened ? `[nolo] \u2713 Opened it in your browser \u2014 complete the verification there (sign in with the same Google account), then retry your agent.` : `[nolo] Copy the URL above into a browser signed into ${credential.accountId ?? "that account"}, complete the verification, then retry your agent.`
1365
+ opened ? t("auth.verificationOpened") : t("auth.verificationCopyUrl", credential.accountId ?? "that account")
1099
1366
  );
1100
1367
  return 0;
1101
1368
  }
1369
+ const refreshSuffix = refreshError ? t("auth.httpWithoutVerificationLink.refreshSuffix", refreshError) : "";
1102
1370
  error.error(
1103
- `[nolo] The provider returned HTTP ${result.status} without a verification link \u2014 this is not the one-time-verification case --verify handles.` + (refreshError ? ` (token refresh also failed earlier: ${refreshError})` : "") + ` Response detail: ${JSON.stringify(result.body ?? {}).slice(0, 400)}`
1371
+ t(
1372
+ "auth.httpWithoutVerificationLink",
1373
+ String(result.status),
1374
+ refreshSuffix,
1375
+ JSON.stringify(result.body ?? {}).slice(0, 400)
1376
+ )
1104
1377
  );
1105
1378
  return 1;
1106
1379
  }
@@ -1131,6 +1404,8 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1131
1404
  credential = await runCursorOAuthLogin(flowDeps);
1132
1405
  } else if (provider === "devin") {
1133
1406
  credential = await runDevinOAuthLogin(flowDeps);
1407
+ } else if (provider === "workbuddy" || provider === "workbuddy-ai") {
1408
+ credential = await runWorkBuddyOAuthLogin(provider, flowDeps);
1134
1409
  } else if (provider === "cloudflare") {
1135
1410
  credential = await runCloudflareOAuthLogin({
1136
1411
  ...flowDeps,
@@ -1147,10 +1422,12 @@ async function runAuthProviderCommand(provider, args, _ctx, deps = {}) {
1147
1422
  fetchImpl: deps.fetchImpl ?? fetch
1148
1423
  });
1149
1424
  output.log(
1150
- `[nolo] Generated Cloudflare API token for zone ${zoneName} (${zoneId}).
1151
- Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1152
- ${token}
1153
- `
1425
+ t(
1426
+ "auth.cloudflareTokenGenerated",
1427
+ zoneName,
1428
+ zoneId,
1429
+ token
1430
+ )
1154
1431
  );
1155
1432
  if (writeToEnvPath) {
1156
1433
  upsertEnvVariable(
@@ -1159,7 +1436,7 @@ Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1159
1436
  token
1160
1437
  );
1161
1438
  output.log(
1162
- `[nolo] Updated ${writeToEnvPath} with CLOUDFLARE_EMAIL_ROUTING_API_TOKEN.`
1439
+ t("auth.envUpdated", writeToEnvPath)
1163
1440
  );
1164
1441
  }
1165
1442
  }
@@ -1169,7 +1446,11 @@ Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1169
1446
  tokenStore.write(provider, credential);
1170
1447
  const accountLabel = credential.metadata?.email ?? credential.accountId ?? "";
1171
1448
  output.log(
1172
- `[nolo] ${provider} authorization saved` + (accountLabel ? ` for ${accountLabel}` : "") + `.`
1449
+ t(
1450
+ "auth.authorizationSaved",
1451
+ provider,
1452
+ accountLabel ? t("auth.authorizationSavedForAccount", accountLabel) : ""
1453
+ )
1173
1454
  );
1174
1455
  const hasExplicitNoSync = args.includes("--no-sync-to-server");
1175
1456
  const hasExplicitSync = args.includes("--sync-to-server");
@@ -1179,7 +1460,17 @@ Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1179
1460
  saveProfileOAuthSync(p, s);
1180
1461
  });
1181
1462
  let shouldSync = false;
1182
- if (hasExplicitNoSync || envAutoSync === "0") {
1463
+ if (provider === "workbuddy" || provider === "workbuddy-ai") {
1464
+ if (hasExplicitSync) {
1465
+ setOAuthSync(provider, true);
1466
+ shouldSync = true;
1467
+ } else {
1468
+ if (hasExplicitNoSync) {
1469
+ setOAuthSync(provider, false);
1470
+ }
1471
+ shouldSync = false;
1472
+ }
1473
+ } else if (hasExplicitNoSync || envAutoSync === "0") {
1183
1474
  if (hasExplicitNoSync) {
1184
1475
  setOAuthSync(provider, false);
1185
1476
  }
@@ -1198,12 +1489,16 @@ Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1198
1489
  if (!syncConfig) {
1199
1490
  shouldSync = false;
1200
1491
  output.log(
1201
- `[nolo] \u672A\u914D\u7F6E\u670D\u52A1\u5668\u3002\u5982\u9700\u5728\u7F51\u9875\u7AEF\u4F7F\u7528\uFF0C\u8BF7\u5148\u8FD0\u884C nolo login\uFF0C\u518D\u8FD0\u884C nolo auth ${provider} --sync-only`
1492
+ t("auth.noServerConfigured", provider)
1202
1493
  );
1203
1494
  } else {
1204
1495
  const isTTY = typeof deps.isTTY === "function" ? deps.isTTY() : deps.isTTY ?? Boolean(process.stdin.isTTY && process.stdout.isTTY);
1205
1496
  if (isTTY) {
1206
- const question = `\u540C\u6B65\u5230 ${syncConfig.serverOrigin}\uFF0C\u8BA9\u7F51\u9875\u7AEF\u4E5F\u80FD\u4F7F\u7528\u8FD9\u4E2A ${provider} \u8BA2\u9605\uFF1F\u51ED\u8BC1\u52A0\u5BC6\u5B58\u50A8\uFF0C\u53EF\u968F\u65F6 nolo auth ${provider} --no-sync-to-server \u5173\u95ED [Y/n] `;
1497
+ const question = t(
1498
+ "auth.syncPrompt",
1499
+ syncConfig.serverOrigin,
1500
+ provider
1501
+ );
1207
1502
  let answer;
1208
1503
  if (deps.promptOAuthSync) {
1209
1504
  answer = await deps.promptOAuthSync(question);
@@ -1231,7 +1526,7 @@ Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1231
1526
  } else {
1232
1527
  shouldSync = false;
1233
1528
  output.log(
1234
- `[nolo] \u672A\u540C\u6B65\u51ED\u636E\u5230\u670D\u52A1\u5668\u3002\u5982\u9700\u7F51\u9875\u7AEF\u4F7F\u7528\uFF0C\u8BF7\u8FD0\u884C: nolo auth ${provider} --sync-to-server\uFF08\u6216 --sync-only\uFF09`
1529
+ t("auth.notSyncedToServer", provider)
1235
1530
  );
1236
1531
  }
1237
1532
  }
@@ -1240,14 +1535,14 @@ Store it as CLOUDFLARE_EMAIL_ROUTING_API_TOKEN:
1240
1535
  if (shouldSync) {
1241
1536
  const syncResult = await syncCredentialToServer(provider, credential, deps);
1242
1537
  if (syncResult === "mark_failed") {
1243
- error.error(`[nolo] \u51ED\u636E\u5DF2\u6210\u529F\u4E0A\u4F20\u670D\u52A1\u5668\uFF0C\u4F46\u672C\u5730\u6253\u4E0A\u6258\u7BA1\u6807\u8BB0\u5931\u8D25\u3002\u4E3A\u9632\u53CC\u65B9\u7ADE\u6001\u5237\u65B0\u5BFC\u81F4\u5931\u6548\uFF0C\u8BF7\u91CD\u65B0\u6388\u6743\u3002`);
1538
+ error.error(t("auth.markFailed"));
1244
1539
  return 1;
1245
1540
  }
1246
1541
  }
1247
1542
  return 0;
1248
1543
  } catch (err) {
1249
1544
  error.error(
1250
- `nolo auth ${provider} failed: ${toErrorMessage(err)}`
1545
+ t("auth.commandFailed", provider, toErrorMessage(err))
1251
1546
  );
1252
1547
  return 1;
1253
1548
  }
@@ -1273,6 +1568,12 @@ async function runAuthCursorCommand(args, ctx, deps) {
1273
1568
  async function runAuthDevinCommand(args, ctx, deps) {
1274
1569
  return runAuthProviderCommand("devin", args, ctx, deps);
1275
1570
  }
1571
+ async function runAuthWorkbuddyCommand(args, ctx, deps) {
1572
+ return runAuthProviderCommand("workbuddy", args, ctx, deps);
1573
+ }
1574
+ async function runAuthWorkbuddyAiCommand(args, ctx, deps) {
1575
+ return runAuthProviderCommand("workbuddy-ai", args, ctx, deps);
1576
+ }
1276
1577
  export {
1277
1578
  resolveServerSyncConfig,
1278
1579
  runAuthAntigravityCommand,
@@ -1282,5 +1583,7 @@ export {
1282
1583
  runAuthCursorCommand,
1283
1584
  runAuthDevinCommand,
1284
1585
  runAuthProviderCommand,
1586
+ runAuthWorkbuddyAiCommand,
1587
+ runAuthWorkbuddyCommand,
1285
1588
  runAuthXaiCommand
1286
1589
  };