eve 0.67.0 → 0.67.2
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/CHANGELOG.md +19 -0
- package/dist/src/channel/channel-address.d.ts +2 -2
- package/dist/src/channel/compiled-channel.d.ts +3 -2
- package/dist/src/channel/cross-channel-receive.d.ts +1 -18
- package/dist/src/channel/cross-channel-receive.js +1 -1
- package/dist/src/channel/forwarded-principal.d.ts +3 -2
- package/dist/src/channel/resolve-text.d.ts +2 -1
- package/dist/src/channel/schedule-auth.d.ts +0 -2
- package/dist/src/channel/schedule-auth.js +1 -1
- package/dist/src/channel/schedule.d.ts +2 -2
- package/dist/src/channel/session-callback.d.ts +2 -1
- package/dist/src/channel/types.d.ts +0 -7
- package/dist/src/chunks/{use-eve-agent-OCHP4s0z.js → use-eve-agent-D4HVZBjn.js} +1 -1
- package/dist/src/chunks/{use-eve-agent-DzdyI97Z.js → use-eve-agent-DXcE_8Ja.js} +1 -1
- package/dist/src/cli/acp/command.d.ts +2 -1
- package/dist/src/cli/agent-command.d.ts +2 -1
- package/dist/src/cli/agent-detection.d.ts +0 -1
- package/dist/src/cli/agent-detection.js +1 -1
- package/dist/src/cli/application-command.d.ts +2 -1
- package/dist/src/cli/application-root.d.ts +3 -8
- package/dist/src/cli/application-root.js +1 -1
- package/dist/src/cli/commands/agent-instructions.d.ts +0 -4
- package/dist/src/cli/commands/agent-instructions.js +3 -3
- package/dist/src/cli/commands/extension-init.js +1 -1
- package/dist/src/cli/commands/init-agent-workspace.js +1 -1
- package/dist/src/cli/commands/init-project.d.ts +0 -1
- package/dist/src/cli/commands/init-project.js +1 -1
- package/dist/src/cli/commands/init-target.d.ts +1 -1
- package/dist/src/cli/commands/init-telemetry.d.ts +2 -1
- package/dist/src/cli/commands/init.js +1 -1
- package/dist/src/cli/commands/registry-declared-setups.d.ts +2 -1
- package/dist/src/cli/commands/registry-install-transaction.d.ts +0 -13
- package/dist/src/cli/commands/registry-install-transaction.js +1 -1
- package/dist/src/cli/commands/registry-pnpm-build-policy-flow.d.ts +1 -1
- package/dist/src/cli/commands/registry-presentation.d.ts +0 -1
- package/dist/src/cli/commands/registry-presentation.js +1 -1
- package/dist/src/cli/commands/registry-project.d.ts +2 -1
- package/dist/src/cli/commands/registry.d.ts +0 -4
- package/dist/src/cli/commands/registry.js +1 -1
- package/dist/src/cli/commands/setup-headless.d.ts +2 -1
- package/dist/src/cli/commands/vercel-non-interactive.d.ts +2 -1
- package/dist/src/cli/dev/diagnostic-dump.d.ts +0 -2
- package/dist/src/cli/dev/diagnostic-dump.js +1 -1
- package/dist/src/cli/dev/diagnostic-sink.d.ts +3 -2
- package/dist/src/cli/dev/environment.js +1 -1
- package/dist/src/cli/dev/tui/agent-header.d.ts +2 -1
- package/dist/src/cli/dev/tui/argument-typeahead.d.ts +2 -1
- package/dist/src/cli/dev/tui/dev-rebuild-status.d.ts +2 -1
- package/dist/src/cli/dev/tui/diagnostic-presentation.d.ts +2 -1
- package/dist/src/cli/dev/tui/errors.d.ts +2 -7
- package/dist/src/cli/dev/tui/errors.js +1 -1
- package/dist/src/cli/dev/tui/flow-drawer.d.ts +2 -1
- package/dist/src/cli/dev/tui/line-editor.d.ts +1 -1
- package/dist/src/cli/dev/tui/mcp-connection-status.d.ts +2 -1
- package/dist/src/cli/dev/tui/message-queue.d.ts +4 -3
- package/dist/src/cli/dev/tui/prompt-command-handler.d.ts +2 -1
- package/dist/src/cli/dev/tui/provider-picker.d.ts +3 -2
- package/dist/src/cli/dev/tui/question-panel.d.ts +2 -1
- package/dist/src/cli/dev/tui/registry-result-message.d.ts +3 -4
- package/dist/src/cli/dev/tui/registry-result-message.js +1 -1
- package/dist/src/cli/dev/tui/remote-connection-probe.d.ts +3 -2
- package/dist/src/cli/dev/tui/runner.d.ts +0 -1
- package/dist/src/cli/dev/tui/runner.js +1 -1
- package/dist/src/cli/dev/tui/setup-panel.d.ts +2 -2
- package/dist/src/cli/dev/tui/setup-selection-input.d.ts +2 -2
- package/dist/src/cli/dev/tui/status-line.d.ts +2 -1
- package/dist/src/cli/dev/tui/stream-format.d.ts +3 -2
- package/dist/src/cli/dev/tui/terminal-renderer.d.ts +3 -2
- package/dist/src/cli/dev/tui/theme.d.ts +1 -1
- package/dist/src/cli/dev/tui/tool-block-groups.d.ts +3 -2
- package/dist/src/cli/dev/tui/tool-presentation.d.ts +2 -1
- package/dist/src/cli/dev/tui/traces/trace-content.d.ts +0 -9
- package/dist/src/cli/dev/tui/traces/trace-content.js +1 -1
- package/dist/src/cli/dev/tui/traces/trace-view.d.ts +3 -2
- package/dist/src/cli/dev/tui/traces/trace-viewer-session.d.ts +2 -1
- package/dist/src/cli/dev/tui/traces/trace-viewer-state.d.ts +2 -3
- package/dist/src/cli/dev/tui/traces/trace-viewer-state.js +1 -1
- package/dist/src/cli/dev/ui-options.d.ts +3 -2
- package/dist/src/cli/dev/url-target.d.ts +2 -1
- package/dist/src/cli/invoke/command.d.ts +0 -11
- package/dist/src/cli/invoke/command.js +1 -1
- package/dist/src/cli/invoke/result.d.ts +1 -1
- package/dist/src/cli/telemetry/index.d.ts +0 -6
- package/dist/src/cli/telemetry/preference.d.ts +2 -1
- package/dist/src/cli/ui/alt-screen.d.ts +3 -2
- package/dist/src/cli/ui/live-region.d.ts +3 -2
- package/dist/src/cli/ui/output.d.ts +1 -16
- package/dist/src/cli/ui/output.js +2 -5
- package/dist/src/client/eve-agent-store-helpers.d.ts +0 -1
- package/dist/src/client/eve-agent-store-helpers.js +1 -1
- package/dist/src/client/eve-agent-store.js +1 -1
- package/dist/src/client/message-action-parts.d.ts +2 -1
- package/dist/src/client/session-utils.d.ts +3 -2
- package/dist/src/compiled/.vendor-stamp.json +6 -6
- package/dist/src/compiled/@workflow/core/index.js +2 -2
- package/dist/src/compiled/@workflow/core/private.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime/constants.d.ts +4 -3
- package/dist/src/compiled/@workflow/core/runtime/helpers.d.ts +23 -0
- package/dist/src/compiled/@workflow/core/runtime/helpers.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime/hook-wake.d.ts +69 -36
- package/dist/src/compiled/@workflow/core/runtime/lifecycle-hooks.d.ts +25 -22
- package/dist/src/compiled/@workflow/core/runtime/run-spec-version.d.ts +16 -0
- package/dist/src/compiled/@workflow/core/runtime/start.d.ts +59 -1
- package/dist/src/compiled/@workflow/core/runtime/step-latency.d.ts +3 -2
- package/dist/src/compiled/@workflow/core/runtime/suspension-handler.d.ts +34 -12
- package/dist/src/compiled/@workflow/core/runtime.js +4 -4
- package/dist/src/compiled/@workflow/core/serialization.d.ts +7 -2
- package/dist/src/compiled/@workflow/core/serialization.js +1 -1
- package/dist/src/compiled/@workflow/core/telemetry/semantic-conventions.d.ts +29 -0
- package/dist/src/compiled/@workflow/core/types.d.ts +1 -0
- package/dist/src/compiled/@workflow/core/version.d.ts +1 -1
- package/dist/src/compiled/@workflow/core/workflow.js +1 -1
- package/dist/src/compiled/@workflow/errors/index.d.ts +13 -0
- package/dist/src/compiled/@workflow/errors/index.js +1 -1
- package/dist/src/compiled/@workflow/world/events.d.ts +14 -4
- package/dist/src/compiled/@workflow/world/index.d.ts +2 -2
- package/dist/src/compiled/@workflow/world/interfaces.d.ts +2 -1
- package/dist/src/compiled/@workflow/world/shared.d.ts +24 -0
- package/dist/src/compiled/@workflow/world/spec-version.d.ts +23 -0
- package/dist/src/compiled/@workflow/world-local/index.js +5 -5
- package/dist/src/compiled/@workflow/world-vercel/index.js +16 -16
- package/dist/src/compiled/_chunks/workflow/{attribute-changes-DzJovO_f.js → attribute-changes-D721NpZv.js} +3 -3
- package/dist/src/compiled/_chunks/workflow/{dist-BQSf8Hax.js → dist-BUFGAKRb.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/dist-CaNNONeg.js +3 -0
- package/dist/src/compiled/_chunks/workflow/{frames-qKc30rjg.js → frames-Dr9fHWdo.js} +2 -2
- package/dist/src/compiled/_chunks/workflow/{global-BQnKzRXo.js → global-DKbOgrts.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/helpers-DkKxg_yn.js +1 -0
- package/dist/src/compiled/_chunks/workflow/logger-D4GJNTk4.js +14 -0
- package/dist/src/compiled/_chunks/workflow/resume-hook-uTW-jBYz.js +1 -0
- package/dist/src/compiled/_chunks/workflow/run-5DmiMN9b.js +1 -0
- package/dist/src/compiled/_chunks/workflow/serialization-CNIYl1D3.js +3 -0
- package/dist/src/compiled/_chunks/workflow/sleep-DFKgN7UG.js +1 -0
- package/dist/src/compiled/_chunks/workflow/wait-until-3_1djUuL.js +1 -0
- package/dist/src/compiled/_chunks/workflow/{ws-transport-BrsMYqJg.js → ws-transport--rYOVIaf.js} +1 -1
- package/dist/src/compiler/artifacts.d.ts +4 -27
- package/dist/src/compiler/artifacts.js +1 -1
- package/dist/src/compiler/compile-agent.d.ts +2 -1
- package/dist/src/compiler/compile-agent.js +1 -1
- package/dist/src/compiler/diagnostics.d.ts +0 -11
- package/dist/src/compiler/diagnostics.js +1 -1
- package/dist/src/compiler/manifest.d.ts +0 -4
- package/dist/src/compiler/module-map.d.ts +1 -5
- package/dist/src/compiler/module-map.js +1 -1
- package/dist/src/compiler/normalize-agent-config.js +1 -1
- package/dist/src/compiler/normalize-connection.d.ts +2 -1
- package/dist/src/compiler/normalize-instructions.d.ts +2 -6
- package/dist/src/compiler/normalize-instructions.js +1 -1
- package/dist/src/compiler/normalize-manifest-helpers.d.ts +0 -1
- package/dist/src/compiler/normalize-manifest-helpers.js +1 -1
- package/dist/src/compiler/normalize-manifest.js +1 -1
- package/dist/src/compiler/normalize-skill.d.ts +2 -1
- package/dist/src/compiler/project-sources.d.ts +0 -14
- package/dist/src/compiler/project-sources.js +1 -1
- package/dist/src/compiler/resolve-workspace-subagent.js +1 -1
- package/dist/src/compiler/source-graph.d.ts +1 -2
- package/dist/src/compiler/source-graph.js +1 -1
- package/dist/src/context/build-base-tool-context.d.ts +2 -1
- package/dist/src/context/dynamic-tool-lifecycle.d.ts +0 -4
- package/dist/src/context/dynamic-tool-lifecycle.js +1 -1
- package/dist/src/context/dynamic-tool-metadata.d.ts +0 -1
- package/dist/src/context/dynamic-tool-metadata.js +1 -1
- package/dist/src/context/memory-lifecycle.d.ts +0 -8
- package/dist/src/context/memory-lifecycle.js +1 -1
- package/dist/src/discover/connections.d.ts +0 -15
- package/dist/src/discover/connections.js +1 -1
- package/dist/src/discover/diagnostics.d.ts +0 -12
- package/dist/src/discover/diagnostics.js +1 -1
- package/dist/src/discover/discover-agent.js +1 -1
- package/dist/src/discover/discover-subagent.d.ts +0 -1
- package/dist/src/discover/discover-subagent.js +1 -1
- package/dist/src/discover/extensions.d.ts +3 -10
- package/dist/src/discover/extensions.js +1 -1
- package/dist/src/discover/filesystem.d.ts +5 -9
- package/dist/src/discover/filesystem.js +1 -1
- package/dist/src/discover/grammar.d.ts +0 -46
- package/dist/src/discover/grammar.js +1 -1
- package/dist/src/discover/manifest.d.ts +5 -4
- package/dist/src/discover/memory.d.ts +0 -1
- package/dist/src/discover/memory.js +1 -1
- package/dist/src/discover/named-source-directory.js +1 -1
- package/dist/src/discover/project-source.d.ts +2 -1
- package/dist/src/discover/project.js +1 -1
- package/dist/src/discover/sandbox.js +1 -1
- package/dist/src/discover/skills.d.ts +0 -4
- package/dist/src/discover/skills.js +1 -1
- package/dist/src/evals/cli/eval-client.d.ts +2 -1
- package/dist/src/evals/judge.d.ts +2 -1
- package/dist/src/evals/runner/execute-task.d.ts +1 -1
- package/dist/src/evals/types.d.ts +1 -1
- package/dist/src/eve-channel/support.d.ts +1 -3
- package/dist/src/eve-channel/support.js +1 -1
- package/dist/src/execution/dynamic-workflow/schema.d.ts +2 -1
- package/dist/src/execution/dynamic-workflow/tool.js +1 -1
- package/dist/src/execution/effective-agent-config.d.ts +2 -1
- package/dist/src/execution/eve-workflow-attributes.d.ts +3 -5
- package/dist/src/execution/eve-workflow-attributes.js +1 -1
- package/dist/src/execution/history-view.d.ts +2 -1
- package/dist/src/execution/node-step.d.ts +3 -2
- package/dist/src/execution/runtime-context.js +1 -1
- package/dist/src/execution/sandbox/active-handles.d.ts +2 -4
- package/dist/src/execution/sandbox/active-handles.js +1 -1
- package/dist/src/execution/sandbox/bash.d.ts +2 -1
- package/dist/src/execution/sandbox/bindings/docker-templates.js +1 -1
- package/dist/src/execution/sandbox/bindings/docker.js +1 -1
- package/dist/src/execution/sandbox/bindings/immutable-resources.d.ts +0 -6
- package/dist/src/execution/sandbox/bindings/immutable-resources.js +1 -1
- package/dist/src/execution/sandbox/bindings/just-bash.js +1 -1
- package/dist/src/execution/sandbox/bindings/local-provider-utils.d.ts +3 -2
- package/dist/src/execution/sandbox/bindings/microsandbox-lifecycle.d.ts +0 -1
- package/dist/src/execution/sandbox/bindings/microsandbox-lifecycle.js +1 -1
- package/dist/src/execution/sandbox/bindings/microsandbox-network.d.ts +1 -1
- package/dist/src/execution/sandbox/bindings/microsandbox-options.d.ts +0 -3
- package/dist/src/execution/sandbox/bindings/microsandbox-options.js +1 -1
- package/dist/src/execution/sandbox/bindings/microsandbox-templates.d.ts +0 -1
- package/dist/src/execution/sandbox/bindings/microsandbox-templates.js +1 -1
- package/dist/src/execution/sandbox/bindings/vercel.d.ts +1 -1
- package/dist/src/execution/sandbox/dockerfile.d.ts +0 -1
- package/dist/src/execution/sandbox/dockerfile.js +1 -1
- package/dist/src/execution/sandbox/ensure.d.ts +2 -1
- package/dist/src/execution/sandbox/ensure.js +1 -1
- package/dist/src/execution/sandbox/prewarm.d.ts +1 -18
- package/dist/src/execution/sandbox/prewarm.js +1 -1
- package/dist/src/execution/sandbox/require-sandbox.d.ts +0 -11
- package/dist/src/execution/sandbox/require-sandbox.js +1 -1
- package/dist/src/execution/sandbox/truncate-output.d.ts +2 -5
- package/dist/src/execution/sandbox/truncate-output.js +2 -2
- package/dist/src/execution/session/admission.d.ts +3 -2
- package/dist/src/execution/session/event-sink.d.ts +2 -1
- package/dist/src/execution/session/finalization.d.ts +2 -1
- package/dist/src/execution/session/handoff.d.ts +3 -2
- package/dist/src/execution/session/route-selected-delivery.d.ts +2 -1
- package/dist/src/execution/session/timeout-control.d.ts +2 -1
- package/dist/src/execution/session-activity.d.ts +0 -3
- package/dist/src/execution/session-activity.js +1 -1
- package/dist/src/execution/session-inbox/protocol.d.ts +2 -1
- package/dist/src/execution/session.d.ts +3 -2
- package/dist/src/execution/stable-workflow-names.d.ts +0 -6
- package/dist/src/execution/stable-workflow-names.js +1 -1
- package/dist/src/execution/tools/agent-router-workflow.js +1 -1
- package/dist/src/execution/tools/ask-question-workflow.js +1 -1
- package/dist/src/execution/tools/connection-search.js +1 -1
- package/dist/src/execution/tools/sleep-workflow.js +1 -1
- package/dist/src/execution/tools/subagent/invoke-preparation.d.ts +2 -1
- package/dist/src/execution/tools/subagent/start.js +1 -1
- package/dist/src/execution/tools/subagent/task-agent-requests.d.ts +4 -3
- package/dist/src/execution/tools/workflow/background.d.ts +2 -6
- package/dist/src/execution/tools/workflow/background.js +1 -1
- package/dist/src/execution/tools/workflow/owner-channels.d.ts +1 -1
- package/dist/src/execution/tools/workflow/workflow-owner-background.d.ts +2 -1
- package/dist/src/execution/web-fetch/execute.d.ts +2 -2
- package/dist/src/execution/web-fetch/request.d.ts +2 -1
- package/dist/src/extensions/code/extension/lib/computer-use-driver-source.d.ts +0 -2
- package/dist/src/extensions/code/extension/lib/computer-use-driver-source.js +57 -57
- package/dist/src/extensions/code/extension/lib/computer-use.d.ts +1 -1
- package/dist/src/extensions/code/extension/lib/generated-paths.d.ts +2 -1
- package/dist/src/extensions/code/extension/lib/grep-search.d.ts +5 -5
- package/dist/src/extensions/code/extension/lib/grep-search.js +2 -2
- package/dist/src/extensions/code/extension/lib/guidelines.d.ts +2 -1
- package/dist/src/extensions/code/extension/lib/patch.d.ts +3 -2
- package/dist/src/extensions/code/extension/lib/prwatch-github.d.ts +1 -2
- package/dist/src/extensions/code/extension/lib/prwatch-github.js +1 -1
- package/dist/src/extensions/code/extension/lib/prwatch-registry.d.ts +2 -1
- package/dist/src/framework/host-inventory.d.ts +3 -2
- package/dist/src/harness/approval-candidates.d.ts +4 -3
- package/dist/src/harness/approval-delivery-coordinator.d.ts +2 -1
- package/dist/src/harness/authorization.d.ts +0 -9
- package/dist/src/harness/authorization.js +1 -1
- package/dist/src/harness/compaction-prompt.d.ts +2 -1
- package/dist/src/harness/coordination.d.ts +0 -4
- package/dist/src/harness/coordination.js +1 -1
- package/dist/src/harness/input-requests.d.ts +1 -10
- package/dist/src/harness/input-requests.js +1 -1
- package/dist/src/harness/pending-input-batches.d.ts +0 -5
- package/dist/src/harness/pending-input-batches.js +1 -1
- package/dist/src/harness/provider-safety.d.ts +9 -0
- package/dist/src/harness/provider-safety.js +1 -1
- package/dist/src/harness/provider-tools.d.ts +2 -1
- package/dist/src/harness/session-limit-continuation.d.ts +0 -4
- package/dist/src/harness/session-limit-continuation.js +1 -1
- package/dist/src/harness/session-usage-limits.d.ts +2 -1
- package/dist/src/harness/step-hooks.js +1 -1
- package/dist/src/harness/tool-loop.js +2 -2
- package/dist/src/harness/tool-model-output.d.ts +2 -1
- package/dist/src/harness/turn-cancellation.d.ts +2 -7
- package/dist/src/harness/turn-cancellation.js +1 -1
- package/dist/src/harness/turn-client-context.d.ts +2 -1
- package/dist/src/harness/workflow-stream-error.d.ts +0 -7
- package/dist/src/harness/workflow-stream-error.js +1 -1
- package/dist/src/instrumentation/runtime.js +1 -1
- package/dist/src/instrumentation/state.d.ts +2 -2
- package/dist/src/internal/agent-name.d.ts +0 -2
- package/dist/src/internal/agent-name.js +1 -1
- package/dist/src/internal/application/build-profile.d.ts +2 -2
- package/dist/src/internal/application/cache-metadata.js +1 -1
- package/dist/src/internal/application/compiled-artifacts.js +1 -1
- package/dist/src/internal/application/dev-environment.d.ts +2 -8
- package/dist/src/internal/application/dev-environment.js +1 -1
- package/dist/src/internal/application/optional-package-import.js +1 -1
- package/dist/src/internal/application/optional-package-install.js +1 -1
- package/dist/src/internal/application/output-publication-lock.js +1 -1
- package/dist/src/internal/application/output-publication.d.ts +1 -1
- package/dist/src/internal/application/package.js +1 -1
- package/dist/src/internal/application/paths.d.ts +0 -5
- package/dist/src/internal/application/paths.js +1 -1
- package/dist/src/internal/application/tsconfig-dependencies.d.ts +0 -16
- package/dist/src/internal/application/tsconfig-dependencies.js +1 -1
- package/dist/src/internal/authored-asset-import-plugin.js +1 -1
- package/dist/src/internal/authored-definition/schema-backed.js +1 -1
- package/dist/src/internal/authored-definition/source-identity.d.ts +1 -1
- package/dist/src/internal/authored-module-evaluation-error.js +1 -1
- package/dist/src/internal/authored-module-loader.js +1 -1
- package/dist/src/internal/authored-module-map-loader.js +1 -1
- package/dist/src/internal/authored-package-boundary.js +1 -1
- package/dist/src/internal/authored-relative-extension-resolver.js +1 -1
- package/dist/src/internal/bundler/extension-scope-plugin.d.ts +2 -1
- package/dist/src/internal/bundler/extension-scope-plugin.js +1 -1
- package/dist/src/internal/bundler/nitro-rolldown.d.ts +3 -12
- package/dist/src/internal/bundler/nitro-rolldown.js +1 -1
- package/dist/src/internal/bundler/vendored-dependency-log.d.ts +7 -0
- package/dist/src/internal/bundler/vendored-dependency-log.js +1 -0
- package/dist/src/internal/eve-project-root.d.ts +0 -3
- package/dist/src/internal/eve-project-root.js +1 -1
- package/dist/src/internal/external-resources-snapshot.d.ts +1 -1
- package/dist/src/internal/external-resources.d.ts +0 -1
- package/dist/src/internal/external-resources.js +1 -1
- package/dist/src/internal/gateway.d.ts +2 -0
- package/dist/src/internal/gateway.js +1 -1
- package/dist/src/internal/helpers/markdown.js +1 -1
- package/dist/src/internal/instrumentation-layout.js +1 -1
- package/dist/src/internal/invocation/metadata.d.ts +1 -1
- package/dist/src/internal/materialized-authored-modules.d.ts +2 -1
- package/dist/src/internal/materialized-authored-modules.js +1 -1
- package/dist/src/internal/mcp/protected-resource.d.ts +2 -1
- package/dist/src/internal/mcp/streamable-http-server.d.ts +4 -5
- package/dist/src/internal/mcp/streamable-http-server.js +1 -1
- package/dist/src/internal/model-catalog.d.ts +2 -1
- package/dist/src/internal/nitro/dev-runtime-artifacts-retention.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-artifacts.d.ts +0 -4
- package/dist/src/internal/nitro/dev-runtime-artifacts.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-source-snapshot-copy.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-source-snapshot-local-roots.js +1 -1
- package/dist/src/internal/nitro/dev-runtime-source-snapshot.d.ts +0 -1
- package/dist/src/internal/nitro/dev-runtime-source-snapshot.js +1 -1
- package/dist/src/internal/nitro/development-generation.d.ts +0 -1
- package/dist/src/internal/nitro/development-generation.js +1 -1
- package/dist/src/internal/nitro/host/build-application.js +1 -1
- package/dist/src/internal/nitro/host/build-extension.js +1 -1
- package/dist/src/internal/nitro/host/build-vercel-agent-summary.js +1 -1
- package/dist/src/internal/nitro/host/channel-routes.d.ts +1 -1
- package/dist/src/internal/nitro/host/configure-nitro-routes.js +1 -1
- package/dist/src/internal/nitro/host/create-application-nitro.js +1 -1
- package/dist/src/internal/nitro/host/dev-authored-rebuild-coordinator.d.ts +2 -1
- package/dist/src/internal/nitro/host/dev-authored-source-watcher.js +1 -1
- package/dist/src/internal/nitro/host/dev-host-candidate.d.ts +2 -1
- package/dist/src/internal/nitro/host/drained-nitro-dev-server.d.ts +1 -1
- package/dist/src/internal/nitro/host/extension-capability-requirements.js +1 -1
- package/dist/src/internal/nitro/host/extension-external-dependency-plugin.js +1 -1
- package/dist/src/internal/nitro/host/local-tracing-runtime-plugin.js +1 -1
- package/dist/src/internal/nitro/host/nitro-bundler-config.js +1 -1
- package/dist/src/internal/nitro/host/schedule-task-routes.d.ts +2 -26
- package/dist/src/internal/nitro/host/schedule-task-routes.js +2 -2
- package/dist/src/internal/nitro/host/start-production-server.js +1 -1
- package/dist/src/internal/nitro/host/workspace-extensions.js +1 -1
- package/dist/src/internal/nitro/routes/channel-request-instrumentation.d.ts +2 -1
- package/dist/src/internal/nitro/routes/channel-route-context.d.ts +1 -1
- package/dist/src/internal/nitro/routes/runtime-stack.d.ts +2 -1
- package/dist/src/internal/resolve-model-endpoint-status.d.ts +2 -1
- package/dist/src/internal/vercel/assemble-eve-services.d.ts +3 -2
- package/dist/src/internal/vercel/build-agent-workspace.js +1 -1
- package/dist/src/internal/vercel/eve-service-contribution.d.ts +2 -3
- package/dist/src/internal/vercel/eve-service-contribution.js +1 -1
- package/dist/src/internal/vercel/project-link.d.ts +2 -1
- package/dist/src/internal/vercel/project-link.js +1 -1
- package/dist/src/internal/workflow/development-world-client.js +1 -1
- package/dist/src/internal/workflow/development-world-codec.d.ts +2 -1
- package/dist/src/internal/workflow/development-world-server.js +1 -1
- package/dist/src/internal/workflow/world-compatibility.d.ts +2 -1
- package/dist/src/internal/workflow-bundle/builder-support.d.ts +0 -9
- package/dist/src/internal/workflow-bundle/builder-support.js +2 -3
- package/dist/src/internal/workflow-bundle/builder.js +2 -2
- package/dist/src/internal/workflow-bundle/dynamic-tool-transform.d.ts +0 -1
- package/dist/src/internal/workflow-bundle/dynamic-tool-transform.js +1 -1
- package/dist/src/internal/workflow-bundle/workflow-builders.js +1 -1
- package/dist/src/protocol/activity.d.ts +3 -3
- package/dist/src/protocol/activity.js +1 -1
- package/dist/src/protocol/baggage.d.ts +2 -2
- package/dist/src/protocol/cancel-turn.d.ts +0 -2
- package/dist/src/protocol/event-dedupe.d.ts +2 -1
- package/dist/src/protocol/event-id.d.ts +0 -6
- package/dist/src/protocol/event-id.js +1 -1
- package/dist/src/protocol/traceparent.d.ts +2 -1
- package/dist/src/public/channels/chat-sdk/audience.d.ts +2 -4
- package/dist/src/public/channels/chat-sdk/audience.js +1 -1
- package/dist/src/public/channels/discord/discordChannel.d.ts +1 -1
- package/dist/src/public/channels/github/api.d.ts +2 -22
- package/dist/src/public/channels/github/api.js +1 -1
- package/dist/src/public/channels/github/auth.d.ts +0 -9
- package/dist/src/public/channels/github/auth.js +1 -1
- package/dist/src/public/channels/github/binding.d.ts +3 -2
- package/dist/src/public/channels/github/checkout.d.ts +3 -3
- package/dist/src/public/channels/github/defaults.d.ts +3 -2
- package/dist/src/public/channels/github/githubChannel.d.ts +1 -1
- package/dist/src/public/channels/github/limits.d.ts +0 -2
- package/dist/src/public/channels/github/limits.js +2 -2
- package/dist/src/public/channels/github/pr-context.d.ts +2 -3
- package/dist/src/public/channels/github/pr-context.js +1 -1
- package/dist/src/public/channels/github/state.d.ts +2 -1
- package/dist/src/public/channels/github/verify.d.ts +2 -1
- package/dist/src/public/channels/linear/defaults.d.ts +2 -1
- package/dist/src/public/channels/linear/inbound-images.d.ts +2 -1
- package/dist/src/public/channels/slack/app-manifest.d.ts +3 -4
- package/dist/src/public/channels/slack/app-manifest.js +1 -1
- package/dist/src/public/channels/slack/hitl.d.ts +0 -4
- package/dist/src/public/channels/slack/hitl.js +2 -2
- package/dist/src/public/channels/slack/inbound.d.ts +2 -1
- package/dist/src/public/channels/slack/model-context.d.ts +0 -18
- package/dist/src/public/channels/slack/model-context.js +1 -1
- package/dist/src/public/channels/slack/mrkdwn.d.ts +0 -2
- package/dist/src/public/channels/slack/mrkdwn.js +1 -1
- package/dist/src/public/channels/slack/privacy.d.ts +2 -1
- package/dist/src/public/channels/slack/verify.d.ts +1 -1
- package/dist/src/public/channels/teams/teamsChannel.d.ts +1 -1
- package/dist/src/public/channels/telegram/audience.d.ts +2 -3
- package/dist/src/public/channels/telegram/audience.js +1 -1
- package/dist/src/public/channels/telegram/telegramChannel.d.ts +1 -1
- package/dist/src/public/channels/twilio/defaults.d.ts +0 -7
- package/dist/src/public/channels/twilio/defaults.js +1 -1
- package/dist/src/public/channels/twilio/routing.d.ts +2 -1
- package/dist/src/public/channels/twilio/twilioChannel.d.ts +1 -1
- package/dist/src/public/channels/upload-policy.d.ts +0 -11
- package/dist/src/public/channels/upload-policy.js +1 -1
- package/dist/src/public/definitions/channel.d.ts +1 -1
- package/dist/src/public/index.js +1 -1
- package/dist/src/public/memory/file/provider.js +1 -1
- package/dist/src/public/models/openai/chatgpt/model.d.ts +2 -1
- package/dist/src/public/models/openai/chatgpt/token-broker.d.ts +1 -1
- package/dist/src/public/next/server.js +1 -1
- package/dist/src/public/nuxt/dev-server.d.ts +3 -2
- package/dist/src/public/nuxt/dev-server.js +1 -1
- package/dist/src/public/skills/index.js +1 -1
- package/dist/src/public/sveltekit/dev-server.d.ts +3 -2
- package/dist/src/public/sveltekit/dev-server.js +1 -1
- package/dist/src/public/tools/index.js +1 -1
- package/dist/src/runtime/compiled-artifacts-source.d.ts +0 -4
- package/dist/src/runtime/compiled-artifacts-source.js +1 -1
- package/dist/src/runtime/connections/instance-identity.d.ts +0 -3
- package/dist/src/runtime/connections/instance-identity.js +1 -1
- package/dist/src/runtime/connections/mcp-tracing.d.ts +1 -6
- package/dist/src/runtime/connections/mcp-tracing.js +1 -1
- package/dist/src/runtime/connections/openapi-client.d.ts +1 -1
- package/dist/src/runtime/connections/scoped-authorization.d.ts +0 -9
- package/dist/src/runtime/connections/scoped-authorization.js +1 -1
- package/dist/src/runtime/hooks/registry.d.ts +0 -7
- package/dist/src/runtime/hooks/registry.js +1 -1
- package/dist/src/runtime/loaders/artifact-paths.d.ts +2 -1
- package/dist/src/runtime/loaders/bundled-artifacts.d.ts +0 -1
- package/dist/src/runtime/loaders/bundled-artifacts.js +1 -1
- package/dist/src/runtime/resolve-agent.d.ts +2 -2
- package/dist/src/runtime/resolve-agent.js +1 -1
- package/dist/src/runtime/resolve-dynamic-tool.d.ts +0 -16
- package/dist/src/runtime/resolve-dynamic-tool.js +1 -1
- package/dist/src/runtime/sandbox/prepared-artifacts.d.ts +1 -2
- package/dist/src/runtime/sandbox/prepared-artifacts.js +1 -1
- package/dist/src/runtime/schedules/register.d.ts +0 -4
- package/dist/src/runtime/schedules/register.js +1 -1
- package/dist/src/self-modification/credentials.d.ts +1 -4
- package/dist/src/self-modification/credentials.js +1 -1
- package/dist/src/self-modification/extension/subagents/agent/tools/search_traces.js +1 -1
- package/dist/src/self-modification/filesystem.d.ts +0 -1
- package/dist/src/self-modification/filesystem.js +1 -1
- package/dist/src/self-modification/git-workspace.d.ts +0 -3
- package/dist/src/self-modification/git-workspace.js +1 -1
- package/dist/src/self-modification/github-publisher.d.ts +2 -1
- package/dist/src/self-modification/migration.d.ts +0 -1
- package/dist/src/self-modification/migration.js +1 -1
- package/dist/src/self-modification/mode.d.ts +2 -1
- package/dist/src/self-modification/proposal.d.ts +0 -2
- package/dist/src/self-modification/proposal.js +2 -2
- package/dist/src/self-modification/setup.js +1 -1
- package/dist/src/services/dev-client/agent-info-probe.d.ts +2 -1
- package/dist/src/services/dev-client/request-headers.d.ts +1 -1
- package/dist/src/services/dev-client/vercel-auth-error.d.ts +0 -8
- package/dist/src/services/dev-client/vercel-auth-error.js +2 -3
- package/dist/src/setup/ai-gateway-api-key.d.ts +2 -1
- package/dist/src/setup/append-env.d.ts +3 -2
- package/dist/src/setup/ask.d.ts +3 -3
- package/dist/src/setup/boxes/apply-ai-gateway-credential.d.ts +2 -1
- package/dist/src/setup/boxes/deploy-project.d.ts +4 -3
- package/dist/src/setup/boxes/link-project.d.ts +2 -1
- package/dist/src/setup/boxes/resolve-provisioning.d.ts +2 -1
- package/dist/src/setup/boxes/select-model.d.ts +2 -37
- package/dist/src/setup/boxes/select-model.js +1 -1
- package/dist/src/setup/cli/option-row.d.ts +1 -1
- package/dist/src/setup/cli/prompt-ui.d.ts +0 -10
- package/dist/src/setup/cli/prompt-ui.js +1 -1
- package/dist/src/setup/cli/rail-log.d.ts +0 -2
- package/dist/src/setup/cli/rail-log.js +2 -2
- package/dist/src/setup/connect-provisioning.d.ts +2 -1
- package/dist/src/setup/connection-connector.d.ts +2 -1
- package/dist/src/setup/flows/link.d.ts +2 -1
- package/dist/src/setup/flows/model-login.d.ts +1 -1
- package/dist/src/setup/flows/model-source-change.js +1 -1
- package/dist/src/setup/flows/provider.d.ts +2 -45
- package/dist/src/setup/flows/provider.js +1 -4
- package/dist/src/setup/flows/registry-session.d.ts +3 -2
- package/dist/src/setup/integrations/discord/api.d.ts +2 -1
- package/dist/src/setup/integrations/discord/connect.d.ts +3 -3
- package/dist/src/setup/integrations/discord/connect.js +1 -1
- package/dist/src/setup/integrations/discord/setup.d.ts +2 -1
- package/dist/src/setup/integrations/file-memory/vercel.d.ts +1 -1
- package/dist/src/setup/integrations/github/connect.d.ts +3 -3
- package/dist/src/setup/integrations/github/connect.js +1 -1
- package/dist/src/setup/integrations/github/setup.d.ts +1 -1
- package/dist/src/setup/integrations/linear/connect.d.ts +2 -2
- package/dist/src/setup/integrations/linear/connect.js +1 -1
- package/dist/src/setup/integrations/linear/setup.d.ts +1 -1
- package/dist/src/setup/integrations/linq/connect.d.ts +3 -4
- package/dist/src/setup/integrations/linq/connect.js +1 -1
- package/dist/src/setup/integrations/linq/management.d.ts +2 -1
- package/dist/src/setup/integrations/linq/setup.d.ts +1 -9
- package/dist/src/setup/integrations/linq/setup.js +1 -1
- package/dist/src/setup/integrations/photon/connect.d.ts +5 -7
- package/dist/src/setup/integrations/photon/connect.js +1 -1
- package/dist/src/setup/integrations/photon/management.d.ts +5 -4
- package/dist/src/setup/integrations/photon/setup-flow.d.ts +2 -1
- package/dist/src/setup/integrations/registry.d.ts +0 -2
- package/dist/src/setup/integrations/registry.js +1 -1
- package/dist/src/setup/integrations/runner.d.ts +3 -2
- package/dist/src/setup/integrations/shared/scaffold.d.ts +2 -1
- package/dist/src/setup/integrations/shared/vercel-project.d.ts +2 -1
- package/dist/src/setup/integrations/shopify/setup.d.ts +2 -1
- package/dist/src/setup/integrations/teams/connect.d.ts +3 -3
- package/dist/src/setup/integrations/teams/connect.js +1 -1
- package/dist/src/setup/integrations/teams/setup.d.ts +2 -1
- package/dist/src/setup/integrations/web/setup.d.ts +2 -1
- package/dist/src/setup/primitives/pm/pnpm.js +1 -1
- package/dist/src/setup/primitives/pm/process-result.d.ts +2 -1
- package/dist/src/setup/primitives/pm/shared.d.ts +2 -1
- package/dist/src/setup/primitives/process-output.d.ts +2 -1
- package/dist/src/setup/primitives/run-vercel.js +1 -1
- package/dist/src/setup/project-resolution.d.ts +0 -2
- package/dist/src/setup/project-resolution.js +1 -1
- package/dist/src/setup/provider-settings.js +1 -1
- package/dist/src/setup/quit-guard.d.ts +3 -2
- package/dist/src/setup/scaffold/connections/catalog.d.ts +0 -13
- package/dist/src/setup/scaffold/connections/catalog.js +1 -1
- package/dist/src/setup/scaffold/create/add-to-project.d.ts +2 -1
- package/dist/src/setup/scaffold/create/project.js +1 -1
- package/dist/src/setup/scaffold/files.d.ts +2 -1
- package/dist/src/setup/scaffold/update/channels.d.ts +0 -1
- package/dist/src/setup/scaffold/version-tokens.js +1 -1
- package/dist/src/setup/scaffold/workspace-glob.d.ts +0 -1
- package/dist/src/setup/scaffold/workspace-glob.js +1 -1
- package/dist/src/setup/scaffold/workspace-root.d.ts +2 -1
- package/dist/src/setup/scaffold/workspace-root.js +1 -1
- package/dist/src/setup/slack-connect-create.d.ts +1 -1
- package/dist/src/setup/slack-connect-lifecycle.d.ts +5 -5
- package/dist/src/setup/slack-connect.d.ts +0 -4
- package/dist/src/setup/slack-connect.js +1 -1
- package/dist/src/setup/slackbot.d.ts +3 -3
- package/dist/src/setup/slackbot.js +1 -1
- package/dist/src/setup/vercel-api-failure.d.ts +0 -2
- package/dist/src/setup/vercel-api-failure.js +1 -1
- package/dist/src/setup/vercel-project-api.d.ts +1 -1
- package/dist/src/setup/vercel-project.d.ts +4 -38
- package/dist/src/setup/vercel-project.js +0 -0
- package/dist/src/shared/action-types.d.ts +1 -58
- package/dist/src/shared/action-types.js +1 -1
- package/dist/src/shared/agent-definition.d.ts +0 -3
- package/dist/src/shared/agent-turn-outcome.d.ts +1 -3
- package/dist/src/shared/agent-turn-outcome.js +1 -1
- package/dist/src/shared/chatgpt-model.d.ts +0 -1
- package/dist/src/shared/chatgpt-model.js +1 -1
- package/dist/src/shared/conversation-context.d.ts +2 -1
- package/dist/src/shared/conversation-identity.d.ts +2 -0
- package/dist/src/shared/conversation-identity.js +1 -0
- package/dist/src/shared/extension-package-contract.d.ts +2 -1
- package/dist/src/shared/forwarded-trace-policy.d.ts +3 -2
- package/dist/src/shared/gateway-service-tier.d.ts +2 -1
- package/dist/src/shared/memory-state.d.ts +0 -8
- package/dist/src/shared/memory-state.js +1 -1
- package/dist/src/shared/sandbox-environment.d.ts +0 -1
- package/dist/src/shared/sandbox-environment.js +1 -1
- package/dist/src/shared/skill-package.d.ts +0 -5
- package/dist/src/shared/skill-package.js +1 -1
- package/dist/src/shared/skill-paths.d.ts +0 -13
- package/dist/src/shared/skill-paths.js +2 -2
- package/dist/src/shared/token-usage.d.ts +0 -7
- package/dist/src/shared/token-usage.js +1 -1
- package/dist/src/shared/ulid.d.ts +2 -8
- package/dist/src/shared/ulid.js +1 -1
- package/dist/src/shared/vercel-project.d.ts +2 -1
- package/dist/src/shared/vercel-services.d.ts +2 -2
- package/dist/src/shared/workflow-sandbox.d.ts +0 -7
- package/dist/src/source-change/agent-config-ast.d.ts +2 -1
- package/dist/src/source-change/agent-config-string-path.d.ts +2 -2
- package/dist/src/source-change/apply-agent-model-settings.d.ts +2 -1
- package/dist/src/source-change/apply-model-selection.d.ts +2 -1
- package/dist/src/source-change/static-source-change.d.ts +4 -3
- package/dist/src/subagents/invocation.d.ts +1 -1
- package/dist/src/subagents/tool.d.ts +2 -1
- package/dist/src/svelte/index.js +1 -1
- package/dist/src/svelte/use-eve-agent.js +1 -1
- package/dist/src/tools/definition.d.ts +0 -3
- package/dist/src/tools/durable-callbacks.d.ts +1 -2
- package/dist/src/tools/durable-callbacks.js +1 -1
- package/dist/src/tools/framework/agent.js +1 -1
- package/dist/src/tools/framework/task-cancel.d.ts +1 -1
- package/dist/src/tools/native-definition.d.ts +2 -1
- package/dist/src/tracing/agent-action-instrumentation.d.ts +2 -1
- package/dist/src/tracing/agent-invocation-coordinator.js +1 -1
- package/dist/src/tracing/agent-memory-instrumentation.d.ts +2 -1
- package/dist/src/tracing/agent-otel-attributes.js +1 -1
- package/dist/src/tracing/agent-otel-provider.d.ts +2 -1
- package/dist/src/tracing/agent-span-id-generator.d.ts +0 -1
- package/dist/src/tracing/agent-span-id-generator.js +1 -1
- package/dist/src/tracing/agent-tool-instrumentation.d.ts +2 -1
- package/dist/src/tracing/agent-tool-span-context.d.ts +3 -2
- package/dist/src/tracing/agent-trace-context-store.d.ts +0 -2
- package/dist/src/tracing/agent-trace-context-store.js +1 -1
- package/dist/src/tracing/agent-trace-state.d.ts +0 -24
- package/dist/src/tracing/agent-trace-state.js +1 -1
- package/dist/src/tracing/batch-span-processor.d.ts +2 -1
- package/dist/src/tracing/conversation-context.d.ts +0 -2
- package/dist/src/tracing/conversation-context.js +1 -1
- package/dist/src/tracing/install-instrumentation-runtime.js +1 -1
- package/dist/src/tracing/local-trace-analysis.d.ts +4 -3
- package/dist/src/tracing/local-trace-discovery-index.d.ts +0 -2
- package/dist/src/tracing/local-trace-discovery-index.js +1 -1
- package/dist/src/tracing/local-trace-query.d.ts +2 -1
- package/dist/src/tracing/local-trace-retention.d.ts +4 -4
- package/dist/src/tracing/telemetry-budget.d.ts +0 -1
- package/dist/src/tracing/telemetry-budget.js +1 -1
- package/dist/src/vue/index.js +1 -1
- package/dist/src/vue/use-eve-agent.js +1 -1
- package/docs/agent-config.md +7 -0
- package/package.json +8 -8
- package/dist/src/cli/commands/channel-add-conflicts.d.ts +0 -21
- package/dist/src/cli/commands/channel-add-conflicts.js +0 -1
- package/dist/src/cli/commands/init-confirm.d.ts +0 -12
- package/dist/src/cli/commands/init-confirm.js +0 -1
- package/dist/src/cli/commands/registry-search-presentation.d.ts +0 -16
- package/dist/src/cli/commands/registry-search-presentation.js +0 -6
- package/dist/src/compiled/_chunks/workflow/dist-BfMqXLK3.js +0 -3
- package/dist/src/compiled/_chunks/workflow/helpers-CNMO7zB1.js +0 -1
- package/dist/src/compiled/_chunks/workflow/logger-BCEj9caG.js +0 -14
- package/dist/src/compiled/_chunks/workflow/resume-hook-QS_cMwHn.js +0 -1
- package/dist/src/compiled/_chunks/workflow/run-CA5wWV2S.js +0 -1
- package/dist/src/compiled/_chunks/workflow/serialization-CJ265vSe.js +0 -3
- package/dist/src/compiled/_chunks/workflow/sleep-CBn94Ayv.js +0 -1
- package/dist/src/compiled/_chunks/workflow/wait-until-Bo2U6ON9.js +0 -1
- package/dist/src/compiler/compile-from-memory.d.ts +0 -44
- package/dist/src/compiler/compile-from-memory.js +0 -1
- package/dist/src/execution/connection-auth-tool-result.d.ts +0 -2
- package/dist/src/execution/connection-auth-tool-result.js +0 -1
- package/dist/src/internal/process/pnpm.d.ts +0 -28
- package/dist/src/internal/process/pnpm.js +0 -1
- package/dist/src/public/channels/slack/api-encoding.d.ts +0 -5
- package/dist/src/public/channels/slack/api-encoding.js +0 -1
- package/dist/src/public/definitions/instrumentation.d.ts +0 -1
- package/dist/src/public/definitions/instrumentation.js +0 -1
- package/dist/src/public/models/openai/chatgpt/unsigned-jwt.d.ts +0 -5
- package/dist/src/public/models/openai/chatgpt/unsigned-jwt.js +0 -1
- package/dist/src/sandbox/backends/probes.d.ts +0 -7
- package/dist/src/sandbox/backends/probes.js +0 -1
- package/dist/src/setup/channel-add-conflicts.d.ts +0 -28
- package/dist/src/setup/channel-add-conflicts.js +0 -1
- package/dist/src/setup/gateway-models.d.ts +0 -10
- package/dist/src/setup/gateway-models.js +0 -1
- package/dist/src/setup/primitives/run-pnpm.d.ts +0 -1
- package/dist/src/setup/primitives/run-pnpm.js +0 -1
- package/dist/src/shared/dispatch-action.d.ts +0 -30
- package/dist/src/shared/dispatch-action.js +0 -1
|
@@ -10,8 +10,6 @@ export interface DeploymentInfo {
|
|
|
10
10
|
}
|
|
11
11
|
/** Validated Vercel owner and project identifiers. */
|
|
12
12
|
export type VercelProjectReference = VercelProjectLink;
|
|
13
|
-
/** Parses the complete Vercel owner and project environment pair. */
|
|
14
|
-
export declare function projectReferenceFromEnvironment(environment: Readonly<Record<string, string | undefined>>): VercelProjectReference | undefined;
|
|
15
13
|
/** Rejects Vercel's unsupported legacy link directory before link mutation. */
|
|
16
14
|
export declare function assertNoLegacyProjectLinkDirectory(projectRoot: string): Promise<void>;
|
|
17
15
|
/** Reads a validated project reference from Vercel's link metadata directory. */
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{captureVercel}from"./primitives/run-vercel.js";import{stat}from"node:fs/promises";import{
|
|
1
|
+
import{captureVercel}from"./primitives/run-vercel.js";import{stat}from"node:fs/promises";import{join}from"node:path";import{readVercelResourceName}from"#internal/vercel/api-resource.js";import{readVercelProjectLink}from"#internal/vercel/project-link.js";async function assertNoLegacyProjectLinkDirectory(e){try{if(!(await stat(join(e,`.now`))).isDirectory())return}catch(e){if(e instanceof Error&&`code`in e&&e.code===`ENOENT`)return;throw e}throw Error("Legacy Vercel link directory `.now` is not supported. Remove `.now` before linking this project.")}async function readProjectLink(e){return await assertNoLegacyProjectLinkDirectory(e),await readVercelProjectLink(e)}function pickShortestAlias(e){if(!Array.isArray(e))return;let t;for(let n of e)typeof n==`string`&&n.length!==0&&(t===void 0||n.length<t.length)&&(t=n);return t}async function fetchProductionAlias(e,t,n,r){let i=await captureVercel([`api`,`/v9/projects/${e}?teamId=${t}`,`--scope`,t],{cwd:n,signal:r.signal});if(i.ok)try{let e=pickShortestAlias(JSON.parse(i.stdout).targets?.production?.alias);return e?`https://${e}`:void 0}catch{return}}async function detectDeployment(e,t={}){t.signal?.throwIfAborted();let n=await readProjectLink(e);if(n===void 0)return{state:`unlinked`};let r=await fetchProductionAlias(n.projectId,n.orgId,e,t);return t.signal?.throwIfAborted(),{state:r?`deployed`:`linked`,projectId:n.projectId,orgId:n.orgId,productionUrl:r}}async function fetchVercelName(e,t,n,r){let i=await captureVercel([`api`,e,`--scope`,t],{cwd:n,signal:r.signal});if(i.ok)try{return readVercelResourceName(JSON.parse(i.stdout))}catch{return}}async function detectProjectIdentity(e,t={}){t.signal?.throwIfAborted();let n=await readProjectLink(e);if(n===void 0)return;let[r,i]=await Promise.all([fetchVercelName(`/v9/projects/${n.projectId}?teamId=${n.orgId}`,n.orgId,e,t).then(e=>e??n.projectId),n.orgId.startsWith(`team_`)?fetchVercelName(`/v2/teams/${n.orgId}`,n.orgId,e,t):Promise.resolve(void 0)]);return t.signal?.throwIfAborted(),{projectName:r,teamName:i}}function projectResolutionFromDeployment(e){return e.state===`unlinked`||e.projectId===void 0?{kind:`unresolved`}:e.state===`deployed`&&e.productionUrl!==void 0?{kind:`deployed`,projectId:e.projectId,productionUrl:e.productionUrl}:{kind:`linked`,projectId:e.projectId}}async function detectProjectResolution(e,t={}){return projectResolutionFromDeployment(await detectDeployment(e,t))}function mergeProjectResolution(e,t){return t.kind===`unresolved`||e.kind===`deployed`&&e.projectId===t.projectId?e:t}function projectResolutionFromDeployResult(e,t){return e.kind===`unresolved`||!t.deployed||t.productionUrl===void 0?e:{kind:`deployed`,projectId:e.projectId,productionUrl:t.productionUrl}}function isProjectResolved(e){return e.kind!==`unresolved`}function projectProductionUrlFromResolution(e){return e.kind===`deployed`?e.productionUrl:void 0}export{assertNoLegacyProjectLinkDirectory,detectDeployment,detectProjectIdentity,detectProjectResolution,isProjectResolved,mergeProjectResolution,projectProductionUrlFromResolution,projectResolutionFromDeployResult,projectResolutionFromDeployment,readProjectLink};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{mkdir,readFile}from"node:fs/promises";import{isObject}from"#shared/guards.js";import{
|
|
1
|
+
import{mkdir,readFile}from"node:fs/promises";import{isObject}from"#shared/guards.js";import{readFileSync}from"node:fs";import{join}from"node:path";import{readProjectLink}from"#setup/project-resolution.js";import{hasEnvValue}from"#internal/resolve-model-endpoint-status.js";import{atomicWriteFile}from"#shared/atomic-write-file.js";import{isModelConnection}from"#shared/model-connection.js";import{AI_GATEWAY_API_KEY_ENV_VAR}from"#setup/ai-gateway-api-key.js";import{findEnvFileWithKey}from"#setup/boxes/detect-ai-gateway.js";function providerSettingsPath(e){return join(e,`.eve`,`provider.json`)}async function resolveAvailableProviders(e,t={}){let{signal:n,env:r=process.env}=t;n?.throwIfAborted();let[i,a,o]=await Promise.all([readProjectLink(e),findEnvFileWithKey(e,AI_GATEWAY_API_KEY_ENV_VAR),findEnvFileWithKey(e,`VERCEL_OIDC_TOKEN`)]);n?.throwIfAborted();let s=[`chatgpt`];return(a!==void 0||hasEnvValue(r[AI_GATEWAY_API_KEY_ENV_VAR]))&&s.push(`ai-gateway-key`),(i!==void 0||o!==void 0)&&s.push(`ai-gateway-project`),s}async function readProviderSelection(e){try{return parseProviderSelection(JSON.parse(await readFile(providerSettingsPath(e),`utf8`)))}catch{return}}function readProviderSettingsSync(e){try{let t=JSON.parse(readFileSync(providerSettingsPath(e),`utf8`));return!isObject(t)||!isProviderSelection(t.selected)?void 0:{selected:t.selected,...typeof t.teamId==`string`&&typeof t.teamName==`string`&&{teamId:t.teamId,teamName:t.teamName},...(t.keySource===`environment`||t.keySource===`secret`)&&{keySource:t.keySource}}}catch{return}}async function providerSettingsMatch(e,t){try{let n=JSON.parse(await readFile(providerSettingsPath(e),`utf8`));return isObject(n)&&n.selected===t.selected&&n.teamId===t.teamId&&n.teamName===t.teamName&&n.keySource===t.keySource}catch{return!1}}async function writeProviderSelection(e,t,n,r){await mkdir(join(e,`.eve`),{recursive:!0}),await atomicWriteFile(providerSettingsPath(e),`${JSON.stringify({selected:t,...n,keySource:r},null,2)}\n`)}function parseProviderSelection(e){return isObject(e)&&isProviderSelection(e.selected)?e.selected:void 0}function isProviderSelection(e){return isModelConnection(e)||e===`vercel-cli`||e===`ai-gateway-project`}function readProviderTeamSync(e){let t=readProviderSettingsSync(e);return t?.teamId&&t.teamName?{teamId:t.teamId,teamName:t.teamName}:void 0}function readProviderKeySourceSync(e){return readProviderSettingsSync(e)?.keySource}export{providerSettingsMatch,providerSettingsPath,readProviderKeySourceSync,readProviderSelection,readProviderSettingsSync,readProviderTeamSync,resolveAvailableProviders,writeProviderSelection};
|
|
@@ -17,7 +17,7 @@ export declare const initialQuitGuardState: QuitGuardState;
|
|
|
17
17
|
* Key intents the guard distinguishes. Escape arms or quits; every other key is
|
|
18
18
|
* collapsed to `other-key`, which only matters while armed (it disarms).
|
|
19
19
|
*/
|
|
20
|
-
|
|
20
|
+
type QuitGuardEvent = {
|
|
21
21
|
type: "escape";
|
|
22
22
|
} | {
|
|
23
23
|
type: "other-key";
|
|
@@ -27,7 +27,7 @@ export type QuitGuardEvent = {
|
|
|
27
27
|
* requires the caller to act (cancel the prompt); `arm`/`disarm`/`none` are
|
|
28
28
|
* reflected purely by re-rendering with the returned {@link QuitGuardState}.
|
|
29
29
|
*/
|
|
30
|
-
|
|
30
|
+
type QuitGuardAction = "none" | "arm" | "quit" | "disarm";
|
|
31
31
|
/**
|
|
32
32
|
* Advances the guard for a single keypress.
|
|
33
33
|
*
|
|
@@ -45,3 +45,4 @@ export declare function reduceQuitGuard(state: QuitGuardState, event: QuitGuardE
|
|
|
45
45
|
* status bar pinned under the active prompt.
|
|
46
46
|
*/
|
|
47
47
|
export declare function quitHintNote(state: QuitGuardState, colors: PromptColors): string | undefined;
|
|
48
|
+
export {};
|
|
@@ -106,18 +106,5 @@ export declare function catalogSlugs(): string[];
|
|
|
106
106
|
export declare function effectiveProtocols(declared: readonly ConnectionProtocol[] | undefined): ConnectionProtocol[];
|
|
107
107
|
/** True when a slug is a valid filesystem-derived connection name. */
|
|
108
108
|
export declare function isValidConnectionSlug(slug: string): boolean;
|
|
109
|
-
/**
|
|
110
|
-
* The `vercel connect create <service>` identifier for a Connect-backed
|
|
111
|
-
* connection: the explicit `auth.service` when set, otherwise the MCP host.
|
|
112
|
-
* Returns `undefined` when neither is available, in which case the connector
|
|
113
|
-
* must be provisioned out of band.
|
|
114
|
-
*/
|
|
115
|
-
export declare function connectorServiceForEntry(entry: Pick<ConnectionCatalogEntry, "mcp" | "auth">): string | undefined;
|
|
116
|
-
/** Canonical connector name attempted before offering discovery or creation. */
|
|
117
|
-
export declare function canonicalConnectorNameForEntry(entry: {
|
|
118
|
-
auth?: ConnectionAuthSpec;
|
|
119
|
-
}): string | undefined;
|
|
120
|
-
/** Extracts the bare host from an MCP URL, or `undefined` when unparseable. */
|
|
121
|
-
export declare function mcpServiceHost(url: string | undefined): string | undefined;
|
|
122
109
|
/** Returns the endpoint block required for a protocol, or `null` when missing. */
|
|
123
110
|
export declare function endpointForProtocol(entry: Pick<ConnectionCatalogEntry, "mcp" | "openapi">, protocol: ConnectionProtocol): McpEndpoint | OpenApiEndpoint | null;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{connectionEntries,connectionProtocols}from"#compiled/@eve/catalog/index.js";const SUPPORTED_PROTOCOLS=[`mcp`],CUSTOM_CONNECTION_SLUG=`custom`,CONNECTION_AUTH={"browser-use":{kind:`header`,headers:[{header:`x-browser-use-api-key`,envVar:`BROWSER_USE_API_KEY`}]},linear:{kind:`connect`,connector:`linear`,service:`mcp.linear.app`},notion:{kind:`connect`,connector:`notion`,service:`mcp.notion.com`},datadog:{kind:`connect`,connector:`datadog`,service:`mcp.datadoghq.com`},honeycomb:{kind:`connect`,connector:`honeycomb`,service:`mcp.honeycomb.io`}};function buildCatalogEntry(e,t,n){let r=CONNECTION_AUTH[e];if(r===void 0)throw Error(`Connection "${e}" is in the catalog but has no scaffolder auth overlay.`);let i={slug:e,label:t,protocols:connectionProtocols(n),description:n.description,auth:r};return n.mcp&&(i.mcp={url:n.mcp.url}),n.openapi&&(i.openapi={spec:n.openapi.spec,baseUrl:n.openapi.baseUrl}),i}const CONNECTION_CATALOG=connectionEntries().filter(e=>e.surfaces.scaffoldable).map(e=>{if(e.connection===void 0)throw Error(`Catalog connection "${e.slug}" is missing its connection identity.`);return buildCatalogEntry(e.slug,e.name,e.connection)}),CATALOG_BY_SLUG=new Map(CONNECTION_CATALOG.map(e=>[e.slug,e]));function getCatalogEntry(e){return CATALOG_BY_SLUG.get(e)}function catalogSlugs(){return CONNECTION_CATALOG.map(e=>e.slug)}function effectiveProtocols(e){let t=e===void 0||e.length===0?SUPPORTED_PROTOCOLS:e;return SUPPORTED_PROTOCOLS.filter(e=>t.includes(e))}const CONNECTION_SLUG_PATTERN=/^[a-z][a-z0-9-]{0,63}$/;function isValidConnectionSlug(e){return CONNECTION_SLUG_PATTERN.test(e)}function
|
|
1
|
+
import{connectionEntries,connectionProtocols}from"#compiled/@eve/catalog/index.js";const SUPPORTED_PROTOCOLS=[`mcp`],CUSTOM_CONNECTION_SLUG=`custom`,CONNECTION_AUTH={"browser-use":{kind:`header`,headers:[{header:`x-browser-use-api-key`,envVar:`BROWSER_USE_API_KEY`}]},linear:{kind:`connect`,connector:`linear`,service:`mcp.linear.app`},notion:{kind:`connect`,connector:`notion`,service:`mcp.notion.com`},datadog:{kind:`connect`,connector:`datadog`,service:`mcp.datadoghq.com`},honeycomb:{kind:`connect`,connector:`honeycomb`,service:`mcp.honeycomb.io`}};function buildCatalogEntry(e,t,n){let r=CONNECTION_AUTH[e];if(r===void 0)throw Error(`Connection "${e}" is in the catalog but has no scaffolder auth overlay.`);let i={slug:e,label:t,protocols:connectionProtocols(n),description:n.description,auth:r};return n.mcp&&(i.mcp={url:n.mcp.url}),n.openapi&&(i.openapi={spec:n.openapi.spec,baseUrl:n.openapi.baseUrl}),i}const CONNECTION_CATALOG=connectionEntries().filter(e=>e.surfaces.scaffoldable).map(e=>{if(e.connection===void 0)throw Error(`Catalog connection "${e.slug}" is missing its connection identity.`);return buildCatalogEntry(e.slug,e.name,e.connection)}),CATALOG_BY_SLUG=new Map(CONNECTION_CATALOG.map(e=>[e.slug,e]));function getCatalogEntry(e){return CATALOG_BY_SLUG.get(e)}function catalogSlugs(){return CONNECTION_CATALOG.map(e=>e.slug)}function effectiveProtocols(e){let t=e===void 0||e.length===0?SUPPORTED_PROTOCOLS:e;return SUPPORTED_PROTOCOLS.filter(e=>t.includes(e))}const CONNECTION_SLUG_PATTERN=/^[a-z][a-z0-9-]{0,63}$/;function isValidConnectionSlug(e){return CONNECTION_SLUG_PATTERN.test(e)}function endpointForProtocol(e,t){return t===`mcp`?e.mcp??null:e.openapi??null}export{CONNECTION_CATALOG,CUSTOM_CONNECTION_SLUG,SUPPORTED_PROTOCOLS,catalogSlugs,effectiveProtocols,endpointForProtocol,getCatalogEntry,isValidConnectionSlug};
|
|
@@ -16,7 +16,7 @@ export interface AddAgentToProjectOptions {
|
|
|
16
16
|
connectPackageVersion?: string;
|
|
17
17
|
zodPackageVersion?: string;
|
|
18
18
|
}
|
|
19
|
-
|
|
19
|
+
interface AddAgentToProjectResult {
|
|
20
20
|
filesWritten: string[];
|
|
21
21
|
configurationFilesChanged: string[];
|
|
22
22
|
/** Dependencies added to package.json; ones the project already declares anywhere are left untouched. */
|
|
@@ -33,3 +33,4 @@ export interface AddAgentToProjectResult {
|
|
|
33
33
|
* is written.
|
|
34
34
|
*/
|
|
35
35
|
export declare function addAgentToProject(options: AddAgentToProjectOptions): Promise<AddAgentToProjectResult>;
|
|
36
|
+
export {};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{pinnedNodeEngineMajor}from"../../node-engine.js";import{parseChatGptModelSelection}from"../../../shared/chatgpt-model.js";import{SUPPORTED_AUTHORED_MODULE_FILE_EXTENSIONS}from"../update/module-files.js";import{pathExists,writeTextFile}from"../files.js";import{blockingCreateInPlaceEntries}from"../create-in-place.js";import{DEFAULT_CONNECT_PACKAGE_VERSION,resolveVersionToken}from"../version-tokens.js";import{applyPackageManagerWorkspaceConfiguration,isPackageManagerWorkspaceMember,patchWorkspaceRootPackageJson}from"../workspace-root.js";import{WEB_CHANNEL_TEMPLATES}from"./web-template.js";import{mkdir,readdir,stat}from"node:fs/promises";import{basename,join,resolve}from"node:path";const CURRENT_DIRECTORY_PROJECT_NAME=`.`,DEFAULT_AI_PACKAGE_VERSION=`^7.0.105`,DEFAULT_ZOD_PACKAGE_VERSION=`4.5.4`,DEFAULT_EVE_PACKAGE_CONTRACT={version:`0.67.
|
|
1
|
+
import{pinnedNodeEngineMajor}from"../../node-engine.js";import{parseChatGptModelSelection}from"../../../shared/chatgpt-model.js";import{SUPPORTED_AUTHORED_MODULE_FILE_EXTENSIONS}from"../update/module-files.js";import{pathExists,writeTextFile}from"../files.js";import{blockingCreateInPlaceEntries}from"../create-in-place.js";import{DEFAULT_CONNECT_PACKAGE_VERSION,resolveVersionToken}from"../version-tokens.js";import{applyPackageManagerWorkspaceConfiguration,isPackageManagerWorkspaceMember,patchWorkspaceRootPackageJson}from"../workspace-root.js";import{WEB_CHANNEL_TEMPLATES}from"./web-template.js";import{mkdir,readdir,stat}from"node:fs/promises";import{basename,join,resolve}from"node:path";const CURRENT_DIRECTORY_PROJECT_NAME=`.`,DEFAULT_AI_PACKAGE_VERSION=`^7.0.105`,DEFAULT_ZOD_PACKAGE_VERSION=`4.5.4`,DEFAULT_EVE_PACKAGE_CONTRACT={version:`0.67.2`,nodeEngine:`>=24`};function resolveEvePackageContract(e=DEFAULT_EVE_PACKAGE_CONTRACT){return{version:resolveVersionToken(`evePackage.version`,e.version),nodeEngine:resolveVersionToken(`evePackage.nodeEngine`,e.nodeEngine)}}function modelProviderSlug(e){let t=(e.split(`/`)[0]??``).replaceAll(/[^A-Za-z0-9._-]/gu,``);return t.length>0?t:`anthropic`}function byokProviderEnvVar(e){let t=modelProviderSlug(e).toUpperCase().replaceAll(/[^A-Z0-9]/gu,`_`);return`${/^[0-9]/.test(t)?`_`:``}${t}_API_KEY`}function agentTemplateFiles(e,t){return{"agent/agent.ts":renderAgentTemplate(e,t),"agent/channels/eve.ts":WEB_CHANNEL_TEMPLATES.default,"agent/instructions.md":AGENT_INSTRUCTIONS_TEMPLATE}}function renderAgentTemplate(e,t){let n=parseChatGptModelSelection(e);return n===void 0?BASE_AGENT_TEMPLATE.replaceAll(`__EVE_INIT_MODEL__`,e).replaceAll(`__EVE_INIT_REASONING__`,reasoningTemplateLine(t)):`import { defineAgent } from "eve";\nimport { chatgpt } from "eve/models/openai";\n\nexport default defineAgent({\n model: chatgpt(${JSON.stringify(n)}),\n${reasoningTemplateLine(t)}});\n`}function reasoningTemplateLine(e){return e===void 0||e===`provider-default`?``:` reasoning: "${e}",\n`}function renderTemplate(e,t){return e===BASE_AGENT_TEMPLATE&&parseChatGptModelSelection(t.model)!==void 0?renderAgentTemplate(t.model,t.reasoning):e.replaceAll(`__EVE_INIT_APP_NAME__`,t.appName).replaceAll(`__EVE_INIT_MODEL__`,t.model).replaceAll(`__EVE_INIT_REASONING__`,reasoningTemplateLine(t.reasoning)).replaceAll(`__EVE_INIT_BYOK_PROVIDER__`,modelProviderSlug(t.model)).replaceAll(`__EVE_INIT_BYOK_ENV_VAR__`,byokProviderEnvVar(t.model)).replaceAll(`__EVE_INIT_PACKAGE_VERSION__`,formatEveDependencySpecifier(t.eveVersion)).replaceAll(`__EVE_INIT_AI_SDK_VERSION__`,t.aiPackageVersion).replaceAll(`__EVE_INIT_CONNECT_VERSION__`,t.connectPackageVersion).replaceAll(`__EVE_INIT_ZOD_VERSION__`,t.zodPackageVersion).replaceAll(`__EVE_INIT_TYPESCRIPT_VERSION__`,t.typescriptPackageVersion).replaceAll(`__EVE_INIT_TYPES_NODE_VERSION__`,t.nodeTypesVersion).replaceAll(`__EVE_INIT_NODE_ENGINE__`,t.nodeEngine)}function formatEveDependencySpecifier(e){return/^\d+\.\d+\.\d+(?:[-+][0-9A-Za-z-.]+)?$/.test(e)?`^${e}`:e}const BASE_AGENT_TEMPLATE=`import { defineAgent } from "eve";
|
|
2
2
|
|
|
3
3
|
export default defineAgent({
|
|
4
4
|
model: "__EVE_INIT_MODEL__",
|
|
@@ -3,7 +3,8 @@ export declare class WriteFileExistsError extends Error {
|
|
|
3
3
|
readonly path: string;
|
|
4
4
|
constructor(path: string);
|
|
5
5
|
}
|
|
6
|
-
|
|
6
|
+
interface WriteFileOptions {
|
|
7
7
|
force?: boolean;
|
|
8
8
|
}
|
|
9
9
|
export declare function writeTextFile(path: string, content: string, options?: WriteFileOptions): Promise<void>;
|
|
10
|
+
export {};
|
|
@@ -16,7 +16,6 @@ export interface PackageJsonMutation {
|
|
|
16
16
|
devDependencies: string[];
|
|
17
17
|
scripts: string[];
|
|
18
18
|
}
|
|
19
|
-
export type ChannelMutationAction = "created" | "overwritten" | "skipped";
|
|
20
19
|
export type ChannelMutationResult = SlackChannelMutationResult | WebChannelMutationResult;
|
|
21
20
|
interface SlackChannelWrittenResult {
|
|
22
21
|
kind: "slack";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{existsSync,readFileSync,realpathSync}from"node:fs";import{dirname,join}from"node:path";import{fileURLToPath}from"node:url";function versionToken(e){return`__${e}_VERSION__`}function bareToken(e){return`__${e}__`}const NODE_ENGINE_TOKEN=bareToken(`NODE_ENGINE`),DEFAULT_CONNECT_PACKAGE_VERSION=`2.2.0`,DEFAULT_MICROSANDBOX_PACKAGE_VERSION=`0.5.5`,TOKEN_SOURCES={[versionToken(`EVE_PACKAGE`)]:{kind:`eve-version`},[versionToken(`EVE_PACKAGE_DEPENDENCY`)]:{kind:`eve-version`},[NODE_ENGINE_TOKEN]:{kind:`eve-node-engine`},[versionToken(`AI_SDK`)]:{kind:`catalog`,packageName:`ai`},[versionToken(`NEXT`)]:{kind:`catalog`,packageName:`next`},[versionToken(`REACT`)]:{kind:`catalog`,packageName:`react`},[versionToken(`REACT_DOM`)]:{kind:`catalog`,packageName:`react-dom`},[versionToken(`STREAMDOWN`)]:{kind:`catalog`,packageName:`streamdown`},[versionToken(`ZOD`)]:{kind:`catalog`,packageName:`zod`},[versionToken(`TYPESCRIPT`)]:{kind:`catalog`,packageName:`typescript`},[versionToken(`TYPES_REACT`)]:{kind:`catalog`,packageName:`@types/react`},[versionToken(`TYPES_REACT_DOM`)]:{kind:`catalog`,packageName:`@types/react-dom`}},resolvedTokens=new Map;function findEvePackageRoot(){let e=dirname(realpathSync(fileURLToPath(import.meta.url)));for(;;){let t=join(e,`package.json`);if(existsSync(t)&&JSON.parse(readFileSync(t,`utf8`)).name===`eve`)return e;let n=dirname(e);if(n===e)return;e=n}}function findWorkspaceManifest(e){let t=e;for(;;){let e=join(t,`pnpm-workspace.yaml`);if(existsSync(e))return e;let n=dirname(t);if(n===t)return;t=n}}function readCatalogVersion(e,t){let n=readFileSync(e,`utf8`).split(/\r?\n/),r=!1;for(let e of n){if(/^catalog:\s*$/.test(e)){r=!0;continue}if(!r)continue;if(/^\S/.test(e))break;let n=e.match(/^\s+(?:"([^"]+)"|([\w@/.-]+)):\s*"([^"]+)"/);if(n&&(n[1]??n[2])===t)return n[3]}}function resolveTokenFromDevTree(e){let t=TOKEN_SOURCES[e];if(t!==void 0)try{let e=findEvePackageRoot();if(e===void 0||!existsSync(join(e,`scripts/stamp-version-tokens.mjs`)))return;if(t.kind===`eve-version`){let t=JSON.parse(readFileSync(join(e,`package.json`),`utf8`));return typeof t.version==`string`?t.version:void 0}if(t.kind===`eve-node-engine`){let t=JSON.parse(readFileSync(join(e,`package.json`),`utf8`)).engines?.node;return typeof t==`string`?t:void 0}let n=findWorkspaceManifest(e);return n===void 0?void 0:readCatalogVersion(n,t.packageName)}catch{return}}function resolveVersionToken(e,t){if(!t.startsWith(`__`))return t;let n=resolvedTokens.get(t);if(n!==void 0)return n;let r=resolveTokenFromDevTree(t);if(r===void 0)throw Error(`Scaffold received unstamped version token (${e}=${t}). Build eve before using its dist entrypoint.`);return resolvedTokens.set(t,r),r}export{DEFAULT_CONNECT_PACKAGE_VERSION,DEFAULT_MICROSANDBOX_PACKAGE_VERSION,resolveVersionToken};
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
export declare function workspaceRelativePath(workspaceRoot: string, projectRoot: string): string;
|
|
2
1
|
export declare function isPathInside(parentPath: string, childPath: string): boolean;
|
|
3
2
|
export declare function workspacePatternForProject(workspaceRoot: string, projectRoot: string): string;
|
|
4
3
|
export declare function workspacePatternClaimsRelativePath(pattern: string, relativePath: string): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isAbsolute,relative,resolve,sep}from"node:path";function escapeRegex(e){return e.replace(/[\\^$+?.()|[\]{}]/gu,`\\$&`)}function workspacePatternToRegex(e){let t=e.replaceAll(`\\`,`/`).replace(/^\.\/+/u,``),n=`^`;for(let e=0;e<t.length;e+=1){let r=t[e];r===`*`?t[e+1]===`*`?(n+=`.*`,e+=1):n+=`[^/]*`:n+=escapeRegex(r??``)}return n+=`$`,new RegExp(n,`u`)}function workspaceRelativePath(e,t){return relative(e,resolve(t)).split(sep).join(`/`)}function isPathInside(e,t){let n=relative(resolve(e),resolve(t));return n===``||!n.startsWith(`..`)&&!isAbsolute(n)}function workspacePatternForProject(e,t){let n=workspaceRelativePath(e,t);if(n.length===0)return`.`;let r=n.split(`/`);return r.length===1?n:`${r.slice(0,-1).join(`/`)}/*`}function workspacePatternClaimsRelativePath(e,t){let n=e.replaceAll(`\\`,`/`).replace(/^\.\/+/u,``);return n===`.`||n===t||workspacePatternToRegex(n).test(t)}function workspacePatternsClaimProject(e,t,n){let r=workspaceRelativePath(t,n),i=e.filter(e=>!e.startsWith(`!`)),a=e.filter(e=>e.startsWith(`!`)).map(e=>e.slice(1));return i.some(e=>workspacePatternClaimsRelativePath(e,r))?!a.some(e=>workspacePatternClaimsRelativePath(e,r)):!1}export{isPathInside,workspacePatternClaimsRelativePath,workspacePatternForProject,workspacePatternsClaimProject
|
|
1
|
+
import{isAbsolute,relative,resolve,sep}from"node:path";function escapeRegex(e){return e.replace(/[\\^$+?.()|[\]{}]/gu,`\\$&`)}function workspacePatternToRegex(e){let t=e.replaceAll(`\\`,`/`).replace(/^\.\/+/u,``),n=`^`;for(let e=0;e<t.length;e+=1){let r=t[e];r===`*`?t[e+1]===`*`?(n+=`.*`,e+=1):n+=`[^/]*`:n+=escapeRegex(r??``)}return n+=`$`,new RegExp(n,`u`)}function workspaceRelativePath(e,t){return relative(e,resolve(t)).split(sep).join(`/`)}function isPathInside(e,t){let n=relative(resolve(e),resolve(t));return n===``||!n.startsWith(`..`)&&!isAbsolute(n)}function workspacePatternForProject(e,t){let n=workspaceRelativePath(e,t);if(n.length===0)return`.`;let r=n.split(`/`);return r.length===1?n:`${r.slice(0,-1).join(`/`)}/*`}function workspacePatternClaimsRelativePath(e,t){let n=e.replaceAll(`\\`,`/`).replace(/^\.\/+/u,``);return n===`.`||n===t||workspacePatternToRegex(n).test(t)}function workspacePatternsClaimProject(e,t,n){let r=workspaceRelativePath(t,n),i=e.filter(e=>!e.startsWith(`!`)),a=e.filter(e=>e.startsWith(`!`)).map(e=>e.slice(1));return i.some(e=>workspacePatternClaimsRelativePath(e,r))?!a.some(e=>workspacePatternClaimsRelativePath(e,r)):!1}export{isPathInside,workspacePatternClaimsRelativePath,workspacePatternForProject,workspacePatternsClaimProject};
|
|
@@ -6,7 +6,7 @@ export interface WorkspaceRootMutation {
|
|
|
6
6
|
nodeEngineOverride?: NodeEngineOverride;
|
|
7
7
|
path: string;
|
|
8
8
|
}
|
|
9
|
-
|
|
9
|
+
interface WorkspaceRootPackageJsonPatchResult extends PackageJsonPatchResult {
|
|
10
10
|
/** Root package.json path when an ancestor workspace root was eligible for patching. */
|
|
11
11
|
path?: string;
|
|
12
12
|
}
|
|
@@ -26,3 +26,4 @@ export declare function applyPackageManagerWorkspaceConfiguration(input: {
|
|
|
26
26
|
filesSkipped: string[];
|
|
27
27
|
filesWritten: string[];
|
|
28
28
|
}>;
|
|
29
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{isPathInside,workspacePatternForProject,workspacePatternsClaimProject}from"./workspace-glob.js";import{ensurePnpmWorkspaceIncludesProject,findAncestorPnpmWorkspaceRoot}from"../primitives/pm/pnpm.js";import{getPackageManagerStrategy}from"../primitives/pm/index.js";import{patchPackageJson}from"./update/package-json.js";import{readFile,writeFile}from"node:fs/promises";import{
|
|
1
|
+
import{isPathInside,workspacePatternForProject,workspacePatternsClaimProject}from"./workspace-glob.js";import{ensurePnpmWorkspaceIncludesProject,findAncestorPnpmWorkspaceRoot}from"../primitives/pm/pnpm.js";import{getPackageManagerStrategy}from"../primitives/pm/index.js";import{patchPackageJson}from"./update/package-json.js";import{readFile,writeFile}from"node:fs/promises";import{existsSync,readFileSync}from"node:fs";import{dirname,join,resolve}from"node:path";function isJsonObject(e){return typeof e==`object`&&!!e&&!Array.isArray(e)}function packageJsonWorkspacePatterns(e){let t=e.workspaces;return Array.isArray(t)?t.filter(e=>typeof e==`string`):!isJsonObject(t)||!Array.isArray(t.packages)?[]:t.packages.filter(e=>typeof e==`string`)}function readPackageJsonWorkspacePatterns(e){let t=JSON.parse(readFileSync(e,`utf8`));if(!isJsonObject(t))return;let n=packageJsonWorkspacePatterns(t);return n.length===0?void 0:n}function findAncestorPackageJsonWorkspaceRoot(e){let t=dirname(resolve(e));for(;;){let e=join(t,`package.json`);if(existsSync(e))try{if(readPackageJsonWorkspacePatterns(e)!==void 0)return t}catch{}let n=dirname(t);if(n===t)return;t=n}}function findClaimingPackageJsonWorkspaceRoot(e){let t=findAncestorPackageJsonWorkspaceRoot(e);if(t===void 0)return;let n;try{n=readPackageJsonWorkspacePatterns(join(t,`package.json`))}catch{return}return n!==void 0&&workspacePatternsClaimProject(n,t,e)?t:void 0}function findPackageManagerWorkspaceRoot(e,t){switch(e){case`pnpm`:return findAncestorPnpmWorkspaceRoot(t);case`bun`:case`npm`:case`yarn`:return findAncestorPackageJsonWorkspaceRoot(t)}}function isPackageManagerWorkspaceMember(e,t){let n=findPackageManagerWorkspaceRoot(e,t);return n!==void 0&&resolve(n)!==resolve(t)}function workspaceRootPackageJsonPath(e,t){let n=findPackageManagerWorkspaceRoot(e,t);return n===void 0?void 0:join(n,`package.json`)}async function ensurePackageJsonWorkspaceIncludesProject(e){let t=findAncestorPackageJsonWorkspaceRoot(e);if(t===void 0||resolve(t)===resolve(e)||findClaimingPackageJsonWorkspaceRoot(e)===t)return;let n=join(t,`package.json`),r=JSON.parse(await readFile(n,`utf8`)),i=workspacePatternForProject(t,e);if(Array.isArray(r.workspaces))r.workspaces=[...r.workspaces,i];else if(isJsonObject(r.workspaces)&&Array.isArray(r.workspaces.packages))r.workspaces={...r.workspaces,packages:[...r.workspaces.packages,i]};else return;return await writeFile(n,`${JSON.stringify(r,null,2)}\n`,`utf8`),n}async function ensurePackageManagerWorkspaceIncludesProject(e,t){switch(e){case`pnpm`:{let e=findAncestorPnpmWorkspaceRoot(t);return e===void 0?void 0:await ensurePnpmWorkspaceIncludesProject(t)===`written`?join(e,`pnpm-workspace.yaml`):void 0}case`bun`:case`npm`:case`yarn`:return ensurePackageJsonWorkspaceIncludesProject(t)}}async function patchWorkspaceRootPackageJson(e,t,n){if(!isPackageManagerWorkspaceMember(e,t))return{changed:!1};let r=workspaceRootPackageJsonPath(e,t);if(r===void 0||!existsSync(r))return{changed:!1};let i=await patchPackageJson(r,{nodeEngineRequirement:n.nodeEngineRequirement});return i.changed&&await n.onWorkspaceRootMutation?.({kind:`package-json`,nodeEngineOverride:i.nodeEngineOverride,path:r}),{...i,path:r}}async function applyPackageManagerWorkspaceConfiguration(e){let t=resolve(e.workspaceProbeRoot??e.projectRoot),n=e.packageManager===`pnpm`?void 0:await ensurePackageManagerWorkspaceIncludesProject(e.packageManager,t),r=await getPackageManagerStrategy(e.packageManager).applyProjectConfiguration(e.projectRoot,{workspaceProbeRoot:t}),i=[...n===void 0?[]:[n],...r.filesWritten],a=[...r.filesSkipped];for(let t of i)isPathInside(e.projectRoot,t)||await e.onWorkspaceRootMutation?.({kind:`workspace-config`,path:t});return{filesSkipped:a,filesWritten:i}}export{applyPackageManagerWorkspaceConfiguration,isPackageManagerWorkspaceMember,patchWorkspaceRootPackageJson};
|
|
@@ -7,7 +7,7 @@ export interface SlackConnectorCreateDeps {
|
|
|
7
7
|
delay?: (ms: number, signal?: AbortSignal) => Promise<void>;
|
|
8
8
|
now?: () => number;
|
|
9
9
|
}
|
|
10
|
-
|
|
10
|
+
type SlackConnectorCreateResult = {
|
|
11
11
|
state: "created";
|
|
12
12
|
via: "cli";
|
|
13
13
|
ref: SlackConnectorRef;
|
|
@@ -8,7 +8,7 @@ export interface SlackConnectLifecycleDeps {
|
|
|
8
8
|
captureVercel: typeof captureVercel;
|
|
9
9
|
runVercel: typeof runVercel;
|
|
10
10
|
}
|
|
11
|
-
|
|
11
|
+
type SlackConnectorInventory = {
|
|
12
12
|
state: "ok";
|
|
13
13
|
body: unknown;
|
|
14
14
|
connectors: readonly RawSlackConnector[];
|
|
@@ -24,7 +24,7 @@ export type SlackConnectorCleanupResult = {
|
|
|
24
24
|
};
|
|
25
25
|
type CommandOutput = ReturnType<typeof createPromptCommandOutput>;
|
|
26
26
|
/** Shared dependencies and output routing for one connector cleanup operation. */
|
|
27
|
-
|
|
27
|
+
interface SlackConnectorCleanupContext {
|
|
28
28
|
log: ChannelSetupLog;
|
|
29
29
|
deps: SlackConnectLifecycleDeps;
|
|
30
30
|
projectRoot: string;
|
|
@@ -52,7 +52,7 @@ export declare function findSlackConnector(deps: SlackConnectLifecycleDeps, proj
|
|
|
52
52
|
* while an old trigger destination may still exist. A `detach-failed` connector
|
|
53
53
|
* is left in a known-stale state the caller surfaces with manual recovery steps.
|
|
54
54
|
*/
|
|
55
|
-
|
|
55
|
+
type SlackConnectorAttachmentResult = ConnectTriggerAttachmentResult;
|
|
56
56
|
/**
|
|
57
57
|
* Replaces the connector's default trigger destination with the eve route:
|
|
58
58
|
* detach the existing destination first, then attach this project. Either
|
|
@@ -60,7 +60,7 @@ export type SlackConnectorAttachmentResult = ConnectTriggerAttachmentResult;
|
|
|
60
60
|
* rather than silently left pointing at the wrong place.
|
|
61
61
|
*/
|
|
62
62
|
export declare function attachSlackConnector(deps: SlackConnectLifecycleDeps, projectRoot: string, ref: SlackConnectorRef, onOutput: CommandOutput, signal?: AbortSignal): Promise<SlackConnectorAttachmentResult>;
|
|
63
|
-
|
|
63
|
+
type SlackWorkspaceLookup = {
|
|
64
64
|
state: "connected";
|
|
65
65
|
workspace: SlackWorkspaceConnection;
|
|
66
66
|
} | {
|
|
@@ -69,7 +69,7 @@ export type SlackWorkspaceLookup = {
|
|
|
69
69
|
state: "failed";
|
|
70
70
|
message: string;
|
|
71
71
|
};
|
|
72
|
-
|
|
72
|
+
type SlackConnectorDetailsLookup = {
|
|
73
73
|
state: "found";
|
|
74
74
|
details: SlackConnectorDetails;
|
|
75
75
|
} | {
|
|
@@ -40,10 +40,6 @@ export declare function parseSlackConnectorDetails(body: unknown): SlackConnecto
|
|
|
40
40
|
* Returns `undefined` when stdout is empty or not the expected JSON.
|
|
41
41
|
*/
|
|
42
42
|
export declare function parseCreatedSlackConnector(stdout: string): SlackConnectorRef | undefined;
|
|
43
|
-
/**
|
|
44
|
-
* Finds the expected connector, or the newest Slack connector already attached to this project.
|
|
45
|
-
*/
|
|
46
|
-
export declare function pickSlackConnector(listJson: unknown, projectId: string | undefined, expectedUid: string | undefined): SlackConnectorRef | undefined;
|
|
47
43
|
/**
|
|
48
44
|
* Turns a Slack `app_redirect` install URL into a deep link that opens the
|
|
49
45
|
* Messages tab, a DM compose with the bot, instead of the app's about page.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"#compiled/zod/index.js";const NonEmptyStringSchema=z.string().min(1),SlackConnectorDetailsSchema=z.object({uid:NonEmptyStringSchema,id:NonEmptyStringSchema}).extend({data:z.object({appId:NonEmptyStringSchema.nullish(),slackTeam:z.object({id:NonEmptyStringSchema,name:NonEmptyStringSchema.nullish()}).nullish()}).nullish()});function parseSlackConnectorDetails(e){let t=SlackConnectorDetailsSchema.safeParse(e);if(!t.success)return;let{id:n,uid:r,data:i}=t.data,a={id:n,uid:r};if(i?.appId==null||i.slackTeam==null)return{ref:a};let o=new URL(`https://slack.com/app_redirect`);return o.searchParams.set(`app`,i.appId),o.searchParams.set(`team`,i.slackTeam.id),{ref:a,workspace:i.slackTeam.name==null?{workspaceUrl:o.href}:{workspaceUrl:o.href,workspaceName:i.slackTeam.name}}}function parseCreatedSlackConnector(e){let t=e.trim();if(!t)return;let n;try{n=JSON.parse(t)}catch{return}return parseSlackConnectorDetails(n)?.ref}function
|
|
1
|
+
import{z}from"#compiled/zod/index.js";const NonEmptyStringSchema=z.string().min(1),SlackConnectorDetailsSchema=z.object({uid:NonEmptyStringSchema,id:NonEmptyStringSchema}).extend({data:z.object({appId:NonEmptyStringSchema.nullish(),slackTeam:z.object({id:NonEmptyStringSchema,name:NonEmptyStringSchema.nullish()}).nullish()}).nullish()});function parseSlackConnectorDetails(e){let t=SlackConnectorDetailsSchema.safeParse(e);if(!t.success)return;let{id:n,uid:r,data:i}=t.data,a={id:n,uid:r};if(i?.appId==null||i.slackTeam==null)return{ref:a};let o=new URL(`https://slack.com/app_redirect`);return o.searchParams.set(`app`,i.appId),o.searchParams.set(`team`,i.slackTeam.id),{ref:a,workspace:i.slackTeam.name==null?{workspaceUrl:o.href}:{workspaceUrl:o.href,workspaceName:i.slackTeam.name}}}function parseCreatedSlackConnector(e){let t=e.trim();if(!t)return;let n;try{n=JSON.parse(t)}catch{return}return parseSlackConnectorDetails(n)?.ref}function slackMessageDeepLink(e){let t=URL.parse(e);return t===null||!t.pathname.endsWith(`/app_redirect`)||!t.searchParams.has(`app`)||!t.searchParams.has(`team`)?e:(t.searchParams.set(`tab`,`messages`),t.href)}function parseSlackConnectors(e){if(typeof e!=`object`||!e)return[];let t=e,n=t.connectors??t.clients;if(!Array.isArray(n))return[];let r=[];for(let e of n){if(e.type!==`slack`||typeof e.uid!=`string`)continue;let t=Array.isArray(e.projects)?e.projects.map(e=>typeof e==`object`&&e?e.id:void 0).filter(e=>typeof e==`string`):[],n={uid:e.uid,projectIds:t,createdAt:typeof e.createdAt==`number`?e.createdAt:0};typeof e.id==`string`&&(n.id=e.id),r.push(n)}return r}export{parseCreatedSlackConnector,parseSlackConnectorDetails,parseSlackConnectors,slackMessageDeepLink};
|
|
@@ -3,9 +3,8 @@ import { type ChannelSetupAwaitChoice, type ChannelSetupLog } from "#setup/cli/i
|
|
|
3
3
|
import type { SlackConnectorRef } from "./slack-connect.js";
|
|
4
4
|
import { type SlackConnectorCreateDeps } from "./slack-connect-create.js";
|
|
5
5
|
import { type SlackConnectLifecycleDeps, type SlackConnectorLookup } from "./slack-connect-lifecycle.js";
|
|
6
|
-
export { parseCreatedSlackConnector, parseSlackConnectorDetails, pickSlackConnector, type SlackConnectorRef, } from "./slack-connect.js";
|
|
7
6
|
/** Injected for tests; defaults to the real Vercel CLI subprocess primitives. */
|
|
8
|
-
|
|
7
|
+
interface SlackbotProvisionDeps extends SlackConnectLifecycleDeps, SlackConnectorCreateDeps {
|
|
9
8
|
/** Test seam for the linked Vercel project and team lookup. */
|
|
10
9
|
readProjectLink?: typeof readProjectLink;
|
|
11
10
|
/** Test seam for the workspace poll's pacing; defaults to a real sleep. */
|
|
@@ -65,7 +64,7 @@ export type SlackConnectorSelection = SlackConnectorRef | "create";
|
|
|
65
64
|
export declare function inspectSlackbotConnectors(log: ChannelSetupLog, projectRoot: string, slug: string, signal?: AbortSignal, deps?: SlackbotProvisionDeps): Promise<Extract<SlackConnectorLookup, {
|
|
66
65
|
state: "found" | "not-found";
|
|
67
66
|
}>>;
|
|
68
|
-
|
|
67
|
+
interface ProvisionSlackbotOptions {
|
|
69
68
|
/**
|
|
70
69
|
* Cancels the caller's whole operation. The promise rejects after attempting
|
|
71
70
|
* cleanup; only the explicit interactive Cancel action returns `cancelled`.
|
|
@@ -83,3 +82,4 @@ slug: string, deps?: SlackbotProvisionDeps, options?: ProvisionSlackbotOptions):
|
|
|
83
82
|
* Patches a connector UID chosen by Connect before the caller deploys the channel definition.
|
|
84
83
|
*/
|
|
85
84
|
export declare function reconcileSlackUid(log: ChannelSetupLog, projectRoot: string, slackbot: ProvisionSlackbotResult, expectedUid: string): Promise<boolean>;
|
|
85
|
+
export {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{CONNECT_LOOKUP_TIMEOUT_MS,attachSlackConnector,cleanupCreatedAttempt,fetchSlackWorkspace,findSlackConnector,listSlackConnectors}from"./slack-connect-lifecycle.js";import{createSlackConnector}from"./slack-connect-create.js";import{join}from"node:path";import{SLACK_CHANNEL_DEFAULT_ROUTE}from"#setup/scaffold/index.js";import{readProjectLink}from"#setup/project-resolution.js";import{performance}from"node:perf_hooks";import{captureVercel,runVercel,runVercelCaptureStdout}from"#setup/primitives/run-vercel.js";import{setTimeout}from"node:timers/promises";import{createPromptCommandOutput,withPhase}from"#setup/cli/index.js";import{updateSlackChannelConnectorUid}from"#setup/scaffold/update/update-slack-channel.js";const defaultDeps={captureVercel,runVercel,runVercelCaptureStdout},realDelay=(e,t)=>setTimeout(e,void 0,{signal:t}),monotonicNow=()=>performance.now();async function pollSlackWorkspace(e,t,n,r,i,a){let o=e.delay??realDelay,s=e.now??monotonicNow,c=s()+3e5;for(;;){a?.throwIfAborted();let l=c-s();if(l<=0)return{state:`timed-out`};let u=await fetchSlackWorkspace({deps:e,projectRoot:t,connectorId:n,orgId:r,onOutput:i,timeoutMs:Math.min(CONNECT_LOOKUP_TIMEOUT_MS,l),signal:a});if(a?.throwIfAborted(),u.state!==`pending`)return u;let d=c-s();if(d<=0)return{state:`timed-out`};await o(Math.min(3e3,d),a)}}function isAbortFromSignal(e,t){return t?.aborted===!0&&(e===t.reason||e instanceof Error&&e.name===`AbortError`)}function cleanupFailureResult(e){return{state:`cleanup-failed`,connectorUids:e.connectorUids}}async function runAttempt(e){let{log:t,deps:n,projectRoot:r,orgId:i,onOutput:a,signal:o,phase:s}=e,c,l;if(e.source.state===`existing`)c=e.source.ref;else{let u=await createSlackConnector({deps:n,projectRoot:r,orgId:i,slug:e.slug,onOutput:a,signal:o,phase:s,onCreated:e.onCreated,waitForWorkspace:async(e,t)=>{let o=await pollSlackWorkspace(n,r,e.id,i,a,t);return o.state===`connected`?o.workspace:void 0}});if(u.state===`failed`)return{state:`create-failed`};if(u.state===`unresolved`)return t.warning(`Vercel did not return an exact Slack connector UID for this request, so eve cannot attach or remove it safely.`),{state:`unresolved`};c=u.ref,u.via===`workspace`&&(l=u.workspace)}if(e.source.state===`existing`&&l===void 0){let e=await s(`Waiting for the Slack workspace connection...`,()=>pollSlackWorkspace(n,r,c.id,i,a,o));if(e.state===`timed-out`)return{state:`timed-out`,ref:c};if(e.state===`failed`)return{state:`failed`,ref:c,message:e.message};l=e.workspace}let u=await s(`Configuring Slack event delivery for this agent...`,()=>attachSlackConnector(n,r,c,a,o));return o?.throwIfAborted(),u.state===`attached`?l===void 0?{state:`attached`,ref:c}:{state:`attached`,ref:c,workspace:l}:{state:u.state,ref:c}}async function raceAttemptAgainstChoice(e){let t=new AbortController,n=e.outerSignal?AbortSignal.any([e.outerSignal,t.signal]):t.signal,r=e.run(n);try{let i=await Promise.race([r.then(e=>({via:`work`,outcome:e})),e.prompt.choice.then(e=>({via:`choice`,choice:e}))]);if(i.via===`work`)return i;t.abort();let a;try{a=await r}catch(e){if(!isAbortFromSignal(e,n))throw e}return{via:`choice`,choice:i.choice,settled:a}}catch(e){t.abort();try{await r}catch{}throw e}finally{e.prompt.close()}}async function inspectSlackbotConnectors(e,t,n,r,i=defaultDeps){let a=await(i.readProjectLink??readProjectLink)(t),o=await findSlackConnector(i,t,a?.projectId,`slack/${n}`,createPromptCommandOutput(e),r);if(o.state===`failed`)throw Error(o.message);return o}async function provisionSlackbot(e,t,n,r=defaultDeps,i={}){i.signal?.throwIfAborted();let a=createPromptCommandOutput(e),o={log:e,deps:r,projectRoot:t,onOutput:a},s=await(r.readProjectLink??readProjectLink)(t),c=s?.projectId,l=s?.orgId,u=`slack/${n}`,d=await withPhase(e,`Checking for an existing Slackbot...`,()=>findSlackConnector(r,t,c,u,a,i.signal));if(i.signal?.throwIfAborted(),d.state===`failed`)return e.warning(`Could not inspect existing Slack connectors, so eve did not create another one. ${d.message}`),{state:`connector-lookup-failed`};if(c===void 0&&d.connectorUids.size>0)return e.warning("Could not verify which Slack connectors belong to this Vercel project, so eve did not create another one. Restore `.vercel/project.json`, then try again."),{state:`connector-lookup-failed`};let finishOutcome=async(t,n,r)=>{let i=n.state===`new`;switch(t.state){case`create-failed`:if(i){let e=await r();if(e.state===`failed`)return cleanupFailureResult(e)}return{state:`create-failed`};case`unresolved`:if(i){let e=await r();if(e.state===`failed`)return cleanupFailureResult(e)}return{state:`create-failed`};case`detach-failed`:return e.warning(`Could not remove the connector's existing trigger destination. Run \`vercel connect detach ${t.ref.uid} --yes\`, then \`vercel connect attach ${t.ref.uid} --triggers --trigger-path ${SLACK_CHANNEL_DEFAULT_ROUTE} --yes\`.`),{state:`detach-failed`,connectorUid:t.ref.uid};case`attach-failed`:return e.warning(`Could not register this project as a trigger destination. Run \`vercel connect attach ${t.ref.uid} --triggers --trigger-path ${SLACK_CHANNEL_DEFAULT_ROUTE} --yes\` to enable event delivery.`),{state:`attach-failed`,connectorUid:t.ref.uid};case`attached`:return t.workspace===void 0?{state:`attached`,connectorUid:t.ref.uid}:{state:`attached`,connectorUid:t.ref.uid,chatUrl:t.workspace.workspaceUrl,workspaceName:t.workspace.workspaceName};case`failed`:return e.warning(`Could not verify the Slack workspace connection. ${t.message}`),{state:`installation-check-failed`,connectorUid:t.ref.uid};case`timed-out`:if(e.warning(`The Slackbot did not connect to a Slack workspace in time.`),i){let e=await r();if(e.state===`failed`)return cleanupFailureResult(e)}return{state:`not-installed`}}},cleanupNewAttempt=async(e,t)=>cleanupCreatedAttempt(o,{expectedUid:u,baselineConnectorUids:e.baselineConnectorUids,createdRef:t});function attemptInput(i,o){return{log:e,deps:r,projectRoot:t,orgId:l,slug:n,source:i,onOutput:a,onCreated:o}}async function runExistingConnector(t){let cleanupCurrentAttempt=async()=>({state:`clean`}),notInstalled=()=>(e.warning(`The existing Slack connector \`${t.ref.uid}\` is not connected to a Slack workspace. eve did not remove it because this run did not create it. If its original browser request is still open, complete it; otherwise run \`vercel connect remove ${t.ref.uid} --disconnect-all --yes\` before trying again.`),{state:`existing-not-installed`,connectorUid:t.ref.uid}),finishExistingOutcome=async e=>e.state===`timed-out`?notInstalled():finishOutcome(e,t,cleanupCurrentAttempt);if(i.awaitChoice!==void 0){let e=await raceAttemptAgainstChoice({prompt:i.awaitChoice({status:`Waiting for the existing Slack workspace connection...`,context:`Complete the original setup in the browser`,actions:[{value:`cancel`,label:`Stop waiting`}]}),outerSignal:i.signal,run:e=>runAttempt({...attemptInput(t,()=>{}),signal:e,phase:(e,t)=>t()})});return e.via===`work`?finishExistingOutcome(e.outcome):e.settled?.state===`attached`?finishExistingOutcome(e.settled):notInstalled()}return finishExistingOutcome(await runAttempt({...attemptInput(t,()=>{}),signal:i.signal,phase:(t,n)=>withPhase(e,t,n)}))}async function runUncontrolledAttempt(t){let n,cleanupCurrentAttempt=()=>cleanupNewAttempt(t,n),r=runAttempt({...attemptInput(t,e=>{n=e}),signal:i.signal,phase:(t,n)=>withPhase(e,t,n)});try{return await finishOutcome(await r,t,cleanupCurrentAttempt)}catch(e){throw i.signal?.aborted===!0&&await cleanupCurrentAttempt(),e}}async function runInteractiveAttempt(n,o){let s,cleanupCurrentAttempt=()=>cleanupNewAttempt(n,s),c=o({status:`Waiting for Slack setup to finish...`,context:`Complete setup in the browser, then wait while eve verifies the connection`,actions:[{value:`retry`,label:`Did your browser not open? Try again`},{value:`cancel`,label:`Cancel`}]}),l;try{l=await raceAttemptAgainstChoice({prompt:c,outerSignal:i.signal,run:t=>runAttempt({...attemptInput(n,e=>{s=e}),signal:t,phase:e.spinner===void 0?(e,t)=>t():(t,n)=>withPhase(e,t,n)})})}catch(e){throw await cleanupCurrentAttempt(),e}if(l.via===`work`)return{state:`finished`,result:await finishOutcome(l.outcome,n,cleanupCurrentAttempt)};if(l.settled?.state===`attached`)return{state:`finished`,result:await finishOutcome(l.settled,n,cleanupCurrentAttempt)};let u=await cleanupCurrentAttempt();if(u.state===`failed`)return{state:`finished`,result:cleanupFailureResult(u)};if(l.choice===`retry`){let n=await withPhase(e,`Checking existing Slack connectors...`,()=>listSlackConnectors(r,t,a,i.signal));return i.signal?.throwIfAborted(),n.state===`failed`?(e.warning(`Could not inspect existing Slack connectors, so eve did not create another one. ${n.message}`),{state:`finished`,result:{state:`connector-lookup-failed`}}):{state:`retry`,source:{state:`new`,baselineConnectorUids:new Set(n.connectors.map(e=>e.uid))}}}return{state:`finished`,result:{state:`cancelled`}}}if(d.state===`found`){let e=i.selectConnector===void 0?d.preferred??d.connectors[0]:await i.selectConnector(d.connectors,d.preferred);if(i.signal?.throwIfAborted(),e!==`create`)return runExistingConnector({state:`existing`,ref:e})}let f={state:`new`,baselineConnectorUids:d.connectorUids};if(i.awaitChoice===void 0)return runUncontrolledAttempt(f);for(;;){let e=await runInteractiveAttempt(f,i.awaitChoice);if(e.state===`finished`)return e.result;f=e.source}}async function reconcileSlackUid(e,t,n,r){if(n.state!==`attached`||n.connectorUid===r)return!0;let i=join(t,`agent/channels/slack.ts`),{patched:a}=await updateSlackChannelConnectorUid(i,n.connectorUid);return a?!0:(e.warning(`Could not patch agent/channels/slack.ts automatically. Update \`connectSlackCredentials("...")\` to \`"${n.connectorUid}"\` and run \`vercel deploy --prod\`.`),!1)}export{inspectSlackbotConnectors,provisionSlackbot,reconcileSlackUid};
|
|
@@ -3,7 +3,5 @@ import type { VercelCaptureFailure, VercelCaptureResult } from "#setup/primitive
|
|
|
3
3
|
export declare function normalizeVercelApiResult(result: VercelCaptureResult): VercelCaptureResult;
|
|
4
4
|
/** Whether a Vercel API failure proves that the requested resource does not exist. */
|
|
5
5
|
export declare function isNotFoundApiFailure(failure: VercelCaptureFailure): boolean;
|
|
6
|
-
/** Whether a Vercel API failure proves that the requested resource already exists. */
|
|
7
|
-
export declare function isConflictApiFailure(failure: VercelCaptureFailure): boolean;
|
|
8
6
|
/** Whether a scoped Vercel API request was denied. */
|
|
9
7
|
export declare function isForbiddenApiFailure(failure: VercelCaptureFailure): boolean;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"#compiled/zod/index.js";const VercelApiErrorSchema=z.object({error:z.object({code:z.union([z.string(),z.number()]).optional(),message:z.string().optional()}).optional()});function apiErrorFromStdout(e){try{let t=VercelApiErrorSchema.safeParse(JSON.parse(e));return t.success?t.data.error:void 0}catch{return}}function apiFailureText(e){let t=apiErrorFromStdout(e.stdout);return`${String(t?.code??``)} ${t?.message??``} ${e.stderr}`.toLowerCase()}function normalizeVercelApiResult(e){if(!e.ok)return e;let t=apiErrorFromStdout(e.stdout);if(t===void 0)return e;let n=t.message??(t.code===void 0?void 0:String(t.code));return{ok:!1,failure:{stdout:e.stdout,stderr:``,message:`Vercel API request failed${n===void 0?``:`: ${n}`}.`}}}function isNotFoundApiFailure(e){return/(^|\W)(404|not_found)(\W|$)|not found/.test(apiFailureText(e))}function
|
|
1
|
+
import{z}from"#compiled/zod/index.js";const VercelApiErrorSchema=z.object({error:z.object({code:z.union([z.string(),z.number()]).optional(),message:z.string().optional()}).optional()});function apiErrorFromStdout(e){try{let t=VercelApiErrorSchema.safeParse(JSON.parse(e));return t.success?t.data.error:void 0}catch{return}}function apiFailureText(e){let t=apiErrorFromStdout(e.stdout);return`${String(t?.code??``)} ${t?.message??``} ${e.stderr}`.toLowerCase()}function normalizeVercelApiResult(e){if(!e.ok)return e;let t=apiErrorFromStdout(e.stdout);if(t===void 0)return e;let n=t.message??(t.code===void 0?void 0:String(t.code));return{ok:!1,failure:{stdout:e.stdout,stderr:``,message:`Vercel API request failed${n===void 0?``:`: ${n}`}.`}}}function isNotFoundApiFailure(e){return/(^|\W)(404|not_found)(\W|$)|not found/.test(apiFailureText(e))}function isForbiddenApiFailure(e){return/(^|\W)(403|forbidden|not_authorized|team_unauthorized|sso|saml)(\W|$)|not authorized/.test(apiFailureText(e))}export{isForbiddenApiFailure,isNotFoundApiFailure,normalizeVercelApiResult};
|
|
@@ -16,7 +16,7 @@ declare const VercelProjectListEntrySchema: z.ZodObject<{
|
|
|
16
16
|
}, z.core.$strip>;
|
|
17
17
|
export type VercelProjectListEntry = z.infer<typeof VercelProjectListEntrySchema>;
|
|
18
18
|
/** One ranked Vercel project search page and its optional continuation cursor. */
|
|
19
|
-
|
|
19
|
+
interface VercelProjectSearchPage {
|
|
20
20
|
readonly projects: VercelProjectListEntry[];
|
|
21
21
|
readonly next?: number;
|
|
22
22
|
}
|
|
@@ -1,11 +1,10 @@
|
|
|
1
1
|
import { createPromptCommandOutput } from "#setup/cli/index.js";
|
|
2
|
-
import {
|
|
3
|
-
import { readProjectLink, type ProjectResolution } from "./project-resolution.js";
|
|
2
|
+
import { type ProjectResolution } from "./project-resolution.js";
|
|
4
3
|
import type { Prompter } from "./prompter.js";
|
|
5
4
|
import type { ResolvedVercelProjectSpec, VercelProjectIdentity } from "./state.js";
|
|
6
5
|
import { type VercelProjectOperationOptions } from "./vercel-project-api.js";
|
|
7
6
|
import { type CreatedProjectFrameworkOptions } from "./vercel-project-framework.js";
|
|
8
|
-
|
|
7
|
+
interface PickProjectOptions extends VercelProjectOperationOptions {
|
|
9
8
|
/** Whether an empty project list may fall back to entering a name to create. */
|
|
10
9
|
allowCreateWhenEmpty?: boolean;
|
|
11
10
|
/**
|
|
@@ -15,7 +14,7 @@ export interface PickProjectOptions extends VercelProjectOperationOptions {
|
|
|
15
14
|
*/
|
|
16
15
|
suggestedName?: string;
|
|
17
16
|
}
|
|
18
|
-
|
|
17
|
+
interface PickTeamOptions extends VercelProjectOperationOptions {
|
|
19
18
|
/** Builds the team selector heading from the current team's display name. */
|
|
20
19
|
selectMessage?: (currentTeam: string) => string;
|
|
21
20
|
}
|
|
@@ -23,42 +22,10 @@ export interface LinkProjectOperationOptions extends CreatedProjectFrameworkOpti
|
|
|
23
22
|
/** Configure 100% trace sampling when creating a Vercel project. */
|
|
24
23
|
traceSampling?: boolean;
|
|
25
24
|
}
|
|
26
|
-
/** Effects used to ensure an interactive Vercel project link. */
|
|
27
|
-
export interface EnsureLinkedVercelProjectDeps {
|
|
28
|
-
readProjectLink: typeof readProjectLink;
|
|
29
|
-
runVercel: typeof runVercel;
|
|
30
|
-
}
|
|
31
|
-
/**
|
|
32
|
-
* Returns the existing Vercel project link or creates one through the Vercel
|
|
33
|
-
* CLI's interactive flow. The CLI owns team and project selection.
|
|
34
|
-
*/
|
|
35
|
-
export declare function ensureLinkedVercelProject(input: {
|
|
36
|
-
projectRoot: string;
|
|
37
|
-
prompter: Prompter;
|
|
38
|
-
signal?: AbortSignal;
|
|
39
|
-
deps?: EnsureLinkedVercelProjectDeps;
|
|
40
|
-
}): Promise<NonNullable<Awaited<ReturnType<typeof readProjectLink>>>>;
|
|
41
25
|
export declare function unresolvedProject(): ProjectResolution;
|
|
42
|
-
/** Resolves the linked project id from a resolution, if any. */
|
|
43
|
-
export declare function projectIdFromResolution(project: ProjectResolution): string | undefined;
|
|
44
26
|
/** Resolves one project by exact name or id through the Vercel API. */
|
|
45
27
|
export declare function resolveProjectByNameOrId(projectRoot: string, team: string, projectNameOrId: string, options?: VercelProjectOperationOptions): Promise<VercelProjectIdentity | null>;
|
|
46
28
|
export declare function assertNewProjectNameAvailable(projectRoot: string, team: string, projectName: string, options?: VercelProjectOperationOptions): Promise<void>;
|
|
47
|
-
/**
|
|
48
|
-
* Throws the login action. When the underlying `vercel whoami` failure is
|
|
49
|
-
* known, its diagnostic is folded into the reason: without it the agent only
|
|
50
|
-
* ever hears "log in", even when the real fault is a missing CLI or a transient
|
|
51
|
-
* API error and the user is already authenticated.
|
|
52
|
-
*/
|
|
53
|
-
export declare function requireVercelLogin(failure?: VercelCaptureFailure): never;
|
|
54
|
-
/**
|
|
55
|
-
* Throws the right outcome for a failed `vercel whoami`. ENOENT means the
|
|
56
|
-
* binary isn't installed (its own action, not a login that would fail
|
|
57
|
-
* identically); the explicit not-authenticated diagnostic is a login action;
|
|
58
|
-
* anything else is a transient fault surfaced as a plain error, so the caller
|
|
59
|
-
* reports "try again" rather than mislabeling it "log in".
|
|
60
|
-
*/
|
|
61
|
-
export declare function requireVercelAuth(failure: VercelCaptureFailure): never;
|
|
62
29
|
/**
|
|
63
30
|
* The Vercel auth state, read-only. `cli-missing` (ENOENT) and `unavailable` (a
|
|
64
31
|
* transient network/API fault) are each kept distinct from `logged-out` so a
|
|
@@ -67,8 +34,6 @@ export declare function requireVercelAuth(failure: VercelCaptureFailure): never;
|
|
|
67
34
|
* not-authenticated diagnostic.
|
|
68
35
|
*/
|
|
69
36
|
export type VercelAuthStatus = "authenticated" | "logged-out" | "cli-missing" | "unavailable";
|
|
70
|
-
/** Returns the user-facing reason Vercel-backed setup is unavailable. */
|
|
71
|
-
export declare function vercelAuthBlockerReason(authStatus: VercelAuthStatus): string | undefined;
|
|
72
37
|
export declare function getVercelAuthStatus(projectRoot: string, options?: VercelProjectOperationOptions): Promise<VercelAuthStatus>;
|
|
73
38
|
/**
|
|
74
39
|
* Ensures Vercel authentication before any provisioning. `vercel whoami` exits
|
|
@@ -118,3 +83,4 @@ export declare function pickNewProjectName(prompter: Prompter, projectRoot: stri
|
|
|
118
83
|
* Returns the linked project, or undefined if `vercel link` did not complete.
|
|
119
84
|
*/
|
|
120
85
|
export declare function linkProject(prompter: Prompter, projectRoot: string, spec: ResolvedVercelProjectSpec, onOutput: ReturnType<typeof createPromptCommandOutput>, options?: LinkProjectOperationOptions): Promise<VercelProjectIdentity | undefined>;
|
|
86
|
+
export {};
|
|
Binary file
|
|
@@ -26,7 +26,7 @@ declare const runtimeSubagentCallActionRequestSchema: z.ZodObject<{
|
|
|
26
26
|
subagentName: z.ZodString;
|
|
27
27
|
}, z.core.$strict>;
|
|
28
28
|
export type RuntimeRemoteAgentCallActionRequest = z.infer<typeof runtimeRemoteAgentCallActionRequestSchema>;
|
|
29
|
-
|
|
29
|
+
declare const runtimeRemoteAgentCallActionRequestSchema: z.ZodObject<{
|
|
30
30
|
callId: z.ZodString;
|
|
31
31
|
description: z.ZodString;
|
|
32
32
|
input: z.ZodType<import("#shared/json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonObject, unknown>>;
|
|
@@ -122,41 +122,6 @@ export declare function markRuntimeWorkflowToolAction(action: RuntimeToolCallAct
|
|
|
122
122
|
export declare function isRuntimeWorkflowToolAction(action: RuntimeActionRequest): boolean;
|
|
123
123
|
/** Internal agent dispatch request owned by a workflow task. */
|
|
124
124
|
export type RuntimeAgentDispatchRequest = RuntimeRemoteAgentDispatchRequest | RuntimeSubagentDispatchRequest;
|
|
125
|
-
/**
|
|
126
|
-
* Zod schema for one runtime action request.
|
|
127
|
-
*/
|
|
128
|
-
export declare const runtimeActionRequestSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
129
|
-
callId: z.ZodString;
|
|
130
|
-
input: z.ZodType<import("#shared/json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonObject, unknown>>;
|
|
131
|
-
kind: z.ZodLiteral<"load-skill">;
|
|
132
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
133
|
-
callId: z.ZodString;
|
|
134
|
-
description: z.ZodString;
|
|
135
|
-
input: z.ZodType<import("#shared/json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonObject, unknown>>;
|
|
136
|
-
kind: z.ZodLiteral<"remote-agent-call">;
|
|
137
|
-
name: z.ZodString;
|
|
138
|
-
nodeId: z.ZodString;
|
|
139
|
-
remoteAgentName: z.ZodString;
|
|
140
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
141
|
-
callId: z.ZodString;
|
|
142
|
-
description: z.ZodString;
|
|
143
|
-
input: z.ZodType<import("#shared/json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonObject, unknown>>;
|
|
144
|
-
kind: z.ZodLiteral<"subagent-call">;
|
|
145
|
-
name: z.ZodString;
|
|
146
|
-
nodeId: z.ZodString;
|
|
147
|
-
subagentName: z.ZodString;
|
|
148
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
149
|
-
callId: z.ZodString;
|
|
150
|
-
input: z.ZodType<import("#shared/json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonObject, unknown>>;
|
|
151
|
-
kind: z.ZodLiteral<"tool-call">;
|
|
152
|
-
toolName: z.ZodString;
|
|
153
|
-
}, z.core.$strict>, z.ZodObject<{
|
|
154
|
-
callId: z.ZodString;
|
|
155
|
-
input: z.ZodType<import("#shared/json.js").JsonObject, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonObject, unknown>>;
|
|
156
|
-
kind: z.ZodLiteral<"workflow-tool-call">;
|
|
157
|
-
toolName: z.ZodString;
|
|
158
|
-
workflowId: z.ZodString;
|
|
159
|
-
}, z.core.$strict>], "kind">;
|
|
160
125
|
/**
|
|
161
126
|
* Runtime-owned authored tool-result projected back into a harness resume call.
|
|
162
127
|
*/
|
|
@@ -211,28 +176,6 @@ export interface RuntimeSubagentChildResult {
|
|
|
211
176
|
readonly subagentName: string;
|
|
212
177
|
readonly usage?: import("#shared/token-usage.js").TokenUsage;
|
|
213
178
|
}
|
|
214
|
-
/** Token-only subagent result schema retained for historical wire formats. */
|
|
215
|
-
export declare const runtimeSubagentChildResultSchema: z.ZodObject<{
|
|
216
|
-
backgroundTask: z.ZodOptional<z.ZodObject<{
|
|
217
|
-
status: z.ZodLiteral<"working">;
|
|
218
|
-
taskId: z.ZodString;
|
|
219
|
-
}, z.core.$strict>>;
|
|
220
|
-
callId: z.ZodString;
|
|
221
|
-
isError: z.ZodOptional<z.ZodBoolean>;
|
|
222
|
-
kind: z.ZodLiteral<"subagent-result">;
|
|
223
|
-
origin: z.ZodLiteral<"child">;
|
|
224
|
-
outcome: z.ZodType<import("#shared/agent-turn-outcome.js").AgentTurnOutcome, unknown, z.core.$ZodTypeInternals<import("#shared/agent-turn-outcome.js").AgentTurnOutcome, unknown>>;
|
|
225
|
-
output: z.ZodType<import("#shared/json.js").JsonValue, unknown, z.core.$ZodTypeInternals<import("#shared/json.js").JsonValue, unknown>>;
|
|
226
|
-
subagentName: z.ZodString;
|
|
227
|
-
usage: z.ZodOptional<z.ZodObject<{
|
|
228
|
-
cacheReadTokens: z.ZodNumber;
|
|
229
|
-
cacheWriteTokens: z.ZodNumber;
|
|
230
|
-
inputTokens: z.ZodNumber;
|
|
231
|
-
outputTokens: z.ZodNumber;
|
|
232
|
-
}, z.core.$strip>>;
|
|
233
|
-
}, z.core.$strict>;
|
|
234
|
-
/** Current subagent result schema, including optional model token cost. */
|
|
235
|
-
export declare const runtimeSubagentChildResultWithCostSchema: z.ZodType<RuntimeSubagentChildResult>;
|
|
236
179
|
/**
|
|
237
180
|
* Subagent failure synthesized on the parent side when no child produced a
|
|
238
181
|
* result: dispatch rejections, start failures, and agentId-continuation
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{z}from"#compiled/zod/index.js";import{jsonObjectSchema,jsonValueSchema}from"#shared/json-schemas.js";
|
|
1
|
+
import{z}from"#compiled/zod/index.js";import{jsonObjectSchema,jsonValueSchema}from"#shared/json-schemas.js";const runtimeToolCallActionRequestSchema=z.object({callId:z.string(),input:jsonObjectSchema,kind:z.literal(`tool-call`),toolName:z.string()}).strict();z.object({callId:z.string(),description:z.string(),input:jsonObjectSchema,kind:z.literal(`subagent-call`),name:z.string(),nodeId:z.string(),subagentName:z.string()}).strict(),z.object({callId:z.string(),description:z.string(),input:jsonObjectSchema,kind:z.literal(`remote-agent-call`),name:z.string(),nodeId:z.string(),remoteAgentName:z.string()}).strict(),z.object({callId:z.string(),input:jsonObjectSchema,kind:z.literal(`workflow-tool-call`),toolName:z.string(),workflowId:z.string()}).strict(),z.object({callId:z.string(),description:z.string(),input:jsonObjectSchema,kind:z.literal(`subagent-call`),name:z.string(),nodeId:z.string(),subagentName:z.string()}).strict();const runtimeRemoteAgentDispatchRequestSchema=z.object({callId:z.string(),description:z.string(),input:jsonObjectSchema,kind:z.literal(`remote-agent-call`),name:z.string(),nodeId:z.string(),remoteAgentName:z.string()}).strict(),runtimeWorkflowTaskRequestSchema=z.object({callId:z.string(),executeInput:jsonValueSchema.optional(),input:jsonObjectSchema,kind:z.literal(`workflow-task`),nodeId:z.string().optional(),toolName:z.string(),workflowId:z.string()}).strict();z.object({callId:z.string(),input:jsonObjectSchema,kind:z.literal(`load-skill`)}).strict();const RUNTIME_WORKFLOW_TOOL_ACTION=Symbol.for(`eve:runtime-workflow-tool-action`);function markRuntimeWorkflowToolAction(e){return Object.defineProperty(e,RUNTIME_WORKFLOW_TOOL_ACTION,{value:!0}),e}function isRuntimeWorkflowToolAction(e){return e.kind===`workflow-tool-call`||e.kind===`tool-call`&&Reflect.get(e,RUNTIME_WORKFLOW_TOOL_ACTION)===!0}z.object({callId:z.string(),isError:z.boolean().optional(),kind:z.literal(`tool-result`),output:jsonValueSchema,toolName:z.string()}).strict(),z.object({callId:z.string(),isError:z.literal(!0),kind:z.literal(`subagent-result`),origin:z.literal(`dispatch`),output:jsonValueSchema,subagentName:z.string()}).strict(),z.object({callId:z.string(),isError:z.boolean().optional(),kind:z.literal(`load-skill-result`),output:jsonValueSchema,name:z.string().optional()}).strict();export{isRuntimeWorkflowToolAction,markRuntimeWorkflowToolAction,runtimeRemoteAgentDispatchRequestSchema,runtimeToolCallActionRequestSchema,runtimeWorkflowTaskRequestSchema};
|
|
@@ -65,9 +65,6 @@ export interface PublicAgentModelSelectionDefinition {
|
|
|
65
65
|
export type PublicAgentDynamicModelResult = PublicAgentStaticModelDefinition | PublicAgentModelSelectionDefinition;
|
|
66
66
|
export type AgentModelResolver = (event: unknown, ctx: AgentModelResolveContext) => PublicAgentDynamicModelResult | Promise<PublicAgentDynamicModelResult>;
|
|
67
67
|
export type PublicAgentDynamicModelDefinition = DynamicSentinel<PublicAgentDynamicModelResult>;
|
|
68
|
-
export interface PublicAgentDynamicModelDefinitionInput {
|
|
69
|
-
readonly events: DynamicSentinel<PublicAgentDynamicModelResult>["events"];
|
|
70
|
-
}
|
|
71
68
|
export declare function isDynamicModelDefinition(value: unknown): value is PublicAgentDynamicModelDefinition;
|
|
72
69
|
/**
|
|
73
70
|
* The model handle you assign to an agent's `model` field.
|