@songsid/agend 2.4.0-alpha.2 → 2.4.0-alpha.4

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 (654) hide show
  1. package/dist/account-isolation.d.ts +6 -0
  2. package/dist/account-isolation.js +40 -0
  3. package/dist/account-isolation.js.map +1 -0
  4. package/dist/accounts-signout.d.ts +15 -2
  5. package/dist/accounts-signout.js +52 -4
  6. package/dist/accounts-signout.js.map +1 -1
  7. package/dist/accounts-view.d.ts +114 -27
  8. package/dist/accounts-view.js +123 -60
  9. package/dist/accounts-view.js.map +1 -1
  10. package/dist/agent-cli-instructions.md +15 -9
  11. package/dist/agent-cli.js +47 -20
  12. package/dist/agent-cli.js.map +1 -1
  13. package/dist/agent-endpoint.js +23 -8
  14. package/dist/agent-endpoint.js.map +1 -1
  15. package/dist/agent-list-output.d.ts +23 -0
  16. package/dist/agent-list-output.js +53 -0
  17. package/dist/agent-list-output.js.map +1 -0
  18. package/dist/agent-runtime-change.js +4 -4
  19. package/dist/agent-runtime-change.js.map +1 -1
  20. package/dist/agent-whats-new.js +9 -7
  21. package/dist/agent-whats-new.js.map +1 -1
  22. package/dist/antigravity-first-run.d.ts +4 -0
  23. package/dist/antigravity-first-run.js +57 -0
  24. package/dist/antigravity-first-run.js.map +1 -0
  25. package/dist/antigravity-identity.d.ts +6 -0
  26. package/dist/antigravity-identity.js +27 -0
  27. package/dist/antigravity-identity.js.map +1 -0
  28. package/dist/antigravity-store.d.ts +22 -0
  29. package/dist/antigravity-store.js +79 -0
  30. package/dist/antigravity-store.js.map +1 -0
  31. package/dist/auth-api.js +11 -1
  32. package/dist/auth-api.js.map +1 -1
  33. package/dist/backend/agy-onboarding.d.ts +14 -0
  34. package/dist/backend/agy-onboarding.js +114 -0
  35. package/dist/backend/agy-onboarding.js.map +1 -0
  36. package/dist/backend/antigravity.d.ts +15 -0
  37. package/dist/backend/antigravity.js +44 -4
  38. package/dist/backend/antigravity.js.map +1 -1
  39. package/dist/backend/claude-code.d.ts +8 -0
  40. package/dist/backend/claude-code.js +11 -4
  41. package/dist/backend/claude-code.js.map +1 -1
  42. package/dist/backend/codex.js +7 -3
  43. package/dist/backend/codex.js.map +1 -1
  44. package/dist/backend/credential-profile.d.ts +22 -3
  45. package/dist/backend/credential-profile.js +61 -9
  46. package/dist/backend/credential-profile.js.map +1 -1
  47. package/dist/backend/grok.d.ts +19 -0
  48. package/dist/backend/grok.js +112 -1
  49. package/dist/backend/grok.js.map +1 -1
  50. package/dist/backend/types.d.ts +10 -0
  51. package/dist/backend/types.js.map +1 -1
  52. package/dist/backend-availability.d.ts +6 -0
  53. package/dist/backend-availability.js +11 -0
  54. package/dist/backend-availability.js.map +1 -1
  55. package/dist/browser-backend-signins.d.ts +9 -1
  56. package/dist/browser-backend-signins.js +9 -5
  57. package/dist/browser-backend-signins.js.map +1 -1
  58. package/dist/build-provenance.json +1 -1
  59. package/dist/channel/mcp-tools.js +10 -10
  60. package/dist/channel/mcp-tools.js.map +1 -1
  61. package/dist/child-process.d.ts +1 -0
  62. package/dist/child-process.js.map +1 -1
  63. package/dist/claude-auth-status.d.ts +1 -0
  64. package/dist/claude-auth-status.js +25 -0
  65. package/dist/claude-auth-status.js.map +1 -1
  66. package/dist/claude-model-observation.d.ts +71 -0
  67. package/dist/claude-model-observation.js +169 -0
  68. package/dist/claude-model-observation.js.map +1 -0
  69. package/dist/cli-capability.d.ts +104 -19
  70. package/dist/cli-capability.js +3 -1
  71. package/dist/cli-capability.js.map +1 -1
  72. package/dist/cli-caps-module.d.ts +14 -0
  73. package/dist/cli-caps-module.js +8 -1
  74. package/dist/cli-caps-module.js.map +1 -1
  75. package/dist/cli-registry-check.js +114 -18
  76. package/dist/cli-registry-check.js.map +1 -1
  77. package/dist/cli-registry.d.ts +116 -12
  78. package/dist/cli-registry.js +16 -1
  79. package/dist/cli-registry.js.map +1 -1
  80. package/dist/cli-spec-antigravity.d.ts +53 -11
  81. package/dist/cli-spec-antigravity.js +44 -13
  82. package/dist/cli-spec-antigravity.js.map +1 -1
  83. package/dist/cli-spec-claude-code.d.ts +14 -1
  84. package/dist/cli-spec-claude-code.js +5 -4
  85. package/dist/cli-spec-claude-code.js.map +1 -1
  86. package/dist/cli-spec-codex.d.ts +8 -0
  87. package/dist/cli-spec-codex.js +4 -3
  88. package/dist/cli-spec-codex.js.map +1 -1
  89. package/dist/cli-spec-grok.d.ts +4 -0
  90. package/dist/cli-spec-grok.js +2 -1
  91. package/dist/cli-spec-grok.js.map +1 -1
  92. package/dist/cli-spec-kiro-cli.d.ts +7 -0
  93. package/dist/cli-spec-kiro-cli.js +3 -2
  94. package/dist/cli-spec-kiro-cli.js.map +1 -1
  95. package/dist/cli-spec-muse.d.ts +4 -0
  96. package/dist/cli-spec-muse.js +2 -1
  97. package/dist/cli-spec-muse.js.map +1 -1
  98. package/dist/cli-spec-opencode.d.ts +1 -0
  99. package/dist/cli-spec-opencode.js +1 -0
  100. package/dist/cli-spec-opencode.js.map +1 -1
  101. package/dist/credential-store-proof.d.ts +6 -0
  102. package/dist/credential-store-proof.js +30 -0
  103. package/dist/credential-store-proof.js.map +1 -0
  104. package/dist/cross-instance-envelope.d.ts +4 -1
  105. package/dist/cross-instance-envelope.js +12 -7
  106. package/dist/cross-instance-envelope.js.map +1 -1
  107. package/dist/daemon.d.ts +24 -2
  108. package/dist/daemon.js +265 -37
  109. package/dist/daemon.js.map +1 -1
  110. package/dist/decision-list.d.ts +5 -4
  111. package/dist/decision-list.js +22 -8
  112. package/dist/decision-list.js.map +1 -1
  113. package/dist/delivery-consumed-watch.d.ts +24 -0
  114. package/dist/delivery-consumed-watch.js +21 -10
  115. package/dist/delivery-consumed-watch.js.map +1 -1
  116. package/dist/delivery-outbox.d.ts +5 -1
  117. package/dist/delivery-outbox.js +5 -0
  118. package/dist/delivery-outbox.js.map +1 -1
  119. package/dist/fleet-manager.d.ts +31 -2
  120. package/dist/fleet-manager.js +238 -56
  121. package/dist/fleet-manager.js.map +1 -1
  122. package/dist/fleet-windows-runtime.js +6 -6
  123. package/dist/fleet-windows-runtime.js.map +1 -1
  124. package/dist/general-knowledge/skills/concepts/SKILL.md +48 -7
  125. package/dist/general-knowledge/skills/credential-profiles/SKILL.md +23 -6
  126. package/dist/general-knowledge/skills/cross-instance-messaging/SKILL.md +18 -8
  127. package/dist/general-knowledge/skills/fleet-health/SKILL.md +16 -0
  128. package/dist/general-knowledge/skills/hub/SKILL.md +518 -0
  129. package/dist/general-knowledge/skills/multi-channel/SKILL.md +1 -1
  130. package/dist/general-knowledge/skills/scheduling/SKILL.md +1 -1
  131. package/dist/general-knowledge/skills/web-dashboard/SKILL.md +199 -40
  132. package/dist/general-knowledge/skills/worker-collaboration/SKILL.md +5 -1
  133. package/dist/general-role.d.ts +1 -1
  134. package/dist/general-role.js +1 -0
  135. package/dist/general-role.js.map +1 -1
  136. package/dist/grok-delivery-proof.d.ts +24 -0
  137. package/dist/grok-delivery-proof.js +124 -0
  138. package/dist/grok-delivery-proof.js.map +1 -0
  139. package/dist/hub/assistant/admin-types.d.ts +43 -0
  140. package/dist/hub/assistant/admin-types.js +2 -0
  141. package/dist/hub/assistant/admin-types.js.map +1 -0
  142. package/dist/hub/assistant/claude-host.d.ts +17 -0
  143. package/dist/hub/assistant/claude-host.js +300 -0
  144. package/dist/hub/assistant/claude-host.js.map +1 -0
  145. package/dist/hub/assistant/context.d.ts +3 -0
  146. package/dist/hub/assistant/context.js +7 -0
  147. package/dist/hub/assistant/context.js.map +1 -0
  148. package/dist/hub/assistant/fleet-host.d.ts +19 -0
  149. package/dist/hub/assistant/fleet-host.js +28 -0
  150. package/dist/hub/assistant/fleet-host.js.map +1 -0
  151. package/dist/hub/assistant/runner.d.ts +64 -0
  152. package/dist/hub/assistant/runner.js +239 -0
  153. package/dist/hub/assistant/runner.js.map +1 -0
  154. package/dist/hub/assistant/service.d.ts +51 -0
  155. package/dist/hub/assistant/service.js +143 -0
  156. package/dist/hub/assistant/service.js.map +1 -0
  157. package/dist/hub/assistant/store.d.ts +3 -0
  158. package/dist/hub/assistant/store.js +65 -0
  159. package/dist/hub/assistant/store.js.map +1 -0
  160. package/dist/hub/assistant/types.d.ts +60 -0
  161. package/dist/hub/assistant/types.js +2 -0
  162. package/dist/hub/assistant/types.js.map +1 -0
  163. package/dist/hub/buttons.d.ts +3 -0
  164. package/dist/hub/buttons.js +11 -11
  165. package/dist/hub/buttons.js.map +1 -1
  166. package/dist/hub/catalog.d.ts +13 -6
  167. package/dist/hub/catalog.js +127 -35
  168. package/dist/hub/catalog.js.map +1 -1
  169. package/dist/hub/client.d.ts +16 -0
  170. package/dist/hub/client.js +52 -9
  171. package/dist/hub/client.js.map +1 -1
  172. package/dist/hub/compose/member.d.ts +8 -1
  173. package/dist/hub/compose/member.js +238 -57
  174. package/dist/hub/compose/member.js.map +1 -1
  175. package/dist/hub/compose/server.d.ts +17 -1
  176. package/dist/hub/compose/server.js +76 -13
  177. package/dist/hub/compose/server.js.map +1 -1
  178. package/dist/hub/directory/admission.d.ts +15 -0
  179. package/dist/hub/directory/admission.js +56 -0
  180. package/dist/hub/directory/admission.js.map +1 -0
  181. package/dist/hub/directory/directory.d.ts +1 -1
  182. package/dist/hub/directory/directory.js +114 -0
  183. package/dist/hub/directory/directory.js.map +1 -1
  184. package/dist/hub/directory/types.d.ts +27 -0
  185. package/dist/hub/directory/types.js.map +1 -1
  186. package/dist/hub/enrolment-code.d.ts +1 -1
  187. package/dist/hub/enrolment-code.js +4 -4
  188. package/dist/hub/enrolment-code.js.map +1 -1
  189. package/dist/hub/grant-access.d.ts +11 -0
  190. package/dist/hub/grant-access.js +113 -0
  191. package/dist/hub/grant-access.js.map +1 -0
  192. package/dist/hub/grant-search.d.ts +9 -0
  193. package/dist/hub/grant-search.js +92 -0
  194. package/dist/hub/grant-search.js.map +1 -0
  195. package/dist/hub/group-policy/admin-control.d.ts +1 -0
  196. package/dist/hub/group-policy/admin-control.js +4 -2
  197. package/dist/hub/group-policy/admin-control.js.map +1 -1
  198. package/dist/hub/group-policy/admin-facts.d.ts +1 -0
  199. package/dist/hub/group-policy/admin-facts.js +2 -1
  200. package/dist/hub/group-policy/admin-facts.js.map +1 -1
  201. package/dist/hub/group-policy/admin-impact.d.ts +2 -0
  202. package/dist/hub/group-policy/admin-impact.js +10 -2
  203. package/dist/hub/group-policy/admin-impact.js.map +1 -1
  204. package/dist/hub/group-policy/admin-inventory.js +1 -1
  205. package/dist/hub/group-policy/admin-inventory.js.map +1 -1
  206. package/dist/hub/group-policy/admin-read.d.ts +1 -0
  207. package/dist/hub/group-policy/admin-read.js +3 -2
  208. package/dist/hub/group-policy/admin-read.js.map +1 -1
  209. package/dist/hub/group-policy/authorization.d.ts +5 -2
  210. package/dist/hub/group-policy/authorization.js +73 -32
  211. package/dist/hub/group-policy/authorization.js.map +1 -1
  212. package/dist/hub/group-policy/errors.d.ts +9 -0
  213. package/dist/hub/group-policy/errors.js +13 -0
  214. package/dist/hub/group-policy/errors.js.map +1 -0
  215. package/dist/hub/group-policy/impact-inventory.js +20 -4
  216. package/dist/hub/group-policy/impact-inventory.js.map +1 -1
  217. package/dist/hub/group-policy/resources.d.ts +4 -5
  218. package/dist/hub/group-policy/resources.js +26 -19
  219. package/dist/hub/group-policy/resources.js.map +1 -1
  220. package/dist/hub/group-policy/store.d.ts +21 -12
  221. package/dist/hub/group-policy/store.js +99 -109
  222. package/dist/hub/group-policy/store.js.map +1 -1
  223. package/dist/hub/group-policy/welcome.js.map +1 -1
  224. package/dist/hub/http/compose.d.ts +1 -0
  225. package/dist/hub/http/compose.js +463 -20
  226. package/dist/hub/http/compose.js.map +1 -1
  227. package/dist/hub/http/core.d.ts +24 -5
  228. package/dist/hub/http/core.js +181 -54
  229. package/dist/hub/http/core.js.map +1 -1
  230. package/dist/hub/http/deps.d.ts +26 -0
  231. package/dist/hub/http/schema.js +19 -0
  232. package/dist/hub/http/schema.js.map +1 -1
  233. package/dist/hub/init/member-certificate.d.ts +1 -0
  234. package/dist/hub/init/member-certificate.js +39 -0
  235. package/dist/hub/init/member-certificate.js.map +1 -0
  236. package/dist/hub/init/plan-digest.js +1 -0
  237. package/dist/hub/init/plan-digest.js.map +1 -1
  238. package/dist/hub/invitations.d.ts +96 -0
  239. package/dist/hub/invitations.js +292 -0
  240. package/dist/hub/invitations.js.map +1 -0
  241. package/dist/hub/join/certificate-trust.d.ts +13 -0
  242. package/dist/hub/join/certificate-trust.js +41 -0
  243. package/dist/hub/join/certificate-trust.js.map +1 -0
  244. package/dist/hub/join/certificate.d.ts +11 -0
  245. package/dist/hub/join/certificate.js +67 -0
  246. package/dist/hub/join/certificate.js.map +1 -0
  247. package/dist/hub/join/client.d.ts +5 -0
  248. package/dist/hub/join/client.js +30 -3
  249. package/dist/hub/join/client.js.map +1 -1
  250. package/dist/hub/join/http.js +5 -3
  251. package/dist/hub/join/http.js.map +1 -1
  252. package/dist/hub/join/local.d.ts +37 -1
  253. package/dist/hub/join/local.js +142 -14
  254. package/dist/hub/join/local.js.map +1 -1
  255. package/dist/hub/join/service.d.ts +19 -0
  256. package/dist/hub/join/service.js +46 -35
  257. package/dist/hub/join/service.js.map +1 -1
  258. package/dist/hub/join/trust.d.ts +9 -0
  259. package/dist/hub/join/trust.js +35 -0
  260. package/dist/hub/join/trust.js.map +1 -1
  261. package/dist/hub/member/pairing-api.js +12 -1
  262. package/dist/hub/member/pairing-api.js.map +1 -1
  263. package/dist/hub/member/room-ask.d.ts +137 -0
  264. package/dist/hub/member/room-ask.js +358 -0
  265. package/dist/hub/member/room-ask.js.map +1 -0
  266. package/dist/hub/member-journal.d.ts +18 -1
  267. package/dist/hub/member-journal.js +76 -3
  268. package/dist/hub/member-journal.js.map +1 -1
  269. package/dist/hub/member-origin.d.ts +177 -0
  270. package/dist/hub/member-origin.js +314 -0
  271. package/dist/hub/member-origin.js.map +1 -0
  272. package/dist/hub/pairing-notices.d.ts +1 -0
  273. package/dist/hub/pairing-notices.js +2 -1
  274. package/dist/hub/pairing-notices.js.map +1 -1
  275. package/dist/hub/pairing.d.ts +11 -0
  276. package/dist/hub/pairing.js +69 -21
  277. package/dist/hub/pairing.js.map +1 -1
  278. package/dist/hub/policy.d.ts +1 -1
  279. package/dist/hub/policy.js +19 -6
  280. package/dist/hub/policy.js.map +1 -1
  281. package/dist/hub/protocol.d.ts +172 -0
  282. package/dist/hub/protocol.js +25 -2
  283. package/dist/hub/protocol.js.map +1 -1
  284. package/dist/hub/quota.d.ts +2 -1
  285. package/dist/hub/quota.js +2 -2
  286. package/dist/hub/quota.js.map +1 -1
  287. package/dist/hub/roles/authority.d.ts +45 -0
  288. package/dist/hub/roles/authority.js +199 -0
  289. package/dist/hub/roles/authority.js.map +1 -0
  290. package/dist/hub/roles/change.d.ts +18 -0
  291. package/dist/hub/roles/change.js +76 -0
  292. package/dist/hub/roles/change.js.map +1 -0
  293. package/dist/hub/roles/clock.d.ts +18 -0
  294. package/dist/hub/roles/clock.js +58 -0
  295. package/dist/hub/roles/clock.js.map +1 -0
  296. package/dist/hub/roles/convert.d.ts +11 -0
  297. package/dist/hub/roles/convert.js +27 -0
  298. package/dist/hub/roles/convert.js.map +1 -0
  299. package/dist/hub/roles/cutover-inventory.d.ts +14 -0
  300. package/dist/hub/roles/cutover-inventory.js +42 -0
  301. package/dist/hub/roles/cutover-inventory.js.map +1 -0
  302. package/dist/hub/roles/cutover-marker.d.ts +57 -0
  303. package/dist/hub/roles/cutover-marker.js +26 -0
  304. package/dist/hub/roles/cutover-marker.js.map +1 -0
  305. package/dist/hub/roles/cutover.d.ts +32 -0
  306. package/dist/hub/roles/cutover.js +170 -0
  307. package/dist/hub/roles/cutover.js.map +1 -0
  308. package/dist/hub/roles/delegation.d.ts +24 -0
  309. package/dist/hub/roles/delegation.js +111 -0
  310. package/dist/hub/roles/delegation.js.map +1 -0
  311. package/dist/hub/roles/evaluate.d.ts +50 -0
  312. package/dist/hub/roles/evaluate.js +96 -0
  313. package/dist/hub/roles/evaluate.js.map +1 -0
  314. package/dist/hub/roles/expiry.d.ts +46 -0
  315. package/dist/hub/roles/expiry.js +180 -0
  316. package/dist/hub/roles/expiry.js.map +1 -0
  317. package/dist/hub/roles/mode-effects.d.ts +5 -0
  318. package/dist/hub/roles/mode-effects.js +21 -0
  319. package/dist/hub/roles/mode-effects.js.map +1 -0
  320. package/dist/hub/roles/model.d.ts +171 -0
  321. package/dist/hub/roles/model.js +79 -0
  322. package/dist/hub/roles/model.js.map +1 -0
  323. package/dist/hub/roles/read.d.ts +33 -0
  324. package/dist/hub/roles/read.js +55 -0
  325. package/dist/hub/roles/read.js.map +1 -0
  326. package/dist/hub/roles/writer.d.ts +80 -0
  327. package/dist/hub/roles/writer.js +427 -0
  328. package/dist/hub/roles/writer.js.map +1 -0
  329. package/dist/hub/rooms/admin.d.ts +45 -0
  330. package/dist/hub/rooms/admin.js +105 -0
  331. package/dist/hub/rooms/admin.js.map +1 -0
  332. package/dist/hub/rooms/agents.d.ts +74 -0
  333. package/dist/hub/rooms/agents.js +333 -0
  334. package/dist/hub/rooms/agents.js.map +1 -0
  335. package/dist/hub/rooms/assistant.d.ts +44 -0
  336. package/dist/hub/rooms/assistant.js +179 -0
  337. package/dist/hub/rooms/assistant.js.map +1 -0
  338. package/dist/hub/rooms/context.d.ts +10 -0
  339. package/dist/hub/rooms/context.js +24 -0
  340. package/dist/hub/rooms/context.js.map +1 -0
  341. package/dist/hub/rooms/direct-view.d.ts +39 -0
  342. package/dist/hub/rooms/direct-view.js +38 -0
  343. package/dist/hub/rooms/direct-view.js.map +1 -0
  344. package/dist/hub/rooms/directory.d.ts +35 -0
  345. package/dist/hub/rooms/directory.js +98 -0
  346. package/dist/hub/rooms/directory.js.map +1 -0
  347. package/dist/hub/rooms/schema.d.ts +11 -0
  348. package/dist/hub/rooms/schema.js +73 -0
  349. package/dist/hub/rooms/schema.js.map +1 -0
  350. package/dist/hub/rooms/service.d.ts +449 -0
  351. package/dist/hub/rooms/service.js +581 -0
  352. package/dist/hub/rooms/service.js.map +1 -0
  353. package/dist/hub/rooms/types.d.ts +79 -0
  354. package/dist/hub/rooms/types.js +2 -0
  355. package/dist/hub/rooms/types.js.map +1 -0
  356. package/dist/hub/rooms.d.ts +15 -1
  357. package/dist/hub/rooms.js +76 -31
  358. package/dist/hub/rooms.js.map +1 -1
  359. package/dist/hub/runtime.d.ts +8 -0
  360. package/dist/hub/runtime.js +57 -3
  361. package/dist/hub/runtime.js.map +1 -1
  362. package/dist/hub/server.d.ts +28 -0
  363. package/dist/hub/server.js +66 -6
  364. package/dist/hub/server.js.map +1 -1
  365. package/dist/hub/sessions.js +6 -2
  366. package/dist/hub/sessions.js.map +1 -1
  367. package/dist/hub/settings-commit.d.ts +6 -1
  368. package/dist/hub/settings-commit.js +15 -0
  369. package/dist/hub/settings-commit.js.map +1 -1
  370. package/dist/hub/settings-directory-decision.d.ts +2 -2
  371. package/dist/hub/settings-directory-decision.js +7 -5
  372. package/dist/hub/settings-directory-decision.js.map +1 -1
  373. package/dist/hub/settings-directory-proof.js +3 -1
  374. package/dist/hub/settings-directory-proof.js.map +1 -1
  375. package/dist/hub/settings-directory-recovery.d.ts +5 -0
  376. package/dist/hub/settings-directory-recovery.js +14 -4
  377. package/dist/hub/settings-directory-recovery.js.map +1 -1
  378. package/dist/hub/settings-member-address-control.d.ts +84 -0
  379. package/dist/hub/settings-member-address-control.js +150 -0
  380. package/dist/hub/settings-member-address-control.js.map +1 -0
  381. package/dist/hub/settings-member-address-decision.d.ts +229 -0
  382. package/dist/hub/settings-member-address-decision.js +318 -0
  383. package/dist/hub/settings-member-address-decision.js.map +1 -0
  384. package/dist/hub/settings-member-address-http.d.ts +9 -0
  385. package/dist/hub/settings-member-address-http.js +78 -0
  386. package/dist/hub/settings-member-address-http.js.map +1 -0
  387. package/dist/hub/settings-member-address-network.d.ts +2 -0
  388. package/dist/hub/settings-member-address-network.js +22 -0
  389. package/dist/hub/settings-member-address-network.js.map +1 -0
  390. package/dist/hub/settings-member-address-notices.d.ts +22 -0
  391. package/dist/hub/settings-member-address-notices.js +21 -0
  392. package/dist/hub/settings-member-address-notices.js.map +1 -0
  393. package/dist/hub/settings-member-address-policy.d.ts +21 -0
  394. package/dist/hub/settings-member-address-policy.js +34 -0
  395. package/dist/hub/settings-member-address-policy.js.map +1 -0
  396. package/dist/hub/settings-member-address.d.ts +64 -0
  397. package/dist/hub/settings-member-address.js +239 -0
  398. package/dist/hub/settings-member-address.js.map +1 -0
  399. package/dist/hub/sharing.d.ts +10 -0
  400. package/dist/hub/sharing.js +74 -0
  401. package/dist/hub/sharing.js.map +1 -0
  402. package/dist/hub/socket.d.ts +2 -0
  403. package/dist/hub/socket.js +2 -0
  404. package/dist/hub/socket.js.map +1 -1
  405. package/dist/hub/store.js +6 -2
  406. package/dist/hub/store.js.map +1 -1
  407. package/dist/hub/teams/types.d.ts +41 -0
  408. package/dist/hub/teams/types.js +2 -0
  409. package/dist/hub/teams/types.js.map +1 -0
  410. package/dist/hub/tls.d.ts +47 -0
  411. package/dist/hub/tls.js +23 -6
  412. package/dist/hub/tls.js.map +1 -1
  413. package/dist/hub/types.d.ts +68 -4
  414. package/dist/hub/validation.d.ts +1 -1
  415. package/dist/hub/validation.js +2 -2
  416. package/dist/hub/validation.js.map +1 -1
  417. package/dist/hub/web-origin.d.ts +93 -0
  418. package/dist/hub/web-origin.js +174 -0
  419. package/dist/hub/web-origin.js.map +1 -0
  420. package/dist/hub-pilot-trust-settings.d.ts +4 -0
  421. package/dist/hub-pilot-trust-settings.js +13 -0
  422. package/dist/hub-pilot-trust-settings.js.map +1 -0
  423. package/dist/human-delivery-receipts.d.ts +4 -2
  424. package/dist/human-delivery-receipts.js +20 -13
  425. package/dist/human-delivery-receipts.js.map +1 -1
  426. package/dist/inbound-presentation.d.ts +28 -0
  427. package/dist/inbound-presentation.js +48 -0
  428. package/dist/inbound-presentation.js.map +1 -0
  429. package/dist/instance-lifecycle.d.ts +13 -1
  430. package/dist/instance-lifecycle.js +33 -10
  431. package/dist/instance-lifecycle.js.map +1 -1
  432. package/dist/instructions.d.ts +10 -2
  433. package/dist/instructions.js +32 -7
  434. package/dist/instructions.js.map +1 -1
  435. package/dist/locale.js +20 -6
  436. package/dist/locale.js.map +1 -1
  437. package/dist/log-service.d.ts +3 -0
  438. package/dist/log-service.js +39 -22
  439. package/dist/log-service.js.map +1 -1
  440. package/dist/log-steps.d.ts +56 -1
  441. package/dist/log-steps.js +318 -56
  442. package/dist/log-steps.js.map +1 -1
  443. package/dist/login-flows.d.ts +24 -2
  444. package/dist/login-flows.js +53 -22
  445. package/dist/login-flows.js.map +1 -1
  446. package/dist/login-url.js +3 -0
  447. package/dist/login-url.js.map +1 -1
  448. package/dist/machine-accounts.d.ts +42 -12
  449. package/dist/machine-accounts.js +144 -46
  450. package/dist/machine-accounts.js.map +1 -1
  451. package/dist/machine-signins.d.ts +35 -13
  452. package/dist/machine-signins.js +57 -27
  453. package/dist/machine-signins.js.map +1 -1
  454. package/dist/native-instance-input.js +4 -4
  455. package/dist/native-instance-input.js.map +1 -1
  456. package/dist/native-instance-registry.d.ts +3 -3
  457. package/dist/native-instance-registry.js +11 -10
  458. package/dist/native-instance-registry.js.map +1 -1
  459. package/dist/needs-you-hub.js +6 -2
  460. package/dist/needs-you-hub.js.map +1 -1
  461. package/dist/needs-you.d.ts +5 -1
  462. package/dist/needs-you.js +4 -8
  463. package/dist/needs-you.js.map +1 -1
  464. package/dist/office-share-page.js +1 -1
  465. package/dist/office-share-page.js.map +1 -1
  466. package/dist/outbound-handlers.d.ts +1 -0
  467. package/dist/outbound-handlers.js +25 -19
  468. package/dist/outbound-handlers.js.map +1 -1
  469. package/dist/outbound-schemas.d.ts +19 -0
  470. package/dist/outbound-schemas.js +23 -4
  471. package/dist/outbound-schemas.js.map +1 -1
  472. package/dist/profile-signins.d.ts +5 -0
  473. package/dist/profile-signins.js +1 -0
  474. package/dist/profile-signins.js.map +1 -1
  475. package/dist/queued-handoffs.d.ts +3 -1
  476. package/dist/queued-handoffs.js +1 -1
  477. package/dist/queued-handoffs.js.map +1 -1
  478. package/dist/runtime-build-info.js +6 -2
  479. package/dist/runtime-build-info.js.map +1 -1
  480. package/dist/runtime-cli.js +33 -11
  481. package/dist/runtime-cli.js.map +1 -1
  482. package/dist/runtime-client.d.ts +18 -2
  483. package/dist/runtime-client.js +84 -21
  484. package/dist/runtime-client.js.map +1 -1
  485. package/dist/runtime-credential-profiles.d.ts +36 -4
  486. package/dist/runtime-credential-profiles.js +82 -16
  487. package/dist/runtime-credential-profiles.js.map +1 -1
  488. package/dist/runtime-profile-ownership.d.ts +2 -2
  489. package/dist/runtime-profile-ownership.js +3 -3
  490. package/dist/runtime-profile-ownership.js.map +1 -1
  491. package/dist/runtime-protocol.d.ts +5 -3
  492. package/dist/runtime-protocol.js +4 -0
  493. package/dist/runtime-protocol.js.map +1 -1
  494. package/dist/runtime-remote-accounts.d.ts +72 -5
  495. package/dist/runtime-remote-accounts.js +293 -52
  496. package/dist/runtime-remote-accounts.js.map +1 -1
  497. package/dist/runtime-remote-setup.d.ts +2 -2
  498. package/dist/runtime-remote-setup.js +2 -2
  499. package/dist/runtime-remote-setup.js.map +1 -1
  500. package/dist/runtime-signin-transport.d.ts +22 -4
  501. package/dist/runtime-signin-transport.js +50 -12
  502. package/dist/runtime-signin-transport.js.map +1 -1
  503. package/dist/runtime-signin.d.ts +42 -0
  504. package/dist/runtime-signin.js +105 -9
  505. package/dist/runtime-signin.js.map +1 -1
  506. package/dist/runtime-transcript-source.d.ts +2 -0
  507. package/dist/runtime-transcript-source.js +23 -1
  508. package/dist/runtime-transcript-source.js.map +1 -1
  509. package/dist/runtime-windows-bridge.js +6 -1
  510. package/dist/runtime-windows-bridge.js.map +1 -1
  511. package/dist/scheduler/task-board.d.ts +1 -0
  512. package/dist/scheduler/task-board.js +10 -1
  513. package/dist/scheduler/task-board.js.map +1 -1
  514. package/dist/settings-api.d.ts +1 -0
  515. package/dist/settings-api.js +15 -8
  516. package/dist/settings-api.js.map +1 -1
  517. package/dist/settings-baseline.d.ts +3 -0
  518. package/dist/settings-baseline.js +2 -2
  519. package/dist/settings-baseline.js.map +1 -1
  520. package/dist/settings-effect.d.ts +3 -0
  521. package/dist/settings-effect.js +12 -2
  522. package/dist/settings-effect.js.map +1 -1
  523. package/dist/signin-keepalive.d.ts +31 -2
  524. package/dist/signin-keepalive.js +123 -12
  525. package/dist/signin-keepalive.js.map +1 -1
  526. package/dist/structured-signin-transport.d.ts +2 -2
  527. package/dist/structured-signin-transport.js +27 -6
  528. package/dist/structured-signin-transport.js.map +1 -1
  529. package/dist/structured-signin.d.ts +16 -2
  530. package/dist/structured-signin.js +59 -4
  531. package/dist/structured-signin.js.map +1 -1
  532. package/dist/task-board-tool.d.ts +0 -13
  533. package/dist/task-board-tool.js +42 -6
  534. package/dist/task-board-tool.js.map +1 -1
  535. package/dist/tool-receipt-output.d.ts +151 -0
  536. package/dist/tool-receipt-output.js +50 -0
  537. package/dist/tool-receipt-output.js.map +1 -0
  538. package/dist/topic-commands.js +2 -1
  539. package/dist/topic-commands.js.map +1 -1
  540. package/dist/transcript-jsonl.d.ts +24 -0
  541. package/dist/transcript-jsonl.js +72 -22
  542. package/dist/transcript-jsonl.js.map +1 -1
  543. package/dist/transcript-monitor.d.ts +5 -1
  544. package/dist/transcript-monitor.js +65 -3
  545. package/dist/transcript-monitor.js.map +1 -1
  546. package/dist/transcript-needles.d.ts +1 -1
  547. package/dist/transcript-needles.js +1 -1
  548. package/dist/transcript-records.d.ts +2 -1
  549. package/dist/transcript-records.js.map +1 -1
  550. package/dist/transcript-sources.d.ts +4 -0
  551. package/dist/transcript-sources.js +2 -0
  552. package/dist/transcript-sources.js.map +1 -1
  553. package/dist/ui/accounts-keepalive.js +15 -6
  554. package/dist/ui/accounts-manage.js +25 -5
  555. package/dist/ui/accounts-view.js +28 -24
  556. package/dist/ui/agent-details-settings.js +10 -1
  557. package/dist/ui/agent-proposals.js +22 -2
  558. package/dist/ui/agent-runtime-settings.js +3 -3
  559. package/dist/ui/backend-signin.js +4 -4
  560. package/dist/ui/chat-activity.js +2 -2
  561. package/dist/ui/cli-caps.js +7 -7
  562. package/dist/ui/credential-profile-select.js +32 -19
  563. package/dist/ui/fleet-canvas.js +5 -2
  564. package/dist/ui/fleet-office-card.js +4 -2
  565. package/dist/ui/fleet-org.js +2 -0
  566. package/dist/ui/hub-admin-rooms-strings.js +28 -0
  567. package/dist/ui/hub-admin-rooms.js +77 -0
  568. package/dist/ui/hub-assistant-admin-strings.js +26 -0
  569. package/dist/ui/hub-assistant-admin.js +85 -0
  570. package/dist/ui/hub-chat-store.js +8 -4
  571. package/dist/ui/hub-client.js +224 -33
  572. package/dist/ui/hub-enrolment-code.js +1 -1
  573. package/dist/ui/hub-grant-picker.js +100 -0
  574. package/dist/ui/hub-group-search.js +2 -2
  575. package/dist/ui/hub-invitations-strings.js +30 -0
  576. package/dist/ui/hub-invitations.js +108 -0
  577. package/dist/ui/hub-join-one-strings.js +4 -2
  578. package/dist/ui/hub-join-steps.js +5 -2
  579. package/dist/ui/hub-pairing-form-strings.js +48 -0
  580. package/dist/ui/hub-pilot-trust-strings.js +27 -0
  581. package/dist/ui/hub-pilot-trust.js +41 -0
  582. package/dist/ui/hub-room-composer.js +113 -0
  583. package/dist/ui/hub-room-favorites.js +90 -0
  584. package/dist/ui/hub-room-list.js +152 -0
  585. package/dist/ui/hub-room-members-strings.js +12 -0
  586. package/dist/ui/hub-room-members.js +104 -0
  587. package/dist/ui/hub-room-new-strings.js +46 -0
  588. package/dist/ui/hub-room-new.js +135 -0
  589. package/dist/ui/hub-room-presence.js +123 -0
  590. package/dist/ui/hub-room-settings-strings.js +26 -0
  591. package/dist/ui/hub-room-settings.js +134 -0
  592. package/dist/ui/hub-room-strings.js +222 -0
  593. package/dist/ui/hub-room-thread.js +262 -0
  594. package/dist/ui/hub-room-unread.js +51 -0
  595. package/dist/ui/hub-room-working.js +29 -0
  596. package/dist/ui/log-row.js +14 -5
  597. package/dist/ui/machine-signin.js +47 -14
  598. package/dist/ui/panel-details.js +6 -1
  599. package/dist/ui/panel-fleet.js +2 -2
  600. package/dist/ui/panel-hub.js +145 -59
  601. package/dist/ui/panel-needs.js +2 -0
  602. package/dist/ui/panel-settings.js +2 -2
  603. package/dist/ui/settings-hub-company-join.js +32 -11
  604. package/dist/ui/settings-hub-connection.js +9 -3
  605. package/dist/ui/settings-hub-member-address.js +205 -0
  606. package/dist/ui/settings-hub-section.js +4 -0
  607. package/dist/ui/settings-hub-web-address.js +233 -0
  608. package/dist/ui/settings-hub.js +16 -4
  609. package/dist/ui/shared/accounts-keepalive.css +8 -0
  610. package/dist/ui/shared/accounts-usage-pool.css +10 -0
  611. package/dist/ui/shared/accounts.css +9 -0
  612. package/dist/ui/shared/app-i18n.js +2 -2
  613. package/dist/ui/shared/app-needs.js +3 -0
  614. package/dist/ui/shared/app-shell.js +4 -1
  615. package/dist/ui/shared/app.css +43 -5
  616. package/dist/ui/shared/chat-render.js +10 -0
  617. package/dist/ui/shared/chat-thread.js +14 -5
  618. package/dist/ui/shared/hub-chat.css +17 -0
  619. package/dist/ui/shared/hub-grant-picker.css +4 -0
  620. package/dist/ui/shared/hub-rooms-u2.css +42 -0
  621. package/dist/ui/shared/hub-sharing.css +4 -0
  622. package/dist/ui/shared/model-observation.js +16 -0
  623. package/dist/ui/shared/stale-tab.css +6 -0
  624. package/dist/ui/shared/stale-tab.js +50 -0
  625. package/dist/ui/shared/view-strings.js +2 -2
  626. package/dist/ui/structured-signin.js +19 -6
  627. package/dist/ui/usage-pool.js +76 -0
  628. package/dist/usage/agent-output.d.ts +144 -0
  629. package/dist/usage/agent-output.js +75 -0
  630. package/dist/usage/agent-output.js.map +1 -0
  631. package/dist/usage/provider-alerts.d.ts +6 -0
  632. package/dist/usage/provider-alerts.js +6 -0
  633. package/dist/usage/provider-alerts.js.map +1 -1
  634. package/dist/usage/providers.d.ts +2 -2
  635. package/dist/usage/providers.js +60 -18
  636. package/dist/usage/providers.js.map +1 -1
  637. package/dist/usage/usage-api.d.ts +12 -0
  638. package/dist/usage/usage-api.js +39 -0
  639. package/dist/usage/usage-api.js.map +1 -1
  640. package/dist/web-api.d.ts +4 -0
  641. package/dist/web-api.js +32 -13
  642. package/dist/web-api.js.map +1 -1
  643. package/dist/web-backend-login.d.ts +4 -1
  644. package/dist/web-backend-login.js.map +1 -1
  645. package/dist/windows-cli-providers.js +5 -1
  646. package/dist/windows-cli-providers.js.map +1 -1
  647. package/dist/windows-cli-worker.d.ts +33 -1
  648. package/dist/windows-cli-worker.js +150 -10
  649. package/dist/windows-cli-worker.js.map +1 -1
  650. package/dist/windows-cli.d.ts +7 -1
  651. package/dist/windows-cli.js +19 -2
  652. package/dist/windows-cli.js.map +1 -1
  653. package/dist/workflow-templates/default.md +2 -2
  654. package/package.json +1 -1
@@ -22,6 +22,7 @@ import { WorkingRecoveryCoordinator, WORKING_RECOVERY_KIND, buildWorkingRecovery
22
22
  import { PUBLIC_TUNNEL_TOKEN_ENV, PUBLIC_TUNNEL_TOKEN_HINT, normalizePublicTunnelToken } from "./public-tunnel-config.js";
23
23
  import { humanOwnerObjectId, webHumanOrigin } from "./human-delivery-receipts.js";
24
24
  import { SettingsBaselines } from "./settings-baseline.js";
25
+ import { hubPilotTrustSettings } from "./hub-pilot-trust-settings.js";
25
26
  import { hubMembershipSettings } from "./hub-membership-settings.js";
26
27
  import { prepareSettingsEffect } from "./settings-effect.js";
27
28
  import { settingsDisplay } from "./settings-change.js";
@@ -104,7 +105,7 @@ import { getEffectiveInstanceDefaults, loadFleetConfig, loadRawFleetConfig, load
104
105
  import { EventLog } from "./event-log.js";
105
106
  import { binaryProbe } from "./binary-probe.js";
106
107
  import { deletePlannedTopic, planInstanceTopicDelete, topicDestination, topicMustStay } from "./instance-topic-delete.js";
107
- import { AVAILABILITY_STALE_MS, BackendAvailabilityStore, hostAvailabilityProbes, findExecutableIn, resolveBackendBinary } from "./backend-availability.js";
108
+ import { AVAILABILITY_STALE_MS, BackendAvailabilityStore, versionAtLeast, hostAvailabilityProbes, findExecutableIn, resolveBackendBinary } from "./backend-availability.js";
108
109
  import { classifySqliteOpenError } from "./sqlite-open-errors.js";
109
110
  import { OutboxOpenError } from "./outbox-open-error.js";
110
111
  import { AdapterWorld } from "./adapter-world.js";
@@ -266,8 +267,11 @@ import { envFileKeys } from "./token-env-name.js";
266
267
  import { discordGeneralChannelId } from "./discord-general.js";
267
268
  import { parseEnvText } from "./env-file.js";
268
269
  import { isDisallowedIntentsError, isRejectedTokenError } from "./discord-permissions.js";
269
- import { filterUsageProviders, formatDiscordUsageActivity, getUsageSnapshot, handleUsageRequest, isUsagePath, setCapacityLookup, usageProviderIdForBackend } from "./usage/usage-api.js";
270
- import { LOGIN_FLOWS, checkAuthStatus, checkAuthIdentity, authIdentitySupported, LOGIN_BACKEND_ALIASES } from "./login-flows.js";
270
+ import { filterUsageProviders, formatDiscordUsageActivity, getUsageSnapshot, handleUsageRequest, isUsagePath, refreshUsageAfterSignIn, setCapacityLookup, usageProviderIdForBackend } from "./usage/usage-api.js";
271
+ import { LOGIN_FLOWS, checkAuthStatus, checkAuthSignedOut, checkAuthIdentity, authIdentitySupported, LOGIN_BACKEND_ALIASES } from "./login-flows.js";
272
+ import { structuredSignInSupported } from "./structured-signin.js";
273
+ import { proveFolderIsolation } from "./account-isolation.js";
274
+ import { STRUCTURED_PROFILE_BACKENDS } from "./structured-signin-transport.js";
271
275
  import { LoginSession } from "./login-manager.js";
272
276
  import { runOnLoginShell } from "./login-shell.js";
273
277
  import { tightenInstanceDirs } from "./private-dir.js";
@@ -292,8 +296,8 @@ import { runBeforeDeadline } from "./deadline.js";
292
296
  import { LoginWindowLock } from "./login-window-lock.js";
293
297
  import { BrowserBackendSignIns } from "./browser-backend-signins.js";
294
298
  import { createStructuredSignInTransport } from "./structured-signin-transport.js";
295
- import { ONBOARDING_BACKENDS, readPendingBackendSignIns } from "./backend-signin-pending.js";
296
- import { structuredSignInSupported } from "./structured-signin.js";
299
+ import { ONBOARDING_BACKENDS, ONBOARDING_BROWSER_BACKENDS, readPendingBackendSignIns } from "./backend-signin-pending.js";
300
+ import { hostFacts, runtimeAccountsCapability, runtimeFacts } from "./cli-registry.js";
297
301
  import { handleSettingsRequest, switchClassicRoomProfile } from "./settings-api.js";
298
302
  import { setLocale, detectLocale, getLocale, t } from "./locale.js";
299
303
  import { remoteCardAction, remoteCardChoiceLabel, remoteCardOutcomeText, remoteCardPrompt, REMOTE_CARD_TEXT_MAX } from "./remote-card-prompt.js";
@@ -352,6 +356,7 @@ import { AuthorityStateStore } from "./authority/authority-state.js";
352
356
  import { SessionAuthorizations } from "./authority/session-authorizations.js";
353
357
  import { SessionAuthorizationRequests } from "./web-session-authorization.js";
354
358
  import { GuestLoginCodes, WebLoginCodes, LOGIN_CODE_TTL_MS } from "./web-login.js";
359
+ import { listOptions, scheduleListAnswer, taskListAnswer, taskTitle } from "./agent-list-output.js";
355
360
  import { decisionListAnswer } from "./decision-list.js";
356
361
  import { CodeRequestLimiter, ReturningDevices } from "./web-returning-device.js";
357
362
  import { hubInitializationSession } from "./authority/hub-initialization.js";
@@ -370,10 +375,10 @@ import { PROVIDER_SECRET_SPECS, PUBLIC_TUNNEL_SECRET_SPEC, providerSecretSpec, p
370
375
  const SELF_RESTART_DEADLINE_MS = 300_000;
371
376
  import { APPLY_FLEET_TARGET, ApplyJobStore, viewOf, } from "./apply-job.js";
372
377
  import { kiroHome } from "./backend/kiro-kas-store.js";
373
- import { CHAT_PROFILE_LOGIN_BACKENDS, claudeStoreEnded, credentialHomeSpec, credentialProfileHome, credentialProfileEnv, credentialProfileLogin, credentialProfileLoginCommand, credentialProfileStoreHome, credentialSwitchCarriesConversation, credentialSwitchStartsFresh, instanceCredentialProfile, listConfiguredProfiles, resolveCredentialProfile } from "./backend/credential-profile.js";
378
+ import { CHAT_PROFILE_LOGIN_BACKENDS, claudeStoreEnded, credentialHomeSpec, credentialProfileHome, credentialProfileLaunch, credentialProfileLogin, credentialProfileLoginCommand, credentialProfileStoreHome, credentialSwitchCarriesConversation, credentialSwitchStartsFresh, instanceCredentialProfile, listConfiguredProfiles, resolveCredentialProfile } from "./backend/credential-profile.js";
374
379
  import { carryClaudeConversation } from "./backend/claude-carry.js";
375
380
  import { classicProfile, mergeBackendOptions, profileKey, profileName, profileOf, readClassicBindings, readClassicBindingsStrict } from "./classic-bindings.js";
376
- import { ACCOUNT_CLIS, PROFILE_CLIS, buildAccountsView, profilesOnDisk, shortUsage, weeklyUsage } from "./accounts-view.js";
381
+ import { ACCOUNT_CLIS, PROFILE_CLIS, accountUsage, buildAccountsView, profilesOnDisk } from "./accounts-view.js";
377
382
  import { accountFolderExists, addAccountProfile, removeAccountProfile } from "./accounts-profiles.js";
378
383
  import { signOutAccount } from "./accounts-signout.js";
379
384
  import { MachineAccounts, machineAgents } from "./machine-accounts.js";
@@ -1065,13 +1070,17 @@ export class FleetManager {
1065
1070
  throw new Error("This runtime CLI cannot enforce read-only execution");
1066
1071
  if (credentialProfile !== undefined) {
1067
1072
  // Fail closed at selection time, not at the first message: an old Runtime would ignore the name and run another account.
1068
- if (!machine.runtimeInfo?.capabilities.includes(RUNTIME_CREDENTIAL_CAPABILITY))
1069
- throw new Error("This computer's Runtime is too old to choose a Claude account. Update the Runtime on that computer, then try again.");
1070
- const row = machine.inventory?.credentialProfiles?.profiles.find(profile => profile.name === credentialProfile);
1073
+ const product = cli === "claude-code" ? "Claude" : (runtimeFacts(cli, "provider")?.name ?? cli);
1074
+ if (!machine.runtimeInfo?.capabilities.includes(RUNTIME_CREDENTIAL_CAPABILITY) || (cli !== "claude-code" && !machine.runtimeInfo.capabilities.includes(runtimeAccountsCapability(cli))))
1075
+ throw new Error(`This computer's Runtime is too old to choose a ${product} account. Update the Runtime on that computer, then try again.`);
1076
+ // Claude Code's profiles are the report's `profiles`; another CLI's (Antigravity) are its `byCli`.
1077
+ const reported = cli === "claude-code" ? machine.inventory?.credentialProfiles?.profiles : machine.inventory?.credentialProfiles?.byCli?.[cli];
1078
+ const row = reported?.find(profile => profile.name === credentialProfile);
1079
+ const hint = cli === "claude-code" ? `On that computer run: agend-runtime login claude-code ${credentialProfile}, then choose Detect again in that computer's CLI diagnostics (Settings → Runtime).` : "Add it in Settings → Agent → Accounts, under that computer's name.";
1071
1080
  if (!row)
1072
- throw new Error(`This computer has not reported a credential profile named "${credentialProfile}". On that computer run: agend-runtime login claude-code ${credentialProfile}, then choose Detect again in that computer's CLI diagnostics (Settings → Runtime).`);
1081
+ throw new Error(`This computer has not reported a credential profile named "${credentialProfile}". ${hint}`);
1073
1082
  if (row.loggedIn === false)
1074
- throw new Error(`Credential profile "${credentialProfile}" is not signed in on that computer. Sign in there: agend-runtime login claude-code ${credentialProfile}`);
1083
+ throw new Error(`Credential profile "${credentialProfile}" is not signed in on that computer. ${cli === "claude-code" ? `Sign in there: agend-runtime login claude-code ${credentialProfile}` : "Sign it in from Settings → Agent → Accounts."}`);
1075
1084
  }
1076
1085
  },
1077
1086
  emit: (event, data) => {
@@ -1553,6 +1562,20 @@ export class FleetManager {
1553
1562
  }
1554
1563
  return this.hubWebAddressControl;
1555
1564
  }
1565
+ hubMemberAddressControl = null;
1566
+ async hubMemberAddress() {
1567
+ const runtime = await this.hubRuntimeCreated();
1568
+ if (this.shuttingDown || !this.hubSettingsWriter)
1569
+ throw Error("The Hub is unavailable");
1570
+ if (!this.hubMemberAddressControl) {
1571
+ const { createHubMemberAddressControl } = await import("./hub/settings-member-address-control.js");
1572
+ if (this.shuttingDown)
1573
+ throw Error("The Hub is stopping");
1574
+ this.hubMemberAddressControl ??= createHubMemberAddressControl({ home: this.dataDir, readConfig: () => this.getRawFleetConfig(), writer: this.hubSettingsWriter,
1575
+ withDecision: (work, current) => runtime.withMemberAddressDecision(work, current), running: hub => runtime.serverHealth(hub) === "ready", settle: () => this.applyHubSwitches() });
1576
+ }
1577
+ return this.hubMemberAddressControl;
1578
+ }
1556
1579
  async hubSetup() {
1557
1580
  this.hubSetupInit ??= (async () => {
1558
1581
  const { createHubWebInitializer } = await import("./hub/init/web.js");
@@ -1599,6 +1622,7 @@ export class FleetManager {
1599
1622
  if (this.shuttingDown || incarnation !== this.settingsGeneration)
1600
1623
  throw Error("Fleet is stopping");
1601
1624
  const controller = new CompanyJoinController({ home: this.dataDir,
1625
+ pilotTrustEnabled: () => hubPilotTrustSettings(this.rawFleetConfig, RUNNING_AGEND_VERSION).enabled,
1602
1626
  snapshot: () => {
1603
1627
  const state = join(this.dataDir, "hub-member/state.json");
1604
1628
  return { membership: this.rawFleetConfig?.hub_member?.enabled === true,
@@ -2177,8 +2201,37 @@ export class FleetManager {
2177
2201
  readHub: () => this.rawFleetConfig?.hub,
2178
2202
  directoryDecision: () => this.hubRuntime?.directoryDecision() ?? null,
2179
2203
  webAddressDecision: () => this.hubRuntime?.webAddressDecision() ?? null,
2204
+ memberAddressDecision: () => this.hubRuntime?.memberAddressDecision() ?? null,
2180
2205
  saveHub: patches => this.saveFleetConfig(patches) });
2206
+ const { createFleetRoomAssistant } = await import("./hub/assistant/fleet-host.js");
2181
2207
  const runtime = new HubRuntime({
2208
+ roomAssistant: () => createFleetRoomAssistant({
2209
+ fleetHome: this.dataDir,
2210
+ instanceHome: process.env.AGEND_HUB_ASSISTANT_HOME || join(this.dataDir, "hub-assistant", "instances"),
2211
+ environment: process.env,
2212
+ version: (backend, binary) => this.availabilityProbes.version(backend, binary),
2213
+ facts: () => {
2214
+ const cli = this.backendAvailabilityRows().find(row => row.backend === "claude-code");
2215
+ const accounts = [{ id: null, name: "Default",
2216
+ state: this.claudeSignInEnded("claude-code", null) || cli?.auth === "invalid" ? "needs-sign-in" : cli?.auth === "valid" ? "signed-in" : "unknown" }];
2217
+ for (const profile of profilesOnDisk(this.dataDir, "claude-code")) {
2218
+ let state = "unknown";
2219
+ try {
2220
+ const login = credentialProfileLogin(this.dataDir, "claude-code", profile).state;
2221
+ state = login === "logged-in" && !this.claudeSignInEnded("claude-code", profile) ? "signed-in" : login === "signed-out" || this.claudeSignInEnded("claude-code", profile) ? "needs-sign-in" : "unknown";
2222
+ }
2223
+ catch { /* no credential fallback */ }
2224
+ accounts.push({ id: profile, name: profile, state });
2225
+ }
2226
+ return { binary: cli?.path ?? null, version: cli?.version ?? null, accounts };
2227
+ },
2228
+ quota: async (config) => {
2229
+ const { quotaBand } = await import("./hub/member/quota.js");
2230
+ const id = config.account ? `claude:${config.account}` : "claude";
2231
+ const snapshot = await getUsageSnapshot(false, new Set([id]), { allowStale: true });
2232
+ return quotaBand(snapshot.providers.find(row => row.id === id)).band;
2233
+ },
2234
+ }),
2182
2235
  home: this.dataDir,
2183
2236
  settingsWriter: this.hubSettingsWriter,
2184
2237
  directorySettings: () => this.hubDirectorySettings(),
@@ -2194,6 +2247,14 @@ export class FleetManager {
2194
2247
  // P1 representative mode (docs/design/hub-representative-agent.md): ordinary delivery + the report_result hook.
2195
2248
  representative: {
2196
2249
  quota: agent => this.hubAgentQuota(agent),
2250
+ locale: getLocale(),
2251
+ readState: agent => {
2252
+ const process = this.getInstanceStatus(agent), interaction = this.getInstanceInteraction(agent);
2253
+ return { process, execution: this.getInstanceExecutionState(agent),
2254
+ pauseReason: process === "paused" ? readPauseReason(this.getInstanceDir(agent)) : null,
2255
+ waitingForApproval: interaction?.phase === "waiting" && !interaction.stale && !interaction.suspected
2256
+ && (interaction.kind === "permission" || interaction.kind === "dangerous_command") };
2257
+ },
2197
2258
  deliver: input => this.deliverHubQuestion(input),
2198
2259
  agentToken: agent => this.hubAgentToken(agent),
2199
2260
  // attachments-v1: a question's files go into the agent's inbox; an answer's come from its own paths.
@@ -3517,6 +3578,7 @@ export class FleetManager {
3517
3578
  config: () => this.fleetConfig, current: () => [this.settingsGeneration, this.settingsRuntimeRevision, this.shuttingDown],
3518
3579
  generalLocation: input => this.previewGeneralLocation(input),
3519
3580
  hubMembership: raw => hubMembershipSettings(raw),
3581
+ hubPilotTrust: raw => hubPilotTrustSettings(raw, RUNNING_AGEND_VERSION),
3520
3582
  // S3c (S-55): a Hub exposure publish's confirmation summary, while a member composition is attached.
3521
3583
  hubBrowserCertificate: (input, binding) => {
3522
3584
  const control = this.hubBrowserCertificate();
@@ -7712,7 +7774,8 @@ export class FleetManager {
7712
7774
  this.humanReceiptDaemons.add(daemon);
7713
7775
  daemon.on("human_receipt_result", (result) => {
7714
7776
  try {
7715
- this.deliveryOutbox?.settleHumanReceipt(result.receipt_id, instanceName, result.owner_key, result.proof, this.humanReceiptOwner(instanceName, daemon));
7777
+ const accepted = this.deliveryOutbox?.settleHumanReceipt(result.receipt_id, instanceName, result.owner_key, result.proof, this.humanReceiptOwner(instanceName, daemon));
7778
+ daemon.noteHumanReceiptSettlement?.(result.receipt_id, accepted === true && result.proof !== null);
7716
7779
  }
7717
7780
  catch (err) {
7718
7781
  this.logger.error({ err, instanceName }, "Could not persist human delivery evidence");
@@ -7747,7 +7810,7 @@ export class FleetManager {
7747
7810
  return { ...payload, meta: { ...(payload.meta ?? {}),
7748
7811
  human_receipt_id: row.receipt_id, verification_id: row.message_id, ...(verified ? { web_verified: "1" } : {}) } };
7749
7812
  }
7750
- /** Bind at the actual IPC send, after all wake/reconnect waits. No human retry lane. */
7813
+ /** Register owned preparation at IPC; bind once at the final pane write. No human retry lane. */
7751
7814
  bindHumanReceiptPayload(instanceName, payload) {
7752
7815
  const meta = payload.meta;
7753
7816
  if (!meta?.human_receipt_id || !this.deliveryOutbox)
@@ -7760,6 +7823,23 @@ export class FleetManager {
7760
7823
  }
7761
7824
  this.listenForHumanReceipt(instanceName, daemon);
7762
7825
  const daemonOwner = daemon.captureHumanReceiptOwner();
7826
+ if (payload.type !== "raw_paste" && !String(payload.content ?? "").startsWith("/raw ") && daemon.registerHumanReceiptPreparation) {
7827
+ const content = String(payload.content ?? "");
7828
+ const kind = String(payload.type);
7829
+ const originalMeta = { ...meta };
7830
+ const token = daemon.registerHumanReceiptPreparation(meta.human_receipt_id, presentation => {
7831
+ if (!daemonOwner || this.humanReceiptOwner(instanceName, daemon) !== owner)
7832
+ throw new Error("Human delivery ownership changed");
7833
+ const dialectMeta = { ...originalMeta, human_wire_dialect: presentation.dialect ?? "legacy" };
7834
+ const wire = daemon.humanReceiptWire(content, dialectMeta, kind, presentation);
7835
+ const row = this.deliveryOutbox.bindHumanReceipt(meta.human_receipt_id, instanceName, owner, wire, this.managerBootId);
7836
+ if (this.humanReceiptOwner(instanceName, daemon) !== owner)
7837
+ throw new Error("Human delivery ownership changed");
7838
+ return { wire, meta: { human_owner_key: owner, human_daemon_owner: daemonOwner,
7839
+ human_wire_sha256: row.wire_sha256, human_wire_dialect: dialectMeta.human_wire_dialect } };
7840
+ }, () => { this.deliveryOutbox?.markHumanReceiptUncertain(meta.human_receipt_id, instanceName); });
7841
+ return { ...payload, meta: { ...meta, human_prepare_token: token } };
7842
+ }
7763
7843
  const wire = daemon.humanReceiptWire(String(payload.content ?? ""), meta, String(payload.type));
7764
7844
  const row = this.deliveryOutbox.bindHumanReceipt(meta.human_receipt_id, instanceName, owner, wire, this.managerBootId);
7765
7845
  if (!daemonOwner || this.humanReceiptOwner(instanceName, daemon) !== owner)
@@ -15284,7 +15364,7 @@ export class FleetManager {
15284
15364
  includeArchived: payload.include_archived,
15285
15365
  tags: payload.tags,
15286
15366
  teams: instanceTeams(this.fleetConfig?.teams, instanceName),
15287
- }), { id: payload.id, full: payload.full });
15367
+ }), { id: payload.id, full: payload.full, detail: payload.detail, limit: payload.limit, cursor: payload.cursor });
15288
15368
  break;
15289
15369
  case "fleet_decision_update": {
15290
15370
  const id = payload.id;
@@ -15448,7 +15528,7 @@ export class FleetManager {
15448
15528
  ...(reply.silent !== undefined ? { silent: reply.silent } : {}),
15449
15529
  });
15450
15530
  case "list":
15451
- return scheduler.list(requestedTarget);
15531
+ return scheduleListAnswer(scheduler.list(requestedTarget), args);
15452
15532
  case "update":
15453
15533
  return scheduler.update(args.id, args);
15454
15534
  case "delete":
@@ -15584,7 +15664,7 @@ export class FleetManager {
15584
15664
  includeArchived: args.includeArchived === true || args.include_archived === true,
15585
15665
  tags: asStrArr(args.tags),
15586
15666
  teams: instanceTeams(this.fleetConfig?.teams, instance),
15587
- }), { id: op === "get" ? asStr(args.id) ?? "" : args.id, full: args.full });
15667
+ }), { id: op === "get" ? asStr(args.id) ?? "" : args.id, full: args.full, detail: args.detail, limit: args.limit, cursor: args.cursor });
15588
15668
  case "update": {
15589
15669
  const id = asStr(args.id);
15590
15670
  if (!id)
@@ -15648,19 +15728,22 @@ export class FleetManager {
15648
15728
  // #1336 item 1: default to live-only (no done/cancelled) unless the
15649
15729
  // caller explicitly asked for a status.
15650
15730
  const effectiveStatus = explicitStatus ?? LIVE_TASK_STATUSES;
15651
- const verbose = args.verbose === true;
15731
+ listOptions(args);
15732
+ const verbose = args.verbose === true || args.detail === true;
15652
15733
  const tasks = verbose
15653
15734
  ? db.listTasks({ assignee: filterAssignee, status: effectiveStatus, verbose: true })
15654
15735
  : db.listTasks({ assignee: filterAssignee, status: effectiveStatus });
15655
15736
  // #1335: cap unfiltered list. The default live-only filter does not
15656
15737
  // count as an explicit filter for the cap decision.
15657
- return applyTaskListCap(tasks, filterAssignee, explicitStatus);
15738
+ return args.detail === true || args.verbose === true ? applyTaskListCap(tasks, filterAssignee, explicitStatus) : taskListAnswer(tasks, args);
15658
15739
  }
15659
15740
  case "get": {
15660
15741
  const id = asStr(args.id);
15661
15742
  if (!id)
15662
15743
  return { error: "id is required" };
15663
- return db.getTaskByPrefix(id);
15744
+ listOptions(args);
15745
+ const row = db.getTaskByPrefix(id);
15746
+ return args.detail === true ? row : taskTitle(row);
15664
15747
  }
15665
15748
  case "claim": {
15666
15749
  const id = asStr(args.id);
@@ -15810,17 +15893,19 @@ export class FleetManager {
15810
15893
  const explicitStatus = asStatusFilter(payload.filter_status);
15811
15894
  // #1336 item 1: default to live-only (no done/cancelled).
15812
15895
  const effectiveStatus = explicitStatus ?? LIVE_TASK_STATUSES;
15813
- const verbose = payload.verbose === true;
15896
+ listOptions(payload);
15897
+ const verbose = payload.verbose === true || payload.detail === true;
15814
15898
  const tasks = verbose
15815
15899
  ? db.listTasks({ assignee: filterAssignee, status: effectiveStatus, verbose: true })
15816
15900
  : db.listTasks({ assignee: filterAssignee, status: effectiveStatus });
15817
15901
  // #1335: cap unfiltered list — the default live-only filter does not
15818
15902
  // count as an explicit filter.
15819
- result = applyTaskListCap(tasks, filterAssignee, explicitStatus);
15903
+ result = payload.detail === true || payload.verbose === true ? applyTaskListCap(tasks, filterAssignee, explicitStatus) : taskListAnswer(tasks, payload);
15820
15904
  break;
15821
15905
  }
15822
15906
  case "get":
15823
- result = db.getTaskByPrefix(payload.id);
15907
+ listOptions(payload);
15908
+ result = payload.detail === true ? db.getTaskByPrefix(payload.id) : taskTitle(db.getTaskByPrefix(payload.id));
15824
15909
  break;
15825
15910
  case "claim":
15826
15911
  logTask = db.claimTask(db.getTaskByPrefix(payload.id).id, meta.instance_name || instanceName, { kind: "instance", name: meta.instance_name || instanceName });
@@ -19024,6 +19109,7 @@ export class FleetManager {
19024
19109
  pauseReason, pausedAt,
19025
19110
  crashedAt: crashed ? (this.needsCrashedAt.get(name) ?? null) : null,
19026
19111
  signIn: pauseReason === "auth" ? this.signInFor(name) : null,
19112
+ modelSwitch: this.modelObservationForInstance(name)?.active ?? null,
19027
19113
  usageHold: this.daemons.get(name)?.usageHold?.() ?? null,
19028
19114
  nativeDeliveryHold: this.daemons.get(name)?.nativeDeliveryHold?.() ?? null,
19029
19115
  generalLocation: this.generalLocationAttention(name),
@@ -22021,12 +22107,17 @@ export class FleetManager {
22021
22107
  return this.machineSignInsInstance ??= new MachineSignIns({
22022
22108
  call: (id, operation, payload, timeoutMs) => this.runtimeCoordinator().callAccount(id, operation, payload, timeoutMs),
22023
22109
  current: owner => this.browserSignInOwnerCurrent(owner),
22024
- reported: (id, profile) => this.machineAccounts.profileState(id, profile),
22025
- readiness: id => this.machineAccounts.readiness(id),
22110
+ reported: (id, profile, backend) => this.machineAccounts.profileState(id, profile, backend),
22111
+ reportedDefault: (id, backend) => this.machineAccounts.reportedDefault(id, backend),
22112
+ readiness: (id, backend, named) => this.machineAccounts.readiness(id, backend, named),
22026
22113
  actor: owner => { const handle = owner.handle; return typeof handle === "string" && /^[a-f0-9]{16}$/.test(handle) ? `admin:${handle}` : null; },
22027
22114
  changed: (event, owner) => {
22028
- // Safe fields only: the computer, the profile name, a phase and a fixed reason. Never a URL, a code, output or an e-mail address.
22029
- this.logger.info({ machine: event.machine, profile: event.profile, phase: event.phase, ...(event.reason ? { reason: event.reason } : {}), by: owner.label }, "Computer account sign-in from Settings → Accounts");
22115
+ // Safe fields only: the computer, the CLI, the profile name (none for Antigravity's default login), a phase and a fixed reason. Never a URL, a code, output or an e-mail address.
22116
+ this.logger.info({ machine: event.machine, backend: event.backend, ...(event.profile ? { profile: event.profile } : {}), phase: event.phase, ...(event.reason ? { reason: event.reason } : {}), by: owner.label }, "Computer account sign-in from Settings → Accounts");
22117
+ // The page reads the computer's last detection (agy is never run for a read): a login made just now is remembered until the next one.
22118
+ // Only the computer's OWN login (no profile) is remembered here: a named account's sign-in is reported by its Runtime's inventory, which it sends before the sign-in ends.
22119
+ if (event.phase === "done" && event.profile === undefined)
22120
+ this.machineAccounts.noteDefaultLogin(event.machine, event.backend, true);
22030
22121
  broadcastSseEvent(this.sseClients, "backend_login", {}, err => this.logger.debug({ err }, "backend_login event failed"));
22031
22122
  this.needsYou?.poke();
22032
22123
  },
@@ -22039,13 +22130,15 @@ export class FleetManager {
22039
22130
  call: (id, operation, payload, timeoutMs) => this.runtimeCoordinator().callAccount(id, operation, payload, timeoutMs),
22040
22131
  machine: id => remoteRuntimeEnabled() ? this.runtimeCoordinator().machine(id) ?? undefined : undefined,
22041
22132
  machines: () => remoteRuntimeEnabled() ? this.runtimeCoordinator().listMachines() : [],
22042
- agents: id => machineAgents(this.fleetConfig?.instances, id, name => { try {
22133
+ agents: (id, backend = "claude-code") => machineAgents(this.fleetConfig?.instances, id, name => { try {
22043
22134
  return nativeCredentialProfile(this.fleetConfig?.instances[name]) ?? null;
22044
22135
  }
22045
22136
  catch {
22046
22137
  return null;
22047
- } }, this.fleetConfig?.defaults?.backend ?? "claude-code"),
22048
- signingIn: (id, profile) => this.machineSignInsInstance?.signingIn(id, profile) ?? false,
22138
+ } }, this.fleetConfig?.defaults?.backend ?? "claude-code", backend),
22139
+ signingIn: (id, profile, backend) => this.machineSignInsInstance?.signingIn(id, profile, backend) ?? false,
22140
+ signingInDefault: (id, backend) => this.machineSignInsInstance?.signingInDefault(id, backend) ?? false,
22141
+ cliAgents: (id, backend) => machineAgents(this.fleetConfig?.instances, id, () => null, this.fleetConfig?.defaults?.backend ?? "claude-code", backend).map(agent => agent.name),
22049
22142
  log: entry => this.logger.info(entry, entry.outcome === "ok" ? "Computer account changed from Settings → Accounts" : "Computer account change refused"),
22050
22143
  });
22051
22144
  }
@@ -22068,6 +22161,7 @@ export class FleetManager {
22068
22161
  },
22069
22162
  checkAuth: backend => checkAuthStatus(LOGIN_FLOWS[backend].authCheck),
22070
22163
  checkConsoleAuth: backend => checkAuthStatus(LOGIN_FLOWS[backend].authCheck),
22164
+ accountsPage: true, // Settings → Accounts starts what the registry says can be driven (Antigravity: `agy acp --login`); the first-run page's own instance does not
22071
22165
  transport: () => createStructuredSignInTransport(),
22072
22166
  changed: (event, owner, launched) => {
22073
22167
  try {
@@ -22078,6 +22172,7 @@ export class FleetManager {
22078
22172
  if (event.phase === "done") {
22079
22173
  this.forgetSignInIdentities(); // a sign-in may be a different account now
22080
22174
  this.keepAliveAfterSignIn(event.backend, null); // its file changed, whoever is watching: a "needs sign-in" left from before is no longer the answer
22175
+ this.usageAfterSignIn(); // the usage read before this sign-in is not this account's
22081
22176
  }
22082
22177
  this.needsYou?.poke();
22083
22178
  if (!this.browserSignInOwnerCurrent(owner))
@@ -22112,8 +22207,15 @@ export class FleetManager {
22112
22207
  return result.ok;
22113
22208
  },
22114
22209
  checkAuth: (backend, profile) => {
22115
- const env = credentialProfileEnv(this.dataDir, backend, profile);
22116
- return env ? checkAuthStatus(LOGIN_FLOWS[backend].authCheck, env) : Promise.resolve("unknown");
22210
+ const launch = credentialProfileLaunch(this.dataDir, backend, profile);
22211
+ return launch ? checkAuthStatus(LOGIN_FLOWS[backend].authCheck, launch.env, launch.args) : Promise.resolve("unknown");
22212
+ },
22213
+ // AGEND-119: a CLI told its account by an argument (Antigravity) first proves the pin keeps a folder's sign-in in that folder (account-isolation.ts): asked about an empty scratch folder, never the account's own
22214
+ // (one that already has a token file proves nothing once the CLI stops honouring the pin).
22215
+ isolated: async (backend) => {
22216
+ if (hostFacts(backend, "namedAccounts")?.home !== "launch-argument")
22217
+ return true;
22218
+ return proveFolderIsolation(backend, launch => checkAuthSignedOut(LOGIN_FLOWS[backend].authCheck, launch.env, launch.args));
22117
22219
  },
22118
22220
  transport: target => createStructuredSignInTransport({ backend: target.backend, dataDir: this.dataDir }),
22119
22221
  changed: (event, owner, launched) => {
@@ -22125,6 +22227,7 @@ export class FleetManager {
22125
22227
  if (event.phase === "done") {
22126
22228
  this.forgetSignInIdentities(); // a sign-in may be a different account now
22127
22229
  this.keepAliveAfterSignIn(event.backend, event.profile);
22230
+ this.usageAfterSignIn();
22128
22231
  }
22129
22232
  this.needsYou?.poke();
22130
22233
  if (!this.browserSignInOwnerCurrent(owner))
@@ -22147,7 +22250,7 @@ export class FleetManager {
22147
22250
  return pending.map(backend => {
22148
22251
  if (!this.pendingBackendSince.has(backend))
22149
22252
  this.pendingBackendSince.set(backend, Date.now());
22150
- return { backend, since: this.pendingBackendSince.get(backend), browser: structuredSignInSupported(backend) };
22253
+ return { backend, since: this.pendingBackendSince.get(backend), browser: ONBOARDING_BROWSER_BACKENDS.includes(backend) };
22151
22254
  });
22152
22255
  }
22153
22256
  /** #2233: sign-ins started from the web dashboard (local admin sessions), on the same controller as chat's. */
@@ -22205,10 +22308,36 @@ export class FleetManager {
22205
22308
  }
22206
22309
  /** One `claude auth status` for a sign-in (the default one, or a credential profile's folder). */
22207
22310
  async readSignInIdentity(target) {
22208
- let env;
22209
- if (target.profile)
22210
- env = credentialProfileEnv(this.dataDir, target.backend, target.profile) ?? undefined;
22211
- return checkAuthIdentity(target.backend, env);
22311
+ let env, launch;
22312
+ if (target.profile) {
22313
+ const l = credentialProfileLaunch(this.dataDir, target.backend, target.profile);
22314
+ env = l?.env;
22315
+ // AGEND-119: a named account's folder (where a token-file CLI's sign-in is read) and the arguments a probe of it is given.
22316
+ if (l)
22317
+ launch = { args: l.args, folder: credentialProfileHome(this.dataDir, target.backend, target.profile) };
22318
+ }
22319
+ return checkAuthIdentity(target.backend, env, launch);
22320
+ }
22321
+ /**
22322
+ * The sign-ins whose account is read: every sign-in the Accounts list knows (`backendSignInTargets`: each CLI's default and the profiles an agent uses) AND each named account on disk that is signed in, used by an
22323
+ * agent or not — an account that was just signed in and has no agent yet has an account too, and the page shows it as it shows the default's.
22324
+ */
22325
+ identityTargets() {
22326
+ const out = this.backendSignInTargets(), seen = new Set(out.map(t => `${t.backend}\0${t.profile ?? ""}`));
22327
+ for (const backend of PROFILE_CLIS) {
22328
+ for (const profile of profilesOnDisk(this.dataDir, backend)) {
22329
+ if (seen.has(`${backend}\0${profile}`))
22330
+ continue;
22331
+ let login = "unknown";
22332
+ try {
22333
+ login = credentialProfileLogin(this.dataDir, backend, profile).state;
22334
+ }
22335
+ catch { /* unknown */ }
22336
+ if (login === "logged-in")
22337
+ out.push({ backend, profile, state: "usable", signIn: false });
22338
+ }
22339
+ }
22340
+ return out;
22212
22341
  }
22213
22342
  /**
22214
22343
  * Start reading, in the background, the account of each Claude Code sign-in that is signed in (the default and every profile an agent uses) and
@@ -22219,7 +22348,7 @@ export class FleetManager {
22219
22348
  refreshSignInIdentities() {
22220
22349
  const now = Date.now(), fresh = (target) => { const entry = this.signInIdentities.get(`${target.backend}\0${target.profile ?? ""}`); return !!entry && now - entry.at < 5 * 60_000; };
22221
22350
  const started = [];
22222
- for (const target of this.backendSignInTargets()) {
22351
+ for (const target of this.identityTargets()) {
22223
22352
  const key = `${target.backend}\0${target.profile ?? ""}`;
22224
22353
  if (target.state !== "usable" || !authIdentitySupported(target.backend) || fresh(target) || this.signInIdentityReads.has(key))
22225
22354
  continue;
@@ -22262,7 +22391,7 @@ export class FleetManager {
22262
22391
  login = credentialProfileLogin(this.dataDir, backend, profile).state;
22263
22392
  }
22264
22393
  catch { /* unknown */ }
22265
- const signIn = dashboardSignInSupported(backend, profile);
22394
+ const signIn = this.profileSignInSupported(backend, profile);
22266
22395
  const hostCommand = signIn ? null : credentialProfileLoginCommand(this.dataDir, backend, profile);
22267
22396
  const identity = this.signInIdentity(backend, profile);
22268
22397
  rows.push({ profile, state: (login === "logged-in" ? "usable" : login === "signed-out" ? "not_signed_in" : "unknown"), signIn,
@@ -22271,9 +22400,8 @@ export class FleetManager {
22271
22400
  diskProfiles.set(backend, rows);
22272
22401
  }
22273
22402
  const { agents, classic, fleetDefaults } = this.accountUses();
22274
- // Weekly and short-window (5h) usage, from the usage panel's own (cached, never forced) read.
22403
+ // Every pool's and every window's usage, from the usage panel's own (cached, never forced) read.
22275
22404
  const usage = new Map();
22276
- const shortWindow = new Map();
22277
22405
  const ids = new Map(); // provider id → backend\0profile
22278
22406
  for (const backend of ACCOUNT_CLIS) {
22279
22407
  const pid = usageProviderIdForBackend(backend);
@@ -22289,12 +22417,9 @@ export class FleetManager {
22289
22417
  const at = ids.get(provider.id);
22290
22418
  if (!at)
22291
22419
  continue;
22292
- const w = weeklyUsage(provider);
22293
- if (w)
22294
- usage.set(at, w);
22295
- const sh = shortUsage(provider);
22296
- if (sh)
22297
- shortWindow.set(at, sh);
22420
+ const u = accountUsage(at.split("\0")[0], provider);
22421
+ if (u)
22422
+ usage.set(at, u);
22298
22423
  }
22299
22424
  }
22300
22425
  catch { /* the view without usage */ }
@@ -22321,9 +22446,19 @@ export class FleetManager {
22321
22446
  this.logger.debug({ err: err.message }, "Computer accounts not read");
22322
22447
  }
22323
22448
  }
22324
- return buildAccountsView({ targets, diskProfiles, agents, classic, fleetDefaults, usage, shortUsage: shortWindow, keepAlive, machines, installShown: this.webHostInstalls.view()?.backend ?? null,
22449
+ return buildAccountsView({ targets, diskProfiles, agents, classic, fleetDefaults, usage, keepAlive, machines, installShown: this.webHostInstalls.view()?.backend ?? null,
22325
22450
  versions: new Map(this.backendAvailabilityRows().map(row => [row.backend, row.version ?? null])) });
22326
22451
  }
22452
+ /**
22453
+ * AGEND-113: a dashboard sign-in just finished: read the usage once more now (the panel's own forced read, so its 30-second floor and Retry-After hold), instead of showing what was read
22454
+ * before it for up to five minutes, and tell the pages to read their view again when something really was fetched. Never awaited, never allowed to fail the sign-in's follow-up.
22455
+ */
22456
+ usageAfterSignIn() {
22457
+ try {
22458
+ void refreshUsageAfterSignIn(() => broadcastSseEvent(this.sseClients, "backend_login", {}, err => this.logger.debug({ err }, "backend_login event failed"))).catch(() => { });
22459
+ }
22460
+ catch { /* the usage shows itself within its own cache time */ }
22461
+ }
22327
22462
  /**
22328
22463
  * A sign-in just finished for this account: look at its Keep sign-in alive setting once now (when it is on), so what the Accounts row says about
22329
22464
  * "the last check" is not the one from before the sign-in. Never awaited, and never allowed to fail the sign-in's own follow-up.
@@ -22534,7 +22669,7 @@ export class FleetManager {
22534
22669
  const owner = this.worlds.keys().next().value;
22535
22670
  // M-2932: only what a refresh showed (needs_sign_in, not_renewed, transient) — never a stored end date.
22536
22671
  return ka.attention().map(a => ({
22537
- backend: a.backend, profile: a.profile, kind: a.kind, since: a.since, signIn: dashboardSignInSupported(a.backend, a.profile),
22672
+ backend: a.backend, profile: a.profile, kind: a.kind, since: a.since, signIn: this.signInFromDashboard(a.backend, a.profile),
22538
22673
  ...(owner ? { owner } : {}),
22539
22674
  detail: t(`keepalive.${a.kind}`, BACKEND_LABELS[a.backend] ?? a.backend, a.profile ?? t("keepalive.default_name"), day(a.kind === "transient" ? a.failedSince ?? a.since : a.since)),
22540
22675
  }));
@@ -22726,6 +22861,16 @@ export class FleetManager {
22726
22861
  run: async (b, a, e) => watch(await base.run(b, a, e)),
22727
22862
  keychainHas: base.keychainHas,
22728
22863
  stillOwner: () => this.loginWindow.isCurrent(claim),
22864
+ // AGEND-119: a CLI with no logout command (Antigravity) is signed out by removing its sign-in file, and the CLI's own status probe then says whether it took effect — for this very account, launched as the agent is.
22865
+ verify: base.verify ?? (async (backend, profile) => {
22866
+ const check = LOGIN_FLOWS[backend]?.authCheck;
22867
+ if (!check)
22868
+ return "unknown";
22869
+ const launch = profile ? credentialProfileLaunch(this.dataDir, backend, profile) : null;
22870
+ // AGEND-250 (#3771 review P2-3): the strict reading. "Signed out" (`invalid`) only when the CLI exited non-zero AND said it is signed out ("Please sign in"); a DNS failure, a timeout or any other
22871
+ // nonzero exit is `unknown`, which the sign-out reports as unverified. The permissive `checkAuthStatus` took every nonzero exit as proof, so an offline machine "proved" a sign-out that had not happened.
22872
+ return checkAuthSignedOut(check, launch?.env, launch?.args);
22873
+ }),
22729
22874
  };
22730
22875
  let finished;
22731
22876
  const life = new Promise(r => { finished = r; });
@@ -22760,8 +22905,13 @@ export class FleetManager {
22760
22905
  result = { ok: false, error: "signing_in" };
22761
22906
  else
22762
22907
  result = await this.withAccountWriter(claim, deps => signOutAccount(this.dataDir, { backend, profile: profile ?? null, confirm, signingIn: false }, deps));
22908
+ // AGEND-119: the audit record of a sign-out — who, which backend's account (a name, never a path or an e-mail) and how it ended.
22909
+ try {
22910
+ this.eventLog?.insert("login", "account_signout", { backend, profile: shown, by, ok: result.ok, ...(result.ok ? (result.unverified ? { unverified: true } : {}) : { refused: result.error }) });
22911
+ }
22912
+ catch { /* safe metadata only */ }
22763
22913
  if (result.ok) {
22764
- this.logger.info({ backend, profile: shown, by, ...(result.keychainLeft ? { keychainLeft: true } : {}) }, "Account signed out from Settings → Accounts");
22914
+ this.logger.info({ backend, profile: shown, by, ...(result.keychainLeft ? { keychainLeft: true } : {}), ...(result.unverified ? { unverified: true } : {}) }, "Account signed out from Settings → Accounts");
22765
22915
  this.forgetSignInIdentities();
22766
22916
  void this.backendAvailability.refresh([backend], { force: true }).catch(() => { });
22767
22917
  broadcastSseEvent(this.sseClients, "backend_login", {}, err => this.logger.debug({ err }, "backend_login event failed"));
@@ -22782,6 +22932,24 @@ export class FleetManager {
22782
22932
  return false;
22783
22933
  }
22784
22934
  }
22935
+ /** Whether the dashboard can sign this account in — a named one (profileSignInSupported), or a CLI's default sign-in as the Accounts list says it (`backendSignInTargets`). */
22936
+ signInFromDashboard(backend, profile) {
22937
+ if (profile)
22938
+ return this.profileSignInSupported(backend, profile);
22939
+ return this.backendSignInTargets().find(t => t.backend === backend && !t.profile)?.signIn ?? dashboardSignInSupported(backend, null);
22940
+ }
22941
+ /**
22942
+ * Whether the dashboard can sign this NAMED account in: the browser-terminal flow of a CLI that supports it for profiles (`dashboardSignInSupported`), or — AGEND-119, Antigravity — the structured
22943
+ * controls (`agy --app_data_dir <folder> acp --login`) once the CLI is installed and new enough to have the command. A CLI that is older, or whose version is not read yet, is signed in on the host.
22944
+ */
22945
+ profileSignInSupported(backend, profile) {
22946
+ if (dashboardSignInSupported(backend, profile))
22947
+ return true;
22948
+ if (!structuredSignInSupported(backend) || !STRUCTURED_PROFILE_BACKENDS.has(backend))
22949
+ return false;
22950
+ const row = this.backendAvailabilityRows().find(r => r.backend === backend);
22951
+ return !!row && row.state !== "not_installed" && row.state !== "too_old" && versionAtLeast(row.version, hostFacts(backend, "structuredSignIn")?.minVersion);
22952
+ }
22785
22953
  backendSignInTargets() {
22786
22954
  const out = [];
22787
22955
  for (const row of this.backendAvailabilityRows()) {
@@ -22790,13 +22958,20 @@ export class FleetManager {
22790
22958
  // M-2825: `claude auth status` says loggedIn after a refused refresh and past the sign-in's end date — the file says
22791
22959
  // whether it is over, and then it is not signed in (never the other way: the file can't vouch for a login).
22792
22960
  const ended = row.state === "usable" && this.claudeSignInEnded(row.backend, null);
22961
+ // A CLI the dashboard drives with the structured sign-in (registry: `host.structuredSignIn`) although chat's /login and the browser terminal decline it (Antigravity: `agy acp --login`, agy
22962
+ // >= its `minVersion`) is signed in from Settings → Accounts. A CLI that is older, or whose version is not known, keeps "Sign in on the host" and is told to update.
22963
+ const structured = hostFacts(row.backend, "structuredSignIn");
22964
+ const viaStructured = !!structured && flow?.remoteLogin === "unsupported" && row.state !== "not_installed";
22965
+ const structuredSignIn = viaStructured && versionAtLeast(row.version, structured.minVersion);
22966
+ // Told to update only when the version is KNOWN to be older: a version that was not read yet is not "too old".
22967
+ const structuredUpdate = viaStructured && !structuredSignIn && typeof row.version === "string" && /\d/.test(row.version);
22793
22968
  out.push({
22794
22969
  // Not installed or too old: signing in would not help — the row says how to install (or update) it instead.
22795
22970
  backend: row.backend, state: ended ? "not_signed_in" : row.state, ...(ended ? { reconnect: true } : {}),
22796
- signIn: row.state !== "not_installed" && row.state !== "too_old" && dashboardSignInSupported(row.backend),
22797
- ...(flow?.remoteLogin === "unsupported" ? { hostCommand: flow.command } : {}),
22971
+ signIn: row.state !== "not_installed" && row.state !== "too_old" && (viaStructured ? structuredSignIn : dashboardSignInSupported(row.backend)),
22972
+ ...(flow?.remoteLogin === "unsupported" && !structuredSignIn ? { hostCommand: flow.command } : {}),
22798
22973
  ...(row.state === "not_installed" && install ? { install } : {}),
22799
- ...(row.state === "too_old" && install ? { update: install } : {}),
22974
+ ...((row.state === "too_old" || structuredUpdate) && install ? { update: install } : {}),
22800
22975
  ...(this.signInIdentity(row.backend) ? { identity: this.signInIdentity(row.backend) } : {}),
22801
22976
  });
22802
22977
  }
@@ -22812,7 +22987,7 @@ export class FleetManager {
22812
22987
  login = credentialProfileLogin(this.dataDir, backend, profile).state;
22813
22988
  }
22814
22989
  catch { /* unknown */ }
22815
- const signIn = dashboardSignInSupported(backend, profile);
22990
+ const signIn = this.profileSignInSupported(backend, profile);
22816
22991
  const hostCommand = signIn ? null : credentialProfileLoginCommand(this.dataDir, backend, profile);
22817
22992
  out.push({ backend, profile, state: login === "logged-in" ? "usable" : login === "signed-out" ? "not_signed_in" : "unknown", signIn,
22818
22993
  ...(hostCommand ? { hostCommand } : {}), ...(this.signInIdentity(backend, profile) ? { identity: this.signInIdentity(backend, profile) } : {}),
@@ -25219,8 +25394,10 @@ export class FleetManager {
25219
25394
  const backend = this.backendNameForInstance(name);
25220
25395
  const binding = this.webModelBinding(backend, name);
25221
25396
  // A named agy account has no verified relocation/discovery contract. In particular,
25222
- // never publish the ambient account's models under that profile (#3526 / D7).
25223
- if (!binding || (binding.profile && !credentialHomeSpec(backend)))
25397
+ // never publish the ambient account's models under that profile (#3526 / D7). (AGEND-119: agy now HAS
25398
+ // named accounts, but `agy models` is not run with the account's folder, so its answer would still be the
25399
+ // default account's: only a CLI whose profile is a variable the probe inherits is discovered under one.)
25400
+ if (!binding || (binding.profile && (!credentialHomeSpec(backend) || credentialHomeSpec(backend).kind === "launch-argument")))
25224
25401
  continue;
25225
25402
  // A description/defaults save can retire a scoped answer's full binding even
25226
25403
  // though its account signature is unchanged. Keep the conservative fence and
@@ -30610,6 +30787,10 @@ export class FleetManager {
30610
30787
  return off("publicLinkPreviewFailed", `Previews are unavailable on this public link (${status.reason}).`, { detail: status.reason });
30611
30788
  return { dashboardOrigin, previewOrigin: status.origin, reason: null, code: null, boot: status.boot, frameSrc: PUBLIC_PREVIEW_FRAME_SRC };
30612
30789
  }
30790
+ modelObservationForInstance(name) {
30791
+ const observation = this.daemons.get(name)?.modelObservation?.();
30792
+ return observation ? { ...observation, configured: this.resolveInstanceModel(name).model } : null;
30793
+ }
30613
30794
  getUiStatus() {
30614
30795
  return measureSyncWork("fleet.uiStatus", () => this.getUiStatusSync());
30615
30796
  }
@@ -30762,6 +30943,7 @@ export class FleetManager {
30762
30943
  cost,
30763
30944
  model,
30764
30945
  model_source,
30946
+ ...(backend === "claude-code" ? { model_observation: this.modelObservationForInstance(name) } : {}),
30765
30947
  backend,
30766
30948
  effort,
30767
30949
  effort_source,