@hoknie/aip 0.3.1 → 0.5.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.claude-plugin/marketplace.json +3 -0
- package/dist/app/actors.js +82 -0
- package/dist/app/actors.js.map +1 -0
- package/dist/app/agents.js +9 -1
- package/dist/app/agents.js.map +1 -1
- package/dist/app/application.js +72 -57
- package/dist/app/application.js.map +1 -1
- package/dist/app/integration-operations.js +34 -0
- package/dist/app/integration-operations.js.map +1 -0
- package/dist/app/lifecycle.js +91 -2
- package/dist/app/lifecycle.js.map +1 -1
- package/dist/app/maintenance.js +4 -0
- package/dist/app/maintenance.js.map +1 -1
- package/dist/app/notifications/index.js +44 -0
- package/dist/app/notifications/index.js.map +1 -0
- package/dist/app/oidc.js +27 -0
- package/dist/app/oidc.js.map +1 -0
- package/dist/app/saml.js +43 -0
- package/dist/app/saml.js.map +1 -0
- package/dist/app/timings.js +2 -1
- package/dist/app/timings.js.map +1 -1
- package/dist/app/wire.js +88 -0
- package/dist/app/wire.js.map +1 -0
- package/dist/app/wiring.js +10 -0
- package/dist/app/wiring.js.map +1 -1
- package/dist/cli/main.js +42 -0
- package/dist/cli/main.js.map +1 -1
- package/dist/feature/access/services/access.js +73 -0
- package/dist/feature/access/services/access.js.map +1 -0
- package/dist/feature/access/services/create.js +31 -0
- package/dist/feature/access/services/create.js.map +1 -0
- package/dist/feature/access/services/index.js +3 -0
- package/dist/feature/access/services/index.js.map +1 -0
- package/dist/feature/access/types/actions.js +145 -0
- package/dist/feature/access/types/actions.js.map +1 -0
- package/dist/feature/access/types/evaluate.js +58 -0
- package/dist/feature/access/types/evaluate.js.map +1 -0
- package/dist/feature/access/types/index.js +4 -0
- package/dist/feature/access/types/index.js.map +1 -0
- package/dist/feature/access/types/presets.js +41 -0
- package/dist/feature/access/types/presets.js.map +1 -0
- package/dist/feature/agents/clients/agy/runtime.js +1 -0
- package/dist/feature/agents/clients/agy/runtime.js.map +1 -1
- package/dist/feature/agents/clients/claude/parser.js +7 -1
- package/dist/feature/agents/clients/claude/parser.js.map +1 -1
- package/dist/feature/agents/clients/claude/permissions.js +5 -2
- package/dist/feature/agents/clients/claude/permissions.js.map +1 -1
- package/dist/feature/agents/clients/claude/runtime.js +2 -0
- package/dist/feature/agents/clients/claude/runtime.js.map +1 -1
- package/dist/feature/agents/clients/cline/events.js +36 -0
- package/dist/feature/agents/clients/cline/events.js.map +1 -0
- package/dist/feature/agents/clients/cline/gate.js +55 -0
- package/dist/feature/agents/clients/cline/gate.js.map +1 -0
- package/dist/feature/agents/clients/cline/index.js +5 -0
- package/dist/feature/agents/clients/cline/index.js.map +1 -0
- package/dist/feature/agents/clients/cline/parser.js +41 -0
- package/dist/feature/agents/clients/cline/parser.js.map +1 -0
- package/dist/feature/agents/clients/cline/runtime.js +126 -0
- package/dist/feature/agents/clients/cline/runtime.js.map +1 -0
- package/dist/feature/agents/clients/cline/transcript.js +49 -0
- package/dist/feature/agents/clients/cline/transcript.js.map +1 -0
- package/dist/feature/agents/clients/codex/config.js +72 -0
- package/dist/feature/agents/clients/codex/config.js.map +1 -0
- package/dist/feature/agents/clients/codex/events.js +35 -0
- package/dist/feature/agents/clients/codex/events.js.map +1 -0
- package/dist/feature/agents/clients/codex/index.js +5 -0
- package/dist/feature/agents/clients/codex/index.js.map +1 -0
- package/dist/feature/agents/clients/codex/parser.js +54 -0
- package/dist/feature/agents/clients/codex/parser.js.map +1 -0
- package/dist/feature/agents/clients/codex/runtime.js +83 -0
- package/dist/feature/agents/clients/codex/runtime.js.map +1 -0
- package/dist/feature/agents/clients/codex/transcript.js +84 -0
- package/dist/feature/agents/clients/codex/transcript.js.map +1 -0
- package/dist/feature/agents/clients/copilot/config.js +25 -0
- package/dist/feature/agents/clients/copilot/config.js.map +1 -0
- package/dist/feature/agents/clients/copilot/events.js +43 -0
- package/dist/feature/agents/clients/copilot/events.js.map +1 -0
- package/dist/feature/agents/clients/copilot/gate.js +79 -0
- package/dist/feature/agents/clients/copilot/gate.js.map +1 -0
- package/dist/feature/agents/clients/copilot/index.js +6 -0
- package/dist/feature/agents/clients/copilot/index.js.map +1 -0
- package/dist/feature/agents/clients/copilot/parser.js +58 -0
- package/dist/feature/agents/clients/copilot/parser.js.map +1 -0
- package/dist/feature/agents/clients/copilot/runtime.js +149 -0
- package/dist/feature/agents/clients/copilot/runtime.js.map +1 -0
- package/dist/feature/agents/clients/copilot/sandbox.js +107 -0
- package/dist/feature/agents/clients/copilot/sandbox.js.map +1 -0
- package/dist/feature/agents/clients/copilot/transcript.js +45 -0
- package/dist/feature/agents/clients/copilot/transcript.js.map +1 -0
- package/dist/feature/agents/clients/kilo/config.js +84 -0
- package/dist/feature/agents/clients/kilo/config.js.map +1 -0
- package/dist/feature/agents/clients/kilo/index.js +3 -0
- package/dist/feature/agents/clients/kilo/index.js.map +1 -0
- package/dist/feature/agents/clients/kilo/runtime.js +87 -0
- package/dist/feature/agents/clients/kilo/runtime.js.map +1 -0
- package/dist/feature/agents/clients/opencode/parser.js +24 -1
- package/dist/feature/agents/clients/opencode/parser.js.map +1 -1
- package/dist/feature/agents/clients/opencode/runtime.js +1 -0
- package/dist/feature/agents/clients/opencode/runtime.js.map +1 -1
- package/dist/feature/agents/clients/policy/decision.js +69 -0
- package/dist/feature/agents/clients/policy/decision.js.map +1 -0
- package/dist/feature/agents/clients/policy/gate.js +37 -0
- package/dist/feature/agents/clients/policy/gate.js.map +1 -0
- package/dist/feature/agents/clients/policy/index.js +4 -0
- package/dist/feature/agents/clients/policy/index.js.map +1 -0
- package/dist/feature/agents/clients/policy/mcp.js +45 -0
- package/dist/feature/agents/clients/policy/mcp.js.map +1 -0
- package/dist/feature/agents/services/agents.js +18 -6
- package/dist/feature/agents/services/agents.js.map +1 -1
- package/dist/feature/agents/services/create.js +3 -1
- package/dist/feature/agents/services/create.js.map +1 -1
- package/dist/feature/agents/services/index.js +1 -0
- package/dist/feature/agents/services/index.js.map +1 -1
- package/dist/feature/agents/services/providers.js +82 -0
- package/dist/feature/agents/services/providers.js.map +1 -0
- package/dist/feature/agents/services/skills.js +4 -1
- package/dist/feature/agents/services/skills.js.map +1 -1
- package/dist/feature/agents/services/supervisor.js +12 -5
- package/dist/feature/agents/services/supervisor.js.map +1 -1
- package/dist/feature/agents/types/index.js +1 -0
- package/dist/feature/agents/types/index.js.map +1 -1
- package/dist/feature/agents/types/mcp/env.js +6 -1
- package/dist/feature/agents/types/mcp/env.js.map +1 -1
- package/dist/feature/agents/types/message.js +13 -1
- package/dist/feature/agents/types/message.js.map +1 -1
- package/dist/feature/agents/types/providers/providers.js +62 -0
- package/dist/feature/agents/types/providers/providers.js.map +1 -0
- package/dist/feature/agents/types/runtime.js +27 -0
- package/dist/feature/agents/types/runtime.js.map +1 -1
- package/dist/feature/agents/types/worker-tools.js +6 -1
- package/dist/feature/agents/types/worker-tools.js.map +1 -1
- package/dist/feature/audit/repositories/events.js +66 -0
- package/dist/feature/audit/repositories/events.js.map +1 -0
- package/dist/feature/audit/repositories/index.js +2 -0
- package/dist/feature/audit/repositories/index.js.map +1 -0
- package/dist/feature/audit/services/audit-log.js +24 -0
- package/dist/feature/audit/services/audit-log.js.map +1 -0
- package/dist/feature/audit/services/create.js +6 -0
- package/dist/feature/audit/services/create.js.map +1 -0
- package/dist/feature/audit/services/index.js +3 -0
- package/dist/feature/audit/services/index.js.map +1 -0
- package/dist/feature/audit/types/event.js +12 -0
- package/dist/feature/audit/types/event.js.map +1 -0
- package/dist/feature/audit/types/index.js +2 -0
- package/dist/feature/audit/types/index.js.map +1 -0
- package/dist/feature/compose/services/repository-move.js +8 -1
- package/dist/feature/compose/services/repository-move.js.map +1 -1
- package/dist/feature/compose/services/repository-removal.js +6 -1
- package/dist/feature/compose/services/repository-removal.js.map +1 -1
- package/dist/feature/delivery/ports/authors.js +2 -0
- package/dist/feature/delivery/ports/authors.js.map +1 -0
- package/dist/feature/delivery/services/commit-stamp.js +20 -0
- package/dist/feature/delivery/services/commit-stamp.js.map +1 -0
- package/dist/feature/delivery/services/create.js +6 -2
- package/dist/feature/delivery/services/create.js.map +1 -1
- package/dist/feature/delivery/services/deliver.js +8 -0
- package/dist/feature/delivery/services/deliver.js.map +1 -1
- package/dist/feature/delivery/services/push.js +23 -0
- package/dist/feature/delivery/services/push.js.map +1 -0
- package/dist/feature/delivery/types/index.js +2 -0
- package/dist/feature/delivery/types/index.js.map +1 -1
- package/dist/feature/delivery/types/remote-url.js +44 -0
- package/dist/feature/delivery/types/remote-url.js.map +1 -0
- package/dist/feature/delivery/types/trailer.js +22 -0
- package/dist/feature/delivery/types/trailer.js.map +1 -0
- package/dist/feature/identity/clients/oidc/client.js +78 -0
- package/dist/feature/identity/clients/oidc/client.js.map +1 -0
- package/dist/feature/identity/clients/oidc/index.js +2 -0
- package/dist/feature/identity/clients/oidc/index.js.map +1 -0
- package/dist/feature/identity/clients/oidc/signature.js +51 -0
- package/dist/feature/identity/clients/oidc/signature.js.map +1 -0
- package/dist/feature/identity/clients/saml/client.js +108 -0
- package/dist/feature/identity/clients/saml/client.js.map +1 -0
- package/dist/feature/identity/clients/saml/idp-metadata.js +123 -0
- package/dist/feature/identity/clients/saml/idp-metadata.js.map +1 -0
- package/dist/feature/identity/clients/saml/index.js +3 -0
- package/dist/feature/identity/clients/saml/index.js.map +1 -0
- package/dist/feature/identity/ports/clock.js +2 -0
- package/dist/feature/identity/ports/clock.js.map +1 -0
- package/dist/feature/identity/ports/index.js +2 -0
- package/dist/feature/identity/ports/index.js.map +1 -0
- package/dist/feature/identity/ports/oidc.js +2 -0
- package/dist/feature/identity/ports/oidc.js.map +1 -0
- package/dist/feature/identity/ports/saml.js +2 -0
- package/dist/feature/identity/ports/saml.js.map +1 -0
- package/dist/feature/identity/repositories/index.js +7 -0
- package/dist/feature/identity/repositories/index.js.map +1 -0
- package/dist/feature/identity/repositories/links.js +57 -0
- package/dist/feature/identity/repositories/links.js.map +1 -0
- package/dist/feature/identity/repositories/saml-assertions.js +16 -0
- package/dist/feature/identity/repositories/saml-assertions.js.map +1 -0
- package/dist/feature/identity/repositories/sessions.js +27 -0
- package/dist/feature/identity/repositories/sessions.js.map +1 -0
- package/dist/feature/identity/repositories/sso-requests.js +34 -0
- package/dist/feature/identity/repositories/sso-requests.js.map +1 -0
- package/dist/feature/identity/repositories/tokens.js +55 -0
- package/dist/feature/identity/repositories/tokens.js.map +1 -0
- package/dist/feature/identity/repositories/users.js +75 -0
- package/dist/feature/identity/repositories/users.js.map +1 -0
- package/dist/feature/identity/services/cli-login.js +48 -0
- package/dist/feature/identity/services/cli-login.js.map +1 -0
- package/dist/feature/identity/services/create.js +76 -0
- package/dist/feature/identity/services/create.js.map +1 -0
- package/dist/feature/identity/services/index.js +10 -0
- package/dist/feature/identity/services/index.js.map +1 -0
- package/dist/feature/identity/services/saml.js +115 -0
- package/dist/feature/identity/services/saml.js.map +1 -0
- package/dist/feature/identity/services/sessions.js +81 -0
- package/dist/feature/identity/services/sessions.js.map +1 -0
- package/dist/feature/identity/services/sso-accounts.js +46 -0
- package/dist/feature/identity/services/sso-accounts.js.map +1 -0
- package/dist/feature/identity/services/sso.js +120 -0
- package/dist/feature/identity/services/sso.js.map +1 -0
- package/dist/feature/identity/services/system.js +15 -0
- package/dist/feature/identity/services/system.js.map +1 -0
- package/dist/feature/identity/services/tokens.js +74 -0
- package/dist/feature/identity/services/tokens.js.map +1 -0
- package/dist/feature/identity/services/users.js +103 -0
- package/dist/feature/identity/services/users.js.map +1 -0
- package/dist/feature/identity/types/claims.js +39 -0
- package/dist/feature/identity/types/claims.js.map +1 -0
- package/dist/feature/identity/types/index.js +5 -0
- package/dist/feature/identity/types/index.js.map +1 -0
- package/dist/feature/identity/types/token.js +11 -0
- package/dist/feature/identity/types/token.js.map +1 -0
- package/dist/feature/identity/types/ttl.js +19 -0
- package/dist/feature/identity/types/ttl.js.map +1 -0
- package/dist/feature/identity/types/user.js +47 -0
- package/dist/feature/identity/types/user.js.map +1 -0
- package/dist/feature/integrations/ports/adapter.js +2 -0
- package/dist/feature/integrations/ports/adapter.js.map +1 -0
- package/dist/feature/integrations/ports/changes.js +2 -0
- package/dist/feature/integrations/ports/changes.js.map +1 -0
- package/dist/feature/integrations/ports/index.js +5 -0
- package/dist/feature/integrations/ports/index.js.map +1 -0
- package/dist/feature/integrations/ports/operations.js +2 -0
- package/dist/feature/integrations/ports/operations.js.map +1 -0
- package/dist/feature/integrations/ports/secrets.js +2 -0
- package/dist/feature/integrations/ports/secrets.js.map +1 -0
- package/dist/feature/integrations/repositories/connections.js +89 -0
- package/dist/feature/integrations/repositories/connections.js.map +1 -0
- package/dist/feature/integrations/repositories/deliveries.js +56 -0
- package/dist/feature/integrations/repositories/deliveries.js.map +1 -0
- package/dist/feature/integrations/repositories/index.js +4 -0
- package/dist/feature/integrations/repositories/index.js.map +1 -0
- package/dist/feature/integrations/repositories/secrets.js +102 -0
- package/dist/feature/integrations/repositories/secrets.js.map +1 -0
- package/dist/feature/integrations/services/access.js +63 -0
- package/dist/feature/integrations/services/access.js.map +1 -0
- package/dist/feature/integrations/services/catalog.js +38 -0
- package/dist/feature/integrations/services/catalog.js.map +1 -0
- package/dist/feature/integrations/services/checks.js +66 -0
- package/dist/feature/integrations/services/checks.js.map +1 -0
- package/dist/feature/integrations/services/connections.js +189 -0
- package/dist/feature/integrations/services/connections.js.map +1 -0
- package/dist/feature/integrations/services/create.js +71 -0
- package/dist/feature/integrations/services/create.js.map +1 -0
- package/dist/feature/integrations/services/dispatch.js +162 -0
- package/dist/feature/integrations/services/dispatch.js.map +1 -0
- package/dist/feature/integrations/services/index.js +9 -0
- package/dist/feature/integrations/services/index.js.map +1 -0
- package/dist/feature/integrations/services/outbound.js +46 -0
- package/dist/feature/integrations/services/outbound.js.map +1 -0
- package/dist/feature/integrations/services/secrets.js +271 -0
- package/dist/feature/integrations/services/secrets.js.map +1 -0
- package/dist/feature/integrations/types/connection.js +81 -0
- package/dist/feature/integrations/types/connection.js.map +1 -0
- package/dist/feature/integrations/types/deliveries.js +5 -0
- package/dist/feature/integrations/types/deliveries.js.map +1 -0
- package/dist/feature/integrations/types/errors.js +58 -0
- package/dist/feature/integrations/types/errors.js.map +1 -0
- package/dist/feature/integrations/types/index.js +6 -0
- package/dist/feature/integrations/types/index.js.map +1 -0
- package/dist/feature/integrations/types/operations.js +16 -0
- package/dist/feature/integrations/types/operations.js.map +1 -0
- package/dist/feature/integrations/types/secrets.js +8 -0
- package/dist/feature/integrations/types/secrets.js.map +1 -0
- package/dist/feature/notifications/clients/index.js +7 -0
- package/dist/feature/notifications/clients/index.js.map +1 -0
- package/dist/feature/notifications/clients/slack/api.js +133 -0
- package/dist/feature/notifications/clients/slack/api.js.map +1 -0
- package/dist/feature/notifications/clients/slack/blocks.js +189 -0
- package/dist/feature/notifications/clients/slack/blocks.js.map +1 -0
- package/dist/feature/notifications/clients/slack/channel.js +219 -0
- package/dist/feature/notifications/clients/slack/channel.js.map +1 -0
- package/dist/feature/notifications/clients/slack/events.js +117 -0
- package/dist/feature/notifications/clients/slack/events.js.map +1 -0
- package/dist/feature/notifications/clients/slack/kind.js +39 -0
- package/dist/feature/notifications/clients/slack/kind.js.map +1 -0
- package/dist/feature/notifications/clients/slack/socket.js +141 -0
- package/dist/feature/notifications/clients/slack/socket.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/api.js +93 -0
- package/dist/feature/notifications/clients/telegram/api.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/channel.js +250 -0
- package/dist/feature/notifications/clients/telegram/channel.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/kind.js +34 -0
- package/dist/feature/notifications/clients/telegram/kind.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/render.js +68 -0
- package/dist/feature/notifications/clients/telegram/render.js.map +1 -0
- package/dist/feature/notifications/clients/telegram/updates.js +71 -0
- package/dist/feature/notifications/clients/telegram/updates.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/channel.js +131 -0
- package/dist/feature/notifications/clients/webhook/channel.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/kind.js +52 -0
- package/dist/feature/notifications/clients/webhook/kind.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/payload.js +96 -0
- package/dist/feature/notifications/clients/webhook/payload.js.map +1 -0
- package/dist/feature/notifications/clients/webhook/sign.js +15 -0
- package/dist/feature/notifications/clients/webhook/sign.js.map +1 -0
- package/dist/feature/notifications/ports/channel.js +2 -0
- package/dist/feature/notifications/ports/channel.js.map +1 -0
- package/dist/feature/notifications/ports/index.js +2 -0
- package/dist/feature/notifications/ports/index.js.map +1 -0
- package/dist/feature/notifications/ports/publish.js +2 -0
- package/dist/feature/notifications/ports/publish.js.map +1 -0
- package/dist/feature/notifications/repositories/answers.js +25 -0
- package/dist/feature/notifications/repositories/answers.js.map +1 -0
- package/dist/feature/notifications/repositories/attempts.js +34 -0
- package/dist/feature/notifications/repositories/attempts.js.map +1 -0
- package/dist/feature/notifications/repositories/cursors.js +25 -0
- package/dist/feature/notifications/repositories/cursors.js.map +1 -0
- package/dist/feature/notifications/repositories/deliveries.js +118 -0
- package/dist/feature/notifications/repositories/deliveries.js.map +1 -0
- package/dist/feature/notifications/repositories/index.js +7 -0
- package/dist/feature/notifications/repositories/index.js.map +1 -0
- package/dist/feature/notifications/repositories/outcomes.js +80 -0
- package/dist/feature/notifications/repositories/outcomes.js.map +1 -0
- package/dist/feature/notifications/repositories/subscriptions.js +85 -0
- package/dist/feature/notifications/repositories/subscriptions.js.map +1 -0
- package/dist/feature/notifications/services/channels.js +199 -0
- package/dist/feature/notifications/services/channels.js.map +1 -0
- package/dist/feature/notifications/services/closer.js +79 -0
- package/dist/feature/notifications/services/closer.js.map +1 -0
- package/dist/feature/notifications/services/create.js +116 -0
- package/dist/feature/notifications/services/create.js.map +1 -0
- package/dist/feature/notifications/services/dispatcher.js +210 -0
- package/dist/feature/notifications/services/dispatcher.js.map +1 -0
- package/dist/feature/notifications/services/drawing.js +27 -0
- package/dist/feature/notifications/services/drawing.js.map +1 -0
- package/dist/feature/notifications/services/factories.js +31 -0
- package/dist/feature/notifications/services/factories.js.map +1 -0
- package/dist/feature/notifications/services/inbound.js +172 -0
- package/dist/feature/notifications/services/inbound.js.map +1 -0
- package/dist/feature/notifications/services/index.js +10 -0
- package/dist/feature/notifications/services/index.js.map +1 -0
- package/dist/feature/notifications/services/journal.js +38 -0
- package/dist/feature/notifications/services/journal.js.map +1 -0
- package/dist/feature/notifications/services/lanes.js +28 -0
- package/dist/feature/notifications/services/lanes.js.map +1 -0
- package/dist/feature/notifications/services/outbox.js +2 -0
- package/dist/feature/notifications/services/outbox.js.map +1 -0
- package/dist/feature/notifications/services/sender.js +129 -0
- package/dist/feature/notifications/services/sender.js.map +1 -0
- package/dist/feature/notifications/services/senders/index.js +3 -0
- package/dist/feature/notifications/services/senders/index.js.map +1 -0
- package/dist/feature/notifications/services/senders/recent.js +32 -0
- package/dist/feature/notifications/services/senders/recent.js.map +1 -0
- package/dist/feature/notifications/services/senders/senders.js +23 -0
- package/dist/feature/notifications/services/senders/senders.js.map +1 -0
- package/dist/feature/notifications/services/subscriptions.js +221 -0
- package/dist/feature/notifications/services/subscriptions.js.map +1 -0
- package/dist/feature/notifications/services/webhooks/index.js +3 -0
- package/dist/feature/notifications/services/webhooks/index.js.map +1 -0
- package/dist/feature/notifications/services/webhooks/streaks.js +44 -0
- package/dist/feature/notifications/services/webhooks/streaks.js.map +1 -0
- package/dist/feature/notifications/services/webhooks/webhooks.js +249 -0
- package/dist/feature/notifications/services/webhooks/webhooks.js.map +1 -0
- package/dist/feature/notifications/types/answers.js +42 -0
- package/dist/feature/notifications/types/answers.js.map +1 -0
- package/dist/feature/notifications/types/channel.js +20 -0
- package/dist/feature/notifications/types/channel.js.map +1 -0
- package/dist/feature/notifications/types/display-url.js +11 -0
- package/dist/feature/notifications/types/display-url.js.map +1 -0
- package/dist/feature/notifications/types/drafts.js +35 -0
- package/dist/feature/notifications/types/drafts.js.map +1 -0
- package/dist/feature/notifications/types/errors.js +38 -0
- package/dist/feature/notifications/types/errors.js.map +1 -0
- package/dist/feature/notifications/types/events.js +137 -0
- package/dist/feature/notifications/types/events.js.map +1 -0
- package/dist/feature/notifications/types/index.js +13 -0
- package/dist/feature/notifications/types/index.js.map +1 -0
- package/dist/feature/notifications/types/limits.js +32 -0
- package/dist/feature/notifications/types/limits.js.map +1 -0
- package/dist/feature/notifications/types/model.js +29 -0
- package/dist/feature/notifications/types/model.js.map +1 -0
- package/dist/feature/notifications/types/render.js +132 -0
- package/dist/feature/notifications/types/render.js.map +1 -0
- package/dist/feature/notifications/types/retry.js +35 -0
- package/dist/feature/notifications/types/retry.js.map +1 -0
- package/dist/feature/notifications/types/texts.js +130 -0
- package/dist/feature/notifications/types/texts.js.map +1 -0
- package/dist/feature/notifications/types/webhooks.js +22 -0
- package/dist/feature/notifications/types/webhooks.js.map +1 -0
- package/dist/feature/queue/repositories/queues.js +7 -4
- package/dist/feature/queue/repositories/queues.js.map +1 -1
- package/dist/feature/queue/services/advance.js +3 -0
- package/dist/feature/queue/services/advance.js.map +1 -1
- package/dist/feature/queue/services/create.js +2 -0
- package/dist/feature/queue/services/create.js.map +1 -1
- package/dist/feature/queue/services/edit.js +33 -11
- package/dist/feature/queue/services/edit.js.map +1 -1
- package/dist/feature/queue/services/items.js +31 -48
- package/dist/feature/queue/services/items.js.map +1 -1
- package/dist/feature/queue/services/links.js +10 -4
- package/dist/feature/queue/services/links.js.map +1 -1
- package/dist/feature/queue/services/projects.js +26 -9
- package/dist/feature/queue/services/projects.js.map +1 -1
- package/dist/feature/queue/services/task-tags.js +30 -15
- package/dist/feature/queue/services/task-tags.js.map +1 -1
- package/dist/feature/queue/services/worker/tasks.js +108 -0
- package/dist/feature/queue/services/worker/tasks.js.map +1 -0
- package/dist/feature/queue/types/advance.js +1 -0
- package/dist/feature/queue/types/advance.js.map +1 -1
- package/dist/feature/queue/types/duplicates.js +46 -0
- package/dist/feature/queue/types/duplicates.js.map +1 -0
- package/dist/feature/queue/types/edit.js +7 -2
- package/dist/feature/queue/types/edit.js.map +1 -1
- package/dist/feature/queue/types/filter.js +3 -3
- package/dist/feature/queue/types/filter.js.map +1 -1
- package/dist/feature/queue/types/global/queue.js +2 -2
- package/dist/feature/queue/types/global/queue.js.map +1 -1
- package/dist/feature/queue/types/index.js +1 -0
- package/dist/feature/queue/types/index.js.map +1 -1
- package/dist/feature/queue/types/items.js.map +1 -1
- package/dist/feature/queue/types/limit-hits.js +3 -0
- package/dist/feature/queue/types/limit-hits.js.map +1 -1
- package/dist/feature/queue/types/returns.js +3 -0
- package/dist/feature/queue/types/returns.js.map +1 -1
- package/dist/feature/repos/services/projects.js +26 -2
- package/dist/feature/repos/services/projects.js.map +1 -1
- package/dist/feature/repos/types/index.js +1 -0
- package/dist/feature/repos/types/index.js.map +1 -1
- package/dist/feature/repos/types/remote.js +28 -0
- package/dist/feature/repos/types/remote.js.map +1 -0
- package/dist/feature/runs/machine/answers.js +13 -0
- package/dist/feature/runs/machine/answers.js.map +1 -1
- package/dist/feature/runs/machine/delivery-checks.js +4 -2
- package/dist/feature/runs/machine/delivery-checks.js.map +1 -1
- package/dist/feature/runs/machine/delivery-flow.js +18 -1
- package/dist/feature/runs/machine/delivery-flow.js.map +1 -1
- package/dist/feature/runs/machine/exits.js +1 -1
- package/dist/feature/runs/machine/exits.js.map +1 -1
- package/dist/feature/runs/machine/plan.js +17 -4
- package/dist/feature/runs/machine/plan.js.map +1 -1
- package/dist/feature/runs/machine/provider/index.js +2 -0
- package/dist/feature/runs/machine/provider/index.js.map +1 -0
- package/dist/feature/runs/machine/provider/set-provider.js +71 -0
- package/dist/feature/runs/machine/provider/set-provider.js.map +1 -0
- package/dist/feature/runs/machine/push/index.js +2 -0
- package/dist/feature/runs/machine/push/index.js.map +1 -0
- package/dist/feature/runs/machine/push/push.js +48 -0
- package/dist/feature/runs/machine/push/push.js.map +1 -0
- package/dist/feature/runs/machine/restart/index.js +2 -0
- package/dist/feature/runs/machine/restart/index.js.map +1 -0
- package/dist/feature/runs/machine/restart/restart-step.js +31 -0
- package/dist/feature/runs/machine/restart/restart-step.js.map +1 -0
- package/dist/feature/runs/machine/scheduler.js +33 -7
- package/dist/feature/runs/machine/scheduler.js.map +1 -1
- package/dist/feature/runs/machine/texts.js +3 -1
- package/dist/feature/runs/machine/texts.js.map +1 -1
- package/dist/feature/runs/machine/transition.js +28 -4
- package/dist/feature/runs/machine/transition.js.map +1 -1
- package/dist/feature/runs/machine/variant/set-variant.js +3 -22
- package/dist/feature/runs/machine/variant/set-variant.js.map +1 -1
- package/dist/feature/runs/ports/commits.js +2 -0
- package/dist/feature/runs/ports/commits.js.map +1 -0
- package/dist/feature/runs/ports/notify.js +2 -0
- package/dist/feature/runs/ports/notify.js.map +1 -0
- package/dist/feature/runs/ports/push.js +2 -0
- package/dist/feature/runs/ports/push.js.map +1 -0
- package/dist/feature/runs/ports/registry-project.js +2 -0
- package/dist/feature/runs/ports/registry-project.js.map +1 -0
- package/dist/feature/runs/ports/registry-skills.js +2 -0
- package/dist/feature/runs/ports/registry-skills.js.map +1 -0
- package/dist/feature/runs/ports/remote-mcp.js +2 -0
- package/dist/feature/runs/ports/remote-mcp.js.map +1 -0
- package/dist/feature/runs/repositories/finished-runs.js +5 -1
- package/dist/feature/runs/repositories/finished-runs.js.map +1 -1
- package/dist/feature/runs/repositories/rows.js +18 -0
- package/dist/feature/runs/repositories/rows.js.map +1 -1
- package/dist/feature/runs/repositories/write.js +7 -7
- package/dist/feature/runs/repositories/write.js.map +1 -1
- package/dist/feature/runs/services/create.js +1 -0
- package/dist/feature/runs/services/create.js.map +1 -1
- package/dist/feature/runs/services/effects/actions.js +2 -1
- package/dist/feature/runs/services/effects/actions.js.map +1 -1
- package/dist/feature/runs/services/effects/attempts.js +57 -80
- package/dist/feature/runs/services/effects/attempts.js.map +1 -1
- package/dist/feature/runs/services/effects/context.js +2 -0
- package/dist/feature/runs/services/effects/context.js.map +1 -1
- package/dist/feature/runs/services/effects/conversations.js +238 -0
- package/dist/feature/runs/services/effects/conversations.js.map +1 -0
- package/dist/feature/runs/services/effects/effects.js +2 -0
- package/dist/feature/runs/services/effects/effects.js.map +1 -1
- package/dist/feature/runs/services/effects/git.js +17 -2
- package/dist/feature/runs/services/effects/git.js.map +1 -1
- package/dist/feature/runs/services/effects/naming.js +1 -1
- package/dist/feature/runs/services/effects/naming.js.map +1 -1
- package/dist/feature/runs/services/effects/runtime-check.js +28 -0
- package/dist/feature/runs/services/effects/runtime-check.js.map +1 -1
- package/dist/feature/runs/services/effects/skills/index.js +3 -0
- package/dist/feature/runs/services/effects/skills/index.js.map +1 -0
- package/dist/feature/runs/services/effects/skills/outside-queue.js +58 -0
- package/dist/feature/runs/services/effects/skills/outside-queue.js.map +1 -0
- package/dist/feature/runs/services/effects/skills/registry.js +70 -0
- package/dist/feature/runs/services/effects/skills/registry.js.map +1 -0
- package/dist/feature/runs/services/engine.js +8 -1
- package/dist/feature/runs/services/engine.js.map +1 -1
- package/dist/feature/runs/services/index.js +2 -2
- package/dist/feature/runs/services/index.js.map +1 -1
- package/dist/feature/runs/services/reads.js +30 -1
- package/dist/feature/runs/services/reads.js.map +1 -1
- package/dist/feature/runs/services/refresh.js +23 -1
- package/dist/feature/runs/services/refresh.js.map +1 -1
- package/dist/feature/runs/services/requests.js +21 -4
- package/dist/feature/runs/services/requests.js.map +1 -1
- package/dist/feature/runs/services/states.js +2 -2
- package/dist/feature/runs/services/states.js.map +1 -1
- package/dist/feature/runs/types/answers/answers-text.js +7 -0
- package/dist/feature/runs/types/answers/answers-text.js.map +1 -0
- package/dist/feature/runs/types/attempt.js +2 -0
- package/dist/feature/runs/types/attempt.js.map +1 -1
- package/dist/feature/runs/types/chains/chain-select.js +93 -0
- package/dist/feature/runs/types/chains/chain-select.js.map +1 -0
- package/dist/feature/runs/types/constants.js +1 -1
- package/dist/feature/runs/types/constants.js.map +1 -1
- package/dist/feature/runs/types/create.js +17 -4
- package/dist/feature/runs/types/create.js.map +1 -1
- package/dist/feature/runs/types/index.js +2 -0
- package/dist/feature/runs/types/index.js.map +1 -1
- package/dist/feature/runs/types/input.js +2 -1
- package/dist/feature/runs/types/input.js.map +1 -1
- package/dist/feature/runs/types/limits.js +11 -55
- package/dist/feature/runs/types/limits.js.map +1 -1
- package/dist/feature/runs/types/problems.js +9 -5
- package/dist/feature/runs/types/problems.js.map +1 -1
- package/dist/feature/runs/types/run.js.map +1 -1
- package/dist/feature/runs/types/stage-status.js +3 -1
- package/dist/feature/runs/types/stage-status.js.map +1 -1
- package/dist/feature/service-registry/clients/http-mcp/client.js +164 -0
- package/dist/feature/service-registry/clients/http-mcp/client.js.map +1 -0
- package/dist/feature/service-registry/clients/http-mcp/index.js +2 -0
- package/dist/feature/service-registry/clients/http-mcp/index.js.map +1 -0
- package/dist/feature/service-registry/ports/adapter.js +2 -0
- package/dist/feature/service-registry/ports/adapter.js.map +1 -0
- package/dist/feature/service-registry/ports/index.js +3 -0
- package/dist/feature/service-registry/ports/index.js.map +1 -0
- package/dist/feature/service-registry/ports/transport.js +2 -0
- package/dist/feature/service-registry/ports/transport.js.map +1 -0
- package/dist/feature/service-registry/repositories/index.js +2 -0
- package/dist/feature/service-registry/repositories/index.js.map +1 -0
- package/dist/feature/service-registry/repositories/links.js +61 -0
- package/dist/feature/service-registry/repositories/links.js.map +1 -0
- package/dist/feature/service-registry/services/adapter.js +63 -0
- package/dist/feature/service-registry/services/adapter.js.map +1 -0
- package/dist/feature/service-registry/services/calls.js +86 -0
- package/dist/feature/service-registry/services/calls.js.map +1 -0
- package/dist/feature/service-registry/services/catalog-scan.js +49 -0
- package/dist/feature/service-registry/services/catalog-scan.js.map +1 -0
- package/dist/feature/service-registry/services/create.js +30 -0
- package/dist/feature/service-registry/services/create.js.map +1 -0
- package/dist/feature/service-registry/services/forwarder.js +107 -0
- package/dist/feature/service-registry/services/forwarder.js.map +1 -0
- package/dist/feature/service-registry/services/index.js +6 -0
- package/dist/feature/service-registry/services/index.js.map +1 -0
- package/dist/feature/service-registry/services/links.js +256 -0
- package/dist/feature/service-registry/services/links.js.map +1 -0
- package/dist/feature/service-registry/services/skill-cache.js +135 -0
- package/dist/feature/service-registry/services/skill-cache.js.map +1 -0
- package/dist/feature/service-registry/services/skill-source.js +128 -0
- package/dist/feature/service-registry/services/skill-source.js.map +1 -0
- package/dist/feature/service-registry/services/skills.js +197 -0
- package/dist/feature/service-registry/services/skills.js.map +1 -0
- package/dist/feature/service-registry/types/descriptor.js +41 -0
- package/dist/feature/service-registry/types/descriptor.js.map +1 -0
- package/dist/feature/service-registry/types/endpoint.js +2 -0
- package/dist/feature/service-registry/types/endpoint.js.map +1 -0
- package/dist/feature/service-registry/types/errors.js +26 -0
- package/dist/feature/service-registry/types/errors.js.map +1 -0
- package/dist/feature/service-registry/types/index.js +7 -0
- package/dist/feature/service-registry/types/index.js.map +1 -0
- package/dist/feature/service-registry/types/link.js +26 -0
- package/dist/feature/service-registry/types/link.js.map +1 -0
- package/dist/feature/service-registry/types/semver.js +2 -0
- package/dist/feature/service-registry/types/semver.js.map +1 -0
- package/dist/feature/service-registry/types/skills.js +27 -0
- package/dist/feature/service-registry/types/skills.js.map +1 -0
- package/dist/feature/stats/repositories/meta.js +10 -0
- package/dist/feature/stats/repositories/meta.js.map +1 -1
- package/dist/feature/stats/repositories/records.js +18 -7
- package/dist/feature/stats/repositories/records.js.map +1 -1
- package/dist/feature/stats/repositories/report.js +14 -4
- package/dist/feature/stats/repositories/report.js.map +1 -1
- package/dist/feature/stats/services/ledger.js +16 -1
- package/dist/feature/stats/services/ledger.js.map +1 -1
- package/dist/feature/stats/services/report.js +7 -2
- package/dist/feature/stats/services/report.js.map +1 -1
- package/dist/feature/stats/types/capture.js +3 -0
- package/dist/feature/stats/types/capture.js.map +1 -1
- package/dist/feature/stats/types/records.js.map +1 -1
- package/dist/feature/stats/types/report.js +2 -0
- package/dist/feature/stats/types/report.js.map +1 -1
- package/dist/feature/swarm-config/repositories/config-files.js +3 -1
- package/dist/feature/swarm-config/repositories/config-files.js.map +1 -1
- package/dist/feature/swarm-config/services/access/file.js +83 -0
- package/dist/feature/swarm-config/services/access/file.js.map +1 -0
- package/dist/feature/swarm-config/services/access/index.js +3 -0
- package/dist/feature/swarm-config/services/access/index.js.map +1 -0
- package/dist/feature/swarm-config/services/access/validate.js +134 -0
- package/dist/feature/swarm-config/services/access/validate.js.map +1 -0
- package/dist/feature/swarm-config/services/assemble.js +52 -2
- package/dist/feature/swarm-config/services/assemble.js.map +1 -1
- package/dist/feature/swarm-config/services/index.js +3 -2
- package/dist/feature/swarm-config/services/index.js.map +1 -1
- package/dist/feature/swarm-config/services/load.js +22 -2
- package/dist/feature/swarm-config/services/load.js.map +1 -1
- package/dist/feature/swarm-config/services/sections/mcp-servers.js +33 -5
- package/dist/feature/swarm-config/services/sections/mcp-servers.js.map +1 -1
- package/dist/feature/swarm-config/services/sections/provider-access.js +158 -0
- package/dist/feature/swarm-config/services/sections/provider-access.js.map +1 -0
- package/dist/feature/swarm-config/services/sections/provider-models.js +56 -0
- package/dist/feature/swarm-config/services/sections/provider-models.js.map +1 -0
- package/dist/feature/swarm-config/services/sections/providers.js +105 -0
- package/dist/feature/swarm-config/services/sections/providers.js.map +1 -0
- package/dist/feature/swarm-config/services/sections/queue.js +3 -2
- package/dist/feature/swarm-config/services/sections/queue.js.map +1 -1
- package/dist/feature/swarm-config/services/sections/roles.js +27 -0
- package/dist/feature/swarm-config/services/sections/roles.js.map +1 -0
- package/dist/feature/swarm-config/services/sections/server-saml.js +116 -0
- package/dist/feature/swarm-config/services/sections/server-saml.js.map +1 -0
- package/dist/feature/swarm-config/services/sections/server.js +272 -0
- package/dist/feature/swarm-config/services/sections/server.js.map +1 -0
- package/dist/feature/swarm-config/services/settings.js +36 -2
- package/dist/feature/swarm-config/services/settings.js.map +1 -1
- package/dist/feature/swarm-config/services/validate-runtimes.js +60 -6
- package/dist/feature/swarm-config/services/validate-runtimes.js.map +1 -1
- package/dist/feature/swarm-config/services/validate-settings.js +51 -3
- package/dist/feature/swarm-config/services/validate-settings.js.map +1 -1
- package/dist/feature/swarm-config/services/validate-specialists.js +23 -0
- package/dist/feature/swarm-config/services/validate-specialists.js.map +1 -1
- package/dist/feature/swarm-config/services/validate.js +42 -3
- package/dist/feature/swarm-config/services/validate.js.map +1 -1
- package/dist/feature/swarm-config/types/access/index.js +2 -0
- package/dist/feature/swarm-config/types/access/index.js.map +1 -0
- package/dist/feature/swarm-config/types/access/policy.js +10 -0
- package/dist/feature/swarm-config/types/access/policy.js.map +1 -0
- package/dist/feature/swarm-config/types/chain.js +9 -1
- package/dist/feature/swarm-config/types/chain.js.map +1 -1
- package/dist/feature/swarm-config/types/index.js +3 -0
- package/dist/feature/swarm-config/types/index.js.map +1 -1
- package/dist/feature/swarm-config/types/levels.js +1 -0
- package/dist/feature/swarm-config/types/levels.js.map +1 -1
- package/dist/feature/swarm-config/types/machine/machine-settings.js +45 -0
- package/dist/feature/swarm-config/types/machine/machine-settings.js.map +1 -0
- package/dist/feature/swarm-config/types/merge.js +2 -0
- package/dist/feature/swarm-config/types/merge.js.map +1 -1
- package/dist/feature/swarm-config/types/providers/provider.js +55 -0
- package/dist/feature/swarm-config/types/providers/provider.js.map +1 -0
- package/dist/feature/swarm-config/types/settings.js +42 -52
- package/dist/feature/swarm-config/types/settings.js.map +1 -1
- package/dist/feature/swarm-config/types/skills/index.js +3 -0
- package/dist/feature/swarm-config/types/skills/index.js.map +1 -0
- package/dist/feature/swarm-config/types/skills/semver.js +250 -0
- package/dist/feature/swarm-config/types/skills/semver.js.map +1 -0
- package/dist/feature/swarm-config/types/skills/skill-ref.js +35 -0
- package/dist/feature/swarm-config/types/skills/skill-ref.js.map +1 -0
- package/dist/feature/swarm-config/types/specialist.js +8 -1
- package/dist/feature/swarm-config/types/specialist.js.map +1 -1
- package/dist/feature/swarm-config/types/web/index.js +2 -0
- package/dist/feature/swarm-config/types/web/index.js.map +1 -0
- package/dist/feature/swarm-config/types/web/settings.js +14 -0
- package/dist/feature/swarm-config/types/web/settings.js.map +1 -0
- package/dist/feature/swarm-edit/services/config-edits.js +19 -5
- package/dist/feature/swarm-edit/services/config-edits.js.map +1 -1
- package/dist/feature/swarm-edit/services/editor-settings.js +1 -0
- package/dist/feature/swarm-edit/services/editor-settings.js.map +1 -1
- package/dist/feature/swarm-edit/services/editor-view.js +11 -1
- package/dist/feature/swarm-edit/services/editor-view.js.map +1 -1
- package/dist/feature/swarm-edit/services/index.js +1 -1
- package/dist/feature/swarm-edit/services/index.js.map +1 -1
- package/dist/feature/swarm-edit/services/levels.js +1 -0
- package/dist/feature/swarm-edit/services/levels.js.map +1 -1
- package/dist/feature/swarm-edit/services/mcp/editor-mcp.js +2 -0
- package/dist/feature/swarm-edit/services/mcp/editor-mcp.js.map +1 -1
- package/dist/feature/swarm-edit/services/plan-edit.js +9 -4
- package/dist/feature/swarm-edit/services/plan-edit.js.map +1 -1
- package/dist/feature/swarm-edit/services/plan-settings.js +4 -2
- package/dist/feature/swarm-edit/services/plan-settings.js.map +1 -1
- package/dist/feature/swarm-edit/services/references.js +36 -1
- package/dist/feature/swarm-edit/services/references.js.map +1 -1
- package/dist/feature/swarm-edit/services/shared-config.js +5 -0
- package/dist/feature/swarm-edit/services/shared-config.js.map +1 -1
- package/dist/feature/swarm-edit/types/editor.js +3 -1
- package/dist/feature/swarm-edit/types/editor.js.map +1 -1
- package/dist/feature/swarm-edit/types/setting-fields.js +4 -2
- package/dist/feature/swarm-edit/types/setting-fields.js.map +1 -1
- package/dist/feature/swarm-edit/types/stages.js +1 -0
- package/dist/feature/swarm-edit/types/stages.js.map +1 -1
- package/dist/feature/tags/types/tags.js +0 -4
- package/dist/feature/tags/types/tags.js.map +1 -1
- package/dist/platform/archive/index.js +2 -0
- package/dist/platform/archive/index.js.map +1 -0
- package/dist/platform/archive/zip.js +164 -0
- package/dist/platform/archive/zip.js.map +1 -0
- package/dist/platform/files/index.js +2 -0
- package/dist/platform/files/index.js.map +1 -0
- package/dist/platform/files/read.js +20 -0
- package/dist/platform/files/read.js.map +1 -0
- package/dist/platform/git/authorship.js +12 -0
- package/dist/platform/git/authorship.js.map +1 -0
- package/dist/platform/git/changes.js +26 -0
- package/dist/platform/git/changes.js.map +1 -0
- package/dist/platform/git/delivery.js +8 -20
- package/dist/platform/git/delivery.js.map +1 -1
- package/dist/platform/git/index.js +3 -0
- package/dist/platform/git/index.js.map +1 -1
- package/dist/platform/git/remote.js +69 -0
- package/dist/platform/git/remote.js.map +1 -0
- package/dist/platform/git/workspace.js +3 -4
- package/dist/platform/git/workspace.js.map +1 -1
- package/dist/platform/http/index.js +3 -0
- package/dist/platform/http/index.js.map +1 -0
- package/dist/platform/http/request.js +157 -0
- package/dist/platform/http/request.js.map +1 -0
- package/dist/platform/http/websocket-frames.js +155 -0
- package/dist/platform/http/websocket-frames.js.map +1 -0
- package/dist/platform/http/websocket.js +259 -0
- package/dist/platform/http/websocket.js.map +1 -0
- package/dist/platform/paths/index.js +1 -1
- package/dist/platform/paths/index.js.map +1 -1
- package/dist/platform/paths/paths.js +6 -0
- package/dist/platform/paths/paths.js.map +1 -1
- package/dist/platform/secrets/command.js +30 -0
- package/dist/platform/secrets/command.js.map +1 -0
- package/dist/platform/secrets/errors.js +16 -0
- package/dist/platform/secrets/errors.js.map +1 -0
- package/dist/platform/secrets/file-key.js +43 -0
- package/dist/platform/secrets/file-key.js.map +1 -0
- package/dist/platform/secrets/file.js +158 -0
- package/dist/platform/secrets/file.js.map +1 -0
- package/dist/platform/secrets/index.js +6 -0
- package/dist/platform/secrets/index.js.map +1 -0
- package/dist/platform/secrets/keyring.js +73 -0
- package/dist/platform/secrets/keyring.js.map +1 -0
- package/dist/platform/secrets/select.js +124 -0
- package/dist/platform/secrets/select.js.map +1 -0
- package/dist/platform/secrets/store.js +2 -0
- package/dist/platform/secrets/store.js.map +1 -0
- package/dist/platform/sqlite/authorship-migration.js +23 -0
- package/dist/platform/sqlite/authorship-migration.js.map +1 -0
- package/dist/platform/sqlite/identity-migration.js +52 -0
- package/dist/platform/sqlite/identity-migration.js.map +1 -0
- package/dist/platform/sqlite/integrations-migration.js +147 -0
- package/dist/platform/sqlite/integrations-migration.js.map +1 -0
- package/dist/platform/sqlite/parts.js +32 -1
- package/dist/platform/sqlite/parts.js.map +1 -1
- package/dist/platform/sqlite/saml-migration.js +9 -0
- package/dist/platform/sqlite/saml-migration.js.map +1 -0
- package/dist/platform/sqlite/sso-migration.js +17 -0
- package/dist/platform/sqlite/sso-migration.js.map +1 -0
- package/dist/platform/sqlite/stats-migration.js +8 -0
- package/dist/platform/sqlite/stats-migration.js.map +1 -1
- package/dist/presentation/cli/commands/daemon.js +5 -3
- package/dist/presentation/cli/commands/daemon.js.map +1 -1
- package/dist/presentation/cli/commands/integration/index.js +3 -0
- package/dist/presentation/cli/commands/integration/index.js.map +1 -0
- package/dist/presentation/cli/commands/integration/integrations.js +239 -0
- package/dist/presentation/cli/commands/integration/integrations.js.map +1 -0
- package/dist/presentation/cli/commands/integration/skills.js +24 -0
- package/dist/presentation/cli/commands/integration/skills.js.map +1 -0
- package/dist/presentation/cli/commands/mcp.js +23 -1
- package/dist/presentation/cli/commands/mcp.js.map +1 -1
- package/dist/presentation/cli/commands/notify/index.js +2 -0
- package/dist/presentation/cli/commands/notify/index.js.map +1 -0
- package/dist/presentation/cli/commands/notify/notify.js +145 -0
- package/dist/presentation/cli/commands/notify/notify.js.map +1 -0
- package/dist/presentation/cli/commands/provider/index.js +2 -0
- package/dist/presentation/cli/commands/provider/index.js.map +1 -0
- package/dist/presentation/cli/commands/provider/provider.js +49 -0
- package/dist/presentation/cli/commands/provider/provider.js.map +1 -0
- package/dist/presentation/cli/commands/queue-edit.js +17 -26
- package/dist/presentation/cli/commands/queue-edit.js.map +1 -1
- package/dist/presentation/cli/commands/queue.js +3 -2
- package/dist/presentation/cli/commands/queue.js.map +1 -1
- package/dist/presentation/cli/commands/run-delivery.js +47 -2
- package/dist/presentation/cli/commands/run-delivery.js.map +1 -1
- package/dist/presentation/cli/commands/run.js +28 -7
- package/dist/presentation/cli/commands/run.js.map +1 -1
- package/dist/presentation/cli/commands/server/access.js +43 -0
- package/dist/presentation/cli/commands/server/access.js.map +1 -0
- package/dist/presentation/cli/commands/server/admin.js +118 -0
- package/dist/presentation/cli/commands/server/admin.js.map +1 -0
- package/dist/presentation/cli/commands/server/apply.js +82 -0
- package/dist/presentation/cli/commands/server/apply.js.map +1 -0
- package/dist/presentation/cli/commands/server/audit.js +38 -0
- package/dist/presentation/cli/commands/server/audit.js.map +1 -0
- package/dist/presentation/cli/commands/server/login.js +141 -0
- package/dist/presentation/cli/commands/server/login.js.map +1 -0
- package/dist/presentation/cli/commands/server/profile.js +38 -0
- package/dist/presentation/cli/commands/server/profile.js.map +1 -0
- package/dist/presentation/cli/commands/server/register.js +12 -0
- package/dist/presentation/cli/commands/server/register.js.map +1 -0
- package/dist/presentation/cli/commands/server/repository.js +34 -0
- package/dist/presentation/cli/commands/server/repository.js.map +1 -0
- package/dist/presentation/cli/commands/stats.js +10 -1
- package/dist/presentation/cli/commands/stats.js.map +1 -1
- package/dist/presentation/cli/commands/web.js +26 -5
- package/dist/presentation/cli/commands/web.js.map +1 -1
- package/dist/presentation/cli/commands/webhook/index.js +2 -0
- package/dist/presentation/cli/commands/webhook/index.js.map +1 -0
- package/dist/presentation/cli/commands/webhook/webhook.js +172 -0
- package/dist/presentation/cli/commands/webhook/webhook.js.map +1 -0
- package/dist/presentation/cli/context.js +34 -2
- package/dist/presentation/cli/context.js.map +1 -1
- package/dist/presentation/cli/help.js +21 -2
- package/dist/presentation/cli/help.js.map +1 -1
- package/dist/presentation/cli/io.js.map +1 -1
- package/dist/presentation/cli/local/config-check-providers.js +47 -0
- package/dist/presentation/cli/local/config-check-providers.js.map +1 -0
- package/dist/presentation/cli/local/config-check.js +24 -9
- package/dist/presentation/cli/local/config-check.js.map +1 -1
- package/dist/presentation/cli/options.js +53 -0
- package/dist/presentation/cli/options.js.map +1 -1
- package/dist/presentation/cli/program.js +10 -0
- package/dist/presentation/cli/program.js.map +1 -1
- package/dist/presentation/cli/queue-add.js +54 -35
- package/dist/presentation/cli/queue-add.js.map +1 -1
- package/dist/presentation/cli/queue-print.js +34 -1
- package/dist/presentation/cli/queue-print.js.map +1 -1
- package/dist/presentation/cli/secret-keys.js +38 -0
- package/dist/presentation/cli/secret-keys.js.map +1 -0
- package/dist/presentation/format/access/access.js +30 -0
- package/dist/presentation/format/access/access.js.map +1 -0
- package/dist/presentation/format/access/index.js +2 -0
- package/dist/presentation/format/access/index.js.map +1 -0
- package/dist/presentation/format/audit/audit.js +29 -0
- package/dist/presentation/format/audit/audit.js.map +1 -0
- package/dist/presentation/format/audit/index.js +2 -0
- package/dist/presentation/format/audit/index.js.map +1 -0
- package/dist/presentation/format/groups.js +13 -0
- package/dist/presentation/format/groups.js.map +1 -1
- package/dist/presentation/format/index.js +6 -0
- package/dist/presentation/format/index.js.map +1 -1
- package/dist/presentation/format/integration/index.js +3 -0
- package/dist/presentation/format/integration/index.js.map +1 -0
- package/dist/presentation/format/integration/integrations.js +95 -0
- package/dist/presentation/format/integration/integrations.js.map +1 -0
- package/dist/presentation/format/integration/skills.js +17 -0
- package/dist/presentation/format/integration/skills.js.map +1 -0
- package/dist/presentation/format/notifications/index.js +2 -0
- package/dist/presentation/format/notifications/index.js.map +1 -0
- package/dist/presentation/format/notifications/notifications.js +44 -0
- package/dist/presentation/format/notifications/notifications.js.map +1 -0
- package/dist/presentation/format/overview.js +2 -1
- package/dist/presentation/format/overview.js.map +1 -1
- package/dist/presentation/format/providers/index.js +3 -0
- package/dist/presentation/format/providers/index.js.map +1 -0
- package/dist/presentation/format/providers/provider-list.js +72 -0
- package/dist/presentation/format/providers/provider-list.js.map +1 -0
- package/dist/presentation/format/providers/providers.js +13 -0
- package/dist/presentation/format/providers/providers.js.map +1 -0
- package/dist/presentation/format/queue.js +8 -3
- package/dist/presentation/format/queue.js.map +1 -1
- package/dist/presentation/format/runs.js +36 -3
- package/dist/presentation/format/runs.js.map +1 -1
- package/dist/presentation/format/stats.js +9 -3
- package/dist/presentation/format/stats.js.map +1 -1
- package/dist/presentation/format/table.js +3 -2
- package/dist/presentation/format/table.js.map +1 -1
- package/dist/presentation/format/webhooks/index.js +2 -0
- package/dist/presentation/format/webhooks/index.js.map +1 -0
- package/dist/presentation/format/webhooks/webhooks.js +59 -0
- package/dist/presentation/format/webhooks/webhooks.js.map +1 -0
- package/dist/presentation/ipc/client/address.js +8 -0
- package/dist/presentation/ipc/client/address.js.map +1 -0
- package/dist/presentation/ipc/client/client.js +23 -6
- package/dist/presentation/ipc/client/client.js.map +1 -1
- package/dist/presentation/ipc/client/index.js +1 -0
- package/dist/presentation/ipc/client/index.js.map +1 -1
- package/dist/presentation/ipc/client/remote.js +85 -0
- package/dist/presentation/ipc/client/remote.js.map +1 -0
- package/dist/presentation/ipc/contract/access/access.js +21 -0
- package/dist/presentation/ipc/contract/access/access.js.map +1 -0
- package/dist/presentation/ipc/contract/access/index.js +2 -0
- package/dist/presentation/ipc/contract/access/index.js.map +1 -0
- package/dist/presentation/ipc/contract/agents.js +7 -10
- package/dist/presentation/ipc/contract/agents.js.map +1 -1
- package/dist/presentation/ipc/contract/config.js +14 -1
- package/dist/presentation/ipc/contract/config.js.map +1 -1
- package/dist/presentation/ipc/contract/envelope.js +90 -6
- package/dist/presentation/ipc/contract/envelope.js.map +1 -1
- package/dist/presentation/ipc/contract/identity/audit.js +21 -0
- package/dist/presentation/ipc/contract/identity/audit.js.map +1 -0
- package/dist/presentation/ipc/contract/identity/identity.js +120 -0
- package/dist/presentation/ipc/contract/identity/identity.js.map +1 -0
- package/dist/presentation/ipc/contract/identity/index.js +3 -0
- package/dist/presentation/ipc/contract/identity/index.js.map +1 -0
- package/dist/presentation/ipc/contract/index.js +6 -0
- package/dist/presentation/ipc/contract/index.js.map +1 -1
- package/dist/presentation/ipc/contract/integrations/integrations.js +85 -0
- package/dist/presentation/ipc/contract/integrations/integrations.js.map +1 -0
- package/dist/presentation/ipc/contract/integrations/remote.js +16 -0
- package/dist/presentation/ipc/contract/integrations/remote.js.map +1 -0
- package/dist/presentation/ipc/contract/notifications/notifications.js +44 -0
- package/dist/presentation/ipc/contract/notifications/notifications.js.map +1 -0
- package/dist/presentation/ipc/contract/notifications/webhooks.js +48 -0
- package/dist/presentation/ipc/contract/notifications/webhooks.js.map +1 -0
- package/dist/presentation/ipc/contract/panel.js +5 -1
- package/dist/presentation/ipc/contract/panel.js.map +1 -1
- package/dist/presentation/ipc/contract/queue.js +48 -3
- package/dist/presentation/ipc/contract/queue.js.map +1 -1
- package/dist/presentation/ipc/contract/repositories.js +4 -0
- package/dist/presentation/ipc/contract/repositories.js.map +1 -1
- package/dist/presentation/ipc/contract/responses/stats.js +3 -0
- package/dist/presentation/ipc/contract/responses/stats.js.map +1 -1
- package/dist/presentation/ipc/contract/runs.js +18 -1
- package/dist/presentation/ipc/contract/runs.js.map +1 -1
- package/dist/presentation/ipc/contract/stats/stats.js +2 -0
- package/dist/presentation/ipc/contract/stats/stats.js.map +1 -1
- package/dist/presentation/ipc/contract/tags.js +9 -1
- package/dist/presentation/ipc/contract/tags.js.map +1 -1
- package/dist/presentation/ipc/handlers/access/access.js +74 -0
- package/dist/presentation/ipc/handlers/access/access.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/author.js +25 -0
- package/dist/presentation/ipc/handlers/access/author.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/guard.js +57 -0
- package/dist/presentation/ipc/handlers/access/guard.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/index.js +5 -0
- package/dist/presentation/ipc/handlers/access/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/method-actions.js +13 -0
- package/dist/presentation/ipc/handlers/access/method-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/method-runs.js +76 -0
- package/dist/presentation/ipc/handlers/access/method-runs.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/method-settings.js +120 -0
- package/dist/presentation/ipc/handlers/access/method-settings.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/resource.js +129 -0
- package/dist/presentation/ipc/handlers/access/resource.js.map +1 -0
- package/dist/presentation/ipc/handlers/access/visible.js +13 -0
- package/dist/presentation/ipc/handlers/access/visible.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-account-actions.js +52 -0
- package/dist/presentation/ipc/handlers/audit/audit-account-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-actions.js +220 -0
- package/dist/presentation/ipc/handlers/audit/audit-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-helpers.js +56 -0
- package/dist/presentation/ipc/handlers/audit/audit-helpers.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-list.js +57 -0
- package/dist/presentation/ipc/handlers/audit/audit-list.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-readers.js +74 -0
- package/dist/presentation/ipc/handlers/audit/audit-readers.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-settings-actions.js +73 -0
- package/dist/presentation/ipc/handlers/audit/audit-settings-actions.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit-table.js +10 -0
- package/dist/presentation/ipc/handlers/audit/audit-table.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/audit.js +101 -0
- package/dist/presentation/ipc/handlers/audit/audit.js.map +1 -0
- package/dist/presentation/ipc/handlers/audit/index.js +5 -0
- package/dist/presentation/ipc/handlers/audit/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/identity/identity.js +182 -0
- package/dist/presentation/ipc/handlers/identity/identity.js.map +1 -0
- package/dist/presentation/ipc/handlers/identity/index.js +2 -0
- package/dist/presentation/ipc/handlers/identity/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/index.js +6 -0
- package/dist/presentation/ipc/handlers/integrations/index.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/integrations.js +114 -0
- package/dist/presentation/ipc/handlers/integrations/integrations.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/notifications.js +49 -0
- package/dist/presentation/ipc/handlers/integrations/notifications.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/remote.js +35 -0
- package/dist/presentation/ipc/handlers/integrations/remote.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/skills.js +18 -0
- package/dist/presentation/ipc/handlers/integrations/skills.js.map +1 -0
- package/dist/presentation/ipc/handlers/integrations/webhooks.js +30 -0
- package/dist/presentation/ipc/handlers/integrations/webhooks.js.map +1 -0
- package/dist/presentation/ipc/handlers/observers.js +10 -2
- package/dist/presentation/ipc/handlers/observers.js.map +1 -1
- package/dist/presentation/ipc/handlers/providers.js +84 -0
- package/dist/presentation/ipc/handlers/providers.js.map +1 -0
- package/dist/presentation/ipc/handlers/queue.js +78 -20
- package/dist/presentation/ipc/handlers/queue.js.map +1 -1
- package/dist/presentation/ipc/handlers/repositories.js +32 -14
- package/dist/presentation/ipc/handlers/repositories.js.map +1 -1
- package/dist/presentation/ipc/handlers/runs.js +14 -5
- package/dist/presentation/ipc/handlers/runs.js.map +1 -1
- package/dist/presentation/ipc/handlers/stats.js +27 -6
- package/dist/presentation/ipc/handlers/stats.js.map +1 -1
- package/dist/presentation/ipc/handlers/system.js +8 -1
- package/dist/presentation/ipc/handlers/system.js.map +1 -1
- package/dist/presentation/ipc/handlers/table.js +20 -3
- package/dist/presentation/ipc/handlers/table.js.map +1 -1
- package/dist/presentation/ipc/log-signals.js +78 -0
- package/dist/presentation/ipc/log-signals.js.map +1 -0
- package/dist/presentation/ipc/publisher.js +20 -3
- package/dist/presentation/ipc/publisher.js.map +1 -1
- package/dist/presentation/ipc/server.js +58 -14
- package/dist/presentation/ipc/server.js.map +1 -1
- package/dist/presentation/ipc/snapshots.js +24 -4
- package/dist/presentation/ipc/snapshots.js.map +1 -1
- package/dist/presentation/ipc/views/global-queue.js +2 -1
- package/dist/presentation/ipc/views/global-queue.js.map +1 -1
- package/dist/presentation/ipc/views/groups.js +13 -0
- package/dist/presentation/ipc/views/groups.js.map +1 -1
- package/dist/presentation/ipc/views/index.js +2 -0
- package/dist/presentation/ipc/views/index.js.map +1 -1
- package/dist/presentation/ipc/views/notifications/notifications.js +7 -0
- package/dist/presentation/ipc/views/notifications/notifications.js.map +1 -0
- package/dist/presentation/ipc/views/notifications/webhooks.js +6 -0
- package/dist/presentation/ipc/views/notifications/webhooks.js.map +1 -0
- package/dist/presentation/ipc/views/queue.js +34 -7
- package/dist/presentation/ipc/views/queue.js.map +1 -1
- package/dist/presentation/ipc/views/runs.js +21 -8
- package/dist/presentation/ipc/views/runs.js.map +1 -1
- package/dist/presentation/ipc/views/stats.js +11 -3
- package/dist/presentation/ipc/views/stats.js.map +1 -1
- package/dist/presentation/mcp/host-kit.js +7 -0
- package/dist/presentation/mcp/host-kit.js.map +1 -1
- package/dist/presentation/mcp/host-queue-control.js +1 -1
- package/dist/presentation/mcp/host-queue-control.js.map +1 -1
- package/dist/presentation/mcp/host-queue.js +25 -21
- package/dist/presentation/mcp/host-queue.js.map +1 -1
- package/dist/presentation/mcp/host-runs.js +24 -16
- package/dist/presentation/mcp/host-runs.js.map +1 -1
- package/dist/presentation/mcp/host.js +2 -1
- package/dist/presentation/mcp/host.js.map +1 -1
- package/dist/presentation/mcp/index.js +1 -0
- package/dist/presentation/mcp/index.js.map +1 -1
- package/dist/presentation/mcp/remote-bridge.js +50 -0
- package/dist/presentation/mcp/remote-bridge.js.map +1 -0
- package/dist/presentation/mcp/tools.js +18 -0
- package/dist/presentation/mcp/tools.js.map +1 -1
- package/dist/presentation/mcp/worker-extra.js +86 -16
- package/dist/presentation/mcp/worker-extra.js.map +1 -1
- package/dist/presentation/mcp/worker-tools.js.map +1 -1
- package/dist/presentation/mcp/worker.js +2 -1
- package/dist/presentation/mcp/worker.js.map +1 -1
- package/dist/presentation/web/access.js +42 -0
- package/dist/presentation/web/access.js.map +1 -0
- package/dist/presentation/web/auth/context.js +3 -0
- package/dist/presentation/web/auth/context.js.map +1 -0
- package/dist/presentation/web/auth/gate.js +33 -0
- package/dist/presentation/web/auth/gate.js.map +1 -0
- package/dist/presentation/web/auth/oidc.js +49 -0
- package/dist/presentation/web/auth/oidc.js.map +1 -0
- package/dist/presentation/web/auth/pages.js +43 -0
- package/dist/presentation/web/auth/pages.js.map +1 -0
- package/dist/presentation/web/auth/proxy.js +54 -0
- package/dist/presentation/web/auth/proxy.js.map +1 -0
- package/dist/presentation/web/auth/routes.js +152 -0
- package/dist/presentation/web/auth/routes.js.map +1 -0
- package/dist/presentation/web/auth/saml.js +65 -0
- package/dist/presentation/web/auth/saml.js.map +1 -0
- package/dist/presentation/web/auth/session.js +53 -0
- package/dist/presentation/web/auth/session.js.map +1 -0
- package/dist/presentation/web/errors.js +18 -1
- package/dist/presentation/web/errors.js.map +1 -1
- package/dist/presentation/web/hub.js +101 -22
- package/dist/presentation/web/hub.js.map +1 -1
- package/dist/presentation/web/live/protocol.js +68 -0
- package/dist/presentation/web/live/protocol.js.map +1 -0
- package/dist/presentation/web/live/read.js +29 -0
- package/dist/presentation/web/live/read.js.map +1 -0
- package/dist/presentation/web/live/socket.js +93 -0
- package/dist/presentation/web/live/socket.js.map +1 -0
- package/dist/presentation/web/live/state-topics.js +127 -0
- package/dist/presentation/web/live/state-topics.js.map +1 -0
- package/dist/presentation/web/live/topics.js +119 -0
- package/dist/presentation/web/live/topics.js.map +1 -0
- package/dist/presentation/web/options.js.map +1 -1
- package/dist/presentation/web/panel/daemon-panel.js +24 -4
- package/dist/presentation/web/panel/daemon-panel.js.map +1 -1
- package/dist/presentation/web/request.js +42 -3
- package/dist/presentation/web/request.js.map +1 -1
- package/dist/presentation/web/routes/access/access.js +14 -0
- package/dist/presentation/web/routes/access/access.js.map +1 -0
- package/dist/presentation/web/routes/audit/audit.js +11 -0
- package/dist/presentation/web/routes/audit/audit.js.map +1 -0
- package/dist/presentation/web/routes/integrations/integrations.js +147 -0
- package/dist/presentation/web/routes/integrations/integrations.js.map +1 -0
- package/dist/presentation/web/routes/integrations/webhooks.js +73 -0
- package/dist/presentation/web/routes/integrations/webhooks.js.map +1 -0
- package/dist/presentation/web/routes/providers/providers.js +64 -0
- package/dist/presentation/web/routes/providers/providers.js.map +1 -0
- package/dist/presentation/web/routes/queue.js +1 -1
- package/dist/presentation/web/routes/queue.js.map +1 -1
- package/dist/presentation/web/routes/runs.js +20 -20
- package/dist/presentation/web/routes/runs.js.map +1 -1
- package/dist/presentation/web/routes/system.js +21 -13
- package/dist/presentation/web/routes/system.js.map +1 -1
- package/dist/presentation/web/routes/tags.js +5 -1
- package/dist/presentation/web/routes/tags.js.map +1 -1
- package/dist/presentation/web/server.js +97 -17
- package/dist/presentation/web/server.js.map +1 -1
- package/dist/presentation/web/visible.js +93 -0
- package/dist/presentation/web/visible.js.map +1 -0
- package/dist/web/assets/EntryList-CMEscRod.js +3 -0
- package/dist/web/assets/FilterField-BQc_UwWN.js +7 -0
- package/dist/web/assets/LinkTabs-v8NyjDyU.js +4 -0
- package/dist/web/assets/SharedPipelinesGroup-BzlZ5U2Y.js +1 -0
- package/dist/web/assets/deliveryModes-CHEVNJxR.js +1 -0
- package/dist/web/assets/empty-Bho47NOE.js +41 -0
- package/dist/web/assets/index-vRNf1iRZ.css +2 -0
- package/dist/web/assets/index-ztjIJ-Ig.js +41 -0
- package/dist/web/assets/locales-BTrmAl7v.js +1 -0
- package/dist/web/assets/pipelines-DVZ7cqyZ.js +14 -0
- package/dist/web/assets/settingFields-iGwxRKJI.js +1 -0
- package/dist/web/assets/settings-DN_KmJBg.js +6 -0
- package/dist/web/assets/stats-4iy1ZRny.js +1 -0
- package/dist/web/assets/tabs-D26rwwNs.js +1 -0
- package/dist/web/assets/toggle-group-D-oIoacR.js +1 -0
- package/dist/web/assets/topology-CaSfGJbk.js +1 -0
- package/dist/web/index.html +10 -7
- package/integrations/claude-code/.claude-plugin/plugin.json +1 -1
- package/package.json +12 -4
- package/dist/feature/runs/services/effects/proxy.js +0 -5
- package/dist/feature/runs/services/effects/proxy.js.map +0 -1
- package/dist/web/assets/FilterColumn-z60UZhkk.js +0 -1
- package/dist/web/assets/SharedPipelinesGroup-CgUJ-sUc.js +0 -1
- package/dist/web/assets/card-4euJkmfJ.js +0 -1
- package/dist/web/assets/deliveryModes-BGIYJzWQ.js +0 -1
- package/dist/web/assets/empty-OZRGgwa5.js +0 -41
- package/dist/web/assets/index-Cg7gL5P8.css +0 -2
- package/dist/web/assets/index-LD1g1Vkm.js +0 -43
- package/dist/web/assets/locales-D85Vnmev.js +0 -1
- package/dist/web/assets/pipelines-Cej37cah.js +0 -14
- package/dist/web/assets/settingFields-gm9TlqxP.js +0 -1
- package/dist/web/assets/settings-CDiTeiYL.js +0 -6
- package/dist/web/assets/specialists-BGKB5BLI.js +0 -4
- package/dist/web/assets/stats-BM-bGkGX.js +0 -1
- package/dist/web/assets/topology-BE6orrOL.js +0 -1
- package/dist/web/assets/trash-xUZ90-AG.js +0 -1
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { configPaths, loadWebSettings } from '../../../feature/swarm-config/services/index.js';
|
|
1
|
+
import { configPaths, loadServerSettings, loadWebSettings, } from '../../../feature/swarm-config/services/index.js';
|
|
2
2
|
import { request } from '../../ipc/client/index.js';
|
|
3
3
|
import { assertLoopbackHost, latestRepository, openBrowser, readPanelState, startWebServer, webTokenFromEnv, } from '../../web/index.js';
|
|
4
|
-
import { bind, daemon } from '../context.js';
|
|
4
|
+
import { bind, daemon, refuseWithServer } from '../context.js';
|
|
5
5
|
import { usage } from '../io.js';
|
|
6
6
|
import { registerWebControl } from '../web-control.js';
|
|
7
7
|
/** The address and the token the panel is served with; flags beat the settings. */
|
|
@@ -21,7 +21,9 @@ function target(options, settings, io) {
|
|
|
21
21
|
/** The link of the panel the daemon serves on that address, once it is up; undefined otherwise. */
|
|
22
22
|
async function daemonPanel(ctx, io, settings, at) {
|
|
23
23
|
const autostart = settings.autostart && io.env.AIP_WEB_AUTOSTART !== '0' && io.env.AIP_WEB_AUTOSTART !== 'false';
|
|
24
|
-
if (!autostart
|
|
24
|
+
if (!autostart)
|
|
25
|
+
return undefined;
|
|
26
|
+
if (at !== null && (at.host !== settings.host || at.port !== settings.port))
|
|
25
27
|
return undefined;
|
|
26
28
|
// A panel stopped by `aip web stop` is not coming back: do not wait for it.
|
|
27
29
|
const stopped = await request(ctx.socket, 'web_status', {}).then((result) => result.stopped === true, () => false);
|
|
@@ -29,7 +31,9 @@ async function daemonPanel(ctx, io, settings, at) {
|
|
|
29
31
|
for (;;) {
|
|
30
32
|
const state = readPanelState(ctx.stateDirectory);
|
|
31
33
|
// A stand-in panel hands the port to the daemon started above: wait for the daemon's.
|
|
32
|
-
if (state !== null &&
|
|
34
|
+
if (state !== null &&
|
|
35
|
+
!state.standby &&
|
|
36
|
+
(at === null || (state.host === at.host && state.port === at.port))) {
|
|
33
37
|
io.stdout(`aip web: ${state.url}\n`);
|
|
34
38
|
io.stdout(`aip web: served by the aip daemon (pid ${state.pid})\n`);
|
|
35
39
|
return state.url;
|
|
@@ -59,9 +63,25 @@ async function startOwnServer(ctx, settings, at) {
|
|
|
59
63
|
throw error;
|
|
60
64
|
}
|
|
61
65
|
}
|
|
66
|
+
/** In server mode the daemon serves the panel on `server.listen`; `aip web` prints its address. */
|
|
67
|
+
async function runServerWeb(options, io, style, settings) {
|
|
68
|
+
if (options.host !== undefined || options.port !== undefined) {
|
|
69
|
+
throw usage('server mode is on: the address is set by server.listen, not by --host and --port');
|
|
70
|
+
}
|
|
71
|
+
const ctx = bind(io, style).context();
|
|
72
|
+
await daemon(ctx, 'aip web');
|
|
73
|
+
const url = await daemonPanel(ctx, io, settings, null);
|
|
74
|
+
if (url === undefined)
|
|
75
|
+
throw usage('the daemon serves no web panel yet: see its log');
|
|
76
|
+
if (options.open)
|
|
77
|
+
openBrowser(url, io.stderr);
|
|
78
|
+
}
|
|
62
79
|
async function runWeb(options, io, style) {
|
|
63
80
|
const { print, context } = bind(io, style);
|
|
64
|
-
const
|
|
81
|
+
const paths = configPaths(io.cwd, io.env.XDG_CONFIG_HOME, io.env.HOME);
|
|
82
|
+
const settings = loadWebSettings(paths);
|
|
83
|
+
if (loadServerSettings(paths).enabled)
|
|
84
|
+
return runServerWeb(options, io, style, settings);
|
|
65
85
|
const at = target(options, settings, io);
|
|
66
86
|
const ctx = context();
|
|
67
87
|
await daemon(ctx, 'aip web');
|
|
@@ -96,6 +116,7 @@ export function registerWeb(program, io, style) {
|
|
|
96
116
|
'`aip web start|stop|restart|status` control that panel without stopping the daemon.')
|
|
97
117
|
.addHelpText('after', examples(['aip web', 'aip web --port 8080 --open', 'aip web start', 'aip web status']))
|
|
98
118
|
.action((options) => runWeb(options, io, style));
|
|
119
|
+
refuseWithServer(web, io);
|
|
99
120
|
registerWebControl(web, activeStyle, io);
|
|
100
121
|
}
|
|
101
122
|
//# sourceMappingURL=web.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"web.js","sourceRoot":"","sources":["../../../../src/presentation/cli/commands/web.ts"],"names":[],"mappings":"AAEA,OAAO,
|
|
1
|
+
{"version":3,"file":"web.js","sourceRoot":"","sources":["../../../../src/presentation/cli/commands/web.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,WAAW,EACX,kBAAkB,EAClB,eAAe,GAChB,MAAM,iDAAiD,CAAC;AAGzD,OAAO,EAAE,OAAO,EAAE,MAAM,2BAA2B,CAAC;AACpD,OAAO,EACL,kBAAkB,EAClB,gBAAgB,EAChB,WAAW,EACX,cAAc,EACd,cAAc,EACd,eAAe,GAEhB,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,IAAI,EAAE,MAAM,EAAE,gBAAgB,EAAgB,MAAM,eAAe,CAAC;AAC7E,OAAO,EAAE,KAAK,EAAc,MAAM,UAAU,CAAC;AAC7C,OAAO,EAAE,kBAAkB,EAAE,MAAM,mBAAmB,CAAC;AAcvD,mFAAmF;AACnF,SAAS,MAAM,CAAC,OAAmB,EAAE,QAAqB,EAAE,EAAS;IACnE,MAAM,IAAI,GAAG,OAAO,CAAC,IAAI,IAAI,QAAQ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[],"mappings":"AAAA,OAAO,EAAE,eAAe,EAAE,MAAM,cAAc,CAAC"}
|
|
@@ -0,0 +1,172 @@
|
|
|
1
|
+
import { formatWebhookDeliveries, formatWebhooks, formatWebhookTest, webhookNextSteps, } from '../../../format/index.js';
|
|
2
|
+
import { repositoryArgument } from '../../../ipc/client/index.js';
|
|
3
|
+
import { bind, call } from '../../context.js';
|
|
4
|
+
import { usage } from '../../io.js';
|
|
5
|
+
const DEFAULT_LOG_LIMIT = 20;
|
|
6
|
+
const EVENT_NAMES = 'question, failed, conflict, delivery, finished';
|
|
7
|
+
function parseEvents(text) {
|
|
8
|
+
const events = text
|
|
9
|
+
.split(',')
|
|
10
|
+
.map((one) => one.trim())
|
|
11
|
+
.filter((one) => one !== '');
|
|
12
|
+
if (events.length === 0)
|
|
13
|
+
throw usage(`pass --events as <kind>,<kind>: ${EVENT_NAMES}`);
|
|
14
|
+
return events;
|
|
15
|
+
}
|
|
16
|
+
function parseLimit(text) {
|
|
17
|
+
const value = Number(text);
|
|
18
|
+
if (!Number.isInteger(value) || value < 1 || value > 200) {
|
|
19
|
+
throw usage('--limit is a whole number from 1 to 200');
|
|
20
|
+
}
|
|
21
|
+
return value;
|
|
22
|
+
}
|
|
23
|
+
function addList(kit) {
|
|
24
|
+
const { root, examples, context, io, show } = kit;
|
|
25
|
+
root
|
|
26
|
+
.command('list')
|
|
27
|
+
.description('Show webhooks (of one project and of all projects with --repo)')
|
|
28
|
+
.option('-r, --repo <project>', 'project path or slug')
|
|
29
|
+
.option('--json', 'print JSON')
|
|
30
|
+
.addHelpText('after', examples(['aip webhook list', 'aip webhook list --repo shop']))
|
|
31
|
+
.action(async (options) => {
|
|
32
|
+
const repository = options.repo === undefined ? {} : { repository: repositoryArgument(options.repo, io.cwd) };
|
|
33
|
+
show(options.json, (await call(context(), 'webhook_list', repository)));
|
|
34
|
+
});
|
|
35
|
+
}
|
|
36
|
+
function addCreate(kit) {
|
|
37
|
+
const { root, print, examples, context, io, show } = kit;
|
|
38
|
+
root
|
|
39
|
+
.command('add')
|
|
40
|
+
.description('Make a webhook; it starts disabled, without a signing secret')
|
|
41
|
+
.argument('<name>', 'name, unique among webhooks in its scope')
|
|
42
|
+
.requiredOption('--url <url>', 'http(s) address the events are sent to')
|
|
43
|
+
.option('-r, --repo <project>', 'project path or slug; `.` is the current repository')
|
|
44
|
+
.option('--all-projects', 'events of every project')
|
|
45
|
+
.option('--events <kinds>', `${EVENT_NAMES} (default: question)`)
|
|
46
|
+
.option('--json', 'print JSON')
|
|
47
|
+
.addHelpText('after', examples([
|
|
48
|
+
'aip webhook add ci --url https://ci.example.com/aip --repo .',
|
|
49
|
+
'aip webhook add audit --url https://hooks.example.com/aip --all-projects --events question,finished',
|
|
50
|
+
]))
|
|
51
|
+
.action(async (name, options) => {
|
|
52
|
+
if ((options.repo === undefined) === (options.allProjects !== true)) {
|
|
53
|
+
throw usage('pass either --repo <project> or --all-projects');
|
|
54
|
+
}
|
|
55
|
+
const scope = options.allProjects === true
|
|
56
|
+
? { allProjects: true }
|
|
57
|
+
: { repository: repositoryArgument(options.repo ?? '.', io.cwd) };
|
|
58
|
+
const view = (await call(context(), 'webhook_add', {
|
|
59
|
+
name,
|
|
60
|
+
url: options.url,
|
|
61
|
+
...scope,
|
|
62
|
+
...(options.events === undefined ? {} : { events: parseEvents(options.events) }),
|
|
63
|
+
}));
|
|
64
|
+
show(options.json, [view]);
|
|
65
|
+
if (options.json !== true)
|
|
66
|
+
print(`\n${webhookNextSteps(view)}`);
|
|
67
|
+
});
|
|
68
|
+
}
|
|
69
|
+
function addChange(kit) {
|
|
70
|
+
const { root, examples, context, show } = kit;
|
|
71
|
+
root
|
|
72
|
+
.command('edit')
|
|
73
|
+
.description('Change the address or the events of a webhook; the secret and the state stay')
|
|
74
|
+
.argument('<id>', 'id of the webhook (of its connection), from `aip webhook list`')
|
|
75
|
+
.option('--url <url>', 'new address')
|
|
76
|
+
.option('--events <kinds>', EVENT_NAMES)
|
|
77
|
+
.option('--json', 'print JSON')
|
|
78
|
+
.addHelpText('after', examples([
|
|
79
|
+
'aip webhook edit c1a2b3c4d5e6 --url https://ci.example.com/v2/aip',
|
|
80
|
+
'aip webhook edit c1a2b3c4d5e6 --events question,failed',
|
|
81
|
+
]))
|
|
82
|
+
.action(async (id, options) => {
|
|
83
|
+
if (options.url === undefined && options.events === undefined) {
|
|
84
|
+
throw usage('pass --url or --events');
|
|
85
|
+
}
|
|
86
|
+
const view = (await call(context(), 'webhook_edit', {
|
|
87
|
+
id,
|
|
88
|
+
...(options.url === undefined ? {} : { url: options.url }),
|
|
89
|
+
...(options.events === undefined ? {} : { events: parseEvents(options.events) }),
|
|
90
|
+
}));
|
|
91
|
+
show(options.json, [view]);
|
|
92
|
+
});
|
|
93
|
+
}
|
|
94
|
+
function addSwitches(kit) {
|
|
95
|
+
const { root, print, examples, context, show } = kit;
|
|
96
|
+
for (const [verb, method, text] of [
|
|
97
|
+
['enable', 'webhook_enable', 'Turn a webhook on; it needs its signing secret'],
|
|
98
|
+
['disable', 'webhook_disable', 'Turn a webhook off; its journal stays'],
|
|
99
|
+
]) {
|
|
100
|
+
root
|
|
101
|
+
.command(verb)
|
|
102
|
+
.description(text)
|
|
103
|
+
.argument('<id>', 'id of the webhook')
|
|
104
|
+
.option('--json', 'print JSON')
|
|
105
|
+
.addHelpText('after', examples([`aip webhook ${verb} c1a2b3c4d5e6`]))
|
|
106
|
+
.action(async (id, options) => {
|
|
107
|
+
show(options.json, [(await call(context(), method, { id }))]);
|
|
108
|
+
});
|
|
109
|
+
}
|
|
110
|
+
root
|
|
111
|
+
.command('remove')
|
|
112
|
+
.description('Remove a webhook with its secret and its journal')
|
|
113
|
+
.argument('<id>', 'id of the webhook')
|
|
114
|
+
.addHelpText('after', examples(['aip webhook remove c1a2b3c4d5e6']))
|
|
115
|
+
.action(async (id) => {
|
|
116
|
+
await call(context(), 'webhook_remove', { id });
|
|
117
|
+
print(`Removed ${id}`);
|
|
118
|
+
});
|
|
119
|
+
}
|
|
120
|
+
function addDelivery(kit) {
|
|
121
|
+
const { root, print, output, examples, context, activeStyle, io } = kit;
|
|
122
|
+
root
|
|
123
|
+
.command('test')
|
|
124
|
+
.description('Call the address once with a test event; exits with 1 if it is not accepted')
|
|
125
|
+
.argument('<id>', 'id of the webhook')
|
|
126
|
+
.addHelpText('after', examples(['aip webhook test c1a2b3c4d5e6']))
|
|
127
|
+
.action(async (id) => {
|
|
128
|
+
const result = (await call(context(), 'webhook_test', { id }));
|
|
129
|
+
print(formatWebhookTest(result));
|
|
130
|
+
if (!result.ok)
|
|
131
|
+
io.setExitCode(1);
|
|
132
|
+
});
|
|
133
|
+
root
|
|
134
|
+
.command('log')
|
|
135
|
+
.description('Show the deliveries of a webhook with their attempts, the newest first')
|
|
136
|
+
.argument('<id>', 'id of the webhook')
|
|
137
|
+
.option('--state <state>', 'pending, sent, failed or closed')
|
|
138
|
+
.option('--limit <n>', 'how many deliveries', String(DEFAULT_LOG_LIMIT))
|
|
139
|
+
.option('--json', 'print JSON')
|
|
140
|
+
.addHelpText('after', examples(['aip webhook log c1a2b3c4d5e6', 'aip webhook log c1a2b3c4d5e6 --state failed']))
|
|
141
|
+
.action(async (id, options) => {
|
|
142
|
+
const views = (await call(context(), 'webhook_log', {
|
|
143
|
+
id,
|
|
144
|
+
...(options.state === undefined ? {} : { state: options.state }),
|
|
145
|
+
limit: parseLimit(options.limit),
|
|
146
|
+
}));
|
|
147
|
+
output(options.json, formatWebhookDeliveries(views, activeStyle), views);
|
|
148
|
+
});
|
|
149
|
+
root
|
|
150
|
+
.command('redeliver')
|
|
151
|
+
.description('Send a delivery again, with the same webhook-id, as a new series of attempts')
|
|
152
|
+
.argument('<delivery>', 'id of the delivery, from `aip webhook log`')
|
|
153
|
+
.addHelpText('after', examples(['aip webhook redeliver 42']))
|
|
154
|
+
.action(async (delivery) => {
|
|
155
|
+
const id = Number(delivery);
|
|
156
|
+
if (!Number.isInteger(id) || id < 1)
|
|
157
|
+
throw usage('<delivery> is the number from the log');
|
|
158
|
+
await call(context(), 'webhook_redeliver', { id });
|
|
159
|
+
print(`Delivery ${id} is queued again`);
|
|
160
|
+
});
|
|
161
|
+
}
|
|
162
|
+
export function registerWebhook(program, io, style) {
|
|
163
|
+
const { print, output, examples, context, activeStyle } = bind(io, style);
|
|
164
|
+
const root = program
|
|
165
|
+
.command('webhook')
|
|
166
|
+
.description('Outgoing webhooks: signed calls to an address on events, journal, test');
|
|
167
|
+
const show = (json, views) => output(json, formatWebhooks(views, activeStyle), views);
|
|
168
|
+
const kit = { root, print, output, examples, context, activeStyle, io, show };
|
|
169
|
+
for (const add of [addList, addCreate, addChange, addSwitches, addDelivery])
|
|
170
|
+
add(kit);
|
|
171
|
+
}
|
|
172
|
+
//# sourceMappingURL=webhook.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"webhook.js","sourceRoot":"","sources":["../../../../../src/presentation/cli/commands/webhook/webhook.ts"],"names":[],"mappings":"AAEA,OAAO,EACL,uBAAuB,EACvB,cAAc,EACd,iBAAiB,EACjB,gBAAgB,GAEjB,MAAM,0BAA0B,CAAC;AAClC,OAAO,EAAE,kBAAkB,EAAE,MAAM,8BAA8B,CAAC;AAMlE,OAAO,EAAE,IAAI,EAAE,IAAI,EAAgB,MAAM,kBAAkB,CAAC;AAC5D,OAAO,EAAE,KAAK,EAAc,MAAM,aAAa,CAAC;AAEhD,MAAM,iBAAiB,GAAG,EAAE,CAAC;AAC7B,MAAM,WAAW,GAAG,gDAAgD,CAAC;AAErE,SAAS,WAAW,CAAC,IAAY;IAC/B,MAAM,MAAM,GAAG,IAAI;SAChB,KAAK,CAAC,GAAG,CAAC;SACV,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC;SACxB,MAAM,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,GAAG,KAAK,EAAE,CAAC,CAAC;IAC/B,IAAI,MAAM,CAAC,MAAM,KAAK,CAA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KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,WAAW,EAAE,GAAG,IAAI,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;IAC1E,MAAM,IAAI,GAAG,OAAO;SACjB,OAAO,CAAC,SAAS,CAAC;SAClB,WAAW,CAAC,wEAAwE,CAAC,CAAC;IACzF,MAAM,IAAI,GAAG,CAAC,IAAyB,EAAE,KAAoB,EAAQ,EAAE,CACrE,MAAM,CAAC,IAAI,EAAE,cAAc,CAAC,KAAK,EAAE,WAAW,CAAC,EAAE,KAAK,CAAC,CAAC;IAC1D,MAAM,GAAG,GAAQ,EAAE,IAAI,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,OAAO,EAAE,WAAW,EAAE,EAAE,EAAE,IAAI,EAAE,CAAC;IACnF,KAAK,MAAM,GAAG,IAAI,CAAC,OAAO,EAAE,SAAS,EAAE,SAAS,EAAE,WAAW,EAAE,WAAW,CAAC;QAAE,GAAG,CAAC,GAAG,CAAC,CAAC;AACxF,CAAC"}
|
|
@@ -1,8 +1,11 @@
|
|
|
1
1
|
import { join } from 'node:path';
|
|
2
|
+
import { packageVersion } from '../../platform/build/index.js';
|
|
2
3
|
import { lockPath, socketPath, stateDirectoryFromEnvironment } from '../../platform/paths/index.js';
|
|
3
|
-
import { daemonMismatchMessage, ensureDaemon, request } from '../ipc/client/index.js';
|
|
4
|
+
import { daemonMismatchMessage, ensureDaemon, request, } from '../ipc/client/index.js';
|
|
5
|
+
import { remoteOf } from './commands/server/profile.js';
|
|
6
|
+
import { mapRepository } from './commands/server/repository.js';
|
|
4
7
|
import { examples as renderExamples } from './help.js';
|
|
5
|
-
import { writeLine } from './io.js';
|
|
8
|
+
import { usage, writeLine } from './io.js';
|
|
6
9
|
export function context(io, style) {
|
|
7
10
|
const directory = stateDirectoryFromEnvironment(io.env);
|
|
8
11
|
return {
|
|
@@ -11,14 +14,28 @@ export function context(io, style) {
|
|
|
11
14
|
entry: io.entry,
|
|
12
15
|
style,
|
|
13
16
|
io,
|
|
17
|
+
remote: remoteOf(io.env),
|
|
14
18
|
};
|
|
15
19
|
}
|
|
20
|
+
/**
|
|
21
|
+
* A command of the local daemon makes no sense while the commands work with a server: it ends
|
|
22
|
+
* with a hint (`aip logout`, or unset `AIP_SERVER`) before it does anything.
|
|
23
|
+
*/
|
|
24
|
+
export function refuseWithServer(command, io) {
|
|
25
|
+
command.hook('preAction', () => {
|
|
26
|
+
if (remoteOf(io.env) === null)
|
|
27
|
+
return;
|
|
28
|
+
throw usage('this command works with the local daemon, but the commands use a server: run `aip logout` (and unset AIP_SERVER) first');
|
|
29
|
+
});
|
|
30
|
+
}
|
|
16
31
|
const warned = new Set();
|
|
17
32
|
/**
|
|
18
33
|
* Starts the daemon when none runs and replaces an older idle one; a daemon of another build
|
|
19
34
|
* that keeps running is reported on stderr, once per process.
|
|
20
35
|
*/
|
|
21
36
|
export async function daemon(ctx, client = 'aip') {
|
|
37
|
+
if (ctx.remote !== null)
|
|
38
|
+
return checkServer(ctx, ctx.remote);
|
|
22
39
|
const check = await ensureDaemon(ctx.socket, ctx.entry, {
|
|
23
40
|
logPath: join(ctx.stateDirectory, 'daemon.log'),
|
|
24
41
|
environment: ctx.io.env,
|
|
@@ -31,8 +48,23 @@ export async function daemon(ctx, client = 'aip') {
|
|
|
31
48
|
}
|
|
32
49
|
return check;
|
|
33
50
|
}
|
|
51
|
+
/** The server answers and runs the same version as this client; a different one is reported once. */
|
|
52
|
+
async function checkServer(ctx, remote) {
|
|
53
|
+
const ping = (await request(remote, 'ping', {}));
|
|
54
|
+
const server = ping.build?.version;
|
|
55
|
+
const message = server !== undefined && server !== packageVersion()
|
|
56
|
+
? `the server runs aip ${server}, this client ${packageVersion()}: update the older one`
|
|
57
|
+
: null;
|
|
58
|
+
if (message && !warned.has(message)) {
|
|
59
|
+
warned.add(message);
|
|
60
|
+
ctx.io.stderr(`aip: warning: ${message}\n`);
|
|
61
|
+
}
|
|
62
|
+
return { started: false, restarted: false, mismatch: null };
|
|
63
|
+
}
|
|
34
64
|
export async function call(ctx, method, params) {
|
|
35
65
|
await daemon(ctx);
|
|
66
|
+
if (ctx.remote !== null)
|
|
67
|
+
return request(ctx.remote, method, await mapRepository(ctx, params));
|
|
36
68
|
return request(ctx.socket, method, params);
|
|
37
69
|
}
|
|
38
70
|
/** The helpers of the commands, bound to the streams and the style of one call. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"context.js","sourceRoot":"","sources":["../../../src/presentation/cli/context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;
|
|
1
|
+
{"version":3,"file":"context.js","sourceRoot":"","sources":["../../../src/presentation/cli/context.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,IAAI,EAAE,MAAM,WAAW,CAAC;AAIjC,OAAO,EAAE,cAAc,EAAE,MAAM,+BAA+B,CAAC;AAC/D,OAAO,EAAE,QAAQ,EAAE,UAAU,EAAE,6BAA6B,EAAE,MAAM,+BAA+B,CAAC;AACpG,OAAO,EACL,qBAAqB,EACrB,YAAY,EACZ,OAAO,GAER,MAAM,wBAAwB,CAAC;AAIhC,OAAO,EAAE,QAAQ,EAAE,MAAM,8BAA8B,CAAC;AACxD,OAAO,EAAE,aAAa,EAAE,MAAM,iCAAiC,CAAC;AAChE,OAAO,EAAE,QAAQ,IAAI,cAAc,EAAE,MAAM,WAAW,CAAC;AACvD,OAAO,EAAE,KAAK,EAAE,SAAS,EAAc,MAAM,SAAS,CAAC;AAYvD,MAAM,UAAU,OAAO,CAAC,EAAS,EAAE,KAAY;IAC7C,MAAM,SAAS,GAAG,6BAA6B,CAAC,EAAE,CAAC,GAAG,CAAC,CAAC;IACxD,OAAO;QACL,cAAc,EAAE,SAAS;QACzB,MAAM,EAAE,UAAU,CAAC,SAAS,CAAC;QAC7B,KAAK,EAAE,EAAE,CAAC,KAAK;QACf,KAAK;QACL,EAAE;QACF,MAAM,EAAE,QAAQ,CA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IAAa,EAAQ,EAAE,CACvE,KAAK,CAAC,IAAI,CAAC,CAAC,CAAC,IAAI,CAAC,SAAS,CAAC,IAAI,EAAE,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,CAAC,IAAI,CAAC;QACpD,QAAQ,EAAE,CAAC,KAAe,EAAU,EAAE,CAAC,cAAc,CAAC,KAAK,EAAE,KAAK,CAAC;QACnE,OAAO,EAAE,GAAY,EAAE,CAAC,OAAO,CAAC,EAAE,EAAE,KAAK,CAAC;QAC1C,WAAW,EAAE,KAAK;KACnB,CAAC;AACJ,CAAC"}
|
|
@@ -1,9 +1,28 @@
|
|
|
1
1
|
/** Groups of `aip --help`, in the order they are printed. */
|
|
2
2
|
export const HELP_GROUPS = [
|
|
3
3
|
{ heading: 'Runs:', commands: ['run', 'group'] },
|
|
4
|
-
{ heading: 'Queue & repositories:', commands: ['queue', 'repo', 'tag'] },
|
|
4
|
+
{ heading: 'Queue & repositories:', commands: ['queue', 'repo', 'tag', 'provider'] },
|
|
5
5
|
{ heading: 'Dashboards & streams:', commands: ['overview', 'web', 'events', 'stats'] },
|
|
6
|
-
{
|
|
6
|
+
{
|
|
7
|
+
heading: 'Setup & maintenance:',
|
|
8
|
+
commands: [
|
|
9
|
+
'setup',
|
|
10
|
+
'init',
|
|
11
|
+
'config',
|
|
12
|
+
'integration',
|
|
13
|
+
'notify',
|
|
14
|
+
'webhook',
|
|
15
|
+
'login',
|
|
16
|
+
'logout',
|
|
17
|
+
'whoami',
|
|
18
|
+
'token',
|
|
19
|
+
'server',
|
|
20
|
+
'access',
|
|
21
|
+
'audit',
|
|
22
|
+
'version',
|
|
23
|
+
'help',
|
|
24
|
+
],
|
|
25
|
+
},
|
|
7
26
|
{ heading: 'Plumbing (started by hosts and aip itself):', commands: ['daemon', 'mcp'] },
|
|
8
27
|
];
|
|
9
28
|
export const HELP_FOOTER = [
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"help.js","sourceRoot":"","sources":["../../../src/present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C;AAE5C;;;GAGG;AACH,MAAM,UAAU,cAAc,CAAC,OAAgB,EAAE,IAAc;IAC7D,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,OAAO,CAAC;IACtC,IAAI,IAAI,CAAC,MAAM,KAAK,CAAC;QAAE,OAAO,IAAI,CAAC;IACnC,MAAM,GAAG,GAAG,OAAO,CAAC,QAAQ,CAAC,IAAI,CAAC,CAAC,OAAO,EAAE,EAAE,CAAC,OAAO,CAAC,IAAI,EAAE,KAAK,IAAI,CAAC,CAAC,CAAC,CAAC,CAAC;IAC3E,OAAO,GAAG,KAAK,SAAS,IAAI,GAAG,CAAC,QAAQ,CAAC,MAAM,GAAG,CAAC,IAAI,CAAC,QAAQ,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,EAAE,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,CAAC,CAAC,IAAI,CAAC;AAChG,CAAC"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"io.js","sourceRoot":"","sources":["../../../src/presentation/cli/io.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,gCAAgC,CAAC;
|
|
1
|
+
{"version":3,"file":"io.js","sourceRoot":"","sources":["../../../src/presentation/cli/io.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,QAAQ,EAAE,OAAO,EAAE,QAAQ,EAAE,MAAM,gCAAgC,CAAC;AA6C7E,MAAM,UAAU,SAAS,CAAC,EAAS,EAAE,KAAa;IAChD,EAAE,CAAC,MAAM,CAAC,GAAG,KAAK,IAAI,CAAC,CAAC;AAC1B,CAAC;AAED,MAAM,UAAU,QAAQ,CAAC,EAAS,EAAE,MAAc,EAAE,OAAe;IACjE,EAAE,CAAC,MAAM,CAAC,GAAG,MAAM,KAAK,OAAO,IAAI,CAAC,CAAC;IACrC,EAAE,CAAC,WAAW,CAAC,CAAC,CAAC,CAAC;AACpB,CAAC;AAED,qDAAqD;AACrD,MAAM,CAAC,MAAM,KAAK,GAAG,CAAC,OAAe,EAAY,EAAE,CAAC,OAAO,CAAC,WAAW,EAAE,OAAO,CAAC,CAAC;AAElF,yCAAyC;AACzC,MAAM,CAAC,MAAM,YAAY,GAAG,CAAC,OAAe,EAAY,EAAE,CAAC,QAAQ,CAAC,OAAO,EAAE,WAAW,CAAC,CAAC"}
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import { emptyRoles, } from '../../../feature/agents/types/index.js';
|
|
2
|
+
import { providerText } from '../../format/providers/index.js';
|
|
3
|
+
function accessLine(access) {
|
|
4
|
+
const target = access.runtime ?? 'api';
|
|
5
|
+
const prefix = access.modelPrefix === null ? '' : ` prefix ${access.modelPrefix}`;
|
|
6
|
+
const key = access.endpoint === null ? '' : `, key variable ${access.endpoint.keyEnv}`;
|
|
7
|
+
const state = access.available ? 'available' : `unavailable (${access.reasons.join('; ')})`;
|
|
8
|
+
return ` ${access.index + 1}. ${access.kind} ${target}${prefix}${key}: ${state}`;
|
|
9
|
+
}
|
|
10
|
+
function modelsLine(provider) {
|
|
11
|
+
const models = Object.entries(provider.models).map(([role, item]) => `${role}=${item.model}`);
|
|
12
|
+
return ` models: ${models.join(', ') || 'none'}`;
|
|
13
|
+
}
|
|
14
|
+
/** The roles and the providers with their status; no value of a variable is printed. */
|
|
15
|
+
export function providerLines(config, states) {
|
|
16
|
+
const lines = ['', 'Roles:'];
|
|
17
|
+
if (config.roles.length === 0)
|
|
18
|
+
lines.push(' none');
|
|
19
|
+
for (const role of config.roles)
|
|
20
|
+
lines.push(` ${role.slug}: ${role.name}`);
|
|
21
|
+
lines.push('', 'Providers:');
|
|
22
|
+
if (config.defaultProvider !== null) {
|
|
23
|
+
lines.push(` default: ${config.defaultProvider.slug} · ${config.defaultProvider.level}`);
|
|
24
|
+
}
|
|
25
|
+
if (states.length === 0)
|
|
26
|
+
lines.push(' none');
|
|
27
|
+
for (const state of states) {
|
|
28
|
+
const provider = config.providers.find((item) => item.slug === state.slug);
|
|
29
|
+
lines.push(` ${providerText(state.slug, state.name)} · ${state.level} · ${state.enabled ? 'enabled' : 'disabled'} · ${state.status}`, ...state.access.map(accessLine), modelsLine(provider));
|
|
30
|
+
}
|
|
31
|
+
return lines;
|
|
32
|
+
}
|
|
33
|
+
/** An enabled provider without a model for a role leaves an empty cell of the matrix. */
|
|
34
|
+
export function providerWarnings(config) {
|
|
35
|
+
const slug = config.defaultProvider?.slug;
|
|
36
|
+
const off = config.providers.some((provider) => provider.slug === slug && !provider.enabled);
|
|
37
|
+
return [
|
|
38
|
+
...(off ? [`default provider \`${slug}\` is disabled`] : []),
|
|
39
|
+
...emptyRoleWarnings(config),
|
|
40
|
+
];
|
|
41
|
+
}
|
|
42
|
+
function emptyRoleWarnings(config) {
|
|
43
|
+
return config.providers
|
|
44
|
+
.filter((provider) => provider.enabled)
|
|
45
|
+
.flatMap((provider) => emptyRoles(config.roles, provider).map((role) => `provider \`${provider.slug}\` has no model for role \`${role}\``));
|
|
46
|
+
}
|
|
47
|
+
//# sourceMappingURL=config-check-providers.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config-check-providers.js","sourceRoot":"","sources":["../../../../src/presentation/cli/local/config-check-providers.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,UAAU,GAGX,MAAM,wCAAwC,CAAC;AAEhD,OAAO,EAAE,YAAY,EAAE,MAAM,iCAAiC,CAAC;AAE/D,SAAS,UAAU,CAAC,MAAmB;IACrC,MAAM,MAAM,GAAG,MAAM,CAAC,OAAO,IAAI,KAAK,CAAC;IACvC,MAAM,MAAM,GAAG,MAAM,CAAC,WAAW,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,WAAW,MAAM,CAAC,WAAW,EAAE,CAAC;IAClF,MAAM,GAAG,GAAG,MAAM,CAAC,QAAQ,KAAK,IAAI,CAAC,CAAC,CAAC,EAAE,CAAC,CAAC,CAAC,kBAAkB,MAAM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SAAS;SACpB,MAAM,CAAC,CAAC,QAAQ,EAAE,EAAE,CAAC,QAAQ,CAAC,OAAO,CAAC;SACtC,OAAO,CAAC,CAAC,QAAQ,EAAE,EAAE,CACpB,UAAU,CAAC,MAAM,CAAC,KAAK,EAAE,QAAQ,CAAC,CAAC,GAAG,CACpC,CAAC,IAAI,EAAE,EAAE,CAAC,cAAc,QAAQ,CAAC,IAAI,8BAA8B,IAAI,IAAI,CAC5E,CACF,CAAC;AACN,CAAC"}
|
|
@@ -1,10 +1,12 @@
|
|
|
1
1
|
import { stringify } from 'yaml';
|
|
2
2
|
import { ConfigLoadError, formatDuration, } from '../../../feature/swarm-config/types/index.js';
|
|
3
|
-
import { configPathsFromEnvironment, loadConfigSources, } from '../../../feature/swarm-config/services/index.js';
|
|
3
|
+
import { configPathsFromEnvironment, loadAccessPolicy, loadConfigSources, loadServerSettings, } from '../../../feature/swarm-config/services/index.js';
|
|
4
|
+
import { actionNames, similarActions } from '../../../feature/access/types/index.js';
|
|
4
5
|
import { repositoryRoot } from '../../../platform/git/index.js';
|
|
5
6
|
import { findExecutable } from '../../../platform/process/index.js';
|
|
6
|
-
import { agentExecutable } from '../../../app/maintenance.js';
|
|
7
|
+
import { agentExecutable, providerStates } from '../../../app/maintenance.js';
|
|
7
8
|
import { probeVersion } from '../probe.js';
|
|
9
|
+
import { providerLines, providerWarnings } from './config-check-providers.js';
|
|
8
10
|
import { presentVariants } from './present-variants.js';
|
|
9
11
|
/** Whether a runtime may start: the field, then a non-empty AIP_<NAME>_BIN of the environment. */
|
|
10
12
|
function runtimeEnabled(config, name, environment) {
|
|
@@ -27,6 +29,9 @@ function presentDelivery(config) {
|
|
|
27
29
|
mode: config.delivery.mode,
|
|
28
30
|
auto: config.delivery.auto,
|
|
29
31
|
keep: config.delivery.keep,
|
|
32
|
+
push: config.delivery.push,
|
|
33
|
+
remote: config.delivery.remote,
|
|
34
|
+
...(config.delivery.baseBranch ? { base_branch: config.delivery.baseBranch } : {}),
|
|
30
35
|
commit_message: config.delivery.commitMessage,
|
|
31
36
|
...(config.delivery.messageSpecialist
|
|
32
37
|
? { message_specialist: config.delivery.messageSpecialist }
|
|
@@ -62,9 +67,11 @@ function presentChains(config) {
|
|
|
62
67
|
mode: chain.mode,
|
|
63
68
|
runtimes: chain.runtimes.map((item) => ({
|
|
64
69
|
runtime: item.runtime,
|
|
70
|
+
...(item.provider ? { provider: item.provider } : {}),
|
|
65
71
|
...(item.model ? { model: item.model } : {}),
|
|
66
72
|
...(item.variant ? { variant: item.variant } : {}),
|
|
67
73
|
...(item.reasoningEffort ? { reasoning_effort: item.reasoningEffort } : {}),
|
|
74
|
+
...(item.default ? { default: true } : {}),
|
|
68
75
|
...(item.enabled ? {} : { enabled: false }),
|
|
69
76
|
})),
|
|
70
77
|
...(chain.enabled ? {} : { enabled: false }),
|
|
@@ -158,7 +165,7 @@ export function presentConfig(config, environment = {}) {
|
|
|
158
165
|
pipelines: presentPipelines(config),
|
|
159
166
|
};
|
|
160
167
|
}
|
|
161
|
-
export function configWarnings(config) {
|
|
168
|
+
export function configWarnings(config, serverMode = false) {
|
|
162
169
|
const warnings = config.specialists
|
|
163
170
|
.filter((specialist) => specialist.permissions === 'full')
|
|
164
171
|
.map((specialist) => `specialist \`${specialist.slug}\` has permissions: full and runs without any permission checks`);
|
|
@@ -169,6 +176,9 @@ export function configWarnings(config) {
|
|
|
169
176
|
if (config.claude.editMode === 'auto' && claudeEditors) {
|
|
170
177
|
warnings.push('claude.edit_mode: auto lets the Claude Code classifier decide on commands outside allow_commands; it does not keep them inside the worktree');
|
|
171
178
|
}
|
|
179
|
+
if (serverMode && config.workspace.base !== 'working_tree') {
|
|
180
|
+
warnings.push('workspace.base is ignored in the server mode: a run starts from the remote main branch (delivery.remote, delivery.base_branch)');
|
|
181
|
+
}
|
|
172
182
|
return warnings;
|
|
173
183
|
}
|
|
174
184
|
export async function checkConfig(directory, io) {
|
|
@@ -176,13 +186,14 @@ export async function checkConfig(directory, io) {
|
|
|
176
186
|
let config;
|
|
177
187
|
let files;
|
|
178
188
|
let legacy = [];
|
|
189
|
+
let serverMode = false;
|
|
179
190
|
try {
|
|
180
191
|
const repository = await repositoryRoot(directory);
|
|
181
|
-
(
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
192
|
+
const paths = configPathsFromEnvironment(repository, environment);
|
|
193
|
+
({ config, files, legacy = [] } = loadConfigSources(paths));
|
|
194
|
+
// the access policies of the server mode: a file with a mistake is a failed check
|
|
195
|
+
serverMode = loadServerSettings(paths).enabled;
|
|
196
|
+
loadAccessPolicy(paths, { names: actionNames(), similar: (name) => similarActions(name) });
|
|
186
197
|
}
|
|
187
198
|
catch (error) {
|
|
188
199
|
io.stderr(`${error instanceof ConfigLoadError ? error.message : error.message}\n`);
|
|
@@ -208,6 +219,9 @@ export async function checkConfig(directory, io) {
|
|
|
208
219
|
io.stdout(` ${file}\n`);
|
|
209
220
|
io.stdout(' Move the files to aip/pipelines/ and rename split.workflow to split.pipeline in them.\n');
|
|
210
221
|
}
|
|
222
|
+
for (const line of providerLines(config, providerStates(config, environment))) {
|
|
223
|
+
io.stdout(`${line}\n`);
|
|
224
|
+
}
|
|
211
225
|
io.stdout('\nAgent CLIs:\n');
|
|
212
226
|
const disabled = [];
|
|
213
227
|
for (const name of runtimes) {
|
|
@@ -222,8 +236,9 @@ export async function checkConfig(directory, io) {
|
|
|
222
236
|
for (const name of disabled) {
|
|
223
237
|
io.stdout(`Warning: runtime \`${name}\` is disabled and specialists on it fail; set runtimes.${name}.enabled: true in the shared settings.yaml\n`);
|
|
224
238
|
}
|
|
225
|
-
for (const warning of configWarnings(config))
|
|
239
|
+
for (const warning of [...configWarnings(config, serverMode), ...providerWarnings(config)]) {
|
|
226
240
|
io.stdout(`Warning: ${warning}\n`);
|
|
241
|
+
}
|
|
227
242
|
return 0;
|
|
228
243
|
}
|
|
229
244
|
//# sourceMappingURL=config-check.js.map
|