@intentic/sandbox-contract 1.248.0 → 1.250.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/README.md +18 -15
- package/dist/chores/chores.d.ts.map +1 -1
- package/dist/chores/chores.js.map +1 -1
- package/dist/chores/digest.d.ts.map +1 -1
- package/dist/chores/digest.js.map +1 -1
- package/dist/chores/extension-update.d.ts.map +1 -1
- package/dist/chores/extension-update.js.map +1 -1
- package/dist/chores/fix-deps.d.ts.map +1 -1
- package/dist/chores/fix-deps.js.map +1 -1
- package/dist/chores/index.d.ts +2 -2
- package/dist/chores/index.d.ts.map +1 -1
- package/dist/chores/index.js +1 -1
- package/dist/chores/index.js.map +1 -1
- package/dist/chores/probes.d.ts.map +1 -1
- package/dist/chores/probes.js.map +1 -1
- package/dist/chores/prompt.d.ts.map +1 -1
- package/dist/chores/prompt.js.map +1 -1
- package/dist/chores/stack.d.ts.map +1 -1
- package/dist/chores/stack.js.map +1 -1
- package/dist/chores/verdict.d.ts +7 -1
- package/dist/chores/verdict.d.ts.map +1 -1
- package/dist/chores/verdict.js +8 -0
- package/dist/chores/verdict.js.map +1 -1
- package/dist/contracts/accounts.contract.d.ts.map +1 -1
- package/dist/contracts/accounts.contract.js.map +1 -1
- package/dist/contracts/activity.contract.d.ts +1 -0
- package/dist/contracts/activity.contract.d.ts.map +1 -1
- package/dist/contracts/agent.contract.d.ts +12 -205
- package/dist/contracts/agent.contract.d.ts.map +1 -1
- package/dist/contracts/agent.contract.js +2 -1
- package/dist/contracts/agent.contract.js.map +1 -1
- package/dist/contracts/agents.contract.d.ts +228 -54
- package/dist/contracts/agents.contract.d.ts.map +1 -1
- package/dist/contracts/agents.contract.js +11 -2
- package/dist/contracts/agents.contract.js.map +1 -1
- package/dist/contracts/automations.contract.d.ts +35 -17
- package/dist/contracts/automations.contract.d.ts.map +1 -1
- package/dist/contracts/automations.contract.js +10 -1
- package/dist/contracts/automations.contract.js.map +1 -1
- package/dist/contracts/capabilities.contract.d.ts +0 -12
- package/dist/contracts/capabilities.contract.d.ts.map +1 -1
- package/dist/contracts/capabilities.contract.js +1 -1
- package/dist/contracts/capabilities.contract.js.map +1 -1
- package/dist/contracts/chores.contract.d.ts.map +1 -1
- package/dist/contracts/chores.contract.js.map +1 -1
- package/dist/contracts/ci.contract.d.ts +9 -0
- package/dist/contracts/ci.contract.d.ts.map +1 -1
- package/dist/contracts/endpoints.contract.d.ts.map +1 -1
- package/dist/contracts/endpoints.contract.js.map +1 -1
- package/dist/contracts/exit.contract.d.ts.map +1 -1
- package/dist/contracts/exit.contract.js +1 -1
- package/dist/contracts/exit.contract.js.map +1 -1
- package/dist/contracts/extensions.contract.d.ts.map +1 -1
- package/dist/contracts/extensions.contract.js.map +1 -1
- package/dist/contracts/git.contract.d.ts +45 -6
- package/dist/contracts/git.contract.d.ts.map +1 -1
- package/dist/contracts/git.contract.js +9 -9
- package/dist/contracts/git.contract.js.map +1 -1
- package/dist/contracts/host.contract.d.ts +2 -0
- package/dist/contracts/host.contract.d.ts.map +1 -1
- package/dist/contracts/host.contract.js.map +1 -1
- package/dist/contracts/intentic.contract.js +1 -1
- package/dist/contracts/intentic.contract.js.map +1 -1
- package/dist/contracts/logs.contract.d.ts.map +1 -1
- package/dist/contracts/logs.contract.js.map +1 -1
- package/dist/contracts/loops.contract.d.ts.map +1 -1
- package/dist/contracts/loops.contract.js.map +1 -1
- package/dist/contracts/personas.contract.d.ts +1 -0
- package/dist/contracts/personas.contract.d.ts.map +1 -1
- package/dist/contracts/personas.contract.js +1 -1
- package/dist/contracts/personas.contract.js.map +1 -1
- package/dist/contracts/providers.contract.d.ts.map +1 -1
- package/dist/contracts/providers.contract.js.map +1 -1
- package/dist/contracts/runner.contract.d.ts +97 -171
- package/dist/contracts/runner.contract.d.ts.map +1 -1
- package/dist/contracts/runner.contract.js +2 -2
- package/dist/contracts/runner.contract.js.map +1 -1
- package/dist/contracts/safety.contract.d.ts.map +1 -1
- package/dist/contracts/safety.contract.js +1 -1
- package/dist/contracts/safety.contract.js.map +1 -1
- package/dist/contracts/secrets.contract.d.ts.map +1 -1
- package/dist/contracts/secrets.contract.js.map +1 -1
- package/dist/contracts/sessions.contract.d.ts +2 -41
- package/dist/contracts/sessions.contract.d.ts.map +1 -1
- package/dist/contracts/sessions.contract.js +1 -1
- package/dist/contracts/sessions.contract.js.map +1 -1
- package/dist/contracts/settings.contract.d.ts +8 -18
- package/dist/contracts/settings.contract.d.ts.map +1 -1
- package/dist/contracts/settings.contract.js.map +1 -1
- package/dist/contracts/share.contract.d.ts.map +1 -1
- package/dist/contracts/share.contract.js.map +1 -1
- package/dist/contracts/skills.contract.d.ts +6 -0
- package/dist/contracts/skills.contract.d.ts.map +1 -1
- package/dist/contracts/skills.contract.js +13 -4
- package/dist/contracts/skills.contract.js.map +1 -1
- package/dist/contracts/system.contract.d.ts +49 -73
- package/dist/contracts/system.contract.d.ts.map +1 -1
- package/dist/contracts/system.contract.js +12 -2
- package/dist/contracts/system.contract.js.map +1 -1
- package/dist/contracts/usage.contract.d.ts.map +1 -1
- package/dist/contracts/usage.contract.js.map +1 -1
- package/dist/contracts/vpn.contract.d.ts.map +1 -1
- package/dist/contracts/vpn.contract.js +1 -1
- package/dist/contracts/vpn.contract.js.map +1 -1
- package/dist/contracts/webext.contract.d.ts.map +1 -1
- package/dist/contracts/webext.contract.js.map +1 -1
- package/dist/contracts/workflows.contract.d.ts +7 -6
- package/dist/contracts/workflows.contract.d.ts.map +1 -1
- package/dist/contracts/workflows.contract.js +12 -3
- package/dist/contracts/workflows.contract.js.map +1 -1
- package/dist/contracts/workspace.contract.d.ts.map +1 -1
- package/dist/contracts/workspace.contract.js.map +1 -1
- package/dist/events/agent-events.d.ts +1237 -0
- package/dist/events/agent-events.d.ts.map +1 -0
- package/dist/events/agent-events.js +226 -0
- package/dist/events/agent-events.js.map +1 -0
- package/dist/events/cards.d.ts +404 -0
- package/dist/events/cards.d.ts.map +1 -0
- package/dist/events/cards.js +179 -0
- package/dist/events/cards.js.map +1 -0
- package/dist/events/resume.d.ts +23 -0
- package/dist/events/resume.d.ts.map +1 -0
- package/dist/events/resume.js +31 -0
- package/dist/events/resume.js.map +1 -0
- package/dist/events/system-events.d.ts +615 -0
- package/dist/events/system-events.d.ts.map +1 -0
- package/dist/events/system-events.js +64 -0
- package/dist/events/system-events.js.map +1 -0
- package/dist/events/transcript.d.ts +1755 -0
- package/dist/events/transcript.d.ts.map +1 -0
- package/dist/events/transcript.js +205 -0
- package/dist/events/transcript.js.map +1 -0
- package/dist/ids/conversation-ids.d.ts +8 -0
- package/dist/ids/conversation-ids.d.ts.map +1 -0
- package/dist/{conversation-ids.js → ids/conversation-ids.js} +13 -0
- package/dist/ids/conversation-ids.js.map +1 -0
- package/dist/ids/hostnames.d.ts.map +1 -0
- package/dist/ids/hostnames.js.map +1 -0
- package/dist/ids/session-names.d.ts.map +1 -0
- package/dist/ids/session-names.js.map +1 -0
- package/dist/ids/share-paths.d.ts.map +1 -0
- package/dist/ids/share-paths.js.map +1 -0
- package/dist/{tunnel-ids.d.ts → ids/tunnel-ids.d.ts} +1 -0
- package/dist/ids/tunnel-ids.d.ts.map +1 -0
- package/dist/{tunnel-ids.js → ids/tunnel-ids.js} +1 -0
- package/dist/ids/tunnel-ids.js.map +1 -0
- package/dist/index.d.ts +429 -450
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +54 -46
- package/dist/index.js.map +1 -1
- package/dist/{agent-catalog.d.ts → models/agent-catalog.d.ts} +2 -2
- package/dist/models/agent-catalog.d.ts.map +1 -0
- package/dist/models/agent-catalog.js.map +1 -0
- package/dist/models/agent-runtimes.d.ts.map +1 -0
- package/dist/models/agent-runtimes.js.map +1 -0
- package/dist/{fast-tier.d.ts → models/fast-tier.d.ts} +1 -1
- package/dist/models/fast-tier.d.ts.map +1 -0
- package/dist/models/fast-tier.js.map +1 -0
- package/dist/models/model-order.d.ts.map +1 -0
- package/dist/{model-order.js → models/model-order.js} +2 -0
- package/dist/models/model-order.js.map +1 -0
- package/dist/{model-pins.d.ts → models/model-pins.d.ts} +1 -1
- package/dist/models/model-pins.d.ts.map +1 -0
- package/dist/models/model-pins.js.map +1 -0
- package/dist/{model-roles.d.ts → models/model-roles.d.ts} +0 -33
- package/dist/models/model-roles.d.ts.map +1 -0
- package/dist/{model-roles.js → models/model-roles.js} +0 -35
- package/dist/models/model-roles.js.map +1 -0
- package/dist/{plan-pools.d.ts → models/plan-pools.d.ts} +1 -1
- package/dist/models/plan-pools.d.ts.map +1 -0
- package/dist/models/plan-pools.js.map +1 -0
- package/dist/models/prompt-complexity.d.ts.map +1 -0
- package/dist/models/prompt-complexity.js.map +1 -0
- package/dist/models/provider-specs.d.ts.map +1 -0
- package/dist/models/provider-specs.js.map +1 -0
- package/dist/policy/approvals-execution.d.ts.map +1 -0
- package/dist/policy/approvals-execution.js.map +1 -0
- package/dist/{batch-runs.d.ts → policy/batch-runs.d.ts} +5 -1
- package/dist/policy/batch-runs.d.ts.map +1 -0
- package/dist/{batch-runs.js → policy/batch-runs.js} +10 -7
- package/dist/policy/batch-runs.js.map +1 -0
- package/dist/policy/capability-env.d.ts.map +1 -0
- package/dist/policy/capability-env.js.map +1 -0
- package/dist/policy/capability-secrets.d.ts.map +1 -0
- package/dist/policy/capability-secrets.js.map +1 -0
- package/dist/{card-status.d.ts → policy/card-status.d.ts} +2 -2
- package/dist/policy/card-status.d.ts.map +1 -0
- package/dist/{card-status.js → policy/card-status.js} +1 -5
- package/dist/policy/card-status.js.map +1 -0
- package/dist/{command-classes.d.ts → policy/command-classes.d.ts} +6 -2
- package/dist/policy/command-classes.d.ts.map +1 -0
- package/dist/{command-classes.js → policy/command-classes.js} +48 -11
- package/dist/policy/command-classes.js.map +1 -0
- package/dist/{command-run.d.ts → policy/command-run.d.ts} +1 -1
- package/dist/policy/command-run.d.ts.map +1 -0
- package/dist/policy/command-run.js.map +1 -0
- package/dist/policy/control-scopes.d.ts +16 -0
- package/dist/policy/control-scopes.d.ts.map +1 -0
- package/dist/policy/control-scopes.js +26 -0
- package/dist/policy/control-scopes.js.map +1 -0
- package/dist/policy/credential-material.d.ts.map +1 -0
- package/dist/policy/credential-material.js.map +1 -0
- package/dist/policy/needs-action.d.ts.map +1 -0
- package/dist/policy/needs-action.js.map +1 -0
- package/dist/policy/output-fields.d.ts.map +1 -0
- package/dist/policy/output-fields.js.map +1 -0
- package/dist/policy/overlay-lint.d.ts.map +1 -0
- package/dist/policy/overlay-lint.js.map +1 -0
- package/dist/policy/owner-ticket.d.ts.map +1 -0
- package/dist/{owner-ticket.js → policy/owner-ticket.js} +1 -1
- package/dist/policy/owner-ticket.js.map +1 -0
- package/dist/{safety-policy.d.ts → policy/safety-policy.d.ts} +6 -5
- package/dist/policy/safety-policy.d.ts.map +1 -0
- package/dist/{safety-policy.js → policy/safety-policy.js} +12 -12
- package/dist/policy/safety-policy.js.map +1 -0
- package/dist/policy/search-globs.d.ts.map +1 -0
- package/dist/policy/search-globs.js.map +1 -0
- package/dist/protocol/container-requirements.d.ts +20 -0
- package/dist/protocol/container-requirements.d.ts.map +1 -0
- package/dist/protocol/container-requirements.js +23 -0
- package/dist/protocol/container-requirements.js.map +1 -0
- package/dist/{host-protocol.d.ts → protocol/host-protocol.d.ts} +1 -0
- package/dist/protocol/host-protocol.d.ts.map +1 -0
- package/dist/{host-protocol.js → protocol/host-protocol.js} +1 -0
- package/dist/protocol/host-protocol.js.map +1 -0
- package/dist/protocol/ingress-contract.d.ts.map +1 -0
- package/dist/{ingress-contract.js → protocol/ingress-contract.js} +1 -1
- package/dist/protocol/ingress-contract.js.map +1 -0
- package/dist/protocol/ingress-protocol.d.ts.map +1 -0
- package/dist/protocol/ingress-protocol.js.map +1 -0
- package/dist/protocol/listener-protocol.d.ts.map +1 -0
- package/dist/{listener-protocol.js → protocol/listener-protocol.js} +1 -1
- package/dist/protocol/listener-protocol.js.map +1 -0
- package/dist/{peer-dial.d.ts → protocol/peer-dial.d.ts} +4 -1
- package/dist/protocol/peer-dial.d.ts.map +1 -0
- package/dist/{peer-dial.js → protocol/peer-dial.js} +51 -10
- package/dist/protocol/peer-dial.js.map +1 -0
- package/dist/protocol/peer-mcp-server.d.ts.map +1 -0
- package/dist/protocol/peer-mcp-server.js.map +1 -0
- package/dist/protocol/request-id.d.ts.map +1 -0
- package/dist/protocol/request-id.js.map +1 -0
- package/dist/protocol/routes.d.ts.map +1 -0
- package/dist/protocol/routes.js.map +1 -0
- package/dist/{runner-protocol.d.ts → protocol/runner-protocol.d.ts} +1 -0
- package/dist/protocol/runner-protocol.d.ts.map +1 -0
- package/dist/{runner-protocol.js → protocol/runner-protocol.js} +2 -1
- package/dist/protocol/runner-protocol.js.map +1 -0
- package/dist/protocol/sse.d.ts.map +1 -0
- package/dist/protocol/sse.js.map +1 -0
- package/dist/{terminal-protocol.d.ts → protocol/terminal-protocol.d.ts} +1 -3
- package/dist/protocol/terminal-protocol.d.ts.map +1 -0
- package/dist/protocol/terminal-protocol.js.map +1 -0
- package/dist/protocol/webext-links.d.ts.map +1 -0
- package/dist/protocol/webext-links.js.map +1 -0
- package/dist/{webext-protocol.d.ts → protocol/webext-protocol.d.ts} +1 -0
- package/dist/protocol/webext-protocol.d.ts.map +1 -0
- package/dist/{webext-protocol.js → protocol/webext-protocol.js} +1 -0
- package/dist/protocol/webext-protocol.js.map +1 -0
- package/dist/schemas/activity.d.ts +2 -0
- package/dist/schemas/activity.d.ts.map +1 -1
- package/dist/schemas/activity.js +4 -0
- package/dist/schemas/activity.js.map +1 -1
- package/dist/schemas/agent.d.ts +16 -4
- package/dist/schemas/agent.d.ts.map +1 -1
- package/dist/schemas/agent.js +21 -4
- package/dist/schemas/agent.js.map +1 -1
- package/dist/schemas/agents.d.ts +17 -4
- package/dist/schemas/agents.d.ts.map +1 -1
- package/dist/schemas/agents.js +15 -4
- package/dist/schemas/agents.js.map +1 -1
- package/dist/schemas/approvals.d.ts.map +1 -1
- package/dist/schemas/approvals.js.map +1 -1
- package/dist/schemas/automations.d.ts +54 -28
- package/dist/schemas/automations.d.ts.map +1 -1
- package/dist/schemas/automations.js +26 -8
- package/dist/schemas/automations.js.map +1 -1
- package/dist/schemas/capabilities.d.ts +0 -8
- package/dist/schemas/capabilities.d.ts.map +1 -1
- package/dist/schemas/capabilities.js +0 -4
- package/dist/schemas/capabilities.js.map +1 -1
- package/dist/schemas/ci.d.ts +10 -0
- package/dist/schemas/ci.d.ts.map +1 -1
- package/dist/schemas/ci.js +9 -1
- package/dist/schemas/ci.js.map +1 -1
- package/dist/schemas/codebase-health.d.ts.map +1 -1
- package/dist/schemas/codebase-health.js.map +1 -1
- package/dist/schemas/devices.d.ts +92 -0
- package/dist/schemas/devices.d.ts.map +1 -1
- package/dist/schemas/devices.js +12 -1
- package/dist/schemas/devices.js.map +1 -1
- package/dist/schemas/engines.d.ts.map +1 -1
- package/dist/schemas/engines.js.map +1 -1
- package/dist/schemas/environment.d.ts.map +1 -1
- package/dist/schemas/environment.js.map +1 -1
- package/dist/schemas/exit.d.ts.map +1 -1
- package/dist/schemas/exit.js.map +1 -1
- package/dist/schemas/extension-updates.d.ts.map +1 -1
- package/dist/schemas/extension-updates.js.map +1 -1
- package/dist/schemas/git-history.d.ts.map +1 -1
- package/dist/schemas/git-history.js.map +1 -1
- package/dist/schemas/git.d.ts +80 -16
- package/dist/schemas/git.d.ts.map +1 -1
- package/dist/schemas/git.js +37 -25
- package/dist/schemas/git.js.map +1 -1
- package/dist/schemas/history.d.ts.map +1 -1
- package/dist/schemas/history.js.map +1 -1
- package/dist/schemas/hosts.d.ts.map +1 -1
- package/dist/schemas/hosts.js.map +1 -1
- package/dist/schemas/inventory.d.ts.map +1 -1
- package/dist/schemas/inventory.js.map +1 -1
- package/dist/schemas/issues.d.ts +0 -1
- package/dist/schemas/issues.d.ts.map +1 -1
- package/dist/schemas/issues.js +0 -1
- package/dist/schemas/issues.js.map +1 -1
- package/dist/schemas/logs.d.ts.map +1 -1
- package/dist/schemas/logs.js.map +1 -1
- package/dist/schemas/loops.d.ts.map +1 -1
- package/dist/schemas/loops.js +1 -1
- package/dist/schemas/loops.js.map +1 -1
- package/dist/schemas/maintenance.d.ts.map +1 -1
- package/dist/schemas/maintenance.js.map +1 -1
- package/dist/schemas/marketplace.d.ts +0 -4
- package/dist/schemas/marketplace.d.ts.map +1 -1
- package/dist/schemas/panels.d.ts.map +1 -1
- package/dist/schemas/panels.js.map +1 -1
- package/dist/schemas/personas.d.ts +2 -1
- package/dist/schemas/personas.d.ts.map +1 -1
- package/dist/schemas/personas.js +6 -2
- package/dist/schemas/personas.js.map +1 -1
- package/dist/schemas/plan-limits.d.ts +2 -4
- package/dist/schemas/plan-limits.d.ts.map +1 -1
- package/dist/schemas/plan-limits.js +5 -8
- package/dist/schemas/plan-limits.js.map +1 -1
- package/dist/schemas/ports.d.ts.map +1 -1
- package/dist/schemas/ports.js.map +1 -1
- package/dist/schemas/provider-oauth.d.ts.map +1 -1
- package/dist/schemas/provider-oauth.js.map +1 -1
- package/dist/schemas/provider-subscriptions.d.ts +1 -1
- package/dist/schemas/provider-subscriptions.d.ts.map +1 -1
- package/dist/schemas/provider-subscriptions.js +1 -1
- package/dist/schemas/provider-subscriptions.js.map +1 -1
- package/dist/schemas/public.d.ts.map +1 -1
- package/dist/schemas/public.js.map +1 -1
- package/dist/schemas/push.d.ts.map +1 -1
- package/dist/schemas/push.js.map +1 -1
- package/dist/schemas/secrets.d.ts.map +1 -1
- package/dist/schemas/secrets.js.map +1 -1
- package/dist/schemas/settings.d.ts +11 -9
- package/dist/schemas/settings.d.ts.map +1 -1
- package/dist/schemas/settings.js +22 -7
- package/dist/schemas/settings.js.map +1 -1
- package/dist/schemas/share.d.ts.map +1 -1
- package/dist/schemas/share.js.map +1 -1
- package/dist/schemas/shared.d.ts +4 -0
- package/dist/schemas/shared.d.ts.map +1 -1
- package/dist/schemas/shared.js +3 -0
- package/dist/schemas/shared.js.map +1 -1
- package/dist/schemas/system.d.ts +6 -0
- package/dist/schemas/system.d.ts.map +1 -1
- package/dist/schemas/system.js +10 -0
- package/dist/schemas/system.js.map +1 -1
- package/dist/schemas/terminal.d.ts.map +1 -1
- package/dist/schemas/terminal.js.map +1 -1
- package/dist/schemas/usage.d.ts.map +1 -1
- package/dist/schemas/usage.js.map +1 -1
- package/dist/schemas/vpn.d.ts.map +1 -1
- package/dist/schemas/vpn.js.map +1 -1
- package/dist/schemas/webext.d.ts.map +1 -1
- package/dist/schemas/webext.js.map +1 -1
- package/dist/schemas/workflows.d.ts +66 -9
- package/dist/schemas/workflows.d.ts.map +1 -1
- package/dist/schemas/workflows.js +6 -5
- package/dist/schemas/workflows.js.map +1 -1
- package/dist/schemas/workspace-repos.d.ts.map +1 -1
- package/dist/schemas/workspace-repos.js.map +1 -1
- package/dist/schemas/workspace-search.d.ts.map +1 -1
- package/dist/schemas/workspace-search.js.map +1 -1
- package/dist/schemas/workspace-setup.d.ts.map +1 -1
- package/dist/schemas/workspace-setup.js.map +1 -1
- package/dist/schemas/workspace-tree.d.ts.map +1 -1
- package/dist/schemas/workspace-tree.js.map +1 -1
- package/dist/state/arrival.d.ts.map +1 -0
- package/dist/{arrival.js → state/arrival.js} +1 -1
- package/dist/state/arrival.js.map +1 -0
- package/dist/state/contract-lock.d.ts.map +1 -0
- package/dist/{contract-lock.js → state/contract-lock.js} +1 -1
- package/dist/state/contract-lock.js.map +1 -0
- package/dist/{definition.d.ts → state/definition.d.ts} +21 -17
- package/dist/state/definition.d.ts.map +1 -0
- package/dist/{definition.js → state/definition.js} +4 -4
- package/dist/state/definition.js.map +1 -0
- package/dist/state/history-state.d.ts.map +1 -0
- package/dist/{history-state.js → state/history-state.js} +1 -0
- package/dist/state/history-state.js.map +1 -0
- package/dist/state/runtime-state.d.ts.map +1 -0
- package/dist/state/runtime-state.js.map +1 -0
- package/dist/state/starter.d.ts.map +1 -0
- package/dist/state/starter.js.map +1 -0
- package/dist/state/state-portability.d.ts.map +1 -0
- package/dist/state/state-portability.js.map +1 -0
- package/dist/state/versions.d.ts.map +1 -0
- package/dist/state/versions.js.map +1 -0
- package/dist/{workspace-state.d.ts → state/workspace-state.d.ts} +8 -0
- package/dist/state/workspace-state.d.ts.map +1 -0
- package/dist/{workspace-state.js → state/workspace-state.js} +25 -0
- package/dist/state/workspace-state.js.map +1 -0
- package/dist/{documents.d.ts → text/documents.d.ts} +1 -1
- package/dist/text/documents.d.ts.map +1 -0
- package/dist/{documents.js → text/documents.js} +1 -1
- package/dist/text/documents.js.map +1 -0
- package/dist/text/embed.d.ts.map +1 -0
- package/dist/text/embed.js.map +1 -0
- package/dist/text/mentions.d.ts.map +1 -0
- package/dist/text/mentions.js.map +1 -0
- package/dist/text/model-answer.d.ts +3 -0
- package/dist/text/model-answer.d.ts.map +1 -0
- package/dist/text/model-answer.js +3 -0
- package/dist/text/model-answer.js.map +1 -0
- package/dist/text/path-refs.d.ts.map +1 -0
- package/dist/text/path-refs.js.map +1 -0
- package/dist/{shell-regions.d.ts → text/shell-regions.d.ts} +1 -1
- package/dist/text/shell-regions.d.ts.map +1 -0
- package/dist/text/shell-regions.js.map +1 -0
- package/dist/text/title.d.ts.map +1 -0
- package/dist/text/title.js.map +1 -0
- package/dist/{transcript-fold.d.ts → text/transcript-fold.d.ts} +2 -1
- package/dist/text/transcript-fold.d.ts.map +1 -0
- package/dist/{transcript-fold.js → text/transcript-fold.js} +2 -16
- package/dist/text/transcript-fold.js.map +1 -0
- package/dist/text/whisper.d.ts +3 -0
- package/dist/text/whisper.d.ts.map +1 -0
- package/dist/text/whisper.js +11 -0
- package/dist/text/whisper.js.map +1 -0
- package/dist/{workflow-faults.d.ts → text/workflow-faults.d.ts} +1 -1
- package/dist/text/workflow-faults.d.ts.map +1 -0
- package/dist/{workflow-faults.js → text/workflow-faults.js} +1 -1
- package/dist/text/workflow-faults.js.map +1 -0
- package/package.json +70 -70
- package/src/chores/chores.test.ts +4 -10
- package/src/chores/chores.ts +148 -392
- package/src/chores/digest.ts +8 -28
- package/src/chores/extension-update.ts +3 -8
- package/src/chores/fix-deps.ts +4 -18
- package/src/chores/index.ts +2 -2
- package/src/chores/probes.test.ts +7 -43
- package/src/chores/probes.ts +62 -167
- package/src/chores/prompt.ts +10 -34
- package/src/chores/stack.test.ts +6 -45
- package/src/chores/stack.ts +27 -118
- package/src/chores/verdict.test.ts +101 -80
- package/src/chores/verdict.ts +54 -99
- package/src/contracts/accounts.contract.ts +4 -19
- package/src/contracts/agent.contract.ts +7 -22
- package/src/contracts/agents.contract.ts +25 -71
- package/src/contracts/automations.contract.ts +14 -30
- package/src/contracts/capabilities.contract.ts +8 -35
- package/src/contracts/chores.contract.ts +4 -15
- package/src/contracts/endpoints.contract.ts +5 -22
- package/src/contracts/exit.contract.ts +7 -30
- package/src/contracts/extensions.contract.ts +8 -30
- package/src/contracts/git.contract.ts +25 -49
- package/src/contracts/host.contract.ts +9 -44
- package/src/contracts/intentic.contract.ts +1 -1
- package/src/contracts/logs.contract.ts +3 -13
- package/src/contracts/loops.contract.ts +9 -40
- package/src/contracts/personas.contract.ts +10 -35
- package/src/contracts/providers.contract.ts +4 -17
- package/src/contracts/runner.contract.ts +12 -39
- package/src/contracts/safety.contract.ts +5 -14
- package/src/contracts/secrets.contract.ts +4 -22
- package/src/contracts/sessions.contract.ts +1 -1
- package/src/contracts/settings.contract.ts +4 -10
- package/src/contracts/share.contract.ts +3 -9
- package/src/contracts/skills.contract.ts +21 -19
- package/src/contracts/system.contract.ts +26 -52
- package/src/contracts/usage.contract.ts +7 -21
- package/src/contracts/vpn.contract.ts +9 -16
- package/src/contracts/webext.contract.ts +9 -25
- package/src/contracts/workflows.contract.ts +34 -58
- package/src/contracts/workspace.contract.ts +19 -50
- package/src/events/agent-events.ts +345 -0
- package/src/events/cards.ts +286 -0
- package/src/{events.test.ts → events/resume.test.ts} +4 -19
- package/src/events/resume.ts +60 -0
- package/src/events/system-events.ts +139 -0
- package/src/events/transcript.ts +320 -0
- package/src/{conversation-ids.test.ts → ids/conversation-ids.test.ts} +25 -13
- package/src/ids/conversation-ids.ts +178 -0
- package/src/ids/hostnames.ts +129 -0
- package/src/ids/session-names.ts +29 -0
- package/src/ids/share-paths.ts +43 -0
- package/src/{tunnel-ids.test.ts → ids/tunnel-ids.test.ts} +1 -14
- package/src/ids/tunnel-ids.ts +29 -0
- package/src/index.ts +71 -87
- package/src/{agent-catalog.test.ts → models/agent-catalog.test.ts} +19 -93
- package/src/models/agent-catalog.ts +174 -0
- package/src/models/agent-runtimes.ts +201 -0
- package/src/models/capability-ledger.test.ts +84 -0
- package/src/{fast-tier.test.ts → models/fast-tier.test.ts} +7 -18
- package/src/models/fast-tier.ts +36 -0
- package/src/{model-order.test.ts → models/model-order.test.ts} +54 -40
- package/src/models/model-order.ts +171 -0
- package/src/{model-pins.test.ts → models/model-pins.test.ts} +12 -46
- package/src/models/model-pins.ts +57 -0
- package/src/models/model-roles.test.ts +38 -0
- package/src/models/model-roles.ts +180 -0
- package/src/{plan-pools.test.ts → models/plan-pools.test.ts} +6 -11
- package/src/models/plan-pools.ts +65 -0
- package/src/{prompt-complexity.test.ts → models/prompt-complexity.test.ts} +8 -60
- package/src/models/prompt-complexity.ts +215 -0
- package/src/{provider-specs.test.ts → models/provider-specs.test.ts} +18 -47
- package/src/models/provider-specs.ts +272 -0
- package/src/policy/approvals-execution.ts +58 -0
- package/src/{batch-runs.test.ts → policy/batch-runs.test.ts} +4 -20
- package/src/policy/batch-runs.ts +137 -0
- package/src/policy/capability-secrets.ts +5 -0
- package/src/{card-status.ts → policy/card-status.ts} +11 -26
- package/src/{command-classes.test.ts → policy/command-classes.test.ts} +11 -118
- package/src/policy/command-classes.ts +395 -0
- package/src/policy/command-run.ts +65 -0
- package/src/policy/control-scopes.ts +38 -0
- package/src/{credential-material.test.ts → policy/credential-material.test.ts} +4 -26
- package/src/policy/credential-material.ts +91 -0
- package/src/policy/needs-action.ts +5 -0
- package/src/policy/output-fields.ts +86 -0
- package/src/policy/overlay-lint.ts +100 -0
- package/src/{owner-ticket.test.ts → policy/owner-ticket.test.ts} +1 -1
- package/src/{owner-ticket.ts → policy/owner-ticket.ts} +9 -31
- package/src/policy/safety-policy.test.ts +84 -0
- package/src/policy/safety-policy.ts +142 -0
- package/src/policy/search-globs.ts +60 -0
- package/src/protocol/container-requirements.test.ts +72 -0
- package/src/protocol/container-requirements.ts +58 -0
- package/src/protocol/host-protocol.ts +29 -0
- package/src/protocol/ingress-contract.ts +103 -0
- package/src/{ingress-protocol.test.ts → protocol/ingress-protocol.test.ts} +25 -90
- package/src/protocol/ingress-protocol.ts +441 -0
- package/src/protocol/listener-protocol.ts +75 -0
- package/src/{peer-dial.test.ts → protocol/peer-dial.test.ts} +52 -1
- package/src/protocol/peer-dial.ts +207 -0
- package/src/{peer-mcp-server.ts → protocol/peer-mcp-server.ts} +16 -41
- package/src/protocol/request-id.ts +5 -0
- package/src/{routes.test.ts → protocol/routes.test.ts} +14 -22
- package/src/protocol/routes.ts +159 -0
- package/src/protocol/runner-protocol.ts +197 -0
- package/src/protocol/terminal-protocol.ts +13 -0
- package/src/protocol/webext-links.ts +50 -0
- package/src/protocol/webext-protocol.ts +24 -0
- package/src/schemas/activity.ts +22 -30
- package/src/schemas/agent.ts +130 -238
- package/src/schemas/agents.ts +165 -483
- package/src/schemas/approvals.ts +23 -71
- package/src/schemas/automations.ts +142 -250
- package/src/schemas/capabilities.ts +127 -414
- package/src/schemas/ci.ts +56 -108
- package/src/schemas/codebase-health.ts +7 -11
- package/src/schemas/devices.ts +103 -321
- package/src/schemas/engines.ts +16 -44
- package/src/schemas/environment.ts +41 -91
- package/src/schemas/exit.ts +24 -81
- package/src/schemas/extension-updates.ts +42 -87
- package/src/schemas/git-history.ts +30 -84
- package/src/schemas/git.ts +141 -256
- package/src/schemas/history.ts +14 -40
- package/src/schemas/hosts.ts +9 -15
- package/src/schemas/inventory.ts +8 -10
- package/src/schemas/issues.ts +66 -134
- package/src/schemas/logs.ts +15 -34
- package/src/schemas/loops.ts +46 -163
- package/src/schemas/maintenance.ts +47 -172
- package/src/schemas/panels.ts +20 -45
- package/src/schemas/personas.ts +50 -200
- package/src/schemas/plan-limits.ts +58 -197
- package/src/schemas/ports.ts +14 -32
- package/src/schemas/provider-oauth.ts +23 -76
- package/src/schemas/provider-subscriptions.ts +4 -13
- package/src/schemas/public.ts +4 -15
- package/src/schemas/push.ts +8 -36
- package/src/schemas/secrets.ts +20 -64
- package/src/schemas/settings.ts +182 -602
- package/src/schemas/share.ts +14 -32
- package/src/schemas/shared.ts +14 -13
- package/src/schemas/system.ts +46 -78
- package/src/schemas/terminal.ts +41 -120
- package/src/schemas/usage.ts +44 -233
- package/src/schemas/version-seam.test.ts +9 -26
- package/src/schemas/vpn.ts +27 -64
- package/src/schemas/webext.ts +22 -53
- package/src/schemas/workflows.ts +57 -183
- package/src/schemas/workspace-repos.ts +12 -24
- package/src/schemas/workspace-search.ts +17 -35
- package/src/schemas/workspace-setup.ts +4 -11
- package/src/schemas/workspace-tree.ts +32 -91
- package/src/state/arrival.ts +109 -0
- package/src/state/contract-lock.test.ts +17 -0
- package/src/state/contract-lock.ts +49 -0
- package/src/state/definition.ts +143 -0
- package/src/state/history-state.ts +103 -0
- package/src/{runtime-state.test.ts → state/runtime-state.test.ts} +3 -10
- package/src/state/runtime-state.ts +63 -0
- package/src/state/starter.ts +5 -0
- package/src/state/state-portability.ts +27 -0
- package/src/state/versions.ts +26 -0
- package/src/{workspace-state.test.ts → state/workspace-state.test.ts} +65 -172
- package/src/state/workspace-state.ts +669 -0
- package/src/{documents.test.ts → text/documents.test.ts} +1 -1
- package/src/text/documents.ts +42 -0
- package/src/text/embed.ts +132 -0
- package/src/text/mentions.ts +21 -0
- package/src/text/model-answer.ts +9 -0
- package/src/text/path-refs.ts +39 -0
- package/src/text/shell-regions.ts +224 -0
- package/src/{title.test.ts → text/title.test.ts} +13 -32
- package/src/text/title.ts +202 -0
- package/src/{transcript-fold.test.ts → text/transcript-fold.test.ts} +5 -83
- package/src/{transcript-fold.ts → text/transcript-fold.ts} +65 -170
- package/src/text/whisper.test.ts +19 -0
- package/src/text/whisper.ts +17 -0
- package/src/{workflow-faults.test.ts → text/workflow-faults.test.ts} +6 -24
- package/src/{workflow-faults.ts → text/workflow-faults.ts} +20 -60
- package/dist/agent-catalog.d.ts.map +0 -1
- package/dist/agent-catalog.js.map +0 -1
- package/dist/agent-runtimes.d.ts.map +0 -1
- package/dist/agent-runtimes.js.map +0 -1
- package/dist/approvals-execution.d.ts.map +0 -1
- package/dist/approvals-execution.js.map +0 -1
- package/dist/arrival.d.ts.map +0 -1
- package/dist/arrival.js.map +0 -1
- package/dist/batch-runs.d.ts.map +0 -1
- package/dist/batch-runs.js.map +0 -1
- package/dist/capability-env.d.ts.map +0 -1
- package/dist/capability-env.js.map +0 -1
- package/dist/capability-secrets.d.ts.map +0 -1
- package/dist/capability-secrets.js.map +0 -1
- package/dist/card-status.d.ts.map +0 -1
- package/dist/card-status.js.map +0 -1
- package/dist/command-classes.d.ts.map +0 -1
- package/dist/command-classes.js.map +0 -1
- package/dist/command-run.d.ts.map +0 -1
- package/dist/command-run.js.map +0 -1
- package/dist/contract-lock.d.ts.map +0 -1
- package/dist/contract-lock.js.map +0 -1
- package/dist/conversation-ids.d.ts +0 -4
- package/dist/conversation-ids.d.ts.map +0 -1
- package/dist/conversation-ids.js.map +0 -1
- package/dist/credential-material.d.ts.map +0 -1
- package/dist/credential-material.js.map +0 -1
- package/dist/definition.d.ts.map +0 -1
- package/dist/definition.js.map +0 -1
- package/dist/documents.d.ts.map +0 -1
- package/dist/documents.js.map +0 -1
- package/dist/embed.d.ts.map +0 -1
- package/dist/embed.js.map +0 -1
- package/dist/events.d.ts +0 -4336
- package/dist/events.d.ts.map +0 -1
- package/dist/events.js +0 -725
- package/dist/events.js.map +0 -1
- package/dist/fast-tier.d.ts.map +0 -1
- package/dist/fast-tier.js.map +0 -1
- package/dist/history-state.d.ts.map +0 -1
- package/dist/history-state.js.map +0 -1
- package/dist/host-protocol.d.ts.map +0 -1
- package/dist/host-protocol.js.map +0 -1
- package/dist/hostnames.d.ts.map +0 -1
- package/dist/hostnames.js.map +0 -1
- package/dist/ingress-contract.d.ts.map +0 -1
- package/dist/ingress-contract.js.map +0 -1
- package/dist/ingress-protocol.d.ts.map +0 -1
- package/dist/ingress-protocol.js.map +0 -1
- package/dist/listener-protocol.d.ts.map +0 -1
- package/dist/listener-protocol.js.map +0 -1
- package/dist/mentions.d.ts.map +0 -1
- package/dist/mentions.js.map +0 -1
- package/dist/model-order.d.ts.map +0 -1
- package/dist/model-order.js.map +0 -1
- package/dist/model-pins.d.ts.map +0 -1
- package/dist/model-pins.js.map +0 -1
- package/dist/model-roles.d.ts.map +0 -1
- package/dist/model-roles.js.map +0 -1
- package/dist/needs-action.d.ts.map +0 -1
- package/dist/needs-action.js.map +0 -1
- package/dist/output-fields.d.ts.map +0 -1
- package/dist/output-fields.js.map +0 -1
- package/dist/overlay-lint.d.ts.map +0 -1
- package/dist/overlay-lint.js.map +0 -1
- package/dist/owner-ticket.d.ts.map +0 -1
- package/dist/owner-ticket.js.map +0 -1
- package/dist/path-refs.d.ts.map +0 -1
- package/dist/path-refs.js.map +0 -1
- package/dist/peer-dial.d.ts.map +0 -1
- package/dist/peer-dial.js.map +0 -1
- package/dist/peer-mcp-server.d.ts.map +0 -1
- package/dist/peer-mcp-server.js.map +0 -1
- package/dist/plan-pools.d.ts.map +0 -1
- package/dist/plan-pools.js.map +0 -1
- package/dist/prompt-complexity.d.ts.map +0 -1
- package/dist/prompt-complexity.js.map +0 -1
- package/dist/provider-specs.d.ts.map +0 -1
- package/dist/provider-specs.js.map +0 -1
- package/dist/request-id.d.ts.map +0 -1
- package/dist/request-id.js.map +0 -1
- package/dist/routes.d.ts.map +0 -1
- package/dist/routes.js.map +0 -1
- package/dist/runner-protocol.d.ts.map +0 -1
- package/dist/runner-protocol.js.map +0 -1
- package/dist/runtime-state.d.ts.map +0 -1
- package/dist/runtime-state.js.map +0 -1
- package/dist/safety-policy.d.ts.map +0 -1
- package/dist/safety-policy.js.map +0 -1
- package/dist/search-globs.d.ts.map +0 -1
- package/dist/search-globs.js.map +0 -1
- package/dist/session-names.d.ts.map +0 -1
- package/dist/session-names.js.map +0 -1
- package/dist/share-paths.d.ts.map +0 -1
- package/dist/share-paths.js.map +0 -1
- package/dist/shell-regions.d.ts.map +0 -1
- package/dist/shell-regions.js.map +0 -1
- package/dist/sse.d.ts.map +0 -1
- package/dist/sse.js.map +0 -1
- package/dist/starter.d.ts.map +0 -1
- package/dist/starter.js.map +0 -1
- package/dist/state-portability.d.ts.map +0 -1
- package/dist/state-portability.js.map +0 -1
- package/dist/terminal-protocol.d.ts.map +0 -1
- package/dist/terminal-protocol.js.map +0 -1
- package/dist/title.d.ts.map +0 -1
- package/dist/title.js.map +0 -1
- package/dist/transcript-fold.d.ts.map +0 -1
- package/dist/transcript-fold.js.map +0 -1
- package/dist/tunnel-ids.d.ts.map +0 -1
- package/dist/tunnel-ids.js.map +0 -1
- package/dist/versions.d.ts.map +0 -1
- package/dist/versions.js.map +0 -1
- package/dist/webext-links.d.ts.map +0 -1
- package/dist/webext-links.js.map +0 -1
- package/dist/webext-protocol.d.ts.map +0 -1
- package/dist/webext-protocol.js.map +0 -1
- package/dist/workflow-faults.d.ts.map +0 -1
- package/dist/workflow-faults.js.map +0 -1
- package/dist/workspace-state.d.ts.map +0 -1
- package/dist/workspace-state.js.map +0 -1
- package/src/agent-catalog.ts +0 -316
- package/src/agent-runtimes.ts +0 -419
- package/src/approvals-execution.ts +0 -96
- package/src/arrival.ts +0 -160
- package/src/batch-runs.ts +0 -188
- package/src/capability-ledger.test.ts +0 -140
- package/src/capability-secrets.ts +0 -20
- package/src/command-classes.ts +0 -617
- package/src/command-run.ts +0 -78
- package/src/contract-lock.test.ts +0 -23
- package/src/contract-lock.ts +0 -66
- package/src/conversation-ids.ts +0 -207
- package/src/credential-material.ts +0 -181
- package/src/definition.ts +0 -207
- package/src/documents.ts +0 -67
- package/src/embed.ts +0 -164
- package/src/events.ts +0 -1870
- package/src/fast-tier.ts +0 -72
- package/src/history-state.ts +0 -174
- package/src/host-protocol.ts +0 -36
- package/src/hostnames.ts +0 -180
- package/src/ingress-contract.ts +0 -157
- package/src/ingress-protocol.ts +0 -625
- package/src/listener-protocol.ts +0 -96
- package/src/mentions.ts +0 -25
- package/src/model-order.ts +0 -262
- package/src/model-pins.ts +0 -132
- package/src/model-roles.test.ts +0 -52
- package/src/model-roles.ts +0 -320
- package/src/needs-action.ts +0 -14
- package/src/output-fields.ts +0 -111
- package/src/overlay-lint.ts +0 -116
- package/src/path-refs.ts +0 -59
- package/src/peer-dial.ts +0 -163
- package/src/plan-pools.ts +0 -92
- package/src/prompt-complexity.ts +0 -334
- package/src/provider-specs.ts +0 -432
- package/src/request-id.ts +0 -41
- package/src/routes.ts +0 -219
- package/src/runner-protocol.ts +0 -239
- package/src/runtime-state.ts +0 -140
- package/src/safety-policy.test.ts +0 -88
- package/src/safety-policy.ts +0 -258
- package/src/search-globs.ts +0 -76
- package/src/session-names.ts +0 -44
- package/src/share-paths.ts +0 -68
- package/src/shell-regions.ts +0 -289
- package/src/starter.ts +0 -13
- package/src/state-portability.ts +0 -56
- package/src/terminal-protocol.ts +0 -16
- package/src/title.ts +0 -267
- package/src/tunnel-ids.ts +0 -57
- package/src/versions.ts +0 -48
- package/src/webext-links.ts +0 -90
- package/src/webext-protocol.ts +0 -27
- package/src/workspace-state.ts +0 -1090
- /package/dist/{hostnames.d.ts → ids/hostnames.d.ts} +0 -0
- /package/dist/{hostnames.js → ids/hostnames.js} +0 -0
- /package/dist/{session-names.d.ts → ids/session-names.d.ts} +0 -0
- /package/dist/{session-names.js → ids/session-names.js} +0 -0
- /package/dist/{share-paths.d.ts → ids/share-paths.d.ts} +0 -0
- /package/dist/{share-paths.js → ids/share-paths.js} +0 -0
- /package/dist/{agent-catalog.js → models/agent-catalog.js} +0 -0
- /package/dist/{agent-runtimes.d.ts → models/agent-runtimes.d.ts} +0 -0
- /package/dist/{agent-runtimes.js → models/agent-runtimes.js} +0 -0
- /package/dist/{fast-tier.js → models/fast-tier.js} +0 -0
- /package/dist/{model-order.d.ts → models/model-order.d.ts} +0 -0
- /package/dist/{model-pins.js → models/model-pins.js} +0 -0
- /package/dist/{plan-pools.js → models/plan-pools.js} +0 -0
- /package/dist/{prompt-complexity.d.ts → models/prompt-complexity.d.ts} +0 -0
- /package/dist/{prompt-complexity.js → models/prompt-complexity.js} +0 -0
- /package/dist/{provider-specs.d.ts → models/provider-specs.d.ts} +0 -0
- /package/dist/{provider-specs.js → models/provider-specs.js} +0 -0
- /package/dist/{approvals-execution.d.ts → policy/approvals-execution.d.ts} +0 -0
- /package/dist/{approvals-execution.js → policy/approvals-execution.js} +0 -0
- /package/dist/{capability-env.d.ts → policy/capability-env.d.ts} +0 -0
- /package/dist/{capability-env.js → policy/capability-env.js} +0 -0
- /package/dist/{capability-secrets.d.ts → policy/capability-secrets.d.ts} +0 -0
- /package/dist/{capability-secrets.js → policy/capability-secrets.js} +0 -0
- /package/dist/{command-run.js → policy/command-run.js} +0 -0
- /package/dist/{credential-material.d.ts → policy/credential-material.d.ts} +0 -0
- /package/dist/{credential-material.js → policy/credential-material.js} +0 -0
- /package/dist/{needs-action.d.ts → policy/needs-action.d.ts} +0 -0
- /package/dist/{needs-action.js → policy/needs-action.js} +0 -0
- /package/dist/{output-fields.d.ts → policy/output-fields.d.ts} +0 -0
- /package/dist/{output-fields.js → policy/output-fields.js} +0 -0
- /package/dist/{overlay-lint.d.ts → policy/overlay-lint.d.ts} +0 -0
- /package/dist/{overlay-lint.js → policy/overlay-lint.js} +0 -0
- /package/dist/{owner-ticket.d.ts → policy/owner-ticket.d.ts} +0 -0
- /package/dist/{search-globs.d.ts → policy/search-globs.d.ts} +0 -0
- /package/dist/{search-globs.js → policy/search-globs.js} +0 -0
- /package/dist/{ingress-contract.d.ts → protocol/ingress-contract.d.ts} +0 -0
- /package/dist/{ingress-protocol.d.ts → protocol/ingress-protocol.d.ts} +0 -0
- /package/dist/{ingress-protocol.js → protocol/ingress-protocol.js} +0 -0
- /package/dist/{listener-protocol.d.ts → protocol/listener-protocol.d.ts} +0 -0
- /package/dist/{peer-mcp-server.d.ts → protocol/peer-mcp-server.d.ts} +0 -0
- /package/dist/{peer-mcp-server.js → protocol/peer-mcp-server.js} +0 -0
- /package/dist/{request-id.d.ts → protocol/request-id.d.ts} +0 -0
- /package/dist/{request-id.js → protocol/request-id.js} +0 -0
- /package/dist/{routes.d.ts → protocol/routes.d.ts} +0 -0
- /package/dist/{routes.js → protocol/routes.js} +0 -0
- /package/dist/{sse.d.ts → protocol/sse.d.ts} +0 -0
- /package/dist/{sse.js → protocol/sse.js} +0 -0
- /package/dist/{terminal-protocol.js → protocol/terminal-protocol.js} +0 -0
- /package/dist/{webext-links.d.ts → protocol/webext-links.d.ts} +0 -0
- /package/dist/{webext-links.js → protocol/webext-links.js} +0 -0
- /package/dist/{arrival.d.ts → state/arrival.d.ts} +0 -0
- /package/dist/{contract-lock.d.ts → state/contract-lock.d.ts} +0 -0
- /package/dist/{history-state.d.ts → state/history-state.d.ts} +0 -0
- /package/dist/{runtime-state.d.ts → state/runtime-state.d.ts} +0 -0
- /package/dist/{runtime-state.js → state/runtime-state.js} +0 -0
- /package/dist/{starter.d.ts → state/starter.d.ts} +0 -0
- /package/dist/{starter.js → state/starter.js} +0 -0
- /package/dist/{state-portability.d.ts → state/state-portability.d.ts} +0 -0
- /package/dist/{state-portability.js → state/state-portability.js} +0 -0
- /package/dist/{versions.d.ts → state/versions.d.ts} +0 -0
- /package/dist/{versions.js → state/versions.js} +0 -0
- /package/dist/{embed.d.ts → text/embed.d.ts} +0 -0
- /package/dist/{embed.js → text/embed.js} +0 -0
- /package/dist/{mentions.d.ts → text/mentions.d.ts} +0 -0
- /package/dist/{mentions.js → text/mentions.js} +0 -0
- /package/dist/{path-refs.d.ts → text/path-refs.d.ts} +0 -0
- /package/dist/{path-refs.js → text/path-refs.js} +0 -0
- /package/dist/{shell-regions.js → text/shell-regions.js} +0 -0
- /package/dist/{title.d.ts → text/title.d.ts} +0 -0
- /package/dist/{title.js → text/title.js} +0 -0
- /package/src/{hostnames.test.ts → ids/hostnames.test.ts} +0 -0
- /package/src/{share-paths.test.ts → ids/share-paths.test.ts} +0 -0
- /package/src/{capability-env.ts → policy/capability-env.ts} +0 -0
- /package/src/{overlay-lint.test.ts → policy/overlay-lint.test.ts} +0 -0
- /package/src/{search-globs.test.ts → policy/search-globs.test.ts} +0 -0
- /package/src/{ingress-contract.test.ts → protocol/ingress-contract.test.ts} +0 -0
- /package/src/{peer-mcp-server.test.ts → protocol/peer-mcp-server.test.ts} +0 -0
- /package/src/{sse.ts → protocol/sse.ts} +0 -0
- /package/src/{versions.test.ts → state/versions.test.ts} +0 -0
- /package/src/{embed.test.ts → text/embed.test.ts} +0 -0
- /package/src/{mentions.test.ts → text/mentions.test.ts} +0 -0
- /package/src/{path-refs.test.ts → text/path-refs.test.ts} +0 -0
|
@@ -1,14 +1,12 @@
|
|
|
1
|
-
//
|
|
2
|
-
//
|
|
3
|
-
// each row's live status, the probe behind it, and the connect/rename/sign-in inputs.
|
|
1
|
+
// The one `{ id, kind, config }` shape every sandbox connection is written as: the config arm per kind, the union over
|
|
2
|
+
// them, and what the Capabilities page reads (status, probe, connect/rename/sign-in inputs).
|
|
4
3
|
import { z } from "zod";
|
|
5
4
|
import { ExitConfigSchema } from "./exit.js";
|
|
6
5
|
import { entryId } from "./internal.js";
|
|
7
6
|
import { ServiceKindSchema } from "./inventory.js";
|
|
8
7
|
import { VpnConfigSchema } from "./vpn.js";
|
|
9
|
-
// Everything a user adds
|
|
10
|
-
//
|
|
11
|
-
// is the capability that scaffolds the intent/desired-state repos, until it's active the sandbox is empty.
|
|
8
|
+
// Everything a user adds is a capability with an idempotent apply plus a status check; the manifest is the source of
|
|
9
|
+
// truth for what's active, and `mcp`-kind entries also feed the agent's MCP servers each turn.
|
|
12
10
|
|
|
13
11
|
export const CapabilityKindSchema = z.enum([
|
|
14
12
|
"devops",
|
|
@@ -46,20 +44,15 @@ export const ServiceConfigSchema = z.object({
|
|
|
46
44
|
on: z.string().min(1).describe("Which machine to put it on."),
|
|
47
45
|
expose: z.string().min(1).describe("How it should be reachable."),
|
|
48
46
|
});
|
|
49
|
-
// External-app credential injected into
|
|
50
|
-
//
|
|
51
|
-
//
|
|
52
|
-
// desired-state resolver only knows the providers in InventoryProviderSchema. So an integration card is NOT
|
|
53
|
-
// extension-contributable, the vocabulary belongs to the deploy engine, not to a manifest.
|
|
47
|
+
// External-app credential injected into deployed apps (i.have.stripe → STRIPE_API_KEY), not agent-facing like `cli`.
|
|
48
|
+
// Closed, unlike `cli`: it becomes an `i.have.<provider>` deploy.config.ts entry, so the vocabulary belongs to the
|
|
49
|
+
// deploy engine, not an extension.
|
|
54
50
|
export const IntegrationConfigSchema = z.object({
|
|
55
51
|
provider: z.literal("stripe").describe("Which outside service's credential to make available to deployed apps."),
|
|
56
52
|
});
|
|
57
|
-
//
|
|
58
|
-
//
|
|
59
|
-
//
|
|
60
|
-
// data (fields, env, skill, image fragment) is DATA in an installed extension's `contributes.capabilities`, not
|
|
61
|
-
// a per-provider schema arm, so the config is `provider` + arbitrary string fields, validated against the
|
|
62
|
-
// card's declared fields at add-time (see the sandbox's capabilities/contributions.ts) rather than by this schema.
|
|
53
|
+
// Gives the agent an authenticated CLI tool: credential plus any non-secret URL, injected into the agent's env each
|
|
54
|
+
// turn, taught via an .agents/skills/<id> cheatsheet. Provider fields are data in an extension's
|
|
55
|
+
// `contributes.capabilities`, validated at add-time, not by this schema.
|
|
63
56
|
export const CliConfigSchema = z
|
|
64
57
|
.object({
|
|
65
58
|
provider: z
|
|
@@ -70,9 +63,8 @@ export const CliConfigSchema = z
|
|
|
70
63
|
),
|
|
71
64
|
})
|
|
72
65
|
.catchall(z.string());
|
|
73
|
-
// A Claude Code plugin from a git repo
|
|
74
|
-
//
|
|
75
|
-
// marketplace/monorepo checkout. `token` = https auth for private repos (never echoed; becomes hasToken).
|
|
66
|
+
// A Claude Code plugin from a git repo; the daemon only owns the checkout, the Agent SDK's plugin loader reads its
|
|
67
|
+
// internals. `path` is a subdirectory for a plugin inside a larger checkout; `token` is https auth for a private repo.
|
|
76
68
|
export const PluginConfigSchema = z.object({
|
|
77
69
|
url: z.url().describe("The repository to take the plugin from."),
|
|
78
70
|
// Branch / tag / commit sha to pin; absent = the default branch's HEAD.
|
|
@@ -85,10 +77,9 @@ export const PluginConfigSchema = z.object({
|
|
|
85
77
|
.describe("Where inside the repository the plugin lives, for one that sits in a larger checkout."),
|
|
86
78
|
token: z.string().min(1).optional().describe("A credential for a private repository. Stored, never echoed back."),
|
|
87
79
|
});
|
|
88
|
-
// An intentic extension from a git repo (
|
|
89
|
-
//
|
|
90
|
-
//
|
|
91
|
-
// re-adds at a new sha. `path`/`token` as in PluginConfigSchema.
|
|
80
|
+
// An intentic extension from a git repo (UI bundle + agent contributions + processes). Unlike `plugin`, `ref` must be a
|
|
81
|
+
// full commit sha, since extension code runs trusted in the owner's browser and every update is a deliberate re-add at
|
|
82
|
+
// a new sha.
|
|
92
83
|
export const ExtensionConfigSchema = z.object({
|
|
93
84
|
url: z.url().describe("The repository to take the extension from."),
|
|
94
85
|
ref: z
|
|
@@ -104,23 +95,7 @@ export const ExtensionConfigSchema = z.object({
|
|
|
104
95
|
.optional()
|
|
105
96
|
.describe("Where inside the repository the extension lives, for one that sits in a larger checkout."),
|
|
106
97
|
token: z.string().min(1).optional().describe("A credential for a private repository. Stored, never echoed back."),
|
|
107
|
-
|
|
108
|
-
* two pool duties key off: installing (or updating) donates the owner's credits to the publisher, the
|
|
109
|
-
* gate the apply passes through, and enabling needs the owner's membership. An absent tier means free,
|
|
110
|
-
* donates nothing, and asks for nothing; NO usage is metered or reported either way. Self-declared rather
|
|
111
|
-
* than verified against the registry (the daemon is the owner's own machine; a stripped marker skips a
|
|
112
|
-
* donation the owner was choosing to make, which cheats the creator once, and is exactly the honesty the
|
|
113
|
-
* open-source posture accepts and the docs state). */
|
|
114
|
-
tier: z
|
|
115
|
-
.enum(["free", "premium"])
|
|
116
|
-
.optional()
|
|
117
|
-
.describe(
|
|
118
|
-
"Whether installing this donates credits to its publisher. Absent means free, which donates nothing and asks for nothing. Taken from the listing rather than checked against it, which is the honesty an open-source posture accepts.",
|
|
119
|
-
),
|
|
120
|
-
/* The registry this install's row lives in, copied on by the browse pre-fill like `tier`, what the update
|
|
121
|
-
* check compares the pinned sha against and reads advisories from. Absent (a hand-typed git install) falls
|
|
122
|
-
* back to the official registry: if the extension is listed there, its updates and its blocked-markings
|
|
123
|
-
* concern this owner exactly as much as anyone's. */
|
|
98
|
+
// What update checks and advisories are read against; absent falls back to the official registry.
|
|
124
99
|
registry: z
|
|
125
100
|
.url()
|
|
126
101
|
.optional()
|
|
@@ -128,10 +103,9 @@ export const ExtensionConfigSchema = z.object({
|
|
|
128
103
|
"Which registry this install came from, which is what update checks and security advisories are read against. Absent falls back to the official one.",
|
|
129
104
|
),
|
|
130
105
|
});
|
|
131
|
-
// A remote machine the
|
|
132
|
-
//
|
|
133
|
-
//
|
|
134
|
-
// several machines never collide. Discriminated by auth so exactly one credential shape is required.
|
|
106
|
+
// A remote machine the agent reaches over SSH; one capability per machine, the id is its ssh-config Host alias. Writes
|
|
107
|
+
// a config block and a 0600 key/password file, unlike `cli`, so nothing is injected into the agent's env and machines
|
|
108
|
+
// never collide.
|
|
135
109
|
export const SshConfigSchema = z.discriminatedUnion("auth", [
|
|
136
110
|
z.object({
|
|
137
111
|
auth: z.literal("key").describe("Sign in with a key."),
|
|
@@ -148,79 +122,25 @@ export const SshConfigSchema = z.discriminatedUnion("auth", [
|
|
|
148
122
|
password: z.string().min(1).describe("The password. Stored, never echoed back."),
|
|
149
123
|
}),
|
|
150
124
|
]);
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
* run without it, so a switch would offer a broken sandbox as a choice.)
|
|
155
|
-
*
|
|
156
|
-
* TWO FAMILIES, and which one an option belongs to is the most consequential thing about it, because it is the
|
|
157
|
-
* difference between a five-second change and a five-minute one:
|
|
158
|
-
*
|
|
159
|
-
* IMAGE (`gpu`), rides the environment overlay. Changing it recomposes the Dockerfile, so it costs an
|
|
160
|
-
* owner-approved rebuild and a container recreate. Only `fragment()` may read these.
|
|
161
|
-
* ENGINE (everything below it): /etc/docker/daemon.json, which dockerd reads at start. Changing one
|
|
162
|
-
* rewrites the file and restarts dockerd: no rebuild, no new image, but it DOES stop whatever containers
|
|
163
|
-
* the engine is running, which is why it is disclosed rather than silently applied.
|
|
164
|
-
*
|
|
165
|
-
* Keep the split honest in both directions: an engine option that leaked into the fragment would demand a
|
|
166
|
-
* rebuild for a value dockerd re-reads anyway, and an image option applied by rewriting a file would silently
|
|
167
|
-
* do nothing. The card badges the difference per field (CapabilityField.rebuild).
|
|
168
|
-
*
|
|
169
|
-
* Flat rather than nested, and "on"/"off" rather than booleans, because the capability form carries a flat
|
|
170
|
-
* bag of strings, one spelling of a two-state config across the manifest (the vpn's pfs/aggressive) beats a
|
|
171
|
-
* second one for the same shape. */
|
|
125
|
+
// What is optional about the in-sandbox Docker Engine: `gpu` is an IMAGE option (rides the Dockerfile overlay, needs a
|
|
126
|
+
// rebuild), everything else is an ENGINE option (rewrites daemon.json, restarts dockerd, no rebuild but stops running
|
|
127
|
+
// containers). Flat strings, not nested booleans, to match the manifest's own two-state convention.
|
|
172
128
|
export const DockerConfigSchema = z.object({
|
|
173
129
|
gpu: z.enum(["on", "off"]).default("off"),
|
|
174
|
-
|
|
175
|
-
|
|
130
|
+
// Pull-through cache/mirror; the nested engine starts with an empty image store, so the first compose up pulls
|
|
131
|
+
// everything.
|
|
176
132
|
registryMirror: z.url().optional(),
|
|
177
|
-
// Registries reachable over plain http or
|
|
178
|
-
//
|
|
133
|
+
// Registries reachable over plain http or a self-signed cert (a LAN or homelab registry); space- or
|
|
134
|
+
// comma-separated.
|
|
179
135
|
insecureRegistries: z.string().optional(),
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
* and the failure it produces is unusually cruel: the sandbox keeps working, dockerd keeps working, and
|
|
183
|
-
* exactly the internal hosts the user was reaching for become unreachable, routed into a bridge instead
|
|
184
|
-
* of down the tunnel. One CIDR, and the pool is carved from it. */
|
|
136
|
+
// One CIDR the nested engine carves container networks from; docker's default commonly collides with a corporate
|
|
137
|
+
// VPN or LAN, silently routing some hosts into the bridge instead of the tunnel.
|
|
185
138
|
addressPool: z.string().optional(),
|
|
186
139
|
});
|
|
187
|
-
// A logged-in browser session the
|
|
188
|
-
//
|
|
189
|
-
//
|
|
190
|
-
//
|
|
191
|
-
// Dockerfile fragment, applied on an owner rebuild.
|
|
192
|
-
//
|
|
193
|
-
// ONE CAPABILITY = ONE ACCOUNT, not one platform: several entries may name the same `platform` (reddit-work and
|
|
194
|
-
// reddit-personal), and the ID is what the profile, the login, the passkey and the agent's tool prefix are all
|
|
195
|
-
// keyed by, so each account signs in separately and is disconnected on its own.
|
|
196
|
-
//
|
|
197
|
-
// `platform` is an OPEN slug, not an enum, for the reason `cli`'s `provider` is: a platform is a card, a login URL
|
|
198
|
-
// and a skill in an installed extension's `contributes.capabilities`, so the set of them is not a fact this
|
|
199
|
-
// contract can know. The add route validates it against the contributed entry instead (see contributions.ts).
|
|
200
|
-
//
|
|
201
|
-
// `username`/`password` are the account's SIGN-IN CREDENTIALS, on every card rather than declared per platform
|
|
202
|
-
// (which box a login form wants filled is the same fact everywhere). Both optional: a profile that signed in by
|
|
203
|
-
// hand needs neither, and the password is the entry's SECRET, stored so the daemon can type it into the page on
|
|
204
|
-
// the agent's behalf (the accounts tools), never so the agent can read it. When the agent signs UP it has the
|
|
205
|
-
// daemon generate and store one here, so the credential outlives the profile's cookies.
|
|
206
|
-
//
|
|
207
|
-
// `catchall`, the `cli` precedent, for the card that carries no site at all: a GENERIC browser session, where the
|
|
208
|
-
// page to open and what the account is for are answered on the form instead of pinned in a manifest. A site card
|
|
209
|
-
// pins its URLs and declares no fields; the generic one declares fields and pins nothing, one kind, because
|
|
210
|
-
// nothing downstream of the URLs differs. Which other keys are legal is the CARD's business, checked against its
|
|
211
|
-
// declared fields at add-time (validateContributionConfig), not this schema's.
|
|
212
|
-
//
|
|
213
|
-
// `identity` names the identity capability this account was born from (or was filed under): the account then
|
|
214
|
-
// lives INSIDE that identity's browser, one profile, one set of cookies, which is what makes "Continue with
|
|
215
|
-
// Google" one click instead of a second Google login the platform would block. Absent ⇒ the account keeps its
|
|
216
|
-
// own private profile, exactly as every hand-connected account always has.
|
|
217
|
-
//
|
|
218
|
-
// `purpose` and `openedAt` are the ACCOUNT's own history, core for the same reason `identity` is: what this
|
|
219
|
-
// account was opened for and when are facts about the sandbox's own past, not about any site, and a site card
|
|
220
|
-
// that declared no fields (every one of them, a pinned-URL card declares none) could not carry them otherwise.
|
|
221
|
-
// They are what makes the roster answerable months later, when "do we already have an account here" is asked by
|
|
222
|
-
// a session that was not the one that signed up. Both optional: an account the owner connected by hand has no
|
|
223
|
-
// signup story to tell, and an empty purpose is better than a fabricated one.
|
|
140
|
+
// A logged-in browser session the agent drives via Playwright MCP, one capability per account (not per platform): the
|
|
141
|
+
// id keys the profile, login, passkey and tool prefix. `identity` shares another capability's browser and cookies (so
|
|
142
|
+
// its own `exit`/credentials are ignored); `purpose`/`openedAt` record why and when the agent opened it, since a site
|
|
143
|
+
// card declares no fields to carry that otherwise.
|
|
224
144
|
export const BrowserConfigSchema = z
|
|
225
145
|
.object({
|
|
226
146
|
platform: z.string().min(1),
|
|
@@ -230,72 +150,30 @@ export const BrowserConfigSchema = z
|
|
|
230
150
|
purpose: z.string().optional(),
|
|
231
151
|
// ISO-8601 date, stamped when the agent opens the account, absent for one connected by hand.
|
|
232
152
|
openedAt: z.string().optional(),
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
*
|
|
236
|
-
* Only meaningful on an account that owns its OWN profile. An account born from an identity shares
|
|
237
|
-
* that identity's browser, cookies, passkeys and all, so it shares its exit too and this field is
|
|
238
|
-
* ignored for it (see the daemon's browser/browser-exit.ts). That is not a limitation, it is the
|
|
239
|
-
* point: one Google session appearing from Berlin in one tab and Osaka in another is a far louder
|
|
240
|
-
* signal than any address, so the exit belongs to whatever owns the profile. */
|
|
153
|
+
// The `exit` capability this profile browses from; ignored for an account born from an `identity`, since the
|
|
154
|
+
// exit belongs to whoever owns the shared profile.
|
|
241
155
|
exit: z.string().optional(),
|
|
242
156
|
})
|
|
243
157
|
.catchall(z.string());
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
* one: Google signed in once (by the OWNER's hand, in the guided window, automated Google logins are exactly
|
|
249
|
-
* what Google blocks), and every account born from it sharing those cookies, so a platform's "Continue with
|
|
250
|
-
* Google" is a click rather than an email round-trip. Browser accounts join it by naming it in their `identity`
|
|
251
|
-
* field; accounts that name no identity keep their own private profile, which is how work and personal stay two
|
|
252
|
-
* containers, two identities, not one profile with a flag.
|
|
253
|
-
*
|
|
254
|
-
* WHY A CAPABILITY AND NOT A PERSONA: this card holds SECRETS (an email password the daemon types but never
|
|
255
|
-
* shows) and a live profile's identity, and the personas file is committed to git precisely because it holds
|
|
256
|
-
* neither (personas-store.ts). A persona is how a session BEHAVES; an identity is who the browser IS SIGNED IN
|
|
257
|
-
* as. A persona may point at accounts that live inside an identity, and neither card needs to know the other
|
|
258
|
-
* exists.
|
|
259
|
-
*
|
|
260
|
-
* `email` is the identity itself, what signup forms get typed into their username box, and how the guided
|
|
261
|
-
* login knows where to start (gmail.com ⇒ accounts.google.com; `loginUrl` overrides for any other provider).
|
|
262
|
-
* `password` is the entry's SECRET, the browser-config precedent: typed by the daemon, never readable.
|
|
263
|
-
* `mailbox` names a connected mail capability (imap, google) the narrow code tool reads, the agent asks for
|
|
264
|
-
* "the latest code from this site" and gets six digits, not an inbox.
|
|
265
|
-
* `openAccounts` is THE consent switch, off by default and a select rather than a boolean (the host-scope
|
|
266
|
-
* precedent, form values arrive as strings): automated signup is against most platforms' terms, so minting
|
|
267
|
-
* accounts unattended is an explicit, per-identity, informed choice, never a silent global default. */
|
|
158
|
+
// One email identity the sandbox acts as online: one persisted Chromium profile, signed in once by the owner, that
|
|
159
|
+
// every browser account naming it in `identity` shares. A capability, not a persona, since it holds live secrets (email
|
|
160
|
+
// password, profile identity) that must never be committed to git. `mailbox` feeds the code-reading tool;
|
|
161
|
+
// `openAccounts` is the explicit, off-by-default consent to sign up unattended.
|
|
268
162
|
export const IdentityConfigSchema = z.object({
|
|
269
163
|
email: z.string().min(3),
|
|
270
164
|
password: z.string().optional(),
|
|
271
165
|
mailbox: z.string().optional(),
|
|
272
166
|
loginUrl: z.url().optional(),
|
|
273
167
|
openAccounts: z.enum(["on", "off"]).default("off"),
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
* the only coherent place to set it: the shared thing is one browser, and one browser is in one place. */
|
|
168
|
+
// Sets browsing location for the whole shared profile at once; the only coherent place to set it, since every
|
|
169
|
+
// account born from this identity shares one browser.
|
|
277
170
|
exit: z.string().optional(),
|
|
278
171
|
});
|
|
279
172
|
export type IdentityConfig = z.infer<typeof IdentityConfigSchema>;
|
|
280
|
-
|
|
281
|
-
|
|
282
|
-
|
|
283
|
-
|
|
284
|
-
* never implements a tool itself, so the machine's capabilities evolve with ITS binary, not with a daemon release.
|
|
285
|
-
*
|
|
286
|
-
* One capability = one machine. The id is the machine's name and namespaces its tools (mcp__laptop__run_command),
|
|
287
|
-
* so several connected machines never collide, the `ssh` precedent. `platform` splits the SKILL pack: a Windows
|
|
288
|
-
* machine is taught PowerShell and a Linux one systemd/D-Bus, and neither carries the other's noise.
|
|
289
|
-
*
|
|
290
|
-
* SCOPES ARE THE GRANT, and they are enforced ON THE MACHINE, never here: the daemon pushes them down on every
|
|
291
|
-
* connect, and the agent refuses out-of-scope calls itself. So a sandbox that is compromised, or an agent talked
|
|
292
|
-
* into it by something it read on the internet, still cannot exceed what the owner ticked. `roots` bounds file
|
|
293
|
-
* reads AND writes to a set of directories (empty ⇒ the user's home).
|
|
294
|
-
*
|
|
295
|
-
* Like a browser `platform`, this is an OPEN slug: an OS is a card plus a skill pack in an installed extension's
|
|
296
|
-
* `contributes.capabilities`, and teaching the agent a new one should not need a daemon release. */
|
|
297
|
-
// on/off rather than a boolean: capability configs arrive from the add form as strings (the vpn autoConnect
|
|
298
|
-
// precedent), and a select is what the form renders for an enum.
|
|
173
|
+
// A connected device of the user's own, the inverse of `ssh`: it dials this daemon over one outbound WebSocket and
|
|
174
|
+
// serves an MCP tool surface the daemon tunnels, never implements. Scopes are the grant and are enforced on the
|
|
175
|
+
// machine, never here, so a compromised sandbox can't exceed what the owner ticked.
|
|
176
|
+
// on/off, not boolean: capability configs arrive from the form as strings, and a select renders an enum.
|
|
299
177
|
const hostScope = z.enum(["on", "off"]);
|
|
300
178
|
export const HostScopesSchema = z.object({
|
|
301
179
|
// Run commands in a real shell (PowerShell on Windows, the login shell on Linux). Off ⇒ files/screen only.
|
|
@@ -304,175 +182,76 @@ export const HostScopesSchema = z.object({
|
|
|
304
182
|
write: hostScope.default("off"),
|
|
305
183
|
// Capture the screen. Off ⇒ screenshot refuses, and the agent is told so rather than getting a black frame.
|
|
306
184
|
screen: hostScope.default("on"),
|
|
307
|
-
|
|
308
|
-
* switch rather than part of `screen` because looking and touching are not the same permission: a screenshot
|
|
309
|
-
* is bounded by what is on the display, while one click can confirm a dialog nobody read. Default off, like
|
|
310
|
-
* `write`, and for the same reason, a user who has not thought about it should not discover the agent has
|
|
311
|
-
* been driving their desktop. */
|
|
185
|
+
// Its own switch, not part of `screen`: looking and touching are different permissions. Default off, like `write`.
|
|
312
186
|
control: hostScope.default("off"),
|
|
313
|
-
|
|
314
|
-
* the machine's supervisor. Its own switch rather than a use of `shell` because it is NARROWER: a user can
|
|
315
|
-
* hand an agent the sandbox fleet without handing it a shell, and the fleet operations are named rather than
|
|
316
|
-
* whatever a model improvises with docker. Default off, like every switch that changes the machine. */
|
|
187
|
+
// Narrower than `shell`: named fleet operations, so an agent can supervise sandboxes without a shell at all.
|
|
317
188
|
sandboxes: hostScope.default("off"),
|
|
318
|
-
|
|
319
|
-
* and /history. Its own switch rather than part of `sandboxes` because the two differ in the only way that
|
|
320
|
-
* matters here: everything `sandboxes` grants is undone by doing it again, and this is undone by nothing.
|
|
321
|
-
* A user who delegated "restart my sandboxes when they wedge" did not thereby agree to lose one. */
|
|
189
|
+
// Separate from `sandboxes`: everything that grants is reversible by doing it again, removal is undone by nothing.
|
|
322
190
|
sandboxRemove: hostScope.default("off"),
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
*
|
|
326
|
-
* ITS OWN SWITCH UNDER `shell`, and the reason is the asymmetry this whole feature turns on. Inside the
|
|
327
|
-
* sandbox a bad `rm -rf` costs a container that exists to be thrown away, so the gate there can afford to
|
|
328
|
-
* hold only the handful of commands nothing undoes and wave the rest through. This is somebody's laptop.
|
|
329
|
-
* There is no image to recreate it from, no checkpoint, no worktree: `rm -rf ~/projects` is the afternoon
|
|
330
|
-
* everybody remembers. And there is no card to raise either, the machine answers a tool call with a value
|
|
331
|
-
* and cannot park it while somebody thinks, so the honest form of "ask me" here is "refuse until they
|
|
332
|
-
* ticked it", which is exactly what a scope is.
|
|
333
|
-
*
|
|
334
|
-
* Default off, with `shell` default ON, which is the pairing to read carefully: a connected device runs
|
|
335
|
-
* commands out of the box, because that is what people connect one for, and the ones that delete are the
|
|
336
|
-
* ones they have to say yes to. */
|
|
191
|
+
// Its own switch under `shell`, default off while `shell` defaults on: a laptop has no disposable image to recreate
|
|
192
|
+
// from.
|
|
337
193
|
destructive: hostScope.default("off"),
|
|
338
194
|
// One directory per line. Empty ⇒ the machine's home directory, which is what the agent reports at connect.
|
|
339
195
|
roots: z.string().optional(),
|
|
340
196
|
});
|
|
341
197
|
export type HostScopes = z.infer<typeof HostScopesSchema>;
|
|
342
198
|
export const HostConfigSchema = HostScopesSchema.extend({ platform: z.string().min(1) });
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
* browser has one power a sandbox's own Chromium can never have, and it is the whole reason this kind exists:
|
|
347
|
-
* it is ALREADY SIGNED IN, as the person, with their passkeys, their hardware second factor, their corporate
|
|
348
|
-
* SSO and their genuine fingerprint. That is the set of sites the sandbox's browser cannot reach at all, and
|
|
349
|
-
* copying a session out of one to fake it is what gets an account locked.
|
|
350
|
-
*
|
|
351
|
-
* WHICH SITES the agent may touch is NOT in here, and that omission is the security design rather than a gap.
|
|
352
|
-
* Origins are Chrome's own optional host permissions, asked for by the extension with the person's hands on
|
|
353
|
-
* the keyboard and revocable in the browser's own UI, so the boundary that matters is enforced by the browser
|
|
354
|
-
* against the extension, one layer below anything a sandbox could reach. What the card carries is the coarser
|
|
355
|
-
* question the sandbox's owner answers once: what KIND of thing may happen on a site they have already allowed.
|
|
356
|
-
*
|
|
357
|
-
* Every switch is enforced IN THE EXTENSION (as every host scope is enforced on the machine): the daemon
|
|
358
|
-
* pushes them on connect and on every edit, and nothing on this side checks one. */
|
|
199
|
+
// The user's own browser, reached through their installed extension; the sibling of `host`, not an arm of it, since
|
|
200
|
+
// it's already signed in as the person, with their passkeys and SSO. Which sites the agent may touch lives in Chrome's
|
|
201
|
+
// own host permissions, not here; every switch is enforced in the extension, never checked on this side.
|
|
359
202
|
const webextScope = z.enum(["on", "off"]);
|
|
360
203
|
export const WebExtScopesSchema = z.object({
|
|
361
|
-
//
|
|
362
|
-
// it off the connection is inert and the card says so rather than pretending.
|
|
204
|
+
// The floor of usefulness, defaults on; off, the connection is inert and the card says so.
|
|
363
205
|
read: webextScope.default("on"),
|
|
364
|
-
|
|
365
|
-
* what the two things ARE: driving a desktop is the last resort after every command-line route failed,
|
|
366
|
-
* while driving the page IS this connector — a browser connection that may only look is a worse version
|
|
367
|
-
* of fetching the URL. The grant that actually bounds it is per-site and lives in the browser. */
|
|
206
|
+
// On by default, unlike a device's `control`: driving the page is what this connector is for, not a last resort.
|
|
368
207
|
act: webextScope.default("on"),
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
* while a screenshot is whatever pixels that window happens to be showing. Worth turning on for canvas
|
|
372
|
-
* apps and PDF viewers, which is exactly when the DOM says nothing. */
|
|
208
|
+
// Off by default: the one read nothing here bounds, since it captures whatever pixels the window shows, not just
|
|
209
|
+
// granted frames.
|
|
373
210
|
screenshot: webextScope.default("off"),
|
|
374
|
-
|
|
375
|
-
* on overnight with the laptop shut. Off by default and deliberately hard to turn on by accident: it is
|
|
376
|
-
* the only switch here that COPIES a credential rather than borrowing the browser holding it, and some
|
|
377
|
-
* sites answer a session arriving from a new fingerprint by invalidating it. */
|
|
211
|
+
// Off by default: the only switch here that copies a credential rather than borrowing the browser holding it.
|
|
378
212
|
cookies: webextScope.default("off"),
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
* confirmation waits for a human click; ordinary navigation and typing do not. "always" makes every action
|
|
382
|
-
* a prompt (correct for a first week, exhausting after it); "never" is the owner saying they will watch
|
|
383
|
-
* instead, which they genuinely can, because they are looking at the tab. */
|
|
213
|
+
// "sensitive" (default) prompts only for a password, payment or delete action; "always" prompts every action,
|
|
214
|
+
// "never" trusts the owner to watch.
|
|
384
215
|
confirm: z.enum(["sensitive", "always", "never"]).default("sensitive"),
|
|
385
216
|
});
|
|
386
217
|
export type WebExtScopes = z.infer<typeof WebExtScopesSchema>;
|
|
387
|
-
//
|
|
388
|
-
// skill pack's wording and the install link, and teaching the agent a new one should not need a daemon release.
|
|
218
|
+
// An open slug (chrome, firefox), like a host's `platform`: a new browser family needs no daemon release.
|
|
389
219
|
export const WebExtConfigSchema = WebExtScopesSchema.extend({ platform: z.string().min(1) });
|
|
390
220
|
export type WebExtConfig = z.infer<typeof WebExtConfigSchema>;
|
|
391
|
-
// An ACP
|
|
392
|
-
//
|
|
393
|
-
//
|
|
394
|
-
// block (one per line); credentials ride here, so the whole block is the secret field (echoed as hasSecret),
|
|
395
|
-
// the vpn-conf precedent. `loginCommand` is an interactive login the user completes in a visible terminal
|
|
396
|
-
// (device-code flows); the agent persists credentials in its own store inside the container. `name` is the
|
|
397
|
-
// picker's display label; absent = the id.
|
|
221
|
+
// An ACP agent served as a chat provider: the daemon spawns `command` as a long-lived JSON-RPC subprocess, and the
|
|
222
|
+
// capability id becomes the provider id. `env` is a pasted KEY=VALUE block, the whole secret field; `loginCommand` runs
|
|
223
|
+
// an interactive device-code login in a visible terminal.
|
|
398
224
|
export const AcpAgentConfigSchema = z.object({
|
|
399
225
|
command: z.string().min(1),
|
|
400
226
|
name: z.string().min(1).optional(),
|
|
401
227
|
env: z.string().optional(),
|
|
402
228
|
loginCommand: z.string().min(1).optional(),
|
|
403
229
|
});
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
* `protocol` is the only real fork, and it is about the WIRE, not about where the server lives:
|
|
410
|
-
* openai , the endpoint speaks OpenAI /v1/chat/completions (Ollama, vLLM, llama.cpp, LM Studio, TGI,
|
|
411
|
-
* OpenRouter, most gateways). The Claude Code harness speaks only the Anthropic Messages API, so
|
|
412
|
-
* these are re-served through the bundled translator, which is already in the image for exactly
|
|
413
|
-
* this job (agent/translator.ts). The user's key stays in the translator's config on /history and
|
|
414
|
-
* never reaches the harness, it gets the loopback bearer instead.
|
|
415
|
-
* anthropic, the endpoint already speaks the Anthropic Messages API (LiteLLM's /v1/messages, a Bedrock or
|
|
416
|
-
* Vertex router, a corporate Anthropic gateway). Nothing to translate: the harness is pointed
|
|
417
|
-
* straight at it with the user's own key.
|
|
418
|
-
*
|
|
419
|
-
* `headers` is a pasted `Name: value` block, one per line, the extra headers gateways ask for (a tenant id, a
|
|
420
|
-
* routing hint). The key is the secret field; the header block is not, because it is where non-credential
|
|
421
|
-
* routing metadata lives and hiding it would make a misrouted endpoint undiagnosable. */
|
|
230
|
+
// A model API the user pointed us at: one shape for any server serving models over HTTP, local or remote, since they
|
|
231
|
+
// differ only in the URL. `protocol` is the real fork, about the wire, not location:
|
|
232
|
+
// openai: re-served through the bundled translator, since the harness speaks only Anthropic Messages
|
|
233
|
+
// anthropic: the harness is pointed straight at it with the user's own key
|
|
234
|
+
// `headers` is a pasted block for non-credential routing metadata (a tenant id); not the secret field, `apiKey` is.
|
|
422
235
|
export const EndpointProtocolSchema = z.enum(["openai", "anthropic"]);
|
|
423
236
|
export type EndpointProtocol = z.infer<typeof EndpointProtocolSchema>;
|
|
424
237
|
export const EndpointConfigSchema = z.object({
|
|
425
|
-
//
|
|
426
|
-
// normalised: "which suffix does this server want" is the one thing that actually varies between them, and
|
|
427
|
-
// guessing it is how a working URL becomes an unexplainable 404.
|
|
238
|
+
// Taken verbatim, version segment included: guessing the suffix a server wants is how a working URL 404s.
|
|
428
239
|
baseUrl: z.url(),
|
|
429
240
|
protocol: EndpointProtocolSchema.default("openai"),
|
|
430
241
|
apiKey: z.string().optional(),
|
|
431
242
|
headers: z.string().optional(),
|
|
432
243
|
});
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
* translator, quick-model pinning) sees an `endpoint/<id>` provider and never learns the difference, which is
|
|
438
|
-
* why there is no baseUrl here: the URL is derived from the entry's id (the daemon's endpoints/local-model.ts),
|
|
439
|
-
* not a fact anyone typed.
|
|
440
|
-
*
|
|
441
|
-
* `model` is WHICH WEIGHTS, as a Hugging Face path (`owner/repo/file.gguf`, resolved to the repo's own
|
|
442
|
-
* download), so shipping a new recommended model is a catalog-card edit, not a daemon release. The reserved
|
|
443
|
-
* value "custom" defers to `url`, a direct GGUF link for people who know exactly what they want.
|
|
444
|
-
*
|
|
445
|
-
* `gpu` mirrors the docker card's option and rides the same allowlisted `--gpus=all` directive: the ASK lives
|
|
446
|
-
* here, what became of it is SANDBOX_GPU, stamped by the runner (see the docker handler's gpuState). "on"/"off"
|
|
447
|
-
* rather than a boolean for the manifest-wide reason DockerConfigSchema gives.
|
|
448
|
-
*
|
|
449
|
-
* `context`/`contextTokens` are HOW MUCH CONVERSATION the server holds, the `model`/`url` pair's shape for the
|
|
450
|
-
* same reason: a short list of rungs anyone can choose between, and one escape hatch for a person who knows the
|
|
451
|
-
* exact number they want. Resolved to a single token count in exactly one place (the daemon's
|
|
452
|
-
* endpoints/local-model.ts localModelWindow), because the flag llama-server is started with and the number the
|
|
453
|
-
* card promises must never be two opinions. */
|
|
244
|
+
// A model the sandbox runs itself, the managed counterpart of `endpoint`: the daemon downloads the weights, serves them
|
|
245
|
+
// on a loopback llama-server, and registers an `endpoint/<id>` provider like a user-added one. `model` is a Hugging
|
|
246
|
+
// Face path (or "custom" for a direct GGUF `url`); `context`/`contextTokens` pick the served window, resolved to one
|
|
247
|
+
// token count in exactly one place so the server's flag and the card's promise never disagree.
|
|
454
248
|
export const LOCAL_MODEL_WINDOWS = ["16384", "32768", "65536", "131072"] as const;
|
|
455
249
|
export type LocalModelWindow = (typeof LOCAL_MODEL_WINDOWS)[number];
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
*
|
|
459
|
-
* It is 65,536 because this sandbox runs a TOOL-CALLING AGENT LOOP, and that loop's own fixed cost, its
|
|
460
|
-
* instructions plus one JSON schema per tool it can call, times every capability the owner has connected, is
|
|
461
|
-
* tens of thousands of tokens before the user has typed anything (agent/context-budget.ts holds the measurement
|
|
462
|
-
* and the refusal built on it). A window that cannot hold that cost is not a smaller version of the product; it
|
|
463
|
-
* is a model whose every real turn is refused, which is what the previous flat 32,768 shipped: a 27B model,
|
|
464
|
-
* seventeen gigabytes downloaded, and a first message that died on `36216 tokens exceeds 32768`.
|
|
465
|
-
*
|
|
466
|
-
* So the default is the smallest rung a full turn fits in, and the smaller rungs stay on the list because they
|
|
467
|
-
* are honestly useful: pinned as the quick model (titles, commit messages) a window this size is waste, and the
|
|
468
|
-
* gigabyte it gives back is the difference between running one of these models on an eight-gigabyte laptop and
|
|
469
|
-
* not. What each rung costs in memory is the card's job to say (capability-catalog): roughly 2 GB of quantized
|
|
470
|
-
* cache per 32k of window, on top of the weights. */
|
|
250
|
+
// 65,536: the smallest rung a full agent turn's own tool-schema overhead actually fits in (agent/context-budget.ts);
|
|
251
|
+
// the previous 32,768 default refused a model's first real message outright.
|
|
471
252
|
export const LOCAL_MODEL_WINDOW_DEFAULT: LocalModelWindow = "65536";
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
* number no GGUF on offer was trained for, and llama-server would spend minutes reserving a cache for it before
|
|
475
|
-
* failing. Everything between is the owner's call: their machine, their memory. */
|
|
253
|
+
// Bounds against a typo, not a preference: below the floor no room is left after the loop's own overhead, above the
|
|
254
|
+
// ceiling no shipped GGUF was trained for it.
|
|
476
255
|
export const LOCAL_MODEL_WINDOW_MIN = 2048;
|
|
477
256
|
export const LOCAL_MODEL_WINDOW_MAX = 1_048_576;
|
|
478
257
|
export const LocalModelConfigSchema = z.object({
|
|
@@ -480,36 +259,19 @@ export const LocalModelConfigSchema = z.object({
|
|
|
480
259
|
gpu: z.enum(["on", "off"]).default("off"),
|
|
481
260
|
url: z.url().optional(),
|
|
482
261
|
context: z.union([z.enum(LOCAL_MODEL_WINDOWS), z.literal("custom")]).default(LOCAL_MODEL_WINDOW_DEFAULT),
|
|
483
|
-
// Coerced
|
|
484
|
-
// when `context` is "custom" (the `url`/`model` relationship exactly).
|
|
262
|
+
// Coerced from a text field's string, like the ssh card's `port`; read only when `context` is "custom".
|
|
485
263
|
contextTokens: z.coerce.number().int().min(LOCAL_MODEL_WINDOW_MIN).max(LOCAL_MODEL_WINDOW_MAX).optional(),
|
|
486
264
|
});
|
|
487
265
|
export type LocalModelConfig = z.infer<typeof LocalModelConfigSchema>;
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
* a boundary in this codebase's threat model (see the daemon's secret-vault.ts header), so the key does not
|
|
493
|
-
* enter the container at all. `address` is the wallet's PUBLIC address, written back by the handler's apply
|
|
494
|
-
* from the platform's answer, never typed by anyone: it is where the owner sends USDC, and everything the
|
|
495
|
-
* agent may know.
|
|
496
|
-
*
|
|
497
|
-
* POLICY IS THE OWNER'S DELEGATION, and its defaults are the conservative ones: every payment raises an
|
|
498
|
-
* approval card (`autoApproveUnderUsd: "0"`), bounded per payment and per UTC day. The daemon enforces it at
|
|
499
|
-
* the route AND the platform re-validates at the signer, the daemon's check is UX, the signer's is the
|
|
500
|
-
* guarantee, so a compromised container can at worst request what the owner already permitted. Amounts are
|
|
501
|
-
* DECIMAL STRINGS, never floats: the daemon does its arithmetic in the token's atomic units (USDC has six
|
|
502
|
-
* decimals), and a float here would be a rounding bug wearing a type.
|
|
503
|
-
*
|
|
504
|
-
* `allow`/`deny` are hostname lists (comma- or newline-separated). Empty allow = any host, each behind its
|
|
505
|
-
* card; deny wins over allow. One capability per sandbox (singleton card): a second balance would just be a
|
|
506
|
-
* second opinion about the same owner's wallet. */
|
|
266
|
+
// The sandbox wallet: a USDC balance under owner policy, spent on x402-payable endpoints. The signing key lives with
|
|
267
|
+
// the platform, never the container; `address` is the wallet's public address, written back by apply, never typed.
|
|
268
|
+
// Policy defaults are conservative (every payment carded); amounts are decimal strings, never floats, since the daemon
|
|
269
|
+
// does arithmetic in atomic units.
|
|
507
270
|
const usdAmount = z.string().regex(/^\d+(\.\d{1,6})?$/, "a USD amount like 0.50 (up to six decimals: USDC's own precision)");
|
|
508
271
|
export const WalletNetworkSchema = z.enum(["eip155:8453", "eip155:84532"]);
|
|
509
272
|
export type WalletNetwork = z.infer<typeof WalletNetworkSchema>;
|
|
510
273
|
export const WalletConfigSchema = z.object({
|
|
511
|
-
//
|
|
512
|
-
// whole flow, cards, ledger, receipts, with zero real money).
|
|
274
|
+
// CAIP-2 chain id; Base mainnet, or Base Sepolia for a zero-real-money test mode.
|
|
513
275
|
network: WalletNetworkSchema.default("eip155:8453"),
|
|
514
276
|
// The wallet's public address, the platform's answer at apply time, never a form field.
|
|
515
277
|
address: z.string().optional(),
|
|
@@ -537,8 +299,8 @@ export type AcpAgentConfig = z.infer<typeof AcpAgentConfigSchema>;
|
|
|
537
299
|
export type EndpointConfig = z.infer<typeof EndpointConfigSchema>;
|
|
538
300
|
export const CapabilitySchema = z.discriminatedUnion("kind", [
|
|
539
301
|
z.object({ id: entryId, kind: z.literal("devops"), config: z.object({}) }),
|
|
540
|
-
// A pnpm+turbo monorepo the user scaffolds as its own repo
|
|
541
|
-
//
|
|
302
|
+
// A pnpm+turbo monorepo the user scaffolds as its own repo, named by `id`; apps are added afterwards from its
|
|
303
|
+
// operator panel.
|
|
542
304
|
z.object({ id: entryId, kind: z.literal("monorepo"), config: z.object({}) }),
|
|
543
305
|
z.object({ id: entryId, kind: z.literal("mcp"), config: McpConfigSchema }),
|
|
544
306
|
z.object({ id: entryId, kind: z.literal("service"), config: ServiceConfigSchema }),
|
|
@@ -547,91 +309,61 @@ export const CapabilitySchema = z.discriminatedUnion("kind", [
|
|
|
547
309
|
z.object({ id: entryId, kind: z.literal("plugin"), config: PluginConfigSchema }),
|
|
548
310
|
z.object({ id: entryId, kind: z.literal("extension"), config: ExtensionConfigSchema }),
|
|
549
311
|
z.object({ id: entryId, kind: z.literal("ssh"), config: SshConfigSchema }),
|
|
550
|
-
// No IFNAMSIZ cap on the id: the tunnel
|
|
551
|
-
//
|
|
312
|
+
// No IFNAMSIZ cap on the id: the tunnel interface name is derived, not the id itself, so a descriptive name is
|
|
313
|
+
// free.
|
|
552
314
|
z.object({ id: entryId, kind: z.literal("vpn"), config: VpnConfigSchema }),
|
|
553
|
-
// A geo exit
|
|
554
|
-
//
|
|
315
|
+
// A geo exit; deliberately not a vpn arm, since it routes nothing into the main table and carries no full-tunnel
|
|
316
|
+
// warning.
|
|
555
317
|
z.object({ id: entryId, kind: z.literal("exit"), config: ExitConfigSchema }),
|
|
556
|
-
// The in-sandbox Docker Engine
|
|
557
|
-
//
|
|
558
|
-
// isPrivileged), so a switch there would offer a broken sandbox as a choice. What IS optional lives in
|
|
559
|
-
// DockerConfigSchema. No remove, the engine's state (/var/lib/docker) and whatever runs on it make a
|
|
560
|
-
// silent de-privilege more destructive than useful.
|
|
318
|
+
// The in-sandbox Docker Engine, baked into the image, dormant by default. No remove: de-privileging it silently
|
|
319
|
+
// would be more destructive than useful given what runs on it.
|
|
561
320
|
z.object({ id: entryId, kind: z.literal("docker"), config: DockerConfigSchema }),
|
|
562
321
|
z.object({ id: entryId, kind: z.literal("browser"), config: BrowserConfigSchema }),
|
|
563
|
-
// One email identity
|
|
564
|
-
// (IdentityConfigSchema). Browser entries join it via their `identity` field.
|
|
322
|
+
// One email identity browser accounts are born from; they join it via their own `identity` field.
|
|
565
323
|
z.object({ id: entryId, kind: z.literal("identity"), config: IdentityConfigSchema }),
|
|
566
324
|
z.object({ id: entryId, kind: z.literal("host"), config: HostConfigSchema }),
|
|
567
|
-
// The user's own
|
|
568
|
-
//
|
|
569
|
-
//
|
|
570
|
-
// one is the person's, already signed into everything, and the sandbox only ever borrows it.
|
|
325
|
+
// The user's own browser, through their installed extension; `host`'s sibling, one capability per browser. Distinct
|
|
326
|
+
// from `browser`, the sandbox's own Chromium profile: this one is the person's, already signed into everything,
|
|
327
|
+
// only ever borrowed.
|
|
571
328
|
z.object({ id: entryId, kind: z.literal("webext"), config: WebExtConfigSchema }),
|
|
572
329
|
z.object({ id: entryId, kind: z.literal("agent"), config: AcpAgentConfigSchema }),
|
|
573
|
-
//
|
|
574
|
-
//
|
|
575
|
-
// want opposite ability records (an ACP agent owns its own loop; an endpoint runs the full Claude Code one).
|
|
330
|
+
// The id becomes `endpoint/<id>` in the chat picker, the `agent` kind's precedent, since these two are the only
|
|
331
|
+
// kinds that mint providers.
|
|
576
332
|
z.object({ id: entryId, kind: z.literal("endpoint"), config: EndpointConfigSchema }),
|
|
577
|
-
//
|
|
578
|
-
//
|
|
579
|
-
// happens to operate, so a second provider namespace would be a second code path for the same turns.
|
|
333
|
+
// Deliberately mints the same `endpoint/<id>` ids as `endpoint`: to every consumer this is just an endpoint the
|
|
334
|
+
// daemon happens to operate.
|
|
580
335
|
z.object({ id: entryId, kind: z.literal("localmodel"), config: LocalModelConfigSchema }),
|
|
581
336
|
// The sandbox's USDC wallet (WalletConfigSchema), one per sandbox; the key never enters the container.
|
|
582
337
|
z.object({ id: entryId, kind: z.literal("wallet"), config: WalletConfigSchema }),
|
|
583
338
|
]);
|
|
584
339
|
export type Capability = z.infer<typeof CapabilitySchema>;
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
* it: it sets it in a size you can read across a desk, next to a copy button, and replaces it in place when the
|
|
588
|
-
* provider mints a new one. A sentence with a code buried in it cannot be any of those things. */
|
|
340
|
+
// A credential the owner must type elsewhere (a WhatsApp pairing code); rendered large and copyable, not buried in
|
|
341
|
+
// `detail`'s sentence.
|
|
589
342
|
export const CapabilityStatusSchema = z.object({
|
|
590
343
|
state: CapabilityStateSchema.describe("Whether it is live, still coming up, broken, or switched off."),
|
|
591
344
|
detail: z.string().optional().describe("What is wrong, in words a person can act on."),
|
|
592
345
|
code: z.string().optional().describe("A short marker for that reason, for anything deciding what to do about it."),
|
|
593
346
|
});
|
|
594
347
|
export type CapabilityStatus = z.infer<typeof CapabilityStatusSchema>;
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
* under. It is what makes an edit form possible at all: `config` is everything the browser may see, so a form
|
|
599
|
-
* seeded from it alone cannot tell "this tunnel has a pre-shared key I'm not allowed to show you" from "this
|
|
600
|
-
* tunnel has no pre-shared key", and both render as an empty required box. Saving one then wipes the
|
|
601
|
-
* credential, which is why changing a routed network used to mean re-typing a key.
|
|
602
|
-
*
|
|
603
|
-
* Keys, never values, and never a boolean per known field: the set is derived from what the entry stores, so a
|
|
604
|
-
* field the user left blank is absent and a card that gained a credential since is present. The form reads it as
|
|
605
|
-
* "show dots, and let blank mean keep" (VAULTED, capability-secrets.ts). */
|
|
348
|
+
// The list row: manifest entry plus live status, secrets never returned. `secrets` names which config keys hold a
|
|
349
|
+
// credential without carrying it, since `config` alone can't distinguish a blank field from one already holding a value
|
|
350
|
+
// the browser isn't shown.
|
|
606
351
|
export const CapabilitySummarySchema = z.object({
|
|
607
352
|
id: z.string().describe("The connection's id."),
|
|
608
353
|
kind: CapabilityKindSchema.describe("What sort of thing it is."),
|
|
609
354
|
status: CapabilityStatusSchema.describe("Whether it is working."),
|
|
610
355
|
config: z.record(z.string(), z.union([z.string(), z.number(), z.boolean()])).describe("Its settings, minus anything secret."),
|
|
611
|
-
// Defaulted for the daemon-older-than-browser seam
|
|
612
|
-
//
|
|
356
|
+
// Defaulted for the daemon-older-than-browser seam: a required field would fail the whole list parse on an older
|
|
357
|
+
// sandbox.
|
|
613
358
|
secrets: z
|
|
614
359
|
.array(z.string())
|
|
615
360
|
.default([])
|
|
616
361
|
.describe("Which credentials it holds, by name. The values are on one route only, and it is not this one."),
|
|
617
362
|
});
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
* cannot read one issue until somebody thinks to go looking for the card.
|
|
623
|
-
*
|
|
624
|
-
* KEYED BY CATALOG CARD, NOT BY KIND, because github, gitlab, komodo and every other connector share the single
|
|
625
|
-
* `cli` kind, a kind cannot say which card to open, and matching on one badged all of them at once.
|
|
626
|
-
*
|
|
627
|
-
* WHAT IS STORED IS WHAT WAS SEEN. `evidence` is the artifact itself, a workspace-relative path, a git remote,
|
|
628
|
-
* rendered verbatim so the claim is checkable rather than believed, and `reason` is the same claim in the user's
|
|
629
|
-
* words with the evidence NOT repeated into it. A recommendation is re-derived on every read rather than
|
|
630
|
-
* remembered, so one whose evidence has since moved simply stops being made.
|
|
631
|
-
*
|
|
632
|
-
* `prefill` is the non-secret config the scan could read (a self-hosted instance url, a Komodo core), it fills
|
|
633
|
-
* the card's form so the user supplies only the credential. Secrets are NEVER in here, even when one is sitting
|
|
634
|
-
* in a checked-in file: the flow points at such a file as evidence, it does not absorb what is in it. */
|
|
363
|
+
// A capability the workspace asks for but the manifest doesn't carry, derived from what's checked out under /work, not
|
|
364
|
+
// from configuration; prevents illegible failures like a missing docker socket with no pointer back to the fix. Keyed
|
|
365
|
+
// by catalog card, not kind, since several cards share one kind. Re-derived on every read, so it drops out once its
|
|
366
|
+
// evidence moves; `prefill` is never a secret, even one sitting in a checked-in file.
|
|
635
367
|
export const CapabilityRecommendationSchema = z.object({
|
|
636
368
|
card: z.string().describe("Which connection is being suggested."),
|
|
637
369
|
evidence: z
|
|
@@ -647,9 +379,7 @@ export const CapabilityRecommendationSchema = z.object({
|
|
|
647
379
|
export type CapabilityRecommendation = z.infer<typeof CapabilityRecommendationSchema>;
|
|
648
380
|
export const CapabilitiesListSchema = z.object({
|
|
649
381
|
capabilities: z.array(CapabilitySummarySchema).describe("What this sandbox is connected to."),
|
|
650
|
-
// Defaulted for the daemon-older-than-browser seam
|
|
651
|
-
// version the user has, and a required field here would fail the parse, taking the whole Capabilities page
|
|
652
|
-
// down on every sandbox predating this route, to hide a badge.
|
|
382
|
+
// Defaulted for the daemon-older-than-browser seam, so an older sandbox's parse doesn't fail just to hide a badge.
|
|
653
383
|
recommendations: z
|
|
654
384
|
.array(CapabilityRecommendationSchema)
|
|
655
385
|
.default([])
|
|
@@ -658,11 +388,8 @@ export const CapabilitiesListSchema = z.object({
|
|
|
658
388
|
),
|
|
659
389
|
});
|
|
660
390
|
export const CapabilityIdParamSchema = z.object({ id: z.string().describe("Which connection.") });
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
* never served to a browser: its handler refuses any caller with a member identity, leaving only the daemon's
|
|
664
|
-
* header grants (an extension backend's minted token, which must declare the route in permissions.daemon).
|
|
665
|
-
* The values are the strings the capability stored; the caller knows its own kind's field names. */
|
|
391
|
+
// One capability's config verbatim, secrets included, for capabilities.connection; never served to a browser, since its
|
|
392
|
+
// handler accepts only daemon header grants, not a member identity.
|
|
666
393
|
export const CapabilityConnectionSchema = z.object({
|
|
667
394
|
id: z.string().describe("The connection's id."),
|
|
668
395
|
kind: z.string().describe("What sort of thing it is."),
|
|
@@ -671,23 +398,18 @@ export const CapabilityConnectionSchema = z.object({
|
|
|
671
398
|
.describe("Its settings exactly as stored, credentials included. The field names are its own kind's, which the caller already knows."),
|
|
672
399
|
});
|
|
673
400
|
export type CapabilityConnection = z.infer<typeof CapabilityConnectionSchema>;
|
|
674
|
-
// DELETE /capabilities/recommendations/{card}: the
|
|
675
|
-
//
|
|
676
|
-
// one it was shown, and so the recommendation comes back by itself when the workspace changes under it.
|
|
401
|
+
// DELETE /capabilities/recommendations/{card}: the declined evidence is recorded daemon-side, so the suggestion returns
|
|
402
|
+
// once the workspace changes under it.
|
|
677
403
|
export const CapabilityCardParamSchema = z.object({ card: z.string().describe("Which suggestion to stop making.") });
|
|
678
|
-
// POST /capabilities/{id}/secret
|
|
679
|
-
//
|
|
404
|
+
// POST /capabilities/{id}/secret: replaces just the per-kind secret field and re-runs the capability's idempotent
|
|
405
|
+
// apply.
|
|
680
406
|
export const CapabilitySecretInputSchema = z.object({
|
|
681
407
|
id: z.string().describe("Which connection."),
|
|
682
408
|
value: z.string().min(1).describe("The new credential. Its other settings are left alone."),
|
|
683
409
|
});
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
* `ssh <name>` resolves, so renaming one is a migration and not a label edit. The shape of a name is therefore
|
|
688
|
-
* the same rule the add form enforces, spelled here because the daemon is the gate: letters and digits to start,
|
|
689
|
-
* then hyphens and underscores. Which KINDS may be renamed at all is the handler's own answer (capability.ts
|
|
690
|
-
* `rename`), not something a schema can say. */
|
|
410
|
+
// POST /capabilities/{id}/rename: a capability's id is the agent's handle for it (skill file, tool prefix, env suffix,
|
|
411
|
+
// ssh alias), so renaming is a migration, not a label edit. Which kinds may be renamed is the handler's own answer, not
|
|
412
|
+
// this schema's.
|
|
691
413
|
export const CapabilityRenameSchema = z.object({
|
|
692
414
|
id: z.string(),
|
|
693
415
|
to: z
|
|
@@ -696,29 +418,20 @@ export const CapabilityRenameSchema = z.object({
|
|
|
696
418
|
.max(60)
|
|
697
419
|
.regex(/^[a-zA-Z0-9][a-zA-Z0-9_-]*$/),
|
|
698
420
|
});
|
|
699
|
-
// POST /capabilities/{id}/login
|
|
700
|
-
//
|
|
421
|
+
// POST /capabilities/{id}/login: the tmux session running `loginCommand`, surfaced in the terminal panel to complete
|
|
422
|
+
// sign-in.
|
|
701
423
|
export const CapabilityLoginSchema = z.object({ session: z.string().describe("The terminal the sign-in is happening in. Attach to it to type.") });
|
|
702
|
-
// GET /capabilities/{id}/otp
|
|
703
|
-
//
|
|
704
|
-
// re-mint rather than submit a code about to die.
|
|
424
|
+
// GET /capabilities/{id}/otp: a freshly minted TOTP code; the seed never crosses, `secondsRemaining` cues a re-mint
|
|
425
|
+
// rather than a stale submit.
|
|
705
426
|
export const CapabilityOtpSchema = z.object({
|
|
706
427
|
code: z.string().describe("The code."),
|
|
707
428
|
secondsRemaining: z
|
|
708
429
|
.number()
|
|
709
430
|
.describe("How long it lasts. Its expiring is what makes handing one to an agent safe, since the seed behind it is never revealed."),
|
|
710
431
|
});
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
* they need is either the service's own confirmation ("Reached GitHub, authenticated as ada") or the exact
|
|
715
|
-
* refusal ("GitHub answered 401: the token is not valid"), in the place where the box they would fix still is.
|
|
716
|
-
* That is also the whole point of doing it here: every one of these failures is otherwise discovered after the
|
|
717
|
-
* add, on a card that says "not connected" with nothing about which of six answers was wrong.
|
|
718
|
-
*
|
|
719
|
-
* `ok: false` is a REPORTED failure, not a transport error: the probe ran and the service said no. A card whose
|
|
720
|
-
* settings cannot be checked from here at all answers `checked: false`, which is a different thing from a
|
|
721
|
-
* failure and must never be drawn as one. */
|
|
432
|
+
// POST /capabilities/probe: did these settings actually reach the thing, asked before saving, so a form's reader gets
|
|
433
|
+
// the service's own confirmation or refusal in place, not a later "not connected" card. `ok: false` is a reported
|
|
434
|
+
// failure; `checked: false` means no test exists at all, a different thing that must never render as one.
|
|
722
435
|
export const CapabilityProbeSchema = z.object({
|
|
723
436
|
checked: z.boolean().describe("Whether this connection can be tested from here at all. False is not a failure: it is 'no test exists'."),
|
|
724
437
|
ok: z.boolean().describe("Whether the service answered as itself."),
|