@qodeca/xezar 0.10.1
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/LICENSE +21 -0
- package/README.md +810 -0
- package/dist/agent-config/account-identity.d.ts +44 -0
- package/dist/agent-config/account-identity.js +128 -0
- package/dist/agent-config/account-identity.js.map +1 -0
- package/dist/agent-config/catalog.d.ts +71 -0
- package/dist/agent-config/catalog.js +223 -0
- package/dist/agent-config/catalog.js.map +1 -0
- package/dist/agent-config/files.d.ts +46 -0
- package/dist/agent-config/files.js +119 -0
- package/dist/agent-config/files.js.map +1 -0
- package/dist/agent-config/model-settings/claude.d.ts +2 -0
- package/dist/agent-config/model-settings/claude.js +11 -0
- package/dist/agent-config/model-settings/claude.js.map +1 -0
- package/dist/agent-config/model-settings/codex.d.ts +2 -0
- package/dist/agent-config/model-settings/codex.js +16 -0
- package/dist/agent-config/model-settings/codex.js.map +1 -0
- package/dist/agent-config/model-settings/opencode.d.ts +2 -0
- package/dist/agent-config/model-settings/opencode.js +8 -0
- package/dist/agent-config/model-settings/opencode.js.map +1 -0
- package/dist/agent-config/model-settings/pi.d.ts +12 -0
- package/dist/agent-config/model-settings/pi.js +18 -0
- package/dist/agent-config/model-settings/pi.js.map +1 -0
- package/dist/agent-config/model-settings/shared.d.ts +9 -0
- package/dist/agent-config/model-settings/shared.js +93 -0
- package/dist/agent-config/model-settings/shared.js.map +1 -0
- package/dist/agent-config/model-settings/types.d.ts +9 -0
- package/dist/agent-config/model-settings/types.js +2 -0
- package/dist/agent-config/model-settings/types.js.map +1 -0
- package/dist/agent-config/models.d.ts +9 -0
- package/dist/agent-config/models.js +32 -0
- package/dist/agent-config/models.js.map +1 -0
- package/dist/agent-config/seed.d.ts +7 -0
- package/dist/agent-config/seed.js +90 -0
- package/dist/agent-config/seed.js.map +1 -0
- package/dist/agent-config/service.d.ts +44 -0
- package/dist/agent-config/service.js +71 -0
- package/dist/agent-config/service.js.map +1 -0
- package/dist/agent-config/validate.d.ts +21 -0
- package/dist/agent-config/validate.js +76 -0
- package/dist/agent-config/validate.js.map +1 -0
- package/dist/automations/coordinator.d.ts +26 -0
- package/dist/automations/coordinator.js +66 -0
- package/dist/automations/coordinator.js.map +1 -0
- package/dist/automations/github-poller.d.ts +74 -0
- package/dist/automations/github-poller.js +234 -0
- package/dist/automations/github-poller.js.map +1 -0
- package/dist/automations/scheduler.d.ts +42 -0
- package/dist/automations/scheduler.js +192 -0
- package/dist/automations/scheduler.js.map +1 -0
- package/dist/automations/store.d.ts +65 -0
- package/dist/automations/store.js +298 -0
- package/dist/automations/store.js.map +1 -0
- package/dist/automations/task-template.d.ts +18 -0
- package/dist/automations/task-template.js +95 -0
- package/dist/automations/task-template.js.map +1 -0
- package/dist/automations/types.d.ts +255 -0
- package/dist/automations/types.js +159 -0
- package/dist/automations/types.js.map +1 -0
- package/dist/config.d.ts +77 -0
- package/dist/config.js +242 -0
- package/dist/config.js.map +1 -0
- package/dist/contract/agent-config.d.ts +153 -0
- package/dist/contract/agent-profiles.d.ts +347 -0
- package/dist/contract/automations.d.ts +935 -0
- package/dist/contract/events.d.ts +104 -0
- package/dist/contract/github.d.ts +597 -0
- package/dist/contract/health.d.ts +102 -0
- package/dist/contract/index.d.ts +16 -0
- package/dist/contract/index.js +1953 -0
- package/dist/contract/projects.d.ts +210 -0
- package/dist/contract/repo.d.ts +234 -0
- package/dist/contract/runs.d.ts +1527 -0
- package/dist/contract/skills.d.ts +234 -0
- package/dist/contract/workflows.d.ts +218 -0
- package/dist/contract/workspace.d.ts +579 -0
- package/dist/core/agent-env.d.ts +31 -0
- package/dist/core/agent-env.js +371 -0
- package/dist/core/agent-env.js.map +1 -0
- package/dist/core/agent-model-policy.d.ts +10 -0
- package/dist/core/agent-model-policy.js +36 -0
- package/dist/core/agent-model-policy.js.map +1 -0
- package/dist/core/agent-profiles.d.ts +62 -0
- package/dist/core/agent-profiles.js +90 -0
- package/dist/core/agent-profiles.js.map +1 -0
- package/dist/core/agent-runner.d.ts +211 -0
- package/dist/core/agent-runner.js +68 -0
- package/dist/core/agent-runner.js.map +1 -0
- package/dist/core/ask.d.ts +115 -0
- package/dist/core/ask.js +256 -0
- package/dist/core/ask.js.map +1 -0
- package/dist/core/backend-detect.d.ts +16 -0
- package/dist/core/backend-detect.js +155 -0
- package/dist/core/backend-detect.js.map +1 -0
- package/dist/core/claude-cli-runner.d.ts +65 -0
- package/dist/core/claude-cli-runner.js +479 -0
- package/dist/core/claude-cli-runner.js.map +1 -0
- package/dist/core/claude-model-catalog.d.ts +24 -0
- package/dist/core/claude-model-catalog.js +208 -0
- package/dist/core/claude-model-catalog.js.map +1 -0
- package/dist/core/claude-ui-mapper.d.ts +79 -0
- package/dist/core/claude-ui-mapper.js +597 -0
- package/dist/core/claude-ui-mapper.js.map +1 -0
- package/dist/core/codex-app-server-runner.d.ts +41 -0
- package/dist/core/codex-app-server-runner.js +584 -0
- package/dist/core/codex-app-server-runner.js.map +1 -0
- package/dist/core/codex-app-server-transport.d.ts +35 -0
- package/dist/core/codex-app-server-transport.js +150 -0
- package/dist/core/codex-app-server-transport.js.map +1 -0
- package/dist/core/codex-model-catalog.d.ts +10 -0
- package/dist/core/codex-model-catalog.js +110 -0
- package/dist/core/codex-model-catalog.js.map +1 -0
- package/dist/core/codex-ui-mapper.d.ts +109 -0
- package/dist/core/codex-ui-mapper.js +764 -0
- package/dist/core/codex-ui-mapper.js.map +1 -0
- package/dist/core/model-identity.d.ts +125 -0
- package/dist/core/model-identity.js +132 -0
- package/dist/core/model-identity.js.map +1 -0
- package/dist/core/model-presets.d.ts +21 -0
- package/dist/core/model-presets.js +91 -0
- package/dist/core/model-presets.js.map +1 -0
- package/dist/core/ndjson.d.ts +6 -0
- package/dist/core/ndjson.js +23 -0
- package/dist/core/ndjson.js.map +1 -0
- package/dist/core/opencode-model-catalog.d.ts +32 -0
- package/dist/core/opencode-model-catalog.js +153 -0
- package/dist/core/opencode-model-catalog.js.map +1 -0
- package/dist/core/opencode-server-runner.d.ts +32 -0
- package/dist/core/opencode-server-runner.js +535 -0
- package/dist/core/opencode-server-runner.js.map +1 -0
- package/dist/core/opencode-ui-mapper.d.ts +111 -0
- package/dist/core/opencode-ui-mapper.js +668 -0
- package/dist/core/opencode-ui-mapper.js.map +1 -0
- package/dist/core/pi-runner.d.ts +24 -0
- package/dist/core/pi-runner.js +349 -0
- package/dist/core/pi-runner.js.map +1 -0
- package/dist/core/pi-ui-mapper.d.ts +34 -0
- package/dist/core/pi-ui-mapper.js +270 -0
- package/dist/core/pi-ui-mapper.js.map +1 -0
- package/dist/core/process-usage.d.ts +66 -0
- package/dist/core/process-usage.js +193 -0
- package/dist/core/process-usage.js.map +1 -0
- package/dist/core/provider-auth.d.ts +154 -0
- package/dist/core/provider-auth.js +509 -0
- package/dist/core/provider-auth.js.map +1 -0
- package/dist/core/provider-availability.d.ts +3 -0
- package/dist/core/provider-availability.js +14 -0
- package/dist/core/provider-availability.js.map +1 -0
- package/dist/core/runner-factory.d.ts +8 -0
- package/dist/core/runner-factory.js +25 -0
- package/dist/core/runner-factory.js.map +1 -0
- package/dist/core/runner-model-catalog.d.ts +28 -0
- package/dist/core/runner-model-catalog.js +62 -0
- package/dist/core/runner-model-catalog.js.map +1 -0
- package/dist/core/secret-redaction.d.ts +37 -0
- package/dist/core/secret-redaction.js +115 -0
- package/dist/core/secret-redaction.js.map +1 -0
- package/dist/core/shell-env.d.ts +28 -0
- package/dist/core/shell-env.js +56 -0
- package/dist/core/shell-env.js.map +1 -0
- package/dist/core/tool-display.d.ts +31 -0
- package/dist/core/tool-display.js +179 -0
- package/dist/core/tool-display.js.map +1 -0
- package/dist/core/ui-events.d.ts +332 -0
- package/dist/core/ui-events.js +22 -0
- package/dist/core/ui-events.js.map +1 -0
- package/dist/core/usage-limit.d.ts +42 -0
- package/dist/core/usage-limit.js +209 -0
- package/dist/core/usage-limit.js.map +1 -0
- package/dist/core/usage.d.ts +11 -0
- package/dist/core/usage.js +15 -0
- package/dist/core/usage.js.map +1 -0
- package/dist/core/v1-text-coalescer.d.ts +36 -0
- package/dist/core/v1-text-coalescer.js +72 -0
- package/dist/core/v1-text-coalescer.js.map +1 -0
- package/dist/git-diff-base.d.ts +85 -0
- package/dist/git-diff-base.js +180 -0
- package/dist/git-diff-base.js.map +1 -0
- package/dist/git-refs.d.ts +11 -0
- package/dist/git-refs.js +14 -0
- package/dist/git-refs.js.map +1 -0
- package/dist/git-worktree.d.ts +161 -0
- package/dist/git-worktree.js +508 -0
- package/dist/git-worktree.js.map +1 -0
- package/dist/handoff.d.ts +62 -0
- package/dist/handoff.js +154 -0
- package/dist/handoff.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +684 -0
- package/dist/index.js.map +1 -0
- package/dist/install-as-command.d.ts +40 -0
- package/dist/install-as-command.js +52 -0
- package/dist/install-as-command.js.map +1 -0
- package/dist/pack-check.d.ts +17 -0
- package/dist/pack-check.js +27 -0
- package/dist/pack-check.js.map +1 -0
- package/dist/paths.d.ts +140 -0
- package/dist/paths.js +192 -0
- package/dist/paths.js.map +1 -0
- package/dist/planner.d.ts +27 -0
- package/dist/planner.js +268 -0
- package/dist/planner.js.map +1 -0
- package/dist/release/manifests.d.ts +78 -0
- package/dist/release/manifests.js +57 -0
- package/dist/release/manifests.js.map +1 -0
- package/dist/release/snapshot.d.ts +67 -0
- package/dist/release/snapshot.js +97 -0
- package/dist/release/snapshot.js.map +1 -0
- package/dist/release/stable.d.ts +33 -0
- package/dist/release/stable.js +50 -0
- package/dist/release/stable.js.map +1 -0
- package/dist/runs/agent-tmpdir.d.ts +41 -0
- package/dist/runs/agent-tmpdir.js +183 -0
- package/dist/runs/agent-tmpdir.js.map +1 -0
- package/dist/runs/arm-repo-handle.d.ts +17 -0
- package/dist/runs/arm-repo-handle.js +24 -0
- package/dist/runs/arm-repo-handle.js.map +1 -0
- package/dist/runs/auto-name.d.ts +75 -0
- package/dist/runs/auto-name.js +179 -0
- package/dist/runs/auto-name.js.map +1 -0
- package/dist/runs/event-history.d.ts +50 -0
- package/dist/runs/event-history.js +613 -0
- package/dist/runs/event-history.js.map +1 -0
- package/dist/runs/retention.d.ts +60 -0
- package/dist/runs/retention.js +86 -0
- package/dist/runs/retention.js.map +1 -0
- package/dist/runs/review-gate.d.ts +18 -0
- package/dist/runs/review-gate.js +21 -0
- package/dist/runs/review-gate.js.map +1 -0
- package/dist/runs/run-index.d.ts +19 -0
- package/dist/runs/run-index.js +43 -0
- package/dist/runs/run-index.js.map +1 -0
- package/dist/runs/store.d.ts +490 -0
- package/dist/runs/store.js +1283 -0
- package/dist/runs/store.js.map +1 -0
- package/dist/runs/task-markers.d.ts +28 -0
- package/dist/runs/task-markers.js +74 -0
- package/dist/runs/task-markers.js.map +1 -0
- package/dist/runs/task-refs.d.ts +25 -0
- package/dist/runs/task-refs.js +74 -0
- package/dist/runs/task-refs.js.map +1 -0
- package/dist/runs/ui-event-sink.d.ts +80 -0
- package/dist/runs/ui-event-sink.js +209 -0
- package/dist/runs/ui-event-sink.js.map +1 -0
- package/dist/server/app-type.d.ts +21 -0
- package/dist/server/app-type.js +2 -0
- package/dist/server/app-type.js.map +1 -0
- package/dist/server/capabilities.d.ts +70 -0
- package/dist/server/capabilities.js +152 -0
- package/dist/server/capabilities.js.map +1 -0
- package/dist/server/checkout.d.ts +128 -0
- package/dist/server/checkout.js +296 -0
- package/dist/server/checkout.js.map +1 -0
- package/dist/server/forge/github.d.ts +535 -0
- package/dist/server/forge/github.js +2544 -0
- package/dist/server/forge/github.js.map +1 -0
- package/dist/server/forge/index.d.ts +40 -0
- package/dist/server/forge/index.js +72 -0
- package/dist/server/forge/index.js.map +1 -0
- package/dist/server/forge/types.d.ts +267 -0
- package/dist/server/forge/types.js +2 -0
- package/dist/server/forge/types.js.map +1 -0
- package/dist/server/fs-browse.d.ts +105 -0
- package/dist/server/fs-browse.js +182 -0
- package/dist/server/fs-browse.js.map +1 -0
- package/dist/server/git-changes.d.ts +213 -0
- package/dist/server/git-changes.js +555 -0
- package/dist/server/git-changes.js.map +1 -0
- package/dist/server/git.d.ts +28 -0
- package/dist/server/git.js +112 -0
- package/dist/server/git.js.map +1 -0
- package/dist/server/github.d.ts +9 -0
- package/dist/server/github.js +8 -0
- package/dist/server/github.js.map +1 -0
- package/dist/server/launch-key.d.ts +7 -0
- package/dist/server/launch-key.js +33 -0
- package/dist/server/launch-key.js.map +1 -0
- package/dist/server/open-in-app.d.ts +66 -0
- package/dist/server/open-in-app.js +211 -0
- package/dist/server/open-in-app.js.map +1 -0
- package/dist/server/open-in-terminal.d.ts +70 -0
- package/dist/server/open-in-terminal.js +179 -0
- package/dist/server/open-in-terminal.js.map +1 -0
- package/dist/server/pr.d.ts +7 -0
- package/dist/server/pr.js +7 -0
- package/dist/server/pr.js.map +1 -0
- package/dist/server/project-context.d.ts +120 -0
- package/dist/server/project-context.js +192 -0
- package/dist/server/project-context.js.map +1 -0
- package/dist/server/provider-action-gate.d.ts +8 -0
- package/dist/server/provider-action-gate.js +56 -0
- package/dist/server/provider-action-gate.js.map +1 -0
- package/dist/server/provider-auth-runtime.d.ts +21 -0
- package/dist/server/provider-auth-runtime.js +66 -0
- package/dist/server/provider-auth-runtime.js.map +1 -0
- package/dist/server/server.d.ts +13578 -0
- package/dist/server/server.js +5284 -0
- package/dist/server/server.js.map +1 -0
- package/dist/server/static-ui.d.ts +49 -0
- package/dist/server/static-ui.js +92 -0
- package/dist/server/static-ui.js.map +1 -0
- package/dist/server/validators.d.ts +97 -0
- package/dist/server/validators.js +86 -0
- package/dist/server/validators.js.map +1 -0
- package/dist/server/ws.d.ts +83 -0
- package/dist/server/ws.js +216 -0
- package/dist/server/ws.js.map +1 -0
- package/dist/server/wsl.d.ts +25 -0
- package/dist/server/wsl.js +92 -0
- package/dist/server/wsl.js.map +1 -0
- package/dist/server-install/engine.d.ts +50 -0
- package/dist/server-install/engine.js +324 -0
- package/dist/server-install/engine.js.map +1 -0
- package/dist/server-install/platforms/macosx-ngrok.d.ts +6 -0
- package/dist/server-install/platforms/macosx-ngrok.js +348 -0
- package/dist/server-install/platforms/macosx-ngrok.js.map +1 -0
- package/dist/server-install/platforms/ubuntu-vps.d.ts +63 -0
- package/dist/server-install/platforms/ubuntu-vps.js +997 -0
- package/dist/server-install/platforms/ubuntu-vps.js.map +1 -0
- package/dist/server-install/state.d.ts +52 -0
- package/dist/server-install/state.js +182 -0
- package/dist/server-install/state.js.map +1 -0
- package/dist/server-install/steps.d.ts +109 -0
- package/dist/server-install/steps.js +334 -0
- package/dist/server-install/steps.js.map +1 -0
- package/dist/server-install/strategies.d.ts +4 -0
- package/dist/server-install/strategies.js +20 -0
- package/dist/server-install/strategies.js.map +1 -0
- package/dist/server-install/types.d.ts +287 -0
- package/dist/server-install/types.js +121 -0
- package/dist/server-install/types.js.map +1 -0
- package/dist/server-install/ui.d.ts +42 -0
- package/dist/server-install/ui.js +130 -0
- package/dist/server-install/ui.js.map +1 -0
- package/dist/skills-banner.d.ts +22 -0
- package/dist/skills-banner.js +41 -0
- package/dist/skills-banner.js.map +1 -0
- package/dist/skills-remote.d.ts +84 -0
- package/dist/skills-remote.js +468 -0
- package/dist/skills-remote.js.map +1 -0
- package/dist/skills-update.d.ts +88 -0
- package/dist/skills-update.js +392 -0
- package/dist/skills-update.js.map +1 -0
- package/dist/skills.d.ts +82 -0
- package/dist/skills.js +251 -0
- package/dist/skills.js.map +1 -0
- package/dist/todos.d.ts +48 -0
- package/dist/todos.js +201 -0
- package/dist/todos.js.map +1 -0
- package/dist/ui-state.d.ts +26 -0
- package/dist/ui-state.js +38 -0
- package/dist/ui-state.js.map +1 -0
- package/dist/update-check.d.ts +12 -0
- package/dist/update-check.js +41 -0
- package/dist/update-check.js.map +1 -0
- package/dist/workflows/load.d.ts +15 -0
- package/dist/workflows/load.js +56 -0
- package/dist/workflows/load.js.map +1 -0
- package/dist/workflows/run.d.ts +803 -0
- package/dist/workflows/run.js +3483 -0
- package/dist/workflows/run.js.map +1 -0
- package/dist/workflows/types.d.ts +145 -0
- package/dist/workflows/types.js +194 -0
- package/dist/workflows/types.js.map +1 -0
- package/dist/workspace/agent-accounts.d.ts +153 -0
- package/dist/workspace/agent-accounts.js +304 -0
- package/dist/workspace/agent-accounts.js.map +1 -0
- package/dist/workspace/agent-profiles.d.ts +78 -0
- package/dist/workspace/agent-profiles.js +115 -0
- package/dist/workspace/agent-profiles.js.map +1 -0
- package/dist/workspace/config.d.ts +169 -0
- package/dist/workspace/config.js +379 -0
- package/dist/workspace/config.js.map +1 -0
- package/dist/workspace/migrations.d.ts +45 -0
- package/dist/workspace/migrations.js +147 -0
- package/dist/workspace/migrations.js.map +1 -0
- package/dist/workspace/projects-cli.d.ts +25 -0
- package/dist/workspace/projects-cli.js +172 -0
- package/dist/workspace/projects-cli.js.map +1 -0
- package/dist/workspace/projects.d.ts +109 -0
- package/dist/workspace/projects.js +250 -0
- package/dist/workspace/projects.js.map +1 -0
- package/dist/workspace/semaphore.d.ts +179 -0
- package/dist/workspace/semaphore.js +195 -0
- package/dist/workspace/semaphore.js.map +1 -0
- package/dist/workspace/ui-state.d.ts +34 -0
- package/dist/workspace/ui-state.js +53 -0
- package/dist/workspace/ui-state.js.map +1 -0
- package/package.json +85 -0
- package/scripts/check-pack.mjs +46 -0
- package/scripts/inline-contract.mjs +112 -0
- package/scripts/install-as-command.mjs +120 -0
- package/scripts/mock-claude.mjs +524 -0
- package/scripts/mock-pi-rpc.mjs +83 -0
- package/scripts/sync-readme.mjs +20 -0
- package/scripts/test-process-usage.mjs +47 -0
- package/web/dist/assets/alert-dialog-CGskMvgc.js +1 -0
- package/web/dist/assets/arrow-down-G8adPhbu.js +1 -0
- package/web/dist/assets/arrow-left-BJsIW6A0.js +1 -0
- package/web/dist/assets/bundle-mjs-BT31bpU6.js +1 -0
- package/web/dist/assets/centered-state-B_V_Ai2h.js +43 -0
- package/web/dist/assets/chevron-right-CFzn-von.js +1 -0
- package/web/dist/assets/chunk-BO2N2NFS-DE6qKn3r.js +131 -0
- package/web/dist/assets/collapsible-B_8uYwHb.js +1 -0
- package/web/dist/assets/commit-list-C4Dv6vUL.js +1 -0
- package/web/dist/assets/compare-variants-SR2zZfZq.js +1 -0
- package/web/dist/assets/core-BCsw8oQw.js +12 -0
- package/web/dist/assets/css-BsVw1vtW.js +1 -0
- package/web/dist/assets/diff-CbozNUJq.js +3 -0
- package/web/dist/assets/diff-stat-btAmKFJr.js +1 -0
- package/web/dist/assets/diff-view-BpFTcG3R.js +6 -0
- package/web/dist/assets/diff-woXpYk--.js +1 -0
- package/web/dist/assets/dropdown-menu-Z80KMInL.js +1 -0
- package/web/dist/assets/editable-title-wS5NWwob.js +1 -0
- package/web/dist/assets/ellipsis-vertical-Bmi2u2TG.js +1 -0
- package/web/dist/assets/engine-javascript-FQvzRocB.js +141 -0
- package/web/dist/assets/file-DKoYWRsv.js +1 -0
- package/web/dist/assets/folder-u01HScRT.js +1 -0
- package/web/dist/assets/git-toolbar-DZlZjTGz.js +1 -0
- package/web/dist/assets/github-CFURo9kf.js +1 -0
- package/web/dist/assets/go-rLFTqkRN.js +1 -0
- package/web/dist/assets/highlighted-body-OFNGDK62-BL-MfFgl.js +1 -0
- package/web/dist/assets/highlighter-C8DK1_sG.js +3 -0
- package/web/dist/assets/html-BY76lXLH.js +1 -0
- package/web/dist/assets/image-preview-BR3iIIhf.js +1 -0
- package/web/dist/assets/index-BcI5hug3.css +2 -0
- package/web/dist/assets/index-DlC81_GI.js +7 -0
- package/web/dist/assets/inter-latin-ext-wght-normal-DO1Apj_S.woff2 +0 -0
- package/web/dist/assets/inter-latin-wght-normal-Dx4kXJAl.woff2 +0 -0
- package/web/dist/assets/javascript-BgS3c2Ky.js +1 -0
- package/web/dist/assets/jetbrains-mono-latin-ext-wght-normal-DBQx-q_a.woff2 +0 -0
- package/web/dist/assets/jetbrains-mono-latin-wght-normal-B9CIFXIH.woff2 +0 -0
- package/web/dist/assets/json-qhed-kSA.js +1 -0
- package/web/dist/assets/jsonc-CYpm1nAK.js +1 -0
- package/web/dist/assets/jsx-Bz0zcwM4.js +1 -0
- package/web/dist/assets/lib-BQXq3kEf.js +1 -0
- package/web/dist/assets/lib-BxQXEXDF.js +1 -0
- package/web/dist/assets/markdown-5FuCZDA4.js +2 -0
- package/web/dist/assets/markdown-BYOwaDjH.js +1 -0
- package/web/dist/assets/mermaid-GHXKKRXX-C4jxqUUb.js +1 -0
- package/web/dist/assets/new-task-form-BydHBbef.js +1 -0
- package/web/dist/assets/pill-vNzaaYxj.js +1 -0
- package/web/dist/assets/project-router-BbCzrHKs.js +1 -0
- package/web/dist/assets/prompt-templates-B7Fs2b1S.js +15 -0
- package/web/dist/assets/python-gzcpVVnB.js +1 -0
- package/web/dist/assets/react-runtime-CCIEwYL0.js +9 -0
- package/web/dist/assets/refresh-cw-DGliez3E.js +1 -0
- package/web/dist/assets/repo-git-CJFDMauC.js +1 -0
- package/web/dist/assets/rolldown-runtime-QTnfLwEv.js +1 -0
- package/web/dist/assets/run-diff-Bq9vkSNK.js +3 -0
- package/web/dist/assets/run-header-Cd8mSKBG.js +1 -0
- package/web/dist/assets/rust-Cfkwpbl8.js +1 -0
- package/web/dist/assets/search-x-69n_672Y.js +1 -0
- package/web/dist/assets/shellscript-CLZ0U2zV.js +1 -0
- package/web/dist/assets/skill-empty-hint-DTu0LzaJ.js +1 -0
- package/web/dist/assets/skills-Cs-auniL.js +1 -0
- package/web/dist/assets/skills-D4P-Hgey.js +1 -0
- package/web/dist/assets/sparkles-B8agSxBZ.js +1 -0
- package/web/dist/assets/sql-BsFa4tDR.js +1 -0
- package/web/dist/assets/square-terminal-Cf4Og6ct.js +1 -0
- package/web/dist/assets/tab-link-Cp2-CJS8.js +1 -0
- package/web/dist/assets/task-changes-DYgNXOyY.js +1 -0
- package/web/dist/assets/task-commits-BRpZSz1G.js +1 -0
- package/web/dist/assets/task-files-pKOwSyLh.js +2 -0
- package/web/dist/assets/task-thread-Bfyqqy-t.js +9 -0
- package/web/dist/assets/textarea--cpYshee.js +1 -0
- package/web/dist/assets/thread-loading-GyH2Atwo.js +1 -0
- package/web/dist/assets/toml-CcmNWLt0.js +1 -0
- package/web/dist/assets/trash-2--ZtrzUx3.js +1 -0
- package/web/dist/assets/triangle-alert-D5tJwRD2.js +1 -0
- package/web/dist/assets/tsx-udAQXfEw.js +1 -0
- package/web/dist/assets/typescript-bsJCZSQ-.js +1 -0
- package/web/dist/assets/upload-SnwVxKOA.js +1 -0
- package/web/dist/assets/use-desktop-C31lOFUD.js +1 -0
- package/web/dist/assets/use-submit-shortcut-JY8M_MPL.js +1 -0
- package/web/dist/assets/utils-Bb8ohcr3.js +64 -0
- package/web/dist/assets/workflows-BmOehP-A.js +11 -0
- package/web/dist/assets/yaml-rwi0_p6S.js +1 -0
- package/web/dist/assets/zoomable-image-0G3IBXWC.js +1 -0
- package/web/dist/index.html +80 -0
- package/web/dist/xezar.svg +14 -0
|
@@ -0,0 +1,1527 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
/**
|
|
3
|
+
* The RUNS family of `/api/v1` — a task's record, its lifecycle mutations, and the artifacts
|
|
4
|
+
* (queued prompt stack, commits, git actions) that hang off one run.
|
|
5
|
+
*
|
|
6
|
+
* The record itself is persisted by `src/runs/store.ts`, so these schemas describe a shape that
|
|
7
|
+
* already has a zod definition server-side; they are the WIRE half of it, and the parity guard in
|
|
8
|
+
* `src/server/contract-parity.runs.test.ts` is what keeps the two from drifting.
|
|
9
|
+
*
|
|
10
|
+
* Two things about the mutation responses are deliberate and were measured, not assumed:
|
|
11
|
+
*
|
|
12
|
+
* - every "did it work" flag is a `z.literal(true)`, not a boolean. Each of those routes answers
|
|
13
|
+
* 409 (or 404) on refusal, so `false` is not a value the 200 branch can carry — the
|
|
14
|
+
* hand-written DTO's `boolean` invited a re-check the server never needs. `cancelled` is the
|
|
15
|
+
* one real boolean: `POST /runs/:id/cancel` answers 200 either way.
|
|
16
|
+
* - `POST /runs/:id/messages` answers a three-way UNION, not one object with three optional
|
|
17
|
+
* keys. The client narrows on which key is present, and the DTO's flattened shape allowed
|
|
18
|
+
* `{}` — a payload the route cannot produce.
|
|
19
|
+
*/
|
|
20
|
+
export declare const runStatusSchema: z.ZodEnum<{
|
|
21
|
+
cancelled: "cancelled";
|
|
22
|
+
done: "done";
|
|
23
|
+
failed: "failed";
|
|
24
|
+
queued: "queued";
|
|
25
|
+
review: "review";
|
|
26
|
+
running: "running";
|
|
27
|
+
waiting: "waiting";
|
|
28
|
+
}>;
|
|
29
|
+
export type RunStatus = z.infer<typeof runStatusSchema>;
|
|
30
|
+
/**
|
|
31
|
+
* Sub-state of `running` (spec 2026-07-18-subagent-monitoring-status, #490): the agent ended its
|
|
32
|
+
* turn still working on its own downstream work (a sub-agent, a monitored command) and said so
|
|
33
|
+
* with the `XEZ:MONITORING` marker — a non-attention state, not "needs you".
|
|
34
|
+
*/
|
|
35
|
+
export declare const runActivitySchema: z.ZodEnum<{
|
|
36
|
+
monitoring: "monitoring";
|
|
37
|
+
}>;
|
|
38
|
+
export type RunActivity = z.infer<typeof runActivitySchema>;
|
|
39
|
+
export declare const stepStatusSchema: z.ZodEnum<{
|
|
40
|
+
cancelled: "cancelled";
|
|
41
|
+
done: "done";
|
|
42
|
+
failed: "failed";
|
|
43
|
+
pending: "pending";
|
|
44
|
+
review: "review";
|
|
45
|
+
running: "running";
|
|
46
|
+
skipped: "skipped";
|
|
47
|
+
waiting: "waiting";
|
|
48
|
+
}>;
|
|
49
|
+
export type StepStatus = z.infer<typeof stepStatusSchema>;
|
|
50
|
+
/** One step of a run's chain. */
|
|
51
|
+
export declare const stepStateSchema: z.ZodObject<{
|
|
52
|
+
id: z.ZodString;
|
|
53
|
+
name: z.ZodString;
|
|
54
|
+
kind: z.ZodEnum<{
|
|
55
|
+
agent: "agent";
|
|
56
|
+
check: "check";
|
|
57
|
+
}>;
|
|
58
|
+
status: z.ZodEnum<{
|
|
59
|
+
cancelled: "cancelled";
|
|
60
|
+
done: "done";
|
|
61
|
+
failed: "failed";
|
|
62
|
+
pending: "pending";
|
|
63
|
+
review: "review";
|
|
64
|
+
running: "running";
|
|
65
|
+
skipped: "skipped";
|
|
66
|
+
waiting: "waiting";
|
|
67
|
+
}>;
|
|
68
|
+
iterations: z.ZodNumber;
|
|
69
|
+
tokensUsed: z.ZodNumber;
|
|
70
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
71
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
72
|
+
usageInvocationsStarted: z.ZodOptional<z.ZodNumber>;
|
|
73
|
+
usageInvocationsObserved: z.ZodOptional<z.ZodNumber>;
|
|
74
|
+
usageTurnsStarted: z.ZodOptional<z.ZodNumber>;
|
|
75
|
+
usageTurnsRecorded: z.ZodOptional<z.ZodNumber>;
|
|
76
|
+
usageInvocationEpoch: z.ZodOptional<z.ZodNumber>;
|
|
77
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
78
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
79
|
+
error: z.ZodOptional<z.ZodString>;
|
|
80
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
81
|
+
backend: z.ZodOptional<z.ZodEnum<{
|
|
82
|
+
claude: "claude";
|
|
83
|
+
codex: "codex";
|
|
84
|
+
opencode: "opencode";
|
|
85
|
+
pi: "pi";
|
|
86
|
+
}>>;
|
|
87
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
88
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
89
|
+
}, z.core.$strip>;
|
|
90
|
+
export type StepState = z.infer<typeof stepStateSchema>;
|
|
91
|
+
/** Aggregate diff numbers of a run's worktree vs its base (#389). */
|
|
92
|
+
export declare const diffStatSchema: z.ZodObject<{
|
|
93
|
+
adds: z.ZodNumber;
|
|
94
|
+
dels: z.ZodNumber;
|
|
95
|
+
files: z.ZodNumber;
|
|
96
|
+
repointed: z.ZodOptional<z.ZodBoolean>;
|
|
97
|
+
}, z.core.$strip>;
|
|
98
|
+
export type DiffStat = z.infer<typeof diffStatSchema>;
|
|
99
|
+
/** One prompt message stacked onto a run while it waits for a free agent slot (#472). */
|
|
100
|
+
export declare const queuedMessageSchema: z.ZodObject<{
|
|
101
|
+
id: z.ZodString;
|
|
102
|
+
text: z.ZodString;
|
|
103
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
104
|
+
createdAt: z.ZodString;
|
|
105
|
+
}, z.core.$strip>;
|
|
106
|
+
export type QueuedMessage = z.infer<typeof queuedMessageSchema>;
|
|
107
|
+
/** One aggregated sample of a run's live process tree (`src/core/process-usage.ts`). */
|
|
108
|
+
export declare const processUsageSchema: z.ZodObject<{
|
|
109
|
+
cpuPct: z.ZodNumber;
|
|
110
|
+
rssBytes: z.ZodNumber;
|
|
111
|
+
procCount: z.ZodNumber;
|
|
112
|
+
}, z.core.$strip>;
|
|
113
|
+
export type ProcessUsage = z.infer<typeof processUsageSchema>;
|
|
114
|
+
/**
|
|
115
|
+
* The stored run record, as `runs.json` holds it (`src/runs/store.ts`).
|
|
116
|
+
*
|
|
117
|
+
* `archived` is required although the store schema defaults it: a default fills on PARSE, so the
|
|
118
|
+
* key is always present in what the server hands out. Everything else optional here is optional
|
|
119
|
+
* there — these are additive fields, and an absent one means "this run predates it".
|
|
120
|
+
*/
|
|
121
|
+
export declare const runRecordSchema: z.ZodObject<{
|
|
122
|
+
id: z.ZodString;
|
|
123
|
+
title: z.ZodString;
|
|
124
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
125
|
+
diffStat: z.ZodOptional<z.ZodObject<{
|
|
126
|
+
adds: z.ZodNumber;
|
|
127
|
+
dels: z.ZodNumber;
|
|
128
|
+
files: z.ZodNumber;
|
|
129
|
+
repointed: z.ZodOptional<z.ZodBoolean>;
|
|
130
|
+
}, z.core.$strip>>;
|
|
131
|
+
workflow: z.ZodString;
|
|
132
|
+
task: z.ZodString;
|
|
133
|
+
queuedMessages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
134
|
+
id: z.ZodString;
|
|
135
|
+
text: z.ZodString;
|
|
136
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
137
|
+
createdAt: z.ZodString;
|
|
138
|
+
}, z.core.$strip>>>;
|
|
139
|
+
taskImages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
140
|
+
model: z.ZodOptional<z.ZodString>;
|
|
141
|
+
modelIdentity: z.ZodOptional<z.ZodString>;
|
|
142
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
143
|
+
claude: "claude";
|
|
144
|
+
codex: "codex";
|
|
145
|
+
opencode: "opencode";
|
|
146
|
+
pi: "pi";
|
|
147
|
+
}>>;
|
|
148
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
149
|
+
systemPrompt: z.ZodOptional<z.ZodString>;
|
|
150
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
151
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
152
|
+
automation: z.ZodOptional<z.ZodObject<{
|
|
153
|
+
automationId: z.ZodString;
|
|
154
|
+
automationRevision: z.ZodNumber;
|
|
155
|
+
receiptId: z.ZodString;
|
|
156
|
+
event: z.ZodString;
|
|
157
|
+
githubUrl: z.ZodString;
|
|
158
|
+
}, z.core.$strip>>;
|
|
159
|
+
status: z.ZodEnum<{
|
|
160
|
+
cancelled: "cancelled";
|
|
161
|
+
done: "done";
|
|
162
|
+
failed: "failed";
|
|
163
|
+
queued: "queued";
|
|
164
|
+
review: "review";
|
|
165
|
+
running: "running";
|
|
166
|
+
waiting: "waiting";
|
|
167
|
+
}>;
|
|
168
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
169
|
+
monitoring: "monitoring";
|
|
170
|
+
}>>;
|
|
171
|
+
monitoringWakeAt: z.ZodOptional<z.ZodString>;
|
|
172
|
+
monitoringWakeCapReached: z.ZodOptional<z.ZodBoolean>;
|
|
173
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
174
|
+
autoResumeAttempts: z.ZodOptional<z.ZodNumber>;
|
|
175
|
+
createdAt: z.ZodString;
|
|
176
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
177
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
178
|
+
tokensUsed: z.ZodNumber;
|
|
179
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
180
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
181
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
182
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
183
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
184
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
185
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
186
|
+
referencedIssueNumberSeeded: z.ZodOptional<z.ZodBoolean>;
|
|
187
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
188
|
+
auto: "auto";
|
|
189
|
+
marker: "marker";
|
|
190
|
+
user: "user";
|
|
191
|
+
}>>;
|
|
192
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
193
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
194
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
195
|
+
}, z.core.$strip>>;
|
|
196
|
+
referencedPrCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
197
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
198
|
+
referencedIssueCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
199
|
+
worktree: z.ZodOptional<z.ZodLiteral<false>>;
|
|
200
|
+
worktreePath: z.ZodOptional<z.ZodString>;
|
|
201
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
202
|
+
baseBranch: z.ZodOptional<z.ZodString>;
|
|
203
|
+
worktreeReclaimedAt: z.ZodOptional<z.ZodString>;
|
|
204
|
+
groupId: z.ZodOptional<z.ZodString>;
|
|
205
|
+
variant: z.ZodOptional<z.ZodString>;
|
|
206
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
207
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
208
|
+
archived: z.ZodBoolean;
|
|
209
|
+
archivedAt: z.ZodOptional<z.ZodString>;
|
|
210
|
+
pinned: z.ZodOptional<z.ZodBoolean>;
|
|
211
|
+
pinnedAt: z.ZodOptional<z.ZodString>;
|
|
212
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
213
|
+
currentStepId: z.ZodOptional<z.ZodString>;
|
|
214
|
+
error: z.ZodOptional<z.ZodString>;
|
|
215
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
216
|
+
id: z.ZodString;
|
|
217
|
+
name: z.ZodString;
|
|
218
|
+
kind: z.ZodEnum<{
|
|
219
|
+
agent: "agent";
|
|
220
|
+
check: "check";
|
|
221
|
+
}>;
|
|
222
|
+
status: z.ZodEnum<{
|
|
223
|
+
cancelled: "cancelled";
|
|
224
|
+
done: "done";
|
|
225
|
+
failed: "failed";
|
|
226
|
+
pending: "pending";
|
|
227
|
+
review: "review";
|
|
228
|
+
running: "running";
|
|
229
|
+
skipped: "skipped";
|
|
230
|
+
waiting: "waiting";
|
|
231
|
+
}>;
|
|
232
|
+
iterations: z.ZodNumber;
|
|
233
|
+
tokensUsed: z.ZodNumber;
|
|
234
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
235
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
236
|
+
usageInvocationsStarted: z.ZodOptional<z.ZodNumber>;
|
|
237
|
+
usageInvocationsObserved: z.ZodOptional<z.ZodNumber>;
|
|
238
|
+
usageTurnsStarted: z.ZodOptional<z.ZodNumber>;
|
|
239
|
+
usageTurnsRecorded: z.ZodOptional<z.ZodNumber>;
|
|
240
|
+
usageInvocationEpoch: z.ZodOptional<z.ZodNumber>;
|
|
241
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
242
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
243
|
+
error: z.ZodOptional<z.ZodString>;
|
|
244
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
245
|
+
backend: z.ZodOptional<z.ZodEnum<{
|
|
246
|
+
claude: "claude";
|
|
247
|
+
codex: "codex";
|
|
248
|
+
opencode: "opencode";
|
|
249
|
+
pi: "pi";
|
|
250
|
+
}>>;
|
|
251
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
252
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
253
|
+
}, z.core.$strip>>;
|
|
254
|
+
workflowDef: z.ZodOptional<z.ZodObject<{
|
|
255
|
+
name: z.ZodString;
|
|
256
|
+
description: z.ZodOptional<z.ZodString>;
|
|
257
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
258
|
+
id: z.ZodString;
|
|
259
|
+
name: z.ZodOptional<z.ZodString>;
|
|
260
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
261
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
262
|
+
model: z.ZodOptional<z.ZodString>;
|
|
263
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
264
|
+
claude: "claude";
|
|
265
|
+
codex: "codex";
|
|
266
|
+
opencode: "opencode";
|
|
267
|
+
pi: "pi";
|
|
268
|
+
}>>;
|
|
269
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
270
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
271
|
+
command: z.ZodOptional<z.ZodString>;
|
|
272
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
273
|
+
retry: z.ZodString;
|
|
274
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
275
|
+
}, z.core.$strip>>;
|
|
276
|
+
}, z.core.$strip>>;
|
|
277
|
+
source: z.ZodEnum<{
|
|
278
|
+
"built-in": "built-in";
|
|
279
|
+
file: "file";
|
|
280
|
+
}>;
|
|
281
|
+
path: z.ZodOptional<z.ZodString>;
|
|
282
|
+
}, z.core.$strip>>;
|
|
283
|
+
}, z.core.$strip>;
|
|
284
|
+
export type RunRecord = z.infer<typeof runRecordSchema>;
|
|
285
|
+
/**
|
|
286
|
+
* What `GET /runs` and `GET /runs/:id` answer: the stored record plus the live `usage` sample the
|
|
287
|
+
* server attaches on the way out (`withUsage`). Absent for finished runs and wherever `ps` yields
|
|
288
|
+
* nothing — never persisted, and never attached by the mutation routes.
|
|
289
|
+
*/
|
|
290
|
+
export declare const apiRunSchema: z.ZodObject<{
|
|
291
|
+
id: z.ZodString;
|
|
292
|
+
title: z.ZodString;
|
|
293
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
294
|
+
diffStat: z.ZodOptional<z.ZodObject<{
|
|
295
|
+
adds: z.ZodNumber;
|
|
296
|
+
dels: z.ZodNumber;
|
|
297
|
+
files: z.ZodNumber;
|
|
298
|
+
repointed: z.ZodOptional<z.ZodBoolean>;
|
|
299
|
+
}, z.core.$strip>>;
|
|
300
|
+
workflow: z.ZodString;
|
|
301
|
+
task: z.ZodString;
|
|
302
|
+
queuedMessages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
303
|
+
id: z.ZodString;
|
|
304
|
+
text: z.ZodString;
|
|
305
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
306
|
+
createdAt: z.ZodString;
|
|
307
|
+
}, z.core.$strip>>>;
|
|
308
|
+
taskImages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
309
|
+
model: z.ZodOptional<z.ZodString>;
|
|
310
|
+
modelIdentity: z.ZodOptional<z.ZodString>;
|
|
311
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
312
|
+
claude: "claude";
|
|
313
|
+
codex: "codex";
|
|
314
|
+
opencode: "opencode";
|
|
315
|
+
pi: "pi";
|
|
316
|
+
}>>;
|
|
317
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
318
|
+
systemPrompt: z.ZodOptional<z.ZodString>;
|
|
319
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
320
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
321
|
+
automation: z.ZodOptional<z.ZodObject<{
|
|
322
|
+
automationId: z.ZodString;
|
|
323
|
+
automationRevision: z.ZodNumber;
|
|
324
|
+
receiptId: z.ZodString;
|
|
325
|
+
event: z.ZodString;
|
|
326
|
+
githubUrl: z.ZodString;
|
|
327
|
+
}, z.core.$strip>>;
|
|
328
|
+
status: z.ZodEnum<{
|
|
329
|
+
cancelled: "cancelled";
|
|
330
|
+
done: "done";
|
|
331
|
+
failed: "failed";
|
|
332
|
+
queued: "queued";
|
|
333
|
+
review: "review";
|
|
334
|
+
running: "running";
|
|
335
|
+
waiting: "waiting";
|
|
336
|
+
}>;
|
|
337
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
338
|
+
monitoring: "monitoring";
|
|
339
|
+
}>>;
|
|
340
|
+
monitoringWakeAt: z.ZodOptional<z.ZodString>;
|
|
341
|
+
monitoringWakeCapReached: z.ZodOptional<z.ZodBoolean>;
|
|
342
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
343
|
+
autoResumeAttempts: z.ZodOptional<z.ZodNumber>;
|
|
344
|
+
createdAt: z.ZodString;
|
|
345
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
346
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
347
|
+
tokensUsed: z.ZodNumber;
|
|
348
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
349
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
350
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
351
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
352
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
353
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
354
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
355
|
+
referencedIssueNumberSeeded: z.ZodOptional<z.ZodBoolean>;
|
|
356
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
357
|
+
auto: "auto";
|
|
358
|
+
marker: "marker";
|
|
359
|
+
user: "user";
|
|
360
|
+
}>>;
|
|
361
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
362
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
363
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
364
|
+
}, z.core.$strip>>;
|
|
365
|
+
referencedPrCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
366
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
367
|
+
referencedIssueCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
368
|
+
worktree: z.ZodOptional<z.ZodLiteral<false>>;
|
|
369
|
+
worktreePath: z.ZodOptional<z.ZodString>;
|
|
370
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
371
|
+
baseBranch: z.ZodOptional<z.ZodString>;
|
|
372
|
+
worktreeReclaimedAt: z.ZodOptional<z.ZodString>;
|
|
373
|
+
groupId: z.ZodOptional<z.ZodString>;
|
|
374
|
+
variant: z.ZodOptional<z.ZodString>;
|
|
375
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
376
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
377
|
+
archived: z.ZodBoolean;
|
|
378
|
+
archivedAt: z.ZodOptional<z.ZodString>;
|
|
379
|
+
pinned: z.ZodOptional<z.ZodBoolean>;
|
|
380
|
+
pinnedAt: z.ZodOptional<z.ZodString>;
|
|
381
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
382
|
+
currentStepId: z.ZodOptional<z.ZodString>;
|
|
383
|
+
error: z.ZodOptional<z.ZodString>;
|
|
384
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
385
|
+
id: z.ZodString;
|
|
386
|
+
name: z.ZodString;
|
|
387
|
+
kind: z.ZodEnum<{
|
|
388
|
+
agent: "agent";
|
|
389
|
+
check: "check";
|
|
390
|
+
}>;
|
|
391
|
+
status: z.ZodEnum<{
|
|
392
|
+
cancelled: "cancelled";
|
|
393
|
+
done: "done";
|
|
394
|
+
failed: "failed";
|
|
395
|
+
pending: "pending";
|
|
396
|
+
review: "review";
|
|
397
|
+
running: "running";
|
|
398
|
+
skipped: "skipped";
|
|
399
|
+
waiting: "waiting";
|
|
400
|
+
}>;
|
|
401
|
+
iterations: z.ZodNumber;
|
|
402
|
+
tokensUsed: z.ZodNumber;
|
|
403
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
404
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
405
|
+
usageInvocationsStarted: z.ZodOptional<z.ZodNumber>;
|
|
406
|
+
usageInvocationsObserved: z.ZodOptional<z.ZodNumber>;
|
|
407
|
+
usageTurnsStarted: z.ZodOptional<z.ZodNumber>;
|
|
408
|
+
usageTurnsRecorded: z.ZodOptional<z.ZodNumber>;
|
|
409
|
+
usageInvocationEpoch: z.ZodOptional<z.ZodNumber>;
|
|
410
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
411
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
412
|
+
error: z.ZodOptional<z.ZodString>;
|
|
413
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
414
|
+
backend: z.ZodOptional<z.ZodEnum<{
|
|
415
|
+
claude: "claude";
|
|
416
|
+
codex: "codex";
|
|
417
|
+
opencode: "opencode";
|
|
418
|
+
pi: "pi";
|
|
419
|
+
}>>;
|
|
420
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
421
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
422
|
+
}, z.core.$strip>>;
|
|
423
|
+
workflowDef: z.ZodOptional<z.ZodObject<{
|
|
424
|
+
name: z.ZodString;
|
|
425
|
+
description: z.ZodOptional<z.ZodString>;
|
|
426
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
427
|
+
id: z.ZodString;
|
|
428
|
+
name: z.ZodOptional<z.ZodString>;
|
|
429
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
430
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
431
|
+
model: z.ZodOptional<z.ZodString>;
|
|
432
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
433
|
+
claude: "claude";
|
|
434
|
+
codex: "codex";
|
|
435
|
+
opencode: "opencode";
|
|
436
|
+
pi: "pi";
|
|
437
|
+
}>>;
|
|
438
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
439
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
440
|
+
command: z.ZodOptional<z.ZodString>;
|
|
441
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
442
|
+
retry: z.ZodString;
|
|
443
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
444
|
+
}, z.core.$strip>>;
|
|
445
|
+
}, z.core.$strip>>;
|
|
446
|
+
source: z.ZodEnum<{
|
|
447
|
+
"built-in": "built-in";
|
|
448
|
+
file: "file";
|
|
449
|
+
}>;
|
|
450
|
+
path: z.ZodOptional<z.ZodString>;
|
|
451
|
+
}, z.core.$strip>>;
|
|
452
|
+
usage: z.ZodOptional<z.ZodObject<{
|
|
453
|
+
cpuPct: z.ZodNumber;
|
|
454
|
+
rssBytes: z.ZodNumber;
|
|
455
|
+
procCount: z.ZodNumber;
|
|
456
|
+
}, z.core.$strip>>;
|
|
457
|
+
}, z.core.$strip>;
|
|
458
|
+
export type ApiRun = z.infer<typeof apiRunSchema>;
|
|
459
|
+
/**
|
|
460
|
+
* One run in the WORKSPACE-level index (`GET /api/v1/workspace/runs-index`) — the ⌘K palette's
|
|
461
|
+
* "find a task in any project" list, and the global Tasks page's rows.
|
|
462
|
+
*
|
|
463
|
+
* Deliberately a separate, slim shape rather than `ApiRun`. The index answers for every
|
|
464
|
+
* registered project at once, and `runRecordSchema` carries `steps[]` and `workflowDef` — a fat
|
|
465
|
+
* record whose cost is fine per project and absurd multiplied by the registry. These are exactly
|
|
466
|
+
* the fields a palette row renders: `runTitle`'s three (`title`, `titleSummary`, `titleOrigin`),
|
|
467
|
+
* `deriveAttention`'s `AttentionInput`, `isUnread`'s `ReadStateInput`, and the timestamps
|
|
468
|
+
* `shortAge` reads. Adding a field here is cheap; adding the whole record is what this exists to
|
|
469
|
+
* avoid — but note that widening either of those two `Pick`s means widening this too, or the
|
|
470
|
+
* palette's cross-project rows silently answer differently from every other surface.
|
|
471
|
+
*
|
|
472
|
+
* `projectId` is the join key, NOT the project name: the registry is already on the client and is
|
|
473
|
+
* authoritative for display names, and duplicating one here would let a renamed project show two
|
|
474
|
+
* different labels in one palette.
|
|
475
|
+
*/
|
|
476
|
+
export declare const runIndexEntrySchema: z.ZodObject<{
|
|
477
|
+
projectId: z.ZodString;
|
|
478
|
+
id: z.ZodString;
|
|
479
|
+
title: z.ZodString;
|
|
480
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
481
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
482
|
+
auto: "auto";
|
|
483
|
+
marker: "marker";
|
|
484
|
+
user: "user";
|
|
485
|
+
}>>;
|
|
486
|
+
status: z.ZodEnum<{
|
|
487
|
+
cancelled: "cancelled";
|
|
488
|
+
done: "done";
|
|
489
|
+
failed: "failed";
|
|
490
|
+
queued: "queued";
|
|
491
|
+
review: "review";
|
|
492
|
+
running: "running";
|
|
493
|
+
waiting: "waiting";
|
|
494
|
+
}>;
|
|
495
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
496
|
+
monitoring: "monitoring";
|
|
497
|
+
}>>;
|
|
498
|
+
createdAt: z.ZodString;
|
|
499
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
500
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
501
|
+
archived: z.ZodBoolean;
|
|
502
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
503
|
+
workflow: z.ZodString;
|
|
504
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
505
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
506
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
507
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
508
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
509
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
510
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
511
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
512
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
513
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
514
|
+
}, z.core.$strip>>;
|
|
515
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
516
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
517
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
518
|
+
usage: z.ZodOptional<z.ZodObject<{
|
|
519
|
+
cpuPct: z.ZodNumber;
|
|
520
|
+
rssBytes: z.ZodNumber;
|
|
521
|
+
procCount: z.ZodNumber;
|
|
522
|
+
}, z.core.$strip>>;
|
|
523
|
+
}, z.core.$strip>;
|
|
524
|
+
export type RunIndexEntry = z.infer<typeof runIndexEntrySchema>;
|
|
525
|
+
/**
|
|
526
|
+
* `GET /workspace/runs-index`.
|
|
527
|
+
*
|
|
528
|
+
* `truncated` is not decoration: the index caps each project's contribution, and a capped list
|
|
529
|
+
* that says nothing reads as "your task is not here" when the honest answer is "not in the
|
|
530
|
+
* newest N". Naming the projects that hit the cap is what lets a consumer say so.
|
|
531
|
+
*/
|
|
532
|
+
/**
|
|
533
|
+
* Everything the SERVER already knew about the references its rows carry, per project — the
|
|
534
|
+
* statuses that would otherwise cost a second round trip a beat after the table paints.
|
|
535
|
+
*
|
|
536
|
+
* Read from cache only: this never asks the forge, so a cold entry is simply absent and
|
|
537
|
+
* `GET /github/ref-status` stays the route that actually goes and looks. That makes it free, and
|
|
538
|
+
* being free is what lets it be a superset — the server looks up every number a run mentions
|
|
539
|
+
* rather than re-deriving which one the cockpit will display (#407, #526 live client-side, and
|
|
540
|
+
* duplicating that rule is how the two would drift).
|
|
541
|
+
*/
|
|
542
|
+
export declare const referenceStatusesByProjectSchema: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
543
|
+
prs: z.ZodRecord<z.ZodNumber, z.ZodEnum<{
|
|
544
|
+
"changes-requested": "changes-requested";
|
|
545
|
+
"checks-failing": "checks-failing";
|
|
546
|
+
"checks-pending": "checks-pending";
|
|
547
|
+
closed: "closed";
|
|
548
|
+
completed: "completed";
|
|
549
|
+
draft: "draft";
|
|
550
|
+
merged: "merged";
|
|
551
|
+
"not-planned": "not-planned";
|
|
552
|
+
open: "open";
|
|
553
|
+
ready: "ready";
|
|
554
|
+
"review-required": "review-required";
|
|
555
|
+
}>>;
|
|
556
|
+
issues: z.ZodRecord<z.ZodNumber, z.ZodEnum<{
|
|
557
|
+
"changes-requested": "changes-requested";
|
|
558
|
+
"checks-failing": "checks-failing";
|
|
559
|
+
"checks-pending": "checks-pending";
|
|
560
|
+
closed: "closed";
|
|
561
|
+
completed: "completed";
|
|
562
|
+
draft: "draft";
|
|
563
|
+
merged: "merged";
|
|
564
|
+
"not-planned": "not-planned";
|
|
565
|
+
open: "open";
|
|
566
|
+
ready: "ready";
|
|
567
|
+
"review-required": "review-required";
|
|
568
|
+
}>>;
|
|
569
|
+
}, z.core.$strip>>;
|
|
570
|
+
export declare const runsIndexResponseSchema: z.ZodObject<{
|
|
571
|
+
runs: z.ZodArray<z.ZodObject<{
|
|
572
|
+
projectId: z.ZodString;
|
|
573
|
+
id: z.ZodString;
|
|
574
|
+
title: z.ZodString;
|
|
575
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
576
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
577
|
+
auto: "auto";
|
|
578
|
+
marker: "marker";
|
|
579
|
+
user: "user";
|
|
580
|
+
}>>;
|
|
581
|
+
status: z.ZodEnum<{
|
|
582
|
+
cancelled: "cancelled";
|
|
583
|
+
done: "done";
|
|
584
|
+
failed: "failed";
|
|
585
|
+
queued: "queued";
|
|
586
|
+
review: "review";
|
|
587
|
+
running: "running";
|
|
588
|
+
waiting: "waiting";
|
|
589
|
+
}>;
|
|
590
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
591
|
+
monitoring: "monitoring";
|
|
592
|
+
}>>;
|
|
593
|
+
createdAt: z.ZodString;
|
|
594
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
595
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
596
|
+
archived: z.ZodBoolean;
|
|
597
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
598
|
+
workflow: z.ZodString;
|
|
599
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
600
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
601
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
602
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
603
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
604
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
605
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
606
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
607
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
608
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
609
|
+
}, z.core.$strip>>;
|
|
610
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
611
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
612
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
613
|
+
usage: z.ZodOptional<z.ZodObject<{
|
|
614
|
+
cpuPct: z.ZodNumber;
|
|
615
|
+
rssBytes: z.ZodNumber;
|
|
616
|
+
procCount: z.ZodNumber;
|
|
617
|
+
}, z.core.$strip>>;
|
|
618
|
+
}, z.core.$strip>>;
|
|
619
|
+
referenceStatuses: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
620
|
+
prs: z.ZodRecord<z.ZodNumber, z.ZodEnum<{
|
|
621
|
+
"changes-requested": "changes-requested";
|
|
622
|
+
"checks-failing": "checks-failing";
|
|
623
|
+
"checks-pending": "checks-pending";
|
|
624
|
+
closed: "closed";
|
|
625
|
+
completed: "completed";
|
|
626
|
+
draft: "draft";
|
|
627
|
+
merged: "merged";
|
|
628
|
+
"not-planned": "not-planned";
|
|
629
|
+
open: "open";
|
|
630
|
+
ready: "ready";
|
|
631
|
+
"review-required": "review-required";
|
|
632
|
+
}>>;
|
|
633
|
+
issues: z.ZodRecord<z.ZodNumber, z.ZodEnum<{
|
|
634
|
+
"changes-requested": "changes-requested";
|
|
635
|
+
"checks-failing": "checks-failing";
|
|
636
|
+
"checks-pending": "checks-pending";
|
|
637
|
+
closed: "closed";
|
|
638
|
+
completed: "completed";
|
|
639
|
+
draft: "draft";
|
|
640
|
+
merged: "merged";
|
|
641
|
+
"not-planned": "not-planned";
|
|
642
|
+
open: "open";
|
|
643
|
+
ready: "ready";
|
|
644
|
+
"review-required": "review-required";
|
|
645
|
+
}>>;
|
|
646
|
+
}, z.core.$strip>>;
|
|
647
|
+
perProjectLimit: z.ZodNumber;
|
|
648
|
+
truncated: z.ZodArray<z.ZodString>;
|
|
649
|
+
}, z.core.$strip>;
|
|
650
|
+
export type RunsIndexResponse = z.infer<typeof runsIndexResponseSchema>;
|
|
651
|
+
/**
|
|
652
|
+
* `POST /runs` (201) — one record for ×1, a group for ×2/×3.
|
|
653
|
+
*
|
|
654
|
+
* The ×1 branch is the STORED record, not `ApiRun`: `startRun` answers before any `ps` sample
|
|
655
|
+
* exists, so the create route never runs a record through `withUsage`.
|
|
656
|
+
*/
|
|
657
|
+
export declare const createRunResponseSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
658
|
+
id: z.ZodString;
|
|
659
|
+
title: z.ZodString;
|
|
660
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
661
|
+
diffStat: z.ZodOptional<z.ZodObject<{
|
|
662
|
+
adds: z.ZodNumber;
|
|
663
|
+
dels: z.ZodNumber;
|
|
664
|
+
files: z.ZodNumber;
|
|
665
|
+
repointed: z.ZodOptional<z.ZodBoolean>;
|
|
666
|
+
}, z.core.$strip>>;
|
|
667
|
+
workflow: z.ZodString;
|
|
668
|
+
task: z.ZodString;
|
|
669
|
+
queuedMessages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
670
|
+
id: z.ZodString;
|
|
671
|
+
text: z.ZodString;
|
|
672
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
673
|
+
createdAt: z.ZodString;
|
|
674
|
+
}, z.core.$strip>>>;
|
|
675
|
+
taskImages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
676
|
+
model: z.ZodOptional<z.ZodString>;
|
|
677
|
+
modelIdentity: z.ZodOptional<z.ZodString>;
|
|
678
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
679
|
+
claude: "claude";
|
|
680
|
+
codex: "codex";
|
|
681
|
+
opencode: "opencode";
|
|
682
|
+
pi: "pi";
|
|
683
|
+
}>>;
|
|
684
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
685
|
+
systemPrompt: z.ZodOptional<z.ZodString>;
|
|
686
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
687
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
688
|
+
automation: z.ZodOptional<z.ZodObject<{
|
|
689
|
+
automationId: z.ZodString;
|
|
690
|
+
automationRevision: z.ZodNumber;
|
|
691
|
+
receiptId: z.ZodString;
|
|
692
|
+
event: z.ZodString;
|
|
693
|
+
githubUrl: z.ZodString;
|
|
694
|
+
}, z.core.$strip>>;
|
|
695
|
+
status: z.ZodEnum<{
|
|
696
|
+
cancelled: "cancelled";
|
|
697
|
+
done: "done";
|
|
698
|
+
failed: "failed";
|
|
699
|
+
queued: "queued";
|
|
700
|
+
review: "review";
|
|
701
|
+
running: "running";
|
|
702
|
+
waiting: "waiting";
|
|
703
|
+
}>;
|
|
704
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
705
|
+
monitoring: "monitoring";
|
|
706
|
+
}>>;
|
|
707
|
+
monitoringWakeAt: z.ZodOptional<z.ZodString>;
|
|
708
|
+
monitoringWakeCapReached: z.ZodOptional<z.ZodBoolean>;
|
|
709
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
710
|
+
autoResumeAttempts: z.ZodOptional<z.ZodNumber>;
|
|
711
|
+
createdAt: z.ZodString;
|
|
712
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
713
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
714
|
+
tokensUsed: z.ZodNumber;
|
|
715
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
716
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
717
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
718
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
719
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
720
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
721
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
722
|
+
referencedIssueNumberSeeded: z.ZodOptional<z.ZodBoolean>;
|
|
723
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
724
|
+
auto: "auto";
|
|
725
|
+
marker: "marker";
|
|
726
|
+
user: "user";
|
|
727
|
+
}>>;
|
|
728
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
729
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
730
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
731
|
+
}, z.core.$strip>>;
|
|
732
|
+
referencedPrCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
733
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
734
|
+
referencedIssueCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
735
|
+
worktree: z.ZodOptional<z.ZodLiteral<false>>;
|
|
736
|
+
worktreePath: z.ZodOptional<z.ZodString>;
|
|
737
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
738
|
+
baseBranch: z.ZodOptional<z.ZodString>;
|
|
739
|
+
worktreeReclaimedAt: z.ZodOptional<z.ZodString>;
|
|
740
|
+
groupId: z.ZodOptional<z.ZodString>;
|
|
741
|
+
variant: z.ZodOptional<z.ZodString>;
|
|
742
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
743
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
744
|
+
archived: z.ZodBoolean;
|
|
745
|
+
archivedAt: z.ZodOptional<z.ZodString>;
|
|
746
|
+
pinned: z.ZodOptional<z.ZodBoolean>;
|
|
747
|
+
pinnedAt: z.ZodOptional<z.ZodString>;
|
|
748
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
749
|
+
currentStepId: z.ZodOptional<z.ZodString>;
|
|
750
|
+
error: z.ZodOptional<z.ZodString>;
|
|
751
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
752
|
+
id: z.ZodString;
|
|
753
|
+
name: z.ZodString;
|
|
754
|
+
kind: z.ZodEnum<{
|
|
755
|
+
agent: "agent";
|
|
756
|
+
check: "check";
|
|
757
|
+
}>;
|
|
758
|
+
status: z.ZodEnum<{
|
|
759
|
+
cancelled: "cancelled";
|
|
760
|
+
done: "done";
|
|
761
|
+
failed: "failed";
|
|
762
|
+
pending: "pending";
|
|
763
|
+
review: "review";
|
|
764
|
+
running: "running";
|
|
765
|
+
skipped: "skipped";
|
|
766
|
+
waiting: "waiting";
|
|
767
|
+
}>;
|
|
768
|
+
iterations: z.ZodNumber;
|
|
769
|
+
tokensUsed: z.ZodNumber;
|
|
770
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
771
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
772
|
+
usageInvocationsStarted: z.ZodOptional<z.ZodNumber>;
|
|
773
|
+
usageInvocationsObserved: z.ZodOptional<z.ZodNumber>;
|
|
774
|
+
usageTurnsStarted: z.ZodOptional<z.ZodNumber>;
|
|
775
|
+
usageTurnsRecorded: z.ZodOptional<z.ZodNumber>;
|
|
776
|
+
usageInvocationEpoch: z.ZodOptional<z.ZodNumber>;
|
|
777
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
778
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
779
|
+
error: z.ZodOptional<z.ZodString>;
|
|
780
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
781
|
+
backend: z.ZodOptional<z.ZodEnum<{
|
|
782
|
+
claude: "claude";
|
|
783
|
+
codex: "codex";
|
|
784
|
+
opencode: "opencode";
|
|
785
|
+
pi: "pi";
|
|
786
|
+
}>>;
|
|
787
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
788
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
789
|
+
}, z.core.$strip>>;
|
|
790
|
+
workflowDef: z.ZodOptional<z.ZodObject<{
|
|
791
|
+
name: z.ZodString;
|
|
792
|
+
description: z.ZodOptional<z.ZodString>;
|
|
793
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
794
|
+
id: z.ZodString;
|
|
795
|
+
name: z.ZodOptional<z.ZodString>;
|
|
796
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
797
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
798
|
+
model: z.ZodOptional<z.ZodString>;
|
|
799
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
800
|
+
claude: "claude";
|
|
801
|
+
codex: "codex";
|
|
802
|
+
opencode: "opencode";
|
|
803
|
+
pi: "pi";
|
|
804
|
+
}>>;
|
|
805
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
806
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
807
|
+
command: z.ZodOptional<z.ZodString>;
|
|
808
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
809
|
+
retry: z.ZodString;
|
|
810
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
811
|
+
}, z.core.$strip>>;
|
|
812
|
+
}, z.core.$strip>>;
|
|
813
|
+
source: z.ZodEnum<{
|
|
814
|
+
"built-in": "built-in";
|
|
815
|
+
file: "file";
|
|
816
|
+
}>;
|
|
817
|
+
path: z.ZodOptional<z.ZodString>;
|
|
818
|
+
}, z.core.$strip>>;
|
|
819
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
820
|
+
runs: z.ZodArray<z.ZodObject<{
|
|
821
|
+
id: z.ZodString;
|
|
822
|
+
title: z.ZodString;
|
|
823
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
824
|
+
diffStat: z.ZodOptional<z.ZodObject<{
|
|
825
|
+
adds: z.ZodNumber;
|
|
826
|
+
dels: z.ZodNumber;
|
|
827
|
+
files: z.ZodNumber;
|
|
828
|
+
repointed: z.ZodOptional<z.ZodBoolean>;
|
|
829
|
+
}, z.core.$strip>>;
|
|
830
|
+
workflow: z.ZodString;
|
|
831
|
+
task: z.ZodString;
|
|
832
|
+
queuedMessages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
833
|
+
id: z.ZodString;
|
|
834
|
+
text: z.ZodString;
|
|
835
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
836
|
+
createdAt: z.ZodString;
|
|
837
|
+
}, z.core.$strip>>>;
|
|
838
|
+
taskImages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
839
|
+
model: z.ZodOptional<z.ZodString>;
|
|
840
|
+
modelIdentity: z.ZodOptional<z.ZodString>;
|
|
841
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
842
|
+
claude: "claude";
|
|
843
|
+
codex: "codex";
|
|
844
|
+
opencode: "opencode";
|
|
845
|
+
pi: "pi";
|
|
846
|
+
}>>;
|
|
847
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
848
|
+
systemPrompt: z.ZodOptional<z.ZodString>;
|
|
849
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
850
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
851
|
+
automation: z.ZodOptional<z.ZodObject<{
|
|
852
|
+
automationId: z.ZodString;
|
|
853
|
+
automationRevision: z.ZodNumber;
|
|
854
|
+
receiptId: z.ZodString;
|
|
855
|
+
event: z.ZodString;
|
|
856
|
+
githubUrl: z.ZodString;
|
|
857
|
+
}, z.core.$strip>>;
|
|
858
|
+
status: z.ZodEnum<{
|
|
859
|
+
cancelled: "cancelled";
|
|
860
|
+
done: "done";
|
|
861
|
+
failed: "failed";
|
|
862
|
+
queued: "queued";
|
|
863
|
+
review: "review";
|
|
864
|
+
running: "running";
|
|
865
|
+
waiting: "waiting";
|
|
866
|
+
}>;
|
|
867
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
868
|
+
monitoring: "monitoring";
|
|
869
|
+
}>>;
|
|
870
|
+
monitoringWakeAt: z.ZodOptional<z.ZodString>;
|
|
871
|
+
monitoringWakeCapReached: z.ZodOptional<z.ZodBoolean>;
|
|
872
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
873
|
+
autoResumeAttempts: z.ZodOptional<z.ZodNumber>;
|
|
874
|
+
createdAt: z.ZodString;
|
|
875
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
876
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
877
|
+
tokensUsed: z.ZodNumber;
|
|
878
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
879
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
880
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
881
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
882
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
883
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
884
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
885
|
+
referencedIssueNumberSeeded: z.ZodOptional<z.ZodBoolean>;
|
|
886
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
887
|
+
auto: "auto";
|
|
888
|
+
marker: "marker";
|
|
889
|
+
user: "user";
|
|
890
|
+
}>>;
|
|
891
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
892
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
893
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
894
|
+
}, z.core.$strip>>;
|
|
895
|
+
referencedPrCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
896
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
897
|
+
referencedIssueCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
898
|
+
worktree: z.ZodOptional<z.ZodLiteral<false>>;
|
|
899
|
+
worktreePath: z.ZodOptional<z.ZodString>;
|
|
900
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
901
|
+
baseBranch: z.ZodOptional<z.ZodString>;
|
|
902
|
+
worktreeReclaimedAt: z.ZodOptional<z.ZodString>;
|
|
903
|
+
groupId: z.ZodOptional<z.ZodString>;
|
|
904
|
+
variant: z.ZodOptional<z.ZodString>;
|
|
905
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
906
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
907
|
+
archived: z.ZodBoolean;
|
|
908
|
+
archivedAt: z.ZodOptional<z.ZodString>;
|
|
909
|
+
pinned: z.ZodOptional<z.ZodBoolean>;
|
|
910
|
+
pinnedAt: z.ZodOptional<z.ZodString>;
|
|
911
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
912
|
+
currentStepId: z.ZodOptional<z.ZodString>;
|
|
913
|
+
error: z.ZodOptional<z.ZodString>;
|
|
914
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
915
|
+
id: z.ZodString;
|
|
916
|
+
name: z.ZodString;
|
|
917
|
+
kind: z.ZodEnum<{
|
|
918
|
+
agent: "agent";
|
|
919
|
+
check: "check";
|
|
920
|
+
}>;
|
|
921
|
+
status: z.ZodEnum<{
|
|
922
|
+
cancelled: "cancelled";
|
|
923
|
+
done: "done";
|
|
924
|
+
failed: "failed";
|
|
925
|
+
pending: "pending";
|
|
926
|
+
review: "review";
|
|
927
|
+
running: "running";
|
|
928
|
+
skipped: "skipped";
|
|
929
|
+
waiting: "waiting";
|
|
930
|
+
}>;
|
|
931
|
+
iterations: z.ZodNumber;
|
|
932
|
+
tokensUsed: z.ZodNumber;
|
|
933
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
934
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
935
|
+
usageInvocationsStarted: z.ZodOptional<z.ZodNumber>;
|
|
936
|
+
usageInvocationsObserved: z.ZodOptional<z.ZodNumber>;
|
|
937
|
+
usageTurnsStarted: z.ZodOptional<z.ZodNumber>;
|
|
938
|
+
usageTurnsRecorded: z.ZodOptional<z.ZodNumber>;
|
|
939
|
+
usageInvocationEpoch: z.ZodOptional<z.ZodNumber>;
|
|
940
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
941
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
942
|
+
error: z.ZodOptional<z.ZodString>;
|
|
943
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
944
|
+
backend: z.ZodOptional<z.ZodEnum<{
|
|
945
|
+
claude: "claude";
|
|
946
|
+
codex: "codex";
|
|
947
|
+
opencode: "opencode";
|
|
948
|
+
pi: "pi";
|
|
949
|
+
}>>;
|
|
950
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
951
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
952
|
+
}, z.core.$strip>>;
|
|
953
|
+
workflowDef: z.ZodOptional<z.ZodObject<{
|
|
954
|
+
name: z.ZodString;
|
|
955
|
+
description: z.ZodOptional<z.ZodString>;
|
|
956
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
957
|
+
id: z.ZodString;
|
|
958
|
+
name: z.ZodOptional<z.ZodString>;
|
|
959
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
960
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
961
|
+
model: z.ZodOptional<z.ZodString>;
|
|
962
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
963
|
+
claude: "claude";
|
|
964
|
+
codex: "codex";
|
|
965
|
+
opencode: "opencode";
|
|
966
|
+
pi: "pi";
|
|
967
|
+
}>>;
|
|
968
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
969
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
970
|
+
command: z.ZodOptional<z.ZodString>;
|
|
971
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
972
|
+
retry: z.ZodString;
|
|
973
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
974
|
+
}, z.core.$strip>>;
|
|
975
|
+
}, z.core.$strip>>;
|
|
976
|
+
source: z.ZodEnum<{
|
|
977
|
+
"built-in": "built-in";
|
|
978
|
+
file: "file";
|
|
979
|
+
}>;
|
|
980
|
+
path: z.ZodOptional<z.ZodString>;
|
|
981
|
+
}, z.core.$strip>>;
|
|
982
|
+
}, z.core.$strip>>;
|
|
983
|
+
}, z.core.$strip>]>;
|
|
984
|
+
export type CreateRunResponse = z.infer<typeof createRunResponseSchema>;
|
|
985
|
+
/** `POST /runs/:id/cancel` — genuinely a boolean: an already-settled run answers 200 + `false`. */
|
|
986
|
+
export declare const cancelResponseSchema: z.ZodObject<{
|
|
987
|
+
cancelled: z.ZodBoolean;
|
|
988
|
+
}, z.core.$strip>;
|
|
989
|
+
export type CancelResponse = z.infer<typeof cancelResponseSchema>;
|
|
990
|
+
/**
|
|
991
|
+
* `DELETE /runs/:id/auto-resume` (spec 2026-08-03-auto-resume-after-usage-limit) — the per-task
|
|
992
|
+
* off switch for a pending usage-limit resume, next to the workspace-wide setting.
|
|
993
|
+
*
|
|
994
|
+
* `z.literal(true)`, not a boolean, and that IS the shape: the route is idempotent, so a run with
|
|
995
|
+
* nothing pending answers 200 as well — "this task will not resume itself" is equally true either
|
|
996
|
+
* way. Only an unknown run refuses, with 404.
|
|
997
|
+
*/
|
|
998
|
+
export declare const cancelAutoResumeResponseSchema: z.ZodObject<{
|
|
999
|
+
cancelled: z.ZodLiteral<true>;
|
|
1000
|
+
}, z.core.$strip>;
|
|
1001
|
+
export type CancelAutoResumeResponse = z.infer<typeof cancelAutoResumeResponseSchema>;
|
|
1002
|
+
/** `POST /runs/archive-finished` — how many runs the sweep archived. */
|
|
1003
|
+
export declare const archiveFinishedResponseSchema: z.ZodObject<{
|
|
1004
|
+
archived: z.ZodNumber;
|
|
1005
|
+
}, z.core.$strip>;
|
|
1006
|
+
export type ArchiveFinishedResponse = z.infer<typeof archiveFinishedResponseSchema>;
|
|
1007
|
+
/** `POST /runs/read-all` — how many unread finished runs the sweep marked read. */
|
|
1008
|
+
export declare const markAllReadResponseSchema: z.ZodObject<{
|
|
1009
|
+
read: z.ZodNumber;
|
|
1010
|
+
}, z.core.$strip>;
|
|
1011
|
+
export type MarkAllReadResponse = z.infer<typeof markAllReadResponseSchema>;
|
|
1012
|
+
/** `DELETE /runs/:id` — an active run is a 409 and an unknown one a 404, so this only ever
|
|
1013
|
+
* reports success. */
|
|
1014
|
+
export declare const deleteRunResponseSchema: z.ZodObject<{
|
|
1015
|
+
deleted: z.ZodLiteral<true>;
|
|
1016
|
+
}, z.core.$strip>;
|
|
1017
|
+
export type DeleteRunResponse = z.infer<typeof deleteRunResponseSchema>;
|
|
1018
|
+
/** `POST /runs/:id/finish` — "no open session" is a 409. */
|
|
1019
|
+
export declare const finishResponseSchema: z.ZodObject<{
|
|
1020
|
+
finished: z.ZodLiteral<true>;
|
|
1021
|
+
}, z.core.$strip>;
|
|
1022
|
+
export type FinishResponse = z.infer<typeof finishResponseSchema>;
|
|
1023
|
+
/** `POST /runs/:id/continue` — a refusal to reopen is a 409 carrying the engine's reason. */
|
|
1024
|
+
export declare const continueResponseSchema: z.ZodObject<{
|
|
1025
|
+
continued: z.ZodLiteral<true>;
|
|
1026
|
+
}, z.core.$strip>;
|
|
1027
|
+
export type ContinueResponse = z.infer<typeof continueResponseSchema>;
|
|
1028
|
+
/**
|
|
1029
|
+
* `POST /runs/:id/pr` (201, spec 009) — the draft PR's URL; `dryRun` marks the XEZ_DRY_RUN fake
|
|
1030
|
+
* (no push, no gh). Failure is a 409 whose `ApiError` carries the `manual` merge command instead.
|
|
1031
|
+
*
|
|
1032
|
+
* `dryRun` is REQUIRED: `createDraftPr`'s success outcome always sets it (`forge/types.ts`), so
|
|
1033
|
+
* the key is always on the wire. The hand-written DTO had it optional.
|
|
1034
|
+
*/
|
|
1035
|
+
export declare const createPrResponseSchema: z.ZodObject<{
|
|
1036
|
+
url: z.ZodString;
|
|
1037
|
+
dryRun: z.ZodBoolean;
|
|
1038
|
+
}, z.core.$strip>;
|
|
1039
|
+
export type CreatePrResponse = z.infer<typeof createPrResponseSchema>;
|
|
1040
|
+
/**
|
|
1041
|
+
* `POST /runs/:id/messages` — one of three shapes (#472), by how far the run has got:
|
|
1042
|
+
* `delivered` (a live session took it), `queued` (still waiting for a slot, so it was stacked
|
|
1043
|
+
* onto the prompt and the stored entry rides along), `deferred` (mid-spawn, so it was buffered
|
|
1044
|
+
* and arrives as an ordinary follow-up turn once the session opens). Anything else is a 409.
|
|
1045
|
+
*
|
|
1046
|
+
* A union, not one object of optional flags: exactly one of the three keys is ever present, and
|
|
1047
|
+
* the flattened DTO shape admitted `{}`. Pre-#472 clients only ever saw `delivered`.
|
|
1048
|
+
*/
|
|
1049
|
+
export declare const messageResponseSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
1050
|
+
delivered: z.ZodLiteral<true>;
|
|
1051
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1052
|
+
queued: z.ZodLiteral<true>;
|
|
1053
|
+
message: z.ZodObject<{
|
|
1054
|
+
id: z.ZodString;
|
|
1055
|
+
text: z.ZodString;
|
|
1056
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1057
|
+
createdAt: z.ZodString;
|
|
1058
|
+
}, z.core.$strip>;
|
|
1059
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1060
|
+
deferred: z.ZodLiteral<true>;
|
|
1061
|
+
}, z.core.$strip>]>;
|
|
1062
|
+
export type MessageResponse = z.infer<typeof messageResponseSchema>;
|
|
1063
|
+
/** `PATCH /runs/:id/queued-messages/:msgId` (#472) — the replaced entry. */
|
|
1064
|
+
export declare const editQueuedMessageResponseSchema: z.ZodObject<{
|
|
1065
|
+
message: z.ZodObject<{
|
|
1066
|
+
id: z.ZodString;
|
|
1067
|
+
text: z.ZodString;
|
|
1068
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1069
|
+
createdAt: z.ZodString;
|
|
1070
|
+
}, z.core.$strip>;
|
|
1071
|
+
}, z.core.$strip>;
|
|
1072
|
+
export type EditQueuedMessageResponse = z.infer<typeof editQueuedMessageResponseSchema>;
|
|
1073
|
+
/** `DELETE /runs/:id/queued-messages/:msgId` (#472) — `409 run already started` otherwise. */
|
|
1074
|
+
export declare const removeQueuedMessageResponseSchema: z.ZodObject<{
|
|
1075
|
+
removed: z.ZodLiteral<true>;
|
|
1076
|
+
}, z.core.$strip>;
|
|
1077
|
+
export type RemoveQueuedMessageResponse = z.infer<typeof removeQueuedMessageResponseSchema>;
|
|
1078
|
+
/**
|
|
1079
|
+
* `POST /runs/:id/open-in-cli` — a terminal was spawned with `command` running in it. With no
|
|
1080
|
+
* terminal emulator the server answers 409 and the `ApiError` carries the full `cd … && <command>`
|
|
1081
|
+
* for the clipboard fallback.
|
|
1082
|
+
*/
|
|
1083
|
+
export declare const openInCliResponseSchema: z.ZodObject<{
|
|
1084
|
+
opened: z.ZodLiteral<true>;
|
|
1085
|
+
command: z.ZodString;
|
|
1086
|
+
}, z.core.$strip>;
|
|
1087
|
+
export type OpenInCliResponse = z.infer<typeof openInCliResponseSchema>;
|
|
1088
|
+
/** `POST /runs/:id/remove-worktree` — per-row delete in the worktrees panel (#483). */
|
|
1089
|
+
export declare const removeWorktreeResponseSchema: z.ZodObject<{
|
|
1090
|
+
removed: z.ZodLiteral<true>;
|
|
1091
|
+
}, z.core.$strip>;
|
|
1092
|
+
export type RemoveWorktreeResponse = z.infer<typeof removeWorktreeResponseSchema>;
|
|
1093
|
+
/** `POST /runs/:id/git/commit` — `git add -A && git commit` in the run's worktree. */
|
|
1094
|
+
export declare const gitCommitResponseSchema: z.ZodObject<{
|
|
1095
|
+
committed: z.ZodLiteral<true>;
|
|
1096
|
+
sha: z.ZodString;
|
|
1097
|
+
}, z.core.$strip>;
|
|
1098
|
+
export type GitCommitResponse = z.infer<typeof gitCommitResponseSchema>;
|
|
1099
|
+
/** `POST /runs/:id/git/push` — push the worktree's branch, setting upstream if it has none. */
|
|
1100
|
+
export declare const gitPushResponseSchema: z.ZodObject<{
|
|
1101
|
+
pushed: z.ZodLiteral<true>;
|
|
1102
|
+
branch: z.ZodString;
|
|
1103
|
+
remote: z.ZodString;
|
|
1104
|
+
upstreamSet: z.ZodBoolean;
|
|
1105
|
+
}, z.core.$strip>;
|
|
1106
|
+
export type GitPushResponse = z.infer<typeof gitPushResponseSchema>;
|
|
1107
|
+
/** A commit a run made on its worktree branch. */
|
|
1108
|
+
export declare const runCommitSchema: z.ZodObject<{
|
|
1109
|
+
sha: z.ZodString;
|
|
1110
|
+
subject: z.ZodString;
|
|
1111
|
+
author: z.ZodString;
|
|
1112
|
+
when: z.ZodString;
|
|
1113
|
+
}, z.core.$strip>;
|
|
1114
|
+
export type RunCommit = z.infer<typeof runCommitSchema>;
|
|
1115
|
+
/** `GET /runs/:id/commits` — `<base>..HEAD` on the worktree branch, newest first. */
|
|
1116
|
+
export declare const runCommitsResponseSchema: z.ZodObject<{
|
|
1117
|
+
commits: z.ZodArray<z.ZodObject<{
|
|
1118
|
+
sha: z.ZodString;
|
|
1119
|
+
subject: z.ZodString;
|
|
1120
|
+
author: z.ZodString;
|
|
1121
|
+
when: z.ZodString;
|
|
1122
|
+
}, z.core.$strip>>;
|
|
1123
|
+
}, z.core.$strip>;
|
|
1124
|
+
export type RunCommitsResponse = z.infer<typeof runCommitsResponseSchema>;
|
|
1125
|
+
/**
|
|
1126
|
+
* One variant column of the compare view.
|
|
1127
|
+
*
|
|
1128
|
+
* CAREFUL: `diffStat` here is the raw `git diff --stat` TEXT the server runs in the variant's
|
|
1129
|
+
* worktree — a different thing from the numeric `RunRecord.diffStat`. `''` when the worktree
|
|
1130
|
+
* is gone.
|
|
1131
|
+
*/
|
|
1132
|
+
export declare const groupVariantSchema: z.ZodObject<{
|
|
1133
|
+
id: z.ZodString;
|
|
1134
|
+
variant: z.ZodString;
|
|
1135
|
+
title: z.ZodString;
|
|
1136
|
+
status: z.ZodEnum<{
|
|
1137
|
+
cancelled: "cancelled";
|
|
1138
|
+
done: "done";
|
|
1139
|
+
failed: "failed";
|
|
1140
|
+
queued: "queued";
|
|
1141
|
+
review: "review";
|
|
1142
|
+
running: "running";
|
|
1143
|
+
waiting: "waiting";
|
|
1144
|
+
}>;
|
|
1145
|
+
archived: z.ZodBoolean;
|
|
1146
|
+
tokensUsed: z.ZodNumber;
|
|
1147
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1148
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1149
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
1150
|
+
diffStat: z.ZodString;
|
|
1151
|
+
handoffExcerpt: z.ZodString;
|
|
1152
|
+
}, z.core.$strip>;
|
|
1153
|
+
export type GroupVariant = z.infer<typeof groupVariantSchema>;
|
|
1154
|
+
/** `GET /groups/:groupId` — every run sharing a groupId, side by side. */
|
|
1155
|
+
export declare const groupResponseSchema: z.ZodObject<{
|
|
1156
|
+
groupId: z.ZodString;
|
|
1157
|
+
runs: z.ZodArray<z.ZodObject<{
|
|
1158
|
+
id: z.ZodString;
|
|
1159
|
+
variant: z.ZodString;
|
|
1160
|
+
title: z.ZodString;
|
|
1161
|
+
status: z.ZodEnum<{
|
|
1162
|
+
cancelled: "cancelled";
|
|
1163
|
+
done: "done";
|
|
1164
|
+
failed: "failed";
|
|
1165
|
+
queued: "queued";
|
|
1166
|
+
review: "review";
|
|
1167
|
+
running: "running";
|
|
1168
|
+
waiting: "waiting";
|
|
1169
|
+
}>;
|
|
1170
|
+
archived: z.ZodBoolean;
|
|
1171
|
+
tokensUsed: z.ZodNumber;
|
|
1172
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1173
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1174
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
1175
|
+
diffStat: z.ZodString;
|
|
1176
|
+
handoffExcerpt: z.ZodString;
|
|
1177
|
+
}, z.core.$strip>>;
|
|
1178
|
+
}, z.core.$strip>;
|
|
1179
|
+
export type GroupResponse = z.infer<typeof groupResponseSchema>;
|
|
1180
|
+
/**
|
|
1181
|
+
* `POST /groups/:groupId/pick` — the winner (parked at `review` when it has a diff); the losers
|
|
1182
|
+
* were cancelled if alive, archived, and their worktrees + branches removed.
|
|
1183
|
+
*
|
|
1184
|
+
* `winner` is OPTIONAL because that is what the wire says: `store.getRun(id)` can miss, and
|
|
1185
|
+
* `JSON.stringify` drops a key whose value is `undefined`. The handler spreads the key in
|
|
1186
|
+
* conditionally (`server.ts`, the `/groups/:groupId/pick` route) so its own type says the same
|
|
1187
|
+
* thing — the two-way check in `contract-parity.workflows.test.ts` is what pins that.
|
|
1188
|
+
*/
|
|
1189
|
+
export declare const pickVariantResponseSchema: z.ZodObject<{
|
|
1190
|
+
winner: z.ZodOptional<z.ZodObject<{
|
|
1191
|
+
id: z.ZodString;
|
|
1192
|
+
title: z.ZodString;
|
|
1193
|
+
titleSummary: z.ZodOptional<z.ZodString>;
|
|
1194
|
+
diffStat: z.ZodOptional<z.ZodObject<{
|
|
1195
|
+
adds: z.ZodNumber;
|
|
1196
|
+
dels: z.ZodNumber;
|
|
1197
|
+
files: z.ZodNumber;
|
|
1198
|
+
repointed: z.ZodOptional<z.ZodBoolean>;
|
|
1199
|
+
}, z.core.$strip>>;
|
|
1200
|
+
workflow: z.ZodString;
|
|
1201
|
+
task: z.ZodString;
|
|
1202
|
+
queuedMessages: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1203
|
+
id: z.ZodString;
|
|
1204
|
+
text: z.ZodString;
|
|
1205
|
+
images: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1206
|
+
createdAt: z.ZodString;
|
|
1207
|
+
}, z.core.$strip>>>;
|
|
1208
|
+
taskImages: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1209
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1210
|
+
modelIdentity: z.ZodOptional<z.ZodString>;
|
|
1211
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
1212
|
+
claude: "claude";
|
|
1213
|
+
codex: "codex";
|
|
1214
|
+
opencode: "opencode";
|
|
1215
|
+
pi: "pi";
|
|
1216
|
+
}>>;
|
|
1217
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
1218
|
+
systemPrompt: z.ZodOptional<z.ZodString>;
|
|
1219
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
1220
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
1221
|
+
automation: z.ZodOptional<z.ZodObject<{
|
|
1222
|
+
automationId: z.ZodString;
|
|
1223
|
+
automationRevision: z.ZodNumber;
|
|
1224
|
+
receiptId: z.ZodString;
|
|
1225
|
+
event: z.ZodString;
|
|
1226
|
+
githubUrl: z.ZodString;
|
|
1227
|
+
}, z.core.$strip>>;
|
|
1228
|
+
status: z.ZodEnum<{
|
|
1229
|
+
cancelled: "cancelled";
|
|
1230
|
+
done: "done";
|
|
1231
|
+
failed: "failed";
|
|
1232
|
+
queued: "queued";
|
|
1233
|
+
review: "review";
|
|
1234
|
+
running: "running";
|
|
1235
|
+
waiting: "waiting";
|
|
1236
|
+
}>;
|
|
1237
|
+
activity: z.ZodOptional<z.ZodEnum<{
|
|
1238
|
+
monitoring: "monitoring";
|
|
1239
|
+
}>>;
|
|
1240
|
+
monitoringWakeAt: z.ZodOptional<z.ZodString>;
|
|
1241
|
+
monitoringWakeCapReached: z.ZodOptional<z.ZodBoolean>;
|
|
1242
|
+
autoResumeAt: z.ZodOptional<z.ZodString>;
|
|
1243
|
+
autoResumeAttempts: z.ZodOptional<z.ZodNumber>;
|
|
1244
|
+
createdAt: z.ZodString;
|
|
1245
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
1246
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
1247
|
+
tokensUsed: z.ZodNumber;
|
|
1248
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1249
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1250
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
1251
|
+
pullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
1252
|
+
referencedPullRequestUrl: z.ZodOptional<z.ZodString>;
|
|
1253
|
+
prNumber: z.ZodOptional<z.ZodNumber>;
|
|
1254
|
+
issueNumber: z.ZodOptional<z.ZodNumber>;
|
|
1255
|
+
referencedIssueNumberSeeded: z.ZodOptional<z.ZodBoolean>;
|
|
1256
|
+
titleOrigin: z.ZodOptional<z.ZodEnum<{
|
|
1257
|
+
auto: "auto";
|
|
1258
|
+
marker: "marker";
|
|
1259
|
+
user: "user";
|
|
1260
|
+
}>>;
|
|
1261
|
+
markerRefs: z.ZodOptional<z.ZodObject<{
|
|
1262
|
+
pr: z.ZodOptional<z.ZodNumber>;
|
|
1263
|
+
issue: z.ZodOptional<z.ZodNumber>;
|
|
1264
|
+
}, z.core.$strip>>;
|
|
1265
|
+
referencedPrCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1266
|
+
referencedIssueUrl: z.ZodOptional<z.ZodString>;
|
|
1267
|
+
referencedIssueCandidates: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1268
|
+
worktree: z.ZodOptional<z.ZodLiteral<false>>;
|
|
1269
|
+
worktreePath: z.ZodOptional<z.ZodString>;
|
|
1270
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
1271
|
+
baseBranch: z.ZodOptional<z.ZodString>;
|
|
1272
|
+
worktreeReclaimedAt: z.ZodOptional<z.ZodString>;
|
|
1273
|
+
groupId: z.ZodOptional<z.ZodString>;
|
|
1274
|
+
variant: z.ZodOptional<z.ZodString>;
|
|
1275
|
+
peakRssBytes: z.ZodOptional<z.ZodNumber>;
|
|
1276
|
+
peakProcCount: z.ZodOptional<z.ZodNumber>;
|
|
1277
|
+
archived: z.ZodBoolean;
|
|
1278
|
+
archivedAt: z.ZodOptional<z.ZodString>;
|
|
1279
|
+
pinned: z.ZodOptional<z.ZodBoolean>;
|
|
1280
|
+
pinnedAt: z.ZodOptional<z.ZodString>;
|
|
1281
|
+
seenAt: z.ZodOptional<z.ZodString>;
|
|
1282
|
+
currentStepId: z.ZodOptional<z.ZodString>;
|
|
1283
|
+
error: z.ZodOptional<z.ZodString>;
|
|
1284
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
1285
|
+
id: z.ZodString;
|
|
1286
|
+
name: z.ZodString;
|
|
1287
|
+
kind: z.ZodEnum<{
|
|
1288
|
+
agent: "agent";
|
|
1289
|
+
check: "check";
|
|
1290
|
+
}>;
|
|
1291
|
+
status: z.ZodEnum<{
|
|
1292
|
+
cancelled: "cancelled";
|
|
1293
|
+
done: "done";
|
|
1294
|
+
failed: "failed";
|
|
1295
|
+
pending: "pending";
|
|
1296
|
+
review: "review";
|
|
1297
|
+
running: "running";
|
|
1298
|
+
skipped: "skipped";
|
|
1299
|
+
waiting: "waiting";
|
|
1300
|
+
}>;
|
|
1301
|
+
iterations: z.ZodNumber;
|
|
1302
|
+
tokensUsed: z.ZodNumber;
|
|
1303
|
+
inputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1304
|
+
outputTokens: z.ZodOptional<z.ZodNumber>;
|
|
1305
|
+
usageInvocationsStarted: z.ZodOptional<z.ZodNumber>;
|
|
1306
|
+
usageInvocationsObserved: z.ZodOptional<z.ZodNumber>;
|
|
1307
|
+
usageTurnsStarted: z.ZodOptional<z.ZodNumber>;
|
|
1308
|
+
usageTurnsRecorded: z.ZodOptional<z.ZodNumber>;
|
|
1309
|
+
usageInvocationEpoch: z.ZodOptional<z.ZodNumber>;
|
|
1310
|
+
startedAt: z.ZodOptional<z.ZodString>;
|
|
1311
|
+
finishedAt: z.ZodOptional<z.ZodString>;
|
|
1312
|
+
error: z.ZodOptional<z.ZodString>;
|
|
1313
|
+
sessionId: z.ZodOptional<z.ZodString>;
|
|
1314
|
+
backend: z.ZodOptional<z.ZodEnum<{
|
|
1315
|
+
claude: "claude";
|
|
1316
|
+
codex: "codex";
|
|
1317
|
+
opencode: "opencode";
|
|
1318
|
+
pi: "pi";
|
|
1319
|
+
}>>;
|
|
1320
|
+
profileId: z.ZodOptional<z.ZodString>;
|
|
1321
|
+
costUsd: z.ZodOptional<z.ZodNumber>;
|
|
1322
|
+
}, z.core.$strip>>;
|
|
1323
|
+
workflowDef: z.ZodOptional<z.ZodObject<{
|
|
1324
|
+
name: z.ZodString;
|
|
1325
|
+
description: z.ZodOptional<z.ZodString>;
|
|
1326
|
+
steps: z.ZodArray<z.ZodObject<{
|
|
1327
|
+
id: z.ZodString;
|
|
1328
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1329
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
1330
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
1331
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1332
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
1333
|
+
claude: "claude";
|
|
1334
|
+
codex: "codex";
|
|
1335
|
+
opencode: "opencode";
|
|
1336
|
+
pi: "pi";
|
|
1337
|
+
}>>;
|
|
1338
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1339
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1340
|
+
command: z.ZodOptional<z.ZodString>;
|
|
1341
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
1342
|
+
retry: z.ZodString;
|
|
1343
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
1344
|
+
}, z.core.$strip>>;
|
|
1345
|
+
}, z.core.$strip>>;
|
|
1346
|
+
source: z.ZodEnum<{
|
|
1347
|
+
"built-in": "built-in";
|
|
1348
|
+
file: "file";
|
|
1349
|
+
}>;
|
|
1350
|
+
path: z.ZodOptional<z.ZodString>;
|
|
1351
|
+
}, z.core.$strip>>;
|
|
1352
|
+
}, z.core.$strip>>;
|
|
1353
|
+
}, z.core.$strip>;
|
|
1354
|
+
export type PickVariantResponse = z.infer<typeof pickVariantResponseSchema>;
|
|
1355
|
+
/**
|
|
1356
|
+
* Non-image attachment types the composer may send (#950). Deliberately an allowlist and
|
|
1357
|
+
* deliberately short: xezar serves these files back from the cockpit's own origin, so every entry
|
|
1358
|
+
* here is one more thing that must be safe to hand a browser. `image/*` stays a regex — narrowing
|
|
1359
|
+
* what the route has always accepted would be the breaking half of this change.
|
|
1360
|
+
*
|
|
1361
|
+
* `text/x-markdown` is the spelling some browsers still report for a `.md`.
|
|
1362
|
+
*/
|
|
1363
|
+
export declare const FILE_ATTACHMENT_MEDIA_TYPES: readonly ['text/plain', 'text/markdown', 'text/x-markdown', 'application/pdf'];
|
|
1364
|
+
/** Does this media type travel as an inline image block the model can look at? */
|
|
1365
|
+
export declare function isImageMediaType(mediaType: string): boolean;
|
|
1366
|
+
/** Is this something the composer may attach at all — an image, or one of the file types above? */
|
|
1367
|
+
export declare function isAttachmentMediaType(mediaType: string): boolean;
|
|
1368
|
+
/**
|
|
1369
|
+
* The on-disk extension for an attachment, derived from its media type ALONE — the user's own
|
|
1370
|
+
* filename never reaches the wire, and therefore never reaches a path. `img` is the pre-existing
|
|
1371
|
+
* catch-all for an image type xezar does not name (an SVG, a BMP), kept so those files land where
|
|
1372
|
+
* they always did.
|
|
1373
|
+
*/
|
|
1374
|
+
export declare function attachmentExtension(mediaType: string): string;
|
|
1375
|
+
/**
|
|
1376
|
+
* Does a persisted attachment name (`pasted-3.pdf`, `screenshot-1.png`) refer to an image?
|
|
1377
|
+
*
|
|
1378
|
+
* The one predicate every reader branches on — the engine deciding whether to re-encode a file as
|
|
1379
|
+
* an image block, and the cockpit deciding between a thumbnail and a named chip. Branch on the
|
|
1380
|
+
* NAME, never on the list an entry came from: images and files share one list and one numbering
|
|
1381
|
+
* space on disk, and that is what keeps the orphan sweep, the restart re-read and the per-stack
|
|
1382
|
+
* cap on a single code path.
|
|
1383
|
+
*/
|
|
1384
|
+
export declare function isImageAttachmentName(name: string): boolean;
|
|
1385
|
+
/**
|
|
1386
|
+
* One inline attachment, base64 — ≤4 per request, ~5 MB each once decoded.
|
|
1387
|
+
*
|
|
1388
|
+
* An image rides along as a block the model can view; a file (#950) is written to the run's
|
|
1389
|
+
* attachment folder and reaches the agent as a PATH only, which is the form its file tools want,
|
|
1390
|
+
* the only form that survives the codex/opencode backends (they drop image blocks before the
|
|
1391
|
+
* model sees them), and the one that keeps a multi-megabyte PDF out of the prompt bounds.
|
|
1392
|
+
*/
|
|
1393
|
+
export declare const attachmentInputSchema: z.ZodObject<{
|
|
1394
|
+
mediaType: z.ZodString;
|
|
1395
|
+
data: z.ZodString;
|
|
1396
|
+
}, z.core.$strip>;
|
|
1397
|
+
export type AttachmentInput = z.input<typeof attachmentInputSchema>;
|
|
1398
|
+
/** @deprecated Attachments are no longer images only — use `attachmentInputSchema`. Kept because
|
|
1399
|
+
* the `images` key it validates is the wire contract and did not change name. */
|
|
1400
|
+
export declare const imageInputSchema: z.ZodObject<{
|
|
1401
|
+
mediaType: z.ZodString;
|
|
1402
|
+
data: z.ZodString;
|
|
1403
|
+
}, z.core.$strip>;
|
|
1404
|
+
export type ImageInput = AttachmentInput;
|
|
1405
|
+
/**
|
|
1406
|
+
* The KEYS of `POST /runs`' body, before the XOR refinement that `createRunInputSchema` adds.
|
|
1407
|
+
*
|
|
1408
|
+
* Split out for one reason: `./automations.ts` builds an automation's task on top of this shape
|
|
1409
|
+
* (a task IS a run-creation body minus the three keys an automation supplies itself), and zod
|
|
1410
|
+
* refuses `.omit()` on a schema that carries refinements. Validate with `createRunInputSchema`
|
|
1411
|
+
* below — this half accepts a body naming both `workflow` and `steps`, which the server does not.
|
|
1412
|
+
*/
|
|
1413
|
+
export declare const createRunInputBaseSchema: z.ZodObject<{
|
|
1414
|
+
workflow: z.ZodOptional<z.ZodString>;
|
|
1415
|
+
steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1416
|
+
id: z.ZodString;
|
|
1417
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1418
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
1419
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
1420
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1421
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
1422
|
+
claude: "claude";
|
|
1423
|
+
codex: "codex";
|
|
1424
|
+
opencode: "opencode";
|
|
1425
|
+
pi: "pi";
|
|
1426
|
+
}>>;
|
|
1427
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1428
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1429
|
+
command: z.ZodOptional<z.ZodString>;
|
|
1430
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
1431
|
+
retry: z.ZodString;
|
|
1432
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
1433
|
+
}, z.core.$strip>>;
|
|
1434
|
+
}, z.core.$strip>>>;
|
|
1435
|
+
task: z.ZodString;
|
|
1436
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1437
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
1438
|
+
claude: "claude";
|
|
1439
|
+
codex: "codex";
|
|
1440
|
+
opencode: "opencode";
|
|
1441
|
+
pi: "pi";
|
|
1442
|
+
}>>;
|
|
1443
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
1444
|
+
variants: z.ZodOptional<z.ZodNumber>;
|
|
1445
|
+
worktree: z.ZodOptional<z.ZodBoolean>;
|
|
1446
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
1447
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
1448
|
+
systemPrompt: z.ZodPipe<z.ZodOptional<z.ZodString>, z.ZodTransform<string | undefined, string | undefined>>;
|
|
1449
|
+
images: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1450
|
+
mediaType: z.ZodString;
|
|
1451
|
+
data: z.ZodString;
|
|
1452
|
+
}, z.core.$strip>>>;
|
|
1453
|
+
todoId: z.ZodOptional<z.ZodString>;
|
|
1454
|
+
}, z.core.$strip>;
|
|
1455
|
+
/**
|
|
1456
|
+
* `POST /runs`. Exactly one of `workflow` / `steps` — the server rejects both or neither.
|
|
1457
|
+
*
|
|
1458
|
+
* Every bound here is the server's own (#429): an unbounded body must never reach a spawned
|
|
1459
|
+
* process, so a client that validates before sending gets the same answer the route would give.
|
|
1460
|
+
*/
|
|
1461
|
+
export declare const createRunInputSchema: z.ZodObject<{
|
|
1462
|
+
workflow: z.ZodOptional<z.ZodString>;
|
|
1463
|
+
steps: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1464
|
+
id: z.ZodString;
|
|
1465
|
+
name: z.ZodOptional<z.ZodString>;
|
|
1466
|
+
prompt: z.ZodOptional<z.ZodString>;
|
|
1467
|
+
skill: z.ZodOptional<z.ZodString>;
|
|
1468
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1469
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
1470
|
+
claude: "claude";
|
|
1471
|
+
codex: "codex";
|
|
1472
|
+
opencode: "opencode";
|
|
1473
|
+
pi: "pi";
|
|
1474
|
+
}>>;
|
|
1475
|
+
allowedTools: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1476
|
+
bashAllowlist: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
1477
|
+
command: z.ZodOptional<z.ZodString>;
|
|
1478
|
+
onFail: z.ZodOptional<z.ZodObject<{
|
|
1479
|
+
retry: z.ZodString;
|
|
1480
|
+
max: z.ZodDefault<z.ZodNumber>;
|
|
1481
|
+
}, z.core.$strip>>;
|
|
1482
|
+
}, z.core.$strip>>>;
|
|
1483
|
+
task: z.ZodString;
|
|
1484
|
+
model: z.ZodOptional<z.ZodString>;
|
|
1485
|
+
runner: z.ZodOptional<z.ZodEnum<{
|
|
1486
|
+
claude: "claude";
|
|
1487
|
+
codex: "codex";
|
|
1488
|
+
opencode: "opencode";
|
|
1489
|
+
pi: "pi";
|
|
1490
|
+
}>>;
|
|
1491
|
+
agentProfile: z.ZodOptional<z.ZodString>;
|
|
1492
|
+
variants: z.ZodOptional<z.ZodNumber>;
|
|
1493
|
+
worktree: z.ZodOptional<z.ZodBoolean>;
|
|
1494
|
+
autonomous: z.ZodOptional<z.ZodBoolean>;
|
|
1495
|
+
generateFollowups: z.ZodOptional<z.ZodBoolean>;
|
|
1496
|
+
systemPrompt: z.ZodPipe<z.ZodOptional<z.ZodString>, z.ZodTransform<string | undefined, string | undefined>>;
|
|
1497
|
+
images: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
1498
|
+
mediaType: z.ZodString;
|
|
1499
|
+
data: z.ZodString;
|
|
1500
|
+
}, z.core.$strip>>>;
|
|
1501
|
+
todoId: z.ZodOptional<z.ZodString>;
|
|
1502
|
+
}, z.core.$strip>;
|
|
1503
|
+
export type CreateRunInput = z.input<typeof createRunInputSchema>;
|
|
1504
|
+
/**
|
|
1505
|
+
* `POST /runs/:id/messages` — text and/or pasted attachments for a live session. Both keys have
|
|
1506
|
+
* server-side defaults, so an omitted `text` is `''` and an omitted `images` is `[]`; the refine
|
|
1507
|
+
* is what rejects a message that is empty in both.
|
|
1508
|
+
*/
|
|
1509
|
+
export declare const messageInputSchema: z.ZodObject<{
|
|
1510
|
+
text: z.ZodDefault<z.ZodString>;
|
|
1511
|
+
images: z.ZodDefault<z.ZodArray<z.ZodObject<{
|
|
1512
|
+
mediaType: z.ZodString;
|
|
1513
|
+
data: z.ZodString;
|
|
1514
|
+
}, z.core.$strip>>>;
|
|
1515
|
+
}, z.core.$strip>;
|
|
1516
|
+
export type MessageInput = z.input<typeof messageInputSchema>;
|
|
1517
|
+
/**
|
|
1518
|
+
* `PATCH /runs/:id` (#389). `title` is trimmed server-side, 1–300 chars, and the edit sets both
|
|
1519
|
+
* `title` and `titleSummary` so it wins over any auto-summary. `task` (#472) is the initial
|
|
1520
|
+
* prompt, editable only while the run is still queued — any other status answers
|
|
1521
|
+
* `409 run already started`, and the folded total across the task and its stack bounds it again.
|
|
1522
|
+
*/
|
|
1523
|
+
export declare const patchRunInputSchema: z.ZodObject<{
|
|
1524
|
+
title: z.ZodOptional<z.ZodString>;
|
|
1525
|
+
task: z.ZodOptional<z.ZodString>;
|
|
1526
|
+
}, z.core.$strip>;
|
|
1527
|
+
export type PatchRunInput = z.input<typeof patchRunInputSchema>;
|