@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.
- package/dist/account-isolation.d.ts +6 -0
- package/dist/account-isolation.js +40 -0
- package/dist/account-isolation.js.map +1 -0
- package/dist/accounts-signout.d.ts +15 -2
- package/dist/accounts-signout.js +52 -4
- package/dist/accounts-signout.js.map +1 -1
- package/dist/accounts-view.d.ts +114 -27
- package/dist/accounts-view.js +123 -60
- package/dist/accounts-view.js.map +1 -1
- package/dist/agent-cli-instructions.md +15 -9
- package/dist/agent-cli.js +47 -20
- package/dist/agent-cli.js.map +1 -1
- package/dist/agent-endpoint.js +23 -8
- package/dist/agent-endpoint.js.map +1 -1
- package/dist/agent-list-output.d.ts +23 -0
- package/dist/agent-list-output.js +53 -0
- package/dist/agent-list-output.js.map +1 -0
- package/dist/agent-runtime-change.js +4 -4
- package/dist/agent-runtime-change.js.map +1 -1
- package/dist/agent-whats-new.js +9 -7
- package/dist/agent-whats-new.js.map +1 -1
- package/dist/antigravity-first-run.d.ts +4 -0
- package/dist/antigravity-first-run.js +57 -0
- package/dist/antigravity-first-run.js.map +1 -0
- package/dist/antigravity-identity.d.ts +6 -0
- package/dist/antigravity-identity.js +27 -0
- package/dist/antigravity-identity.js.map +1 -0
- package/dist/antigravity-store.d.ts +22 -0
- package/dist/antigravity-store.js +79 -0
- package/dist/antigravity-store.js.map +1 -0
- package/dist/auth-api.js +11 -1
- package/dist/auth-api.js.map +1 -1
- package/dist/backend/agy-onboarding.d.ts +14 -0
- package/dist/backend/agy-onboarding.js +114 -0
- package/dist/backend/agy-onboarding.js.map +1 -0
- package/dist/backend/antigravity.d.ts +15 -0
- package/dist/backend/antigravity.js +44 -4
- package/dist/backend/antigravity.js.map +1 -1
- package/dist/backend/claude-code.d.ts +8 -0
- package/dist/backend/claude-code.js +11 -4
- package/dist/backend/claude-code.js.map +1 -1
- package/dist/backend/codex.js +7 -3
- package/dist/backend/codex.js.map +1 -1
- package/dist/backend/credential-profile.d.ts +22 -3
- package/dist/backend/credential-profile.js +61 -9
- package/dist/backend/credential-profile.js.map +1 -1
- package/dist/backend/grok.d.ts +19 -0
- package/dist/backend/grok.js +112 -1
- package/dist/backend/grok.js.map +1 -1
- package/dist/backend/types.d.ts +10 -0
- package/dist/backend/types.js.map +1 -1
- package/dist/backend-availability.d.ts +6 -0
- package/dist/backend-availability.js +11 -0
- package/dist/backend-availability.js.map +1 -1
- package/dist/browser-backend-signins.d.ts +9 -1
- package/dist/browser-backend-signins.js +9 -5
- package/dist/browser-backend-signins.js.map +1 -1
- package/dist/build-provenance.json +1 -1
- package/dist/channel/mcp-tools.js +10 -10
- package/dist/channel/mcp-tools.js.map +1 -1
- package/dist/child-process.d.ts +1 -0
- package/dist/child-process.js.map +1 -1
- package/dist/claude-auth-status.d.ts +1 -0
- package/dist/claude-auth-status.js +25 -0
- package/dist/claude-auth-status.js.map +1 -1
- package/dist/claude-model-observation.d.ts +71 -0
- package/dist/claude-model-observation.js +169 -0
- package/dist/claude-model-observation.js.map +1 -0
- package/dist/cli-capability.d.ts +104 -19
- package/dist/cli-capability.js +3 -1
- package/dist/cli-capability.js.map +1 -1
- package/dist/cli-caps-module.d.ts +14 -0
- package/dist/cli-caps-module.js +8 -1
- package/dist/cli-caps-module.js.map +1 -1
- package/dist/cli-registry-check.js +114 -18
- package/dist/cli-registry-check.js.map +1 -1
- package/dist/cli-registry.d.ts +116 -12
- package/dist/cli-registry.js +16 -1
- package/dist/cli-registry.js.map +1 -1
- package/dist/cli-spec-antigravity.d.ts +53 -11
- package/dist/cli-spec-antigravity.js +44 -13
- package/dist/cli-spec-antigravity.js.map +1 -1
- package/dist/cli-spec-claude-code.d.ts +14 -1
- package/dist/cli-spec-claude-code.js +5 -4
- package/dist/cli-spec-claude-code.js.map +1 -1
- package/dist/cli-spec-codex.d.ts +8 -0
- package/dist/cli-spec-codex.js +4 -3
- package/dist/cli-spec-codex.js.map +1 -1
- package/dist/cli-spec-grok.d.ts +4 -0
- package/dist/cli-spec-grok.js +2 -1
- package/dist/cli-spec-grok.js.map +1 -1
- package/dist/cli-spec-kiro-cli.d.ts +7 -0
- package/dist/cli-spec-kiro-cli.js +3 -2
- package/dist/cli-spec-kiro-cli.js.map +1 -1
- package/dist/cli-spec-muse.d.ts +4 -0
- package/dist/cli-spec-muse.js +2 -1
- package/dist/cli-spec-muse.js.map +1 -1
- package/dist/cli-spec-opencode.d.ts +1 -0
- package/dist/cli-spec-opencode.js +1 -0
- package/dist/cli-spec-opencode.js.map +1 -1
- package/dist/credential-store-proof.d.ts +6 -0
- package/dist/credential-store-proof.js +30 -0
- package/dist/credential-store-proof.js.map +1 -0
- package/dist/cross-instance-envelope.d.ts +4 -1
- package/dist/cross-instance-envelope.js +12 -7
- package/dist/cross-instance-envelope.js.map +1 -1
- package/dist/daemon.d.ts +24 -2
- package/dist/daemon.js +265 -37
- package/dist/daemon.js.map +1 -1
- package/dist/decision-list.d.ts +5 -4
- package/dist/decision-list.js +22 -8
- package/dist/decision-list.js.map +1 -1
- package/dist/delivery-consumed-watch.d.ts +24 -0
- package/dist/delivery-consumed-watch.js +21 -10
- package/dist/delivery-consumed-watch.js.map +1 -1
- package/dist/delivery-outbox.d.ts +5 -1
- package/dist/delivery-outbox.js +5 -0
- package/dist/delivery-outbox.js.map +1 -1
- package/dist/fleet-manager.d.ts +31 -2
- package/dist/fleet-manager.js +238 -56
- package/dist/fleet-manager.js.map +1 -1
- package/dist/fleet-windows-runtime.js +6 -6
- package/dist/fleet-windows-runtime.js.map +1 -1
- package/dist/general-knowledge/skills/concepts/SKILL.md +48 -7
- package/dist/general-knowledge/skills/credential-profiles/SKILL.md +23 -6
- package/dist/general-knowledge/skills/cross-instance-messaging/SKILL.md +18 -8
- package/dist/general-knowledge/skills/fleet-health/SKILL.md +16 -0
- package/dist/general-knowledge/skills/hub/SKILL.md +518 -0
- package/dist/general-knowledge/skills/multi-channel/SKILL.md +1 -1
- package/dist/general-knowledge/skills/scheduling/SKILL.md +1 -1
- package/dist/general-knowledge/skills/web-dashboard/SKILL.md +199 -40
- package/dist/general-knowledge/skills/worker-collaboration/SKILL.md +5 -1
- package/dist/general-role.d.ts +1 -1
- package/dist/general-role.js +1 -0
- package/dist/general-role.js.map +1 -1
- package/dist/grok-delivery-proof.d.ts +24 -0
- package/dist/grok-delivery-proof.js +124 -0
- package/dist/grok-delivery-proof.js.map +1 -0
- package/dist/hub/assistant/admin-types.d.ts +43 -0
- package/dist/hub/assistant/admin-types.js +2 -0
- package/dist/hub/assistant/admin-types.js.map +1 -0
- package/dist/hub/assistant/claude-host.d.ts +17 -0
- package/dist/hub/assistant/claude-host.js +300 -0
- package/dist/hub/assistant/claude-host.js.map +1 -0
- package/dist/hub/assistant/context.d.ts +3 -0
- package/dist/hub/assistant/context.js +7 -0
- package/dist/hub/assistant/context.js.map +1 -0
- package/dist/hub/assistant/fleet-host.d.ts +19 -0
- package/dist/hub/assistant/fleet-host.js +28 -0
- package/dist/hub/assistant/fleet-host.js.map +1 -0
- package/dist/hub/assistant/runner.d.ts +64 -0
- package/dist/hub/assistant/runner.js +239 -0
- package/dist/hub/assistant/runner.js.map +1 -0
- package/dist/hub/assistant/service.d.ts +51 -0
- package/dist/hub/assistant/service.js +143 -0
- package/dist/hub/assistant/service.js.map +1 -0
- package/dist/hub/assistant/store.d.ts +3 -0
- package/dist/hub/assistant/store.js +65 -0
- package/dist/hub/assistant/store.js.map +1 -0
- package/dist/hub/assistant/types.d.ts +60 -0
- package/dist/hub/assistant/types.js +2 -0
- package/dist/hub/assistant/types.js.map +1 -0
- package/dist/hub/buttons.d.ts +3 -0
- package/dist/hub/buttons.js +11 -11
- package/dist/hub/buttons.js.map +1 -1
- package/dist/hub/catalog.d.ts +13 -6
- package/dist/hub/catalog.js +127 -35
- package/dist/hub/catalog.js.map +1 -1
- package/dist/hub/client.d.ts +16 -0
- package/dist/hub/client.js +52 -9
- package/dist/hub/client.js.map +1 -1
- package/dist/hub/compose/member.d.ts +8 -1
- package/dist/hub/compose/member.js +238 -57
- package/dist/hub/compose/member.js.map +1 -1
- package/dist/hub/compose/server.d.ts +17 -1
- package/dist/hub/compose/server.js +76 -13
- package/dist/hub/compose/server.js.map +1 -1
- package/dist/hub/directory/admission.d.ts +15 -0
- package/dist/hub/directory/admission.js +56 -0
- package/dist/hub/directory/admission.js.map +1 -0
- package/dist/hub/directory/directory.d.ts +1 -1
- package/dist/hub/directory/directory.js +114 -0
- package/dist/hub/directory/directory.js.map +1 -1
- package/dist/hub/directory/types.d.ts +27 -0
- package/dist/hub/directory/types.js.map +1 -1
- package/dist/hub/enrolment-code.d.ts +1 -1
- package/dist/hub/enrolment-code.js +4 -4
- package/dist/hub/enrolment-code.js.map +1 -1
- package/dist/hub/grant-access.d.ts +11 -0
- package/dist/hub/grant-access.js +113 -0
- package/dist/hub/grant-access.js.map +1 -0
- package/dist/hub/grant-search.d.ts +9 -0
- package/dist/hub/grant-search.js +92 -0
- package/dist/hub/grant-search.js.map +1 -0
- package/dist/hub/group-policy/admin-control.d.ts +1 -0
- package/dist/hub/group-policy/admin-control.js +4 -2
- package/dist/hub/group-policy/admin-control.js.map +1 -1
- package/dist/hub/group-policy/admin-facts.d.ts +1 -0
- package/dist/hub/group-policy/admin-facts.js +2 -1
- package/dist/hub/group-policy/admin-facts.js.map +1 -1
- package/dist/hub/group-policy/admin-impact.d.ts +2 -0
- package/dist/hub/group-policy/admin-impact.js +10 -2
- package/dist/hub/group-policy/admin-impact.js.map +1 -1
- package/dist/hub/group-policy/admin-inventory.js +1 -1
- package/dist/hub/group-policy/admin-inventory.js.map +1 -1
- package/dist/hub/group-policy/admin-read.d.ts +1 -0
- package/dist/hub/group-policy/admin-read.js +3 -2
- package/dist/hub/group-policy/admin-read.js.map +1 -1
- package/dist/hub/group-policy/authorization.d.ts +5 -2
- package/dist/hub/group-policy/authorization.js +73 -32
- package/dist/hub/group-policy/authorization.js.map +1 -1
- package/dist/hub/group-policy/errors.d.ts +9 -0
- package/dist/hub/group-policy/errors.js +13 -0
- package/dist/hub/group-policy/errors.js.map +1 -0
- package/dist/hub/group-policy/impact-inventory.js +20 -4
- package/dist/hub/group-policy/impact-inventory.js.map +1 -1
- package/dist/hub/group-policy/resources.d.ts +4 -5
- package/dist/hub/group-policy/resources.js +26 -19
- package/dist/hub/group-policy/resources.js.map +1 -1
- package/dist/hub/group-policy/store.d.ts +21 -12
- package/dist/hub/group-policy/store.js +99 -109
- package/dist/hub/group-policy/store.js.map +1 -1
- package/dist/hub/group-policy/welcome.js.map +1 -1
- package/dist/hub/http/compose.d.ts +1 -0
- package/dist/hub/http/compose.js +463 -20
- package/dist/hub/http/compose.js.map +1 -1
- package/dist/hub/http/core.d.ts +24 -5
- package/dist/hub/http/core.js +181 -54
- package/dist/hub/http/core.js.map +1 -1
- package/dist/hub/http/deps.d.ts +26 -0
- package/dist/hub/http/schema.js +19 -0
- package/dist/hub/http/schema.js.map +1 -1
- package/dist/hub/init/member-certificate.d.ts +1 -0
- package/dist/hub/init/member-certificate.js +39 -0
- package/dist/hub/init/member-certificate.js.map +1 -0
- package/dist/hub/init/plan-digest.js +1 -0
- package/dist/hub/init/plan-digest.js.map +1 -1
- package/dist/hub/invitations.d.ts +96 -0
- package/dist/hub/invitations.js +292 -0
- package/dist/hub/invitations.js.map +1 -0
- package/dist/hub/join/certificate-trust.d.ts +13 -0
- package/dist/hub/join/certificate-trust.js +41 -0
- package/dist/hub/join/certificate-trust.js.map +1 -0
- package/dist/hub/join/certificate.d.ts +11 -0
- package/dist/hub/join/certificate.js +67 -0
- package/dist/hub/join/certificate.js.map +1 -0
- package/dist/hub/join/client.d.ts +5 -0
- package/dist/hub/join/client.js +30 -3
- package/dist/hub/join/client.js.map +1 -1
- package/dist/hub/join/http.js +5 -3
- package/dist/hub/join/http.js.map +1 -1
- package/dist/hub/join/local.d.ts +37 -1
- package/dist/hub/join/local.js +142 -14
- package/dist/hub/join/local.js.map +1 -1
- package/dist/hub/join/service.d.ts +19 -0
- package/dist/hub/join/service.js +46 -35
- package/dist/hub/join/service.js.map +1 -1
- package/dist/hub/join/trust.d.ts +9 -0
- package/dist/hub/join/trust.js +35 -0
- package/dist/hub/join/trust.js.map +1 -1
- package/dist/hub/member/pairing-api.js +12 -1
- package/dist/hub/member/pairing-api.js.map +1 -1
- package/dist/hub/member/room-ask.d.ts +137 -0
- package/dist/hub/member/room-ask.js +358 -0
- package/dist/hub/member/room-ask.js.map +1 -0
- package/dist/hub/member-journal.d.ts +18 -1
- package/dist/hub/member-journal.js +76 -3
- package/dist/hub/member-journal.js.map +1 -1
- package/dist/hub/member-origin.d.ts +177 -0
- package/dist/hub/member-origin.js +314 -0
- package/dist/hub/member-origin.js.map +1 -0
- package/dist/hub/pairing-notices.d.ts +1 -0
- package/dist/hub/pairing-notices.js +2 -1
- package/dist/hub/pairing-notices.js.map +1 -1
- package/dist/hub/pairing.d.ts +11 -0
- package/dist/hub/pairing.js +69 -21
- package/dist/hub/pairing.js.map +1 -1
- package/dist/hub/policy.d.ts +1 -1
- package/dist/hub/policy.js +19 -6
- package/dist/hub/policy.js.map +1 -1
- package/dist/hub/protocol.d.ts +172 -0
- package/dist/hub/protocol.js +25 -2
- package/dist/hub/protocol.js.map +1 -1
- package/dist/hub/quota.d.ts +2 -1
- package/dist/hub/quota.js +2 -2
- package/dist/hub/quota.js.map +1 -1
- package/dist/hub/roles/authority.d.ts +45 -0
- package/dist/hub/roles/authority.js +199 -0
- package/dist/hub/roles/authority.js.map +1 -0
- package/dist/hub/roles/change.d.ts +18 -0
- package/dist/hub/roles/change.js +76 -0
- package/dist/hub/roles/change.js.map +1 -0
- package/dist/hub/roles/clock.d.ts +18 -0
- package/dist/hub/roles/clock.js +58 -0
- package/dist/hub/roles/clock.js.map +1 -0
- package/dist/hub/roles/convert.d.ts +11 -0
- package/dist/hub/roles/convert.js +27 -0
- package/dist/hub/roles/convert.js.map +1 -0
- package/dist/hub/roles/cutover-inventory.d.ts +14 -0
- package/dist/hub/roles/cutover-inventory.js +42 -0
- package/dist/hub/roles/cutover-inventory.js.map +1 -0
- package/dist/hub/roles/cutover-marker.d.ts +57 -0
- package/dist/hub/roles/cutover-marker.js +26 -0
- package/dist/hub/roles/cutover-marker.js.map +1 -0
- package/dist/hub/roles/cutover.d.ts +32 -0
- package/dist/hub/roles/cutover.js +170 -0
- package/dist/hub/roles/cutover.js.map +1 -0
- package/dist/hub/roles/delegation.d.ts +24 -0
- package/dist/hub/roles/delegation.js +111 -0
- package/dist/hub/roles/delegation.js.map +1 -0
- package/dist/hub/roles/evaluate.d.ts +50 -0
- package/dist/hub/roles/evaluate.js +96 -0
- package/dist/hub/roles/evaluate.js.map +1 -0
- package/dist/hub/roles/expiry.d.ts +46 -0
- package/dist/hub/roles/expiry.js +180 -0
- package/dist/hub/roles/expiry.js.map +1 -0
- package/dist/hub/roles/mode-effects.d.ts +5 -0
- package/dist/hub/roles/mode-effects.js +21 -0
- package/dist/hub/roles/mode-effects.js.map +1 -0
- package/dist/hub/roles/model.d.ts +171 -0
- package/dist/hub/roles/model.js +79 -0
- package/dist/hub/roles/model.js.map +1 -0
- package/dist/hub/roles/read.d.ts +33 -0
- package/dist/hub/roles/read.js +55 -0
- package/dist/hub/roles/read.js.map +1 -0
- package/dist/hub/roles/writer.d.ts +80 -0
- package/dist/hub/roles/writer.js +427 -0
- package/dist/hub/roles/writer.js.map +1 -0
- package/dist/hub/rooms/admin.d.ts +45 -0
- package/dist/hub/rooms/admin.js +105 -0
- package/dist/hub/rooms/admin.js.map +1 -0
- package/dist/hub/rooms/agents.d.ts +74 -0
- package/dist/hub/rooms/agents.js +333 -0
- package/dist/hub/rooms/agents.js.map +1 -0
- package/dist/hub/rooms/assistant.d.ts +44 -0
- package/dist/hub/rooms/assistant.js +179 -0
- package/dist/hub/rooms/assistant.js.map +1 -0
- package/dist/hub/rooms/context.d.ts +10 -0
- package/dist/hub/rooms/context.js +24 -0
- package/dist/hub/rooms/context.js.map +1 -0
- package/dist/hub/rooms/direct-view.d.ts +39 -0
- package/dist/hub/rooms/direct-view.js +38 -0
- package/dist/hub/rooms/direct-view.js.map +1 -0
- package/dist/hub/rooms/directory.d.ts +35 -0
- package/dist/hub/rooms/directory.js +98 -0
- package/dist/hub/rooms/directory.js.map +1 -0
- package/dist/hub/rooms/schema.d.ts +11 -0
- package/dist/hub/rooms/schema.js +73 -0
- package/dist/hub/rooms/schema.js.map +1 -0
- package/dist/hub/rooms/service.d.ts +449 -0
- package/dist/hub/rooms/service.js +581 -0
- package/dist/hub/rooms/service.js.map +1 -0
- package/dist/hub/rooms/types.d.ts +79 -0
- package/dist/hub/rooms/types.js +2 -0
- package/dist/hub/rooms/types.js.map +1 -0
- package/dist/hub/rooms.d.ts +15 -1
- package/dist/hub/rooms.js +76 -31
- package/dist/hub/rooms.js.map +1 -1
- package/dist/hub/runtime.d.ts +8 -0
- package/dist/hub/runtime.js +57 -3
- package/dist/hub/runtime.js.map +1 -1
- package/dist/hub/server.d.ts +28 -0
- package/dist/hub/server.js +66 -6
- package/dist/hub/server.js.map +1 -1
- package/dist/hub/sessions.js +6 -2
- package/dist/hub/sessions.js.map +1 -1
- package/dist/hub/settings-commit.d.ts +6 -1
- package/dist/hub/settings-commit.js +15 -0
- package/dist/hub/settings-commit.js.map +1 -1
- package/dist/hub/settings-directory-decision.d.ts +2 -2
- package/dist/hub/settings-directory-decision.js +7 -5
- package/dist/hub/settings-directory-decision.js.map +1 -1
- package/dist/hub/settings-directory-proof.js +3 -1
- package/dist/hub/settings-directory-proof.js.map +1 -1
- package/dist/hub/settings-directory-recovery.d.ts +5 -0
- package/dist/hub/settings-directory-recovery.js +14 -4
- package/dist/hub/settings-directory-recovery.js.map +1 -1
- package/dist/hub/settings-member-address-control.d.ts +84 -0
- package/dist/hub/settings-member-address-control.js +150 -0
- package/dist/hub/settings-member-address-control.js.map +1 -0
- package/dist/hub/settings-member-address-decision.d.ts +229 -0
- package/dist/hub/settings-member-address-decision.js +318 -0
- package/dist/hub/settings-member-address-decision.js.map +1 -0
- package/dist/hub/settings-member-address-http.d.ts +9 -0
- package/dist/hub/settings-member-address-http.js +78 -0
- package/dist/hub/settings-member-address-http.js.map +1 -0
- package/dist/hub/settings-member-address-network.d.ts +2 -0
- package/dist/hub/settings-member-address-network.js +22 -0
- package/dist/hub/settings-member-address-network.js.map +1 -0
- package/dist/hub/settings-member-address-notices.d.ts +22 -0
- package/dist/hub/settings-member-address-notices.js +21 -0
- package/dist/hub/settings-member-address-notices.js.map +1 -0
- package/dist/hub/settings-member-address-policy.d.ts +21 -0
- package/dist/hub/settings-member-address-policy.js +34 -0
- package/dist/hub/settings-member-address-policy.js.map +1 -0
- package/dist/hub/settings-member-address.d.ts +64 -0
- package/dist/hub/settings-member-address.js +239 -0
- package/dist/hub/settings-member-address.js.map +1 -0
- package/dist/hub/sharing.d.ts +10 -0
- package/dist/hub/sharing.js +74 -0
- package/dist/hub/sharing.js.map +1 -0
- package/dist/hub/socket.d.ts +2 -0
- package/dist/hub/socket.js +2 -0
- package/dist/hub/socket.js.map +1 -1
- package/dist/hub/store.js +6 -2
- package/dist/hub/store.js.map +1 -1
- package/dist/hub/teams/types.d.ts +41 -0
- package/dist/hub/teams/types.js +2 -0
- package/dist/hub/teams/types.js.map +1 -0
- package/dist/hub/tls.d.ts +47 -0
- package/dist/hub/tls.js +23 -6
- package/dist/hub/tls.js.map +1 -1
- package/dist/hub/types.d.ts +68 -4
- package/dist/hub/validation.d.ts +1 -1
- package/dist/hub/validation.js +2 -2
- package/dist/hub/validation.js.map +1 -1
- package/dist/hub/web-origin.d.ts +93 -0
- package/dist/hub/web-origin.js +174 -0
- package/dist/hub/web-origin.js.map +1 -0
- package/dist/hub-pilot-trust-settings.d.ts +4 -0
- package/dist/hub-pilot-trust-settings.js +13 -0
- package/dist/hub-pilot-trust-settings.js.map +1 -0
- package/dist/human-delivery-receipts.d.ts +4 -2
- package/dist/human-delivery-receipts.js +20 -13
- package/dist/human-delivery-receipts.js.map +1 -1
- package/dist/inbound-presentation.d.ts +28 -0
- package/dist/inbound-presentation.js +48 -0
- package/dist/inbound-presentation.js.map +1 -0
- package/dist/instance-lifecycle.d.ts +13 -1
- package/dist/instance-lifecycle.js +33 -10
- package/dist/instance-lifecycle.js.map +1 -1
- package/dist/instructions.d.ts +10 -2
- package/dist/instructions.js +32 -7
- package/dist/instructions.js.map +1 -1
- package/dist/locale.js +20 -6
- package/dist/locale.js.map +1 -1
- package/dist/log-service.d.ts +3 -0
- package/dist/log-service.js +39 -22
- package/dist/log-service.js.map +1 -1
- package/dist/log-steps.d.ts +56 -1
- package/dist/log-steps.js +318 -56
- package/dist/log-steps.js.map +1 -1
- package/dist/login-flows.d.ts +24 -2
- package/dist/login-flows.js +53 -22
- package/dist/login-flows.js.map +1 -1
- package/dist/login-url.js +3 -0
- package/dist/login-url.js.map +1 -1
- package/dist/machine-accounts.d.ts +42 -12
- package/dist/machine-accounts.js +144 -46
- package/dist/machine-accounts.js.map +1 -1
- package/dist/machine-signins.d.ts +35 -13
- package/dist/machine-signins.js +57 -27
- package/dist/machine-signins.js.map +1 -1
- package/dist/native-instance-input.js +4 -4
- package/dist/native-instance-input.js.map +1 -1
- package/dist/native-instance-registry.d.ts +3 -3
- package/dist/native-instance-registry.js +11 -10
- package/dist/native-instance-registry.js.map +1 -1
- package/dist/needs-you-hub.js +6 -2
- package/dist/needs-you-hub.js.map +1 -1
- package/dist/needs-you.d.ts +5 -1
- package/dist/needs-you.js +4 -8
- package/dist/needs-you.js.map +1 -1
- package/dist/office-share-page.js +1 -1
- package/dist/office-share-page.js.map +1 -1
- package/dist/outbound-handlers.d.ts +1 -0
- package/dist/outbound-handlers.js +25 -19
- package/dist/outbound-handlers.js.map +1 -1
- package/dist/outbound-schemas.d.ts +19 -0
- package/dist/outbound-schemas.js +23 -4
- package/dist/outbound-schemas.js.map +1 -1
- package/dist/profile-signins.d.ts +5 -0
- package/dist/profile-signins.js +1 -0
- package/dist/profile-signins.js.map +1 -1
- package/dist/queued-handoffs.d.ts +3 -1
- package/dist/queued-handoffs.js +1 -1
- package/dist/queued-handoffs.js.map +1 -1
- package/dist/runtime-build-info.js +6 -2
- package/dist/runtime-build-info.js.map +1 -1
- package/dist/runtime-cli.js +33 -11
- package/dist/runtime-cli.js.map +1 -1
- package/dist/runtime-client.d.ts +18 -2
- package/dist/runtime-client.js +84 -21
- package/dist/runtime-client.js.map +1 -1
- package/dist/runtime-credential-profiles.d.ts +36 -4
- package/dist/runtime-credential-profiles.js +82 -16
- package/dist/runtime-credential-profiles.js.map +1 -1
- package/dist/runtime-profile-ownership.d.ts +2 -2
- package/dist/runtime-profile-ownership.js +3 -3
- package/dist/runtime-profile-ownership.js.map +1 -1
- package/dist/runtime-protocol.d.ts +5 -3
- package/dist/runtime-protocol.js +4 -0
- package/dist/runtime-protocol.js.map +1 -1
- package/dist/runtime-remote-accounts.d.ts +72 -5
- package/dist/runtime-remote-accounts.js +293 -52
- package/dist/runtime-remote-accounts.js.map +1 -1
- package/dist/runtime-remote-setup.d.ts +2 -2
- package/dist/runtime-remote-setup.js +2 -2
- package/dist/runtime-remote-setup.js.map +1 -1
- package/dist/runtime-signin-transport.d.ts +22 -4
- package/dist/runtime-signin-transport.js +50 -12
- package/dist/runtime-signin-transport.js.map +1 -1
- package/dist/runtime-signin.d.ts +42 -0
- package/dist/runtime-signin.js +105 -9
- package/dist/runtime-signin.js.map +1 -1
- package/dist/runtime-transcript-source.d.ts +2 -0
- package/dist/runtime-transcript-source.js +23 -1
- package/dist/runtime-transcript-source.js.map +1 -1
- package/dist/runtime-windows-bridge.js +6 -1
- package/dist/runtime-windows-bridge.js.map +1 -1
- package/dist/scheduler/task-board.d.ts +1 -0
- package/dist/scheduler/task-board.js +10 -1
- package/dist/scheduler/task-board.js.map +1 -1
- package/dist/settings-api.d.ts +1 -0
- package/dist/settings-api.js +15 -8
- package/dist/settings-api.js.map +1 -1
- package/dist/settings-baseline.d.ts +3 -0
- package/dist/settings-baseline.js +2 -2
- package/dist/settings-baseline.js.map +1 -1
- package/dist/settings-effect.d.ts +3 -0
- package/dist/settings-effect.js +12 -2
- package/dist/settings-effect.js.map +1 -1
- package/dist/signin-keepalive.d.ts +31 -2
- package/dist/signin-keepalive.js +123 -12
- package/dist/signin-keepalive.js.map +1 -1
- package/dist/structured-signin-transport.d.ts +2 -2
- package/dist/structured-signin-transport.js +27 -6
- package/dist/structured-signin-transport.js.map +1 -1
- package/dist/structured-signin.d.ts +16 -2
- package/dist/structured-signin.js +59 -4
- package/dist/structured-signin.js.map +1 -1
- package/dist/task-board-tool.d.ts +0 -13
- package/dist/task-board-tool.js +42 -6
- package/dist/task-board-tool.js.map +1 -1
- package/dist/tool-receipt-output.d.ts +151 -0
- package/dist/tool-receipt-output.js +50 -0
- package/dist/tool-receipt-output.js.map +1 -0
- package/dist/topic-commands.js +2 -1
- package/dist/topic-commands.js.map +1 -1
- package/dist/transcript-jsonl.d.ts +24 -0
- package/dist/transcript-jsonl.js +72 -22
- package/dist/transcript-jsonl.js.map +1 -1
- package/dist/transcript-monitor.d.ts +5 -1
- package/dist/transcript-monitor.js +65 -3
- package/dist/transcript-monitor.js.map +1 -1
- package/dist/transcript-needles.d.ts +1 -1
- package/dist/transcript-needles.js +1 -1
- package/dist/transcript-records.d.ts +2 -1
- package/dist/transcript-records.js.map +1 -1
- package/dist/transcript-sources.d.ts +4 -0
- package/dist/transcript-sources.js +2 -0
- package/dist/transcript-sources.js.map +1 -1
- package/dist/ui/accounts-keepalive.js +15 -6
- package/dist/ui/accounts-manage.js +25 -5
- package/dist/ui/accounts-view.js +28 -24
- package/dist/ui/agent-details-settings.js +10 -1
- package/dist/ui/agent-proposals.js +22 -2
- package/dist/ui/agent-runtime-settings.js +3 -3
- package/dist/ui/backend-signin.js +4 -4
- package/dist/ui/chat-activity.js +2 -2
- package/dist/ui/cli-caps.js +7 -7
- package/dist/ui/credential-profile-select.js +32 -19
- package/dist/ui/fleet-canvas.js +5 -2
- package/dist/ui/fleet-office-card.js +4 -2
- package/dist/ui/fleet-org.js +2 -0
- package/dist/ui/hub-admin-rooms-strings.js +28 -0
- package/dist/ui/hub-admin-rooms.js +77 -0
- package/dist/ui/hub-assistant-admin-strings.js +26 -0
- package/dist/ui/hub-assistant-admin.js +85 -0
- package/dist/ui/hub-chat-store.js +8 -4
- package/dist/ui/hub-client.js +224 -33
- package/dist/ui/hub-enrolment-code.js +1 -1
- package/dist/ui/hub-grant-picker.js +100 -0
- package/dist/ui/hub-group-search.js +2 -2
- package/dist/ui/hub-invitations-strings.js +30 -0
- package/dist/ui/hub-invitations.js +108 -0
- package/dist/ui/hub-join-one-strings.js +4 -2
- package/dist/ui/hub-join-steps.js +5 -2
- package/dist/ui/hub-pairing-form-strings.js +48 -0
- package/dist/ui/hub-pilot-trust-strings.js +27 -0
- package/dist/ui/hub-pilot-trust.js +41 -0
- package/dist/ui/hub-room-composer.js +113 -0
- package/dist/ui/hub-room-favorites.js +90 -0
- package/dist/ui/hub-room-list.js +152 -0
- package/dist/ui/hub-room-members-strings.js +12 -0
- package/dist/ui/hub-room-members.js +104 -0
- package/dist/ui/hub-room-new-strings.js +46 -0
- package/dist/ui/hub-room-new.js +135 -0
- package/dist/ui/hub-room-presence.js +123 -0
- package/dist/ui/hub-room-settings-strings.js +26 -0
- package/dist/ui/hub-room-settings.js +134 -0
- package/dist/ui/hub-room-strings.js +222 -0
- package/dist/ui/hub-room-thread.js +262 -0
- package/dist/ui/hub-room-unread.js +51 -0
- package/dist/ui/hub-room-working.js +29 -0
- package/dist/ui/log-row.js +14 -5
- package/dist/ui/machine-signin.js +47 -14
- package/dist/ui/panel-details.js +6 -1
- package/dist/ui/panel-fleet.js +2 -2
- package/dist/ui/panel-hub.js +145 -59
- package/dist/ui/panel-needs.js +2 -0
- package/dist/ui/panel-settings.js +2 -2
- package/dist/ui/settings-hub-company-join.js +32 -11
- package/dist/ui/settings-hub-connection.js +9 -3
- package/dist/ui/settings-hub-member-address.js +205 -0
- package/dist/ui/settings-hub-section.js +4 -0
- package/dist/ui/settings-hub-web-address.js +233 -0
- package/dist/ui/settings-hub.js +16 -4
- package/dist/ui/shared/accounts-keepalive.css +8 -0
- package/dist/ui/shared/accounts-usage-pool.css +10 -0
- package/dist/ui/shared/accounts.css +9 -0
- package/dist/ui/shared/app-i18n.js +2 -2
- package/dist/ui/shared/app-needs.js +3 -0
- package/dist/ui/shared/app-shell.js +4 -1
- package/dist/ui/shared/app.css +43 -5
- package/dist/ui/shared/chat-render.js +10 -0
- package/dist/ui/shared/chat-thread.js +14 -5
- package/dist/ui/shared/hub-chat.css +17 -0
- package/dist/ui/shared/hub-grant-picker.css +4 -0
- package/dist/ui/shared/hub-rooms-u2.css +42 -0
- package/dist/ui/shared/hub-sharing.css +4 -0
- package/dist/ui/shared/model-observation.js +16 -0
- package/dist/ui/shared/stale-tab.css +6 -0
- package/dist/ui/shared/stale-tab.js +50 -0
- package/dist/ui/shared/view-strings.js +2 -2
- package/dist/ui/structured-signin.js +19 -6
- package/dist/ui/usage-pool.js +76 -0
- package/dist/usage/agent-output.d.ts +144 -0
- package/dist/usage/agent-output.js +75 -0
- package/dist/usage/agent-output.js.map +1 -0
- package/dist/usage/provider-alerts.d.ts +6 -0
- package/dist/usage/provider-alerts.js +6 -0
- package/dist/usage/provider-alerts.js.map +1 -1
- package/dist/usage/providers.d.ts +2 -2
- package/dist/usage/providers.js +60 -18
- package/dist/usage/providers.js.map +1 -1
- package/dist/usage/usage-api.d.ts +12 -0
- package/dist/usage/usage-api.js +39 -0
- package/dist/usage/usage-api.js.map +1 -1
- package/dist/web-api.d.ts +4 -0
- package/dist/web-api.js +32 -13
- package/dist/web-api.js.map +1 -1
- package/dist/web-backend-login.d.ts +4 -1
- package/dist/web-backend-login.js.map +1 -1
- package/dist/windows-cli-providers.js +5 -1
- package/dist/windows-cli-providers.js.map +1 -1
- package/dist/windows-cli-worker.d.ts +33 -1
- package/dist/windows-cli-worker.js +150 -10
- package/dist/windows-cli-worker.js.map +1 -1
- package/dist/windows-cli.d.ts +7 -1
- package/dist/windows-cli.js +19 -2
- package/dist/windows-cli.js.map +1 -1
- package/dist/workflow-templates/default.md +2 -2
- package/package.json +1 -1
package/dist/fleet-manager.js
CHANGED
|
@@ -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 {
|
|
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,
|
|
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
|
|
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
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
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}".
|
|
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
|
-
/**
|
|
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
|
-
|
|
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
|
-
|
|
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
|
-
|
|
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
|
-
|
|
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
|
-
|
|
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
|
|
22116
|
-
return
|
|
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:
|
|
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
|
-
|
|
22211
|
-
|
|
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.
|
|
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 =
|
|
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
|
-
//
|
|
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
|
|
22293
|
-
if (
|
|
22294
|
-
usage.set(at,
|
|
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,
|
|
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:
|
|
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 =
|
|
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
|
-
|
|
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,
|