eve 0.75.0 → 0.76.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +54 -0
- package/dist/src/_virtual/_rolldown/runtime.js +1 -1
- package/dist/src/acp/adapter.js +1 -1
- package/dist/src/channel/task-card.js +1 -1
- package/dist/src/channel/tool-eligibility.d.ts +1 -2
- package/dist/src/chunks/{use-eve-agent-B2Kne9z6.js → use-eve-agent-D2V9UhLt.js} +68 -10
- package/dist/src/chunks/{use-eve-agent-DK_T88EP.js → use-eve-agent-QmriPA-w.js} +68 -10
- package/dist/src/cli/commands/deploy.js +1 -1
- package/dist/src/cli/commands/link.d.ts +2 -1
- package/dist/src/cli/commands/link.js +1 -1
- package/dist/src/cli/commands/registry.js +1 -1
- package/dist/src/cli/commands/vercel-non-interactive.d.ts +6 -4
- package/dist/src/cli/commands/vercel-non-interactive.js +1 -1
- package/dist/src/cli/dev/environment.d.ts +0 -6
- package/dist/src/cli/dev/environment.js +1 -1
- package/dist/src/cli/dev/tui/conversation-view.js +1 -1
- package/dist/src/cli/dev/tui/runner.js +1 -1
- package/dist/src/cli/dev/tui/tool-presentation.js +1 -1
- package/dist/src/cli/dev/tui/transcript.js +1 -1
- package/dist/src/client/message-action-parts.d.ts +3 -0
- package/dist/src/client/message-action-parts.js +1 -1
- package/dist/src/client/message-reducer-types.d.ts +6 -1
- package/dist/src/client/message-reducer.js +1 -1
- package/dist/src/compiled/.vendor-stamp.json +9 -8
- package/dist/src/compiled/@eve/catalog/index.js +1 -1
- package/dist/src/compiled/@vercel/queue/index.d.ts +1066 -0
- package/dist/src/compiled/@vercel/queue/index.js +47 -0
- package/dist/src/compiled/@workflow/core/global.d.ts +10 -0
- package/dist/src/compiled/@workflow/core/index.js +1 -1
- package/dist/src/compiled/@workflow/core/private.d.ts +11 -0
- package/dist/src/compiled/@workflow/core/private.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime/constants.d.ts +36 -8
- package/dist/src/compiled/@workflow/core/runtime/helpers.js +1 -1
- package/dist/src/compiled/@workflow/core/runtime/lifecycle-hooks.d.ts +10 -6
- package/dist/src/compiled/@workflow/core/runtime/out-of-band-observation.d.ts +159 -0
- package/dist/src/compiled/@workflow/core/runtime/vm-mode.d.ts +28 -4
- package/dist/src/compiled/@workflow/core/runtime.js +4 -4
- package/dist/src/compiled/@workflow/core/serialization.js +1 -1
- 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/world-local/index.js +5 -5
- package/dist/src/compiled/@workflow/world-vercel/index.js +4 -4
- package/dist/src/compiled/_chunks/workflow/{attribute-changes-CSqvJx6j.js → attribute-changes-BW-kbMMn.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/dist-CyBgVS7g.js +1 -0
- package/dist/src/compiled/_chunks/workflow/{helpers-BXCuoPUb.js → helpers-DlLD3ov_.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/private-tQUuwBoQ.js +1 -0
- package/dist/src/compiled/_chunks/workflow/{resume-hook-CvENCrxc.js → resume-hook-DMsV_b4n.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/{run-8pLWuR2U.js → run-DzdAqdb1.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/{serialization-vDozzDhh.js → serialization-DPdYS_w2.js} +2 -2
- package/dist/src/compiled/_chunks/workflow/sleep-BY6leHh8.js +1 -0
- package/dist/src/compiled/_chunks/workflow/{token-BKeK6DmC.js → token-D5ugC3PI.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/{token-util-CddTZ_ef.js → token-util-Bla5Z0G9.js} +1 -1
- package/dist/src/compiled/_chunks/workflow/undici-D-ILjOKD.js +95 -0
- package/dist/src/compiled/_chunks/workflow/{wait-until-A344L2AG.js → wait-until-xbRRDuUf.js} +1 -1
- package/dist/src/compiler/connection-ownership.d.ts +6 -0
- package/dist/src/compiler/connection-ownership.js +1 -0
- package/dist/src/compiler/default-tool-policy.d.ts +0 -3
- package/dist/src/compiler/default-tool-policy.js +1 -1
- package/dist/src/compiler/extension-compatibility.d.ts +21 -20
- package/dist/src/compiler/extension-compatibility.js +1 -1
- package/dist/src/compiler/manifest.d.ts +9 -6
- package/dist/src/compiler/manifest.js +1 -1
- package/dist/src/compiler/normalize-connection.js +1 -1
- package/dist/src/compiler/normalize-manifest.js +1 -1
- package/dist/src/compiler/normalize-skill.d.ts +5 -0
- package/dist/src/compiler/normalize-skill.js +1 -1
- package/dist/src/compiler/normalize-subagent.d.ts +2 -1
- package/dist/src/compiler/normalize-subagent.js +1 -1
- package/dist/src/compiler/normalize-tool.js +1 -1
- package/dist/src/compiler/remote-agent-node.d.ts +2 -1
- package/dist/src/compiler/remote-agent-node.js +1 -1
- package/dist/src/connections/ownership.d.ts +18 -0
- package/dist/src/connections/ownership.js +1 -0
- package/dist/src/context/build-dynamic-tools.d.ts +3 -9
- package/dist/src/context/build-dynamic-tools.js +1 -1
- package/dist/src/context/dynamic-connection-lifecycle.js +1 -1
- package/dist/src/context/dynamic-skill-lifecycle.d.ts +2 -11
- package/dist/src/context/dynamic-skill-lifecycle.js +1 -1
- package/dist/src/context/dynamic-subagent-lifecycle.js +1 -1
- package/dist/src/context/dynamic-tool-lifecycle.js +1 -1
- package/dist/src/context/dynamic-tool-metadata.d.ts +1 -0
- package/dist/src/context/keys.d.ts +5 -4
- package/dist/src/context/memory-tools.js +1 -1
- package/dist/src/context/schedule-collection-tools.js +1 -1
- package/dist/src/discover/grammar.d.ts +11 -0
- package/dist/src/discover/grammar.js +1 -1
- package/dist/src/discover/manifest.d.ts +1 -0
- package/dist/src/discover/manifest.js +1 -1
- package/dist/src/discover/skills.d.ts +1 -0
- package/dist/src/discover/skills.js +1 -1
- package/dist/src/dynamic/definition.d.ts +7 -5
- package/dist/src/evals/assertions/collector.d.ts +4 -0
- package/dist/src/evals/assertions/collector.js +1 -1
- package/dist/src/evals/assertions/run.d.ts +2 -3
- package/dist/src/evals/assertions/run.js +2 -2
- package/dist/src/evals/assertions/scoped.js +1 -1
- package/dist/src/evals/index.d.ts +1 -1
- package/dist/src/evals/match.d.ts +9 -6
- package/dist/src/evals/reported-tool-name.d.ts +9 -0
- package/dist/src/evals/reported-tool-name.js +1 -0
- package/dist/src/evals/runner/derive-run-facts.d.ts +3 -3
- package/dist/src/evals/runner/derive-run-facts.js +1 -1
- package/dist/src/evals/runner/execute-task.js +1 -1
- package/dist/src/evals/runner/reporters/braintrust.js +1 -1
- package/dist/src/evals/runner/reporters/datadog-runtime-trace-links.d.ts +11 -0
- package/dist/src/evals/runner/reporters/datadog-runtime-trace-links.js +1 -0
- package/dist/src/evals/runner/reporters/datadog.js +2 -2
- package/dist/src/evals/session.js +2 -2
- package/dist/src/evals/target.d.ts +7 -0
- package/dist/src/evals/target.js +1 -1
- package/dist/src/evals/types.d.ts +17 -1
- package/dist/src/eve-channel/request.js +1 -1
- package/dist/src/execution/agent-sessions/remote.js +1 -1
- package/dist/src/execution/catalog/connection-auth.d.ts +41 -0
- package/dist/src/execution/catalog/connection-auth.js +1 -0
- package/dist/src/execution/catalog/connection-entry.d.ts +16 -0
- package/dist/src/execution/catalog/connection-entry.js +1 -0
- package/dist/src/execution/catalog/listing.d.ts +9 -0
- package/dist/src/execution/catalog/listing.js +3 -0
- package/dist/src/execution/catalog/rank.d.ts +44 -0
- package/dist/src/execution/catalog/rank.js +1 -0
- package/dist/src/execution/catalog/search.d.ts +28 -0
- package/dist/src/execution/catalog/search.js +1 -0
- package/dist/src/execution/catalog/signatures.d.ts +11 -0
- package/dist/src/execution/catalog/signatures.js +1 -0
- package/dist/src/execution/catalog/skills.d.ts +24 -0
- package/dist/src/execution/catalog/skills.js +1 -0
- package/dist/src/execution/catalog/step-catalog.d.ts +51 -0
- package/dist/src/execution/catalog/step-catalog.js +1 -0
- package/dist/src/execution/coordination-dispatch-shared.js +1 -1
- package/dist/src/execution/dynamic-connections.js +1 -1
- package/dist/src/execution/dynamic-workflow/tool.js +1 -1
- package/dist/src/execution/invoke-tool.js +1 -1
- package/dist/src/execution/ndjson-stream.d.ts +6 -6
- package/dist/src/execution/ndjson-stream.js +3 -3
- package/dist/src/execution/node-step.js +1 -1
- package/dist/src/execution/session/active-turn.d.ts +1 -1
- package/dist/src/execution/session/pending-turn-state.js +1 -1
- package/dist/src/execution/session/turn-step.js +1 -1
- package/dist/src/execution/session/turn.d.ts +5 -5
- package/dist/src/execution/session/turn.js +1 -1
- package/dist/src/execution/session.js +1 -1
- package/dist/src/execution/skills/instructions.d.ts +20 -10
- package/dist/src/execution/skills/instructions.js +2 -2
- package/dist/src/execution/tasks/calls.d.ts +6 -5
- package/dist/src/execution/tasks/calls.js +1 -1
- package/dist/src/execution/tasks/model-step.d.ts +10 -10
- package/dist/src/execution/tasks/model-step.js +1 -1
- package/dist/src/execution/tasks/render.d.ts +3 -3
- package/dist/src/execution/tasks/render.js +3 -3
- package/dist/src/execution/tasks/session.d.ts +2 -1
- package/dist/src/execution/tasks/table.d.ts +1 -1
- package/dist/src/execution/tasks/tool-entry-point.d.ts +1 -1
- package/dist/src/execution/tool-auth.js +1 -1
- package/dist/src/execution/tools/agent-router-workflow.js +1 -1
- package/dist/src/execution/tools/workflow/harness-definition.js +1 -1
- package/dist/src/extensions/code/extension/extension.d.ts +4 -18
- package/dist/src/extensions/code/extension/instructions/github.d.ts +3 -0
- package/dist/src/extensions/code/extension/instructions/github.js +1 -0
- package/dist/src/extensions/code/extension/instructions.md +1 -13
- package/dist/src/extensions/code/extension/lib/diagnostics.d.ts +4 -2
- package/dist/src/extensions/code/extension/lib/diagnostics.js +3 -3
- package/dist/src/extensions/code/extension/lib/github-compat.d.ts +28 -0
- package/dist/src/extensions/code/extension/lib/github-compat.js +1 -0
- package/dist/src/extensions/code/extension/lib/grep-search.d.ts +3 -13
- package/dist/src/extensions/code/extension/lib/grep-search.js +2 -2
- package/dist/src/extensions/code/extension/lib/patch.d.ts +8 -2
- package/dist/src/extensions/code/extension/lib/patch.js +4 -4
- package/dist/src/extensions/code/extension/lib/repository-root.d.ts +3 -4
- package/dist/src/extensions/code/extension/lib/repository-root.js +1 -1
- package/dist/src/extensions/code/extension/lib/sandbox.d.ts +2 -1
- package/dist/src/extensions/code/extension/lib/sandbox.js +1 -1
- package/dist/src/extensions/code/extension/lib/tooling.d.ts +4 -4
- package/dist/src/extensions/code/extension/lib/tooling.js +7 -7
- package/dist/src/extensions/code/extension/lib/workspace-root.d.ts +31 -0
- package/dist/src/extensions/code/extension/lib/workspace-root.js +1 -0
- package/dist/src/extensions/code/extension/skills/pr.d.ts +6 -0
- package/dist/src/extensions/code/extension/skills/pr.js +1 -0
- package/dist/src/extensions/code/extension/tools/apply_patch.d.ts +2 -2
- package/dist/src/extensions/code/extension/tools/apply_patch.js +2 -2
- package/dist/src/extensions/code/extension/tools/gh.d.ts +4 -3
- package/dist/src/extensions/code/extension/tools/gh.js +1 -1
- package/dist/src/extensions/code/extension/tools/grep.js +1 -1
- package/dist/src/extensions/code/tools.d.ts +2 -1
- package/dist/src/extensions/code/tools.js +1 -1
- package/dist/src/extensions/git/extension/extension.d.ts +12 -0
- package/dist/src/extensions/git/extension/extension.js +1 -0
- package/dist/src/extensions/git/extension/instructions/github.d.ts +2 -0
- package/dist/src/extensions/git/extension/instructions/github.js +1 -0
- package/dist/src/extensions/git/extension/lib/gh-tool.d.ts +29 -0
- package/dist/src/extensions/git/extension/lib/gh-tool.js +1 -0
- package/dist/src/extensions/git/extension/lib/github-guidance.d.ts +3 -0
- package/dist/src/extensions/git/extension/lib/github-guidance.js +49 -0
- package/dist/src/extensions/{code → git}/extension/lib/github-shell.d.ts +1 -1
- package/dist/src/extensions/git/extension/lib/github-shell.js +1 -0
- package/dist/src/extensions/git/extension/lib/repository-root.d.ts +5 -0
- package/dist/src/extensions/git/extension/lib/repository-root.js +1 -0
- package/dist/src/extensions/git/extension/lib/sandbox.d.ts +6 -0
- package/dist/src/extensions/git/extension/lib/sandbox.js +1 -0
- package/dist/src/extensions/git/extension/lib/shell.d.ts +1 -0
- package/dist/src/extensions/git/extension/lib/shell.js +1 -0
- package/dist/src/extensions/git/extension/lib/tooling.d.ts +4 -0
- package/dist/src/extensions/git/extension/lib/tooling.js +1 -0
- package/dist/src/extensions/git/extension/skills/pr.d.ts +5 -0
- package/dist/src/extensions/git/extension/skills/pr.js +1 -0
- package/dist/src/extensions/git/extension/tools/gh.d.ts +28 -0
- package/dist/src/extensions/git/extension/tools/gh.js +1 -0
- package/dist/src/extensions/git/tools.d.ts +27 -0
- package/dist/src/extensions/git/tools.js +1 -0
- package/dist/src/framework/sources/registry.js +1 -1
- package/dist/src/harness/action-presentation.d.ts +2 -2
- package/dist/src/harness/action-result-helpers.d.ts +10 -2
- package/dist/src/harness/action-result-helpers.js +1 -1
- package/dist/src/harness/announcements.d.ts +2 -8
- package/dist/src/harness/announcements.js +1 -1
- package/dist/src/harness/compaction/engine.d.ts +8 -19
- package/dist/src/harness/compaction/engine.js +1 -1
- package/dist/src/harness/compaction/step.d.ts +7 -1
- package/dist/src/harness/compaction/step.js +1 -1
- package/dist/src/harness/coordination.d.ts +11 -11
- package/dist/src/harness/coordination.js +1 -1
- package/dist/src/harness/current-messages.d.ts +1 -5
- package/dist/src/harness/current-messages.js +1 -1
- package/dist/src/harness/emission.d.ts +2 -2
- package/dist/src/harness/emission.js +1 -1
- package/dist/src/harness/execute-call.d.ts +48 -0
- package/dist/src/harness/execute-call.js +1 -0
- package/dist/src/harness/execute-tool.d.ts +3 -1
- package/dist/src/harness/final-output.d.ts +2 -6
- package/dist/src/harness/final-output.js +1 -1
- package/dist/src/harness/hitl/approvals.d.ts +5 -0
- package/dist/src/harness/hitl/approvals.js +1 -1
- package/dist/src/harness/hitl/approved-calls.d.ts +3 -2
- package/dist/src/harness/hitl/approved-calls.js +1 -1
- package/dist/src/harness/hitl/candidates.d.ts +13 -2
- package/dist/src/harness/hitl/candidates.js +1 -1
- package/dist/src/harness/hitl/coordinator.d.ts +3 -3
- package/dist/src/harness/hitl/coordinator.js +1 -1
- package/dist/src/harness/hitl/index.d.ts +6 -4
- package/dist/src/harness/hitl/index.js +1 -1
- package/dist/src/harness/hitl/intake.d.ts +3 -3
- package/dist/src/harness/hitl/intake.js +1 -1
- package/dist/src/harness/input-extraction.d.ts +4 -1
- package/dist/src/harness/input-extraction.js +1 -1
- package/dist/src/harness/input-request-resolution.d.ts +15 -0
- package/dist/src/harness/input-request-resolution.js +1 -1
- package/dist/src/harness/model-call/call.d.ts +5 -8
- package/dist/src/harness/model-call/call.js +1 -1
- package/dist/src/harness/model-call/errors.js +1 -1
- package/dist/src/harness/model-call/model.d.ts +4 -5
- package/dist/src/harness/model-call/model.js +1 -1
- package/dist/src/harness/model-call/request.d.ts +4 -4
- package/dist/src/harness/model-call/request.js +1 -1
- package/dist/src/harness/model-call/response.d.ts +2 -1
- package/dist/src/harness/model-call/response.js +1 -1
- package/dist/src/harness/model-call/retry.d.ts +1 -1
- package/dist/src/harness/model-call/retry.js +1 -1
- package/dist/src/harness/model-call/run.d.ts +5 -3
- package/dist/src/harness/model-call/run.js +1 -1
- package/dist/src/harness/model-call/tools.d.ts +14 -24
- package/dist/src/harness/model-call/tools.js +1 -1
- package/dist/src/harness/model-call/usage.js +1 -1
- package/dist/src/harness/model-profile.d.ts +28 -0
- package/dist/src/harness/model-profile.js +1 -0
- package/dist/src/harness/prompt-cache.d.ts +5 -53
- package/dist/src/harness/prompt-cache.js +1 -1
- package/dist/src/harness/provider-safety.d.ts +3 -5
- package/dist/src/harness/provider-safety.js +1 -1
- package/dist/src/harness/provider-tools.d.ts +7 -14
- package/dist/src/harness/provider-tools.js +1 -1
- package/dist/src/harness/session-machine/commit.js +1 -1
- package/dist/src/harness/session-machine/transitions.d.ts +5 -2
- package/dist/src/harness/session-machine/transitions.js +1 -1
- package/dist/src/harness/step/after-model.js +1 -1
- package/dist/src/harness/step-hooks.d.ts +6 -9
- package/dist/src/harness/step-hooks.js +1 -1
- package/dist/src/harness/tool-call-input-errors.d.ts +2 -2
- package/dist/src/harness/tool-call-io.d.ts +3 -0
- package/dist/src/harness/tool-call-io.js +1 -1
- package/dist/src/harness/tools.d.ts +24 -22
- package/dist/src/harness/tools.js +1 -1
- package/dist/src/harness/turn-tag-state.d.ts +12 -0
- package/dist/src/harness/turn-tag-state.js +1 -1
- package/dist/src/harness/types.d.ts +14 -0
- package/dist/src/instrumentation/lifecycle.d.ts +0 -1
- package/dist/src/instrumentation/native-events.js +1 -1
- package/dist/src/instrumentation/runtime.d.ts +2 -1
- package/dist/src/internal/application/package.js +1 -1
- package/dist/src/internal/authored-definition/core.js +1 -1
- package/dist/src/internal/authored-definition/schedule-collection.js +1 -1
- package/dist/src/internal/authored-definition/schema-backed.d.ts +2 -2
- package/dist/src/internal/authored-definition/schema-backed.js +1 -1
- package/dist/src/internal/authored-module.d.ts +2 -1
- package/dist/src/internal/authored-module.js +1 -1
- package/dist/src/internal/gateway.d.ts +0 -13
- package/dist/src/internal/gateway.js +1 -1
- package/dist/src/internal/helpers/markdown.js +1 -1
- package/dist/src/internal/mcp/skills.js +1 -1
- package/dist/src/internal/nitro/host/create-application-nitro.js +1 -1
- package/dist/src/internal/nitro/host/dev-host-fingerprint.js +1 -1
- package/dist/src/internal/nitro/host/local-schedules-runtime-plugin.d.ts +5 -0
- package/dist/src/internal/nitro/host/local-schedules-runtime-plugin.js +1 -0
- package/dist/src/internal/nitro/routes/schedule-collection-consumer.d.ts +6 -0
- package/dist/src/internal/nitro/routes/schedule-collection-consumer.js +1 -1
- package/dist/src/internal/schedules/consumer-route.d.ts +2 -0
- package/dist/src/internal/schedules/consumer-route.js +1 -1
- package/dist/src/internal/schedules/dev-environment.d.ts +2 -0
- package/dist/src/internal/schedules/dev-environment.js +1 -0
- package/dist/src/internal/vercel-agent-summary.d.ts +2 -2
- package/dist/src/internal/workflow/vercel-world-defaults.d.ts +1 -1
- package/dist/src/internal/workflow/vercel-world-defaults.js +1 -1
- package/dist/src/protocol/catalog-tools.d.ts +12 -0
- package/dist/src/protocol/catalog-tools.js +1 -0
- package/dist/src/protocol/message-version.js +1 -1
- package/dist/src/protocol/message.d.ts +1 -1
- package/dist/src/protocol/remote-agent-protocol.d.ts +2 -0
- package/dist/src/protocol/remote-agent-protocol.js +1 -1
- package/dist/src/protocol/reply-tool.d.ts +2 -0
- package/dist/src/protocol/reply-tool.js +1 -0
- package/dist/src/protocol/runtime-tools.d.ts +6 -0
- package/dist/src/protocol/runtime-tools.js +1 -0
- package/dist/src/protocol/session-projection.js +1 -1
- package/dist/src/protocol/task-tools.d.ts +4 -4
- package/dist/src/protocol/task-tools.js +1 -1
- package/dist/src/public/channels/chat-sdk/chatSdkChannel.js +1 -1
- package/dist/src/public/channels/linear/defaults.js +2 -2
- package/dist/src/public/channels/slack/action-status.d.ts +0 -9
- package/dist/src/public/channels/slack/action-status.js +1 -1
- package/dist/src/public/channels/slack/defaults.js +2 -2
- package/dist/src/public/channels/slack/task-card.d.ts +1 -1
- package/dist/src/public/definitions/connections/mcp.d.ts +4 -4
- package/dist/src/public/definitions/connections/openapi.d.ts +6 -7
- package/dist/src/public/definitions/remote-agent.d.ts +6 -3
- package/dist/src/public/definitions/workspace-agent.d.ts +6 -3
- package/dist/src/public/experimental/schedules/index.d.ts +1 -1
- package/dist/src/public/schedules/providers/in-memory.js +1 -1
- package/dist/src/public/schedules/providers/vercel.js +1 -1
- package/dist/src/public/schedules/subscription.d.ts +36 -16
- package/dist/src/public/tools/web-search.d.ts +1 -1
- package/dist/src/runtime/agent/bootstrap.d.ts +2 -1
- package/dist/src/runtime/agent/bootstrap.js +1 -1
- package/dist/src/runtime/agent/mock-model-adapter.js +2 -2
- package/dist/src/runtime/agent/mock-model-fixtures.js +2 -2
- package/dist/src/runtime/agent/mock-model-skill-selection.d.ts +2 -0
- package/dist/src/runtime/agent/mock-model-skill-selection.js +2 -2
- package/dist/src/runtime/agent/mock-structured-output.d.ts +1 -1
- package/dist/src/runtime/connections/mcp-client.js +1 -1
- package/dist/src/runtime/connections/registry.js +1 -1
- package/dist/src/runtime/connections/scoped-authorization.js +1 -1
- package/dist/src/runtime/connections/tool-result.d.ts +2 -2
- package/dist/src/runtime/resolve-agent-graph.js +1 -1
- package/dist/src/runtime/resolve-tool.js +1 -1
- package/dist/src/runtime/schedules/collection-client.d.ts +12 -3
- package/dist/src/runtime/schedules/collection-client.js +1 -1
- package/dist/src/runtime/subagents/dynamic-agent-config.d.ts +2 -2
- package/dist/src/runtime/subagents/dynamic-remote-agent-config.d.ts +2 -1
- package/dist/src/runtime/subagents/dynamic-remote-agent-config.js +1 -1
- package/dist/src/runtime/subagents/registry.d.ts +2 -1
- package/dist/src/runtime/subagents/registry.js +1 -1
- package/dist/src/runtime/tools/registry.d.ts +2 -0
- package/dist/src/runtime/tools/registry.js +1 -1
- package/dist/src/runtime/types.d.ts +3 -3
- package/dist/src/setup/connection-connector.js +1 -2
- package/dist/src/setup/index.d.ts +1 -1
- package/dist/src/setup/index.js +1 -1
- package/dist/src/setup/integrations/slack/setup.d.ts +23 -3
- package/dist/src/setup/integrations/slack/setup.js +1 -1
- package/dist/src/setup/primitives/process-output.d.ts +5 -0
- package/dist/src/setup/primitives/process-output.js +2 -1
- package/dist/src/setup/scaffold/create/project.js +1 -1
- package/dist/src/setup/scaffold/create/web-template.d.ts +3 -2
- package/dist/src/setup/scaffold/create/web-template.js +384 -412
- package/dist/src/setup/scaffold/update/update-slack-channel.d.ts +17 -0
- package/dist/src/setup/scaffold/update/update-slack-channel.js +1 -1
- package/dist/src/setup/slack-connect-create.d.ts +10 -2
- package/dist/src/setup/slack-connect-create.js +1 -1
- package/dist/src/setup/slack-connect-lifecycle.d.ts +92 -44
- package/dist/src/setup/slack-connect-lifecycle.js +1 -1
- package/dist/src/setup/slack-connect.d.ts +30 -11
- package/dist/src/setup/slack-connect.js +1 -1
- package/dist/src/setup/slack-setup-plan.d.ts +72 -0
- package/dist/src/setup/slack-setup-plan.js +1 -0
- package/dist/src/setup/slackbot.d.ts +75 -35
- package/dist/src/setup/slackbot.js +2 -1
- package/dist/src/setup/vercel-project.d.ts +1 -1
- package/dist/src/setup/vercel-project.js +0 -0
- package/dist/src/shared/action-label.d.ts +10 -0
- package/dist/src/shared/action-label.js +1 -0
- package/dist/src/shared/action-request-name.d.ts +3 -1
- package/dist/src/shared/action-request-name.js +1 -1
- package/dist/src/shared/action-types.d.ts +7 -8
- package/dist/src/shared/action-types.js +1 -1
- package/dist/src/shared/agent-definition.d.ts +11 -3
- package/dist/src/shared/development-env-files.d.ts +4 -0
- package/dist/src/shared/development-env-files.js +1 -0
- package/dist/src/shared/input.d.ts +0 -1
- package/dist/src/shared/map-with-concurrency.d.ts +2 -0
- package/dist/src/shared/map-with-concurrency.js +1 -0
- package/dist/src/shared/skill-definition.d.ts +6 -0
- package/dist/src/shared/skill-package.d.ts +1 -0
- package/dist/src/shared/skill-package.js +1 -1
- package/dist/src/shared/web-search.d.ts +15 -2
- package/dist/src/shared/web-search.js +1 -1
- package/dist/src/svelte/index.js +1 -1
- package/dist/src/svelte/use-eve-agent.js +1 -1
- package/dist/src/tool-stubs/execute.d.ts +0 -3
- package/dist/src/tool-stubs/execute.js +1 -1
- package/dist/src/tool-stubs/rules.js +1 -1
- package/dist/src/tool-stubs/validate-targets.js +1 -1
- package/dist/src/tools/behavior.d.ts +3 -6
- package/dist/src/tools/definition.d.ts +5 -0
- package/dist/src/tools/dynamic.d.ts +5 -2
- package/dist/src/tools/provided/ask-question-workflow.js +1 -1
- package/dist/src/tools/provided/sleep-workflow.js +1 -1
- package/dist/src/tools/provided/task-cancel.d.ts +1 -1
- package/dist/src/tools/provided/task-wait.d.ts +1 -1
- package/dist/src/tools/provided/web-search.d.ts +20 -7
- package/dist/src/tools/provided/web-search.js +1 -1
- package/dist/src/tools/schema.d.ts +5 -0
- package/dist/src/tools/schema.js +1 -1
- package/dist/src/{runtime/connections/tool-signature.d.ts → tools/signature.d.ts} +2 -2
- package/dist/src/tools/workflow-definition.d.ts +1 -1
- package/dist/src/tracing/agent-approval-instrumentation.js +1 -1
- package/dist/src/tracing/agent-otel-provider.js +2 -2
- package/dist/src/tracing/agent-otel-runtime-context.d.ts +1 -0
- package/dist/src/tracing/agent-otel-runtime-context.js +1 -1
- package/dist/src/tracing/agent-otel-turn-state.d.ts +6 -0
- package/dist/src/tracing/agent-otel-turn-state.js +1 -0
- package/dist/src/tracing/agent-tool-instrumentation.js +1 -1
- package/dist/src/tracing/agent-trace-context-codec.js +1 -1
- package/dist/src/tracing/agent-trace-state.d.ts +4 -1
- package/dist/src/vue/index.js +1 -1
- package/dist/src/vue/use-eve-agent.js +1 -1
- package/docs/agent-config.md +8 -8
- package/docs/channels/chat-sdk.mdx +1 -1
- package/docs/channels/slack.mdx +32 -82
- package/docs/code-extension.mdx +28 -7
- package/docs/concepts/built-in-tools.md +43 -43
- package/docs/concepts/context-control.md +1 -1
- package/docs/concepts/execution-model-and-durability.mdx +1 -1
- package/docs/concepts/sessions-runs-and-streaming.md +4 -4
- package/docs/connections/mcp.mdx +5 -5
- package/docs/connections/openapi.mdx +1 -1
- package/docs/connections/overview.mdx +4 -2
- package/docs/evals/assertions.mdx +5 -3
- package/docs/evals/reporters.mdx +3 -1
- package/docs/evals/tool-stubs.mdx +3 -1
- package/docs/extensions.md +2 -0
- package/docs/guides/dev-tui.md +2 -2
- package/docs/guides/dynamic-capabilities.md +14 -4
- package/docs/guides/frontend/overview.mdx +1 -1
- package/docs/guides/remote-agents.md +10 -3
- package/docs/instructions.mdx +5 -5
- package/docs/reference/cli.md +2 -2
- package/docs/reference/typescript-api.md +3 -3
- package/docs/skills.mdx +19 -4
- package/docs/subagents/index.mdx +5 -3
- package/docs/tools/overview.mdx +22 -1
- package/docs/tools/tasks-upgrade.md +1 -1
- package/docs/tools/tasks.md +32 -32
- package/docs/tools/workflows.mdx +6 -6
- package/docs/tutorial/team-playbooks.mdx +2 -2
- package/package.json +27 -11
- package/dist/src/compiled/_chunks/workflow/dist-DmXynLVH.js +0 -1
- package/dist/src/compiled/_chunks/workflow/private-Dlf90Zvn.js +0 -1
- package/dist/src/compiled/_chunks/workflow/signal-exit-iIdjQcCK.js +0 -95
- package/dist/src/compiled/_chunks/workflow/sleep-BMqbraZM.js +0 -1
- package/dist/src/execution/connection-announcement.d.ts +0 -7
- package/dist/src/execution/connection-announcement.js +0 -4
- package/dist/src/execution/tools/connection-approval.d.ts +0 -25
- package/dist/src/execution/tools/connection-approval.js +0 -1
- package/dist/src/execution/tools/connection-search-rank.d.ts +0 -21
- package/dist/src/execution/tools/connection-search-rank.js +0 -1
- package/dist/src/execution/tools/connection-target.d.ts +0 -18
- package/dist/src/execution/tools/connection-target.js +0 -1
- package/dist/src/execution/tools/connection-tools.d.ts +0 -4
- package/dist/src/execution/tools/connection-tools.js +0 -2
- package/dist/src/execution/tools/load-skill.d.ts +0 -10
- package/dist/src/execution/tools/load-skill.js +0 -1
- package/dist/src/extensions/code/extension/lib/github-shell.js +0 -1
- package/dist/src/extensions/code/extension/skills/pr/SKILL.md +0 -53
- package/dist/src/extensions/code/extension/subagents/worker/tools/load_skill.d.ts +0 -2
- package/dist/src/extensions/code/extension/subagents/worker/tools/load_skill.js +0 -1
- package/dist/src/harness/advertised-tools.d.ts +0 -26
- package/dist/src/harness/advertised-tools.js +0 -1
- package/dist/src/harness/nested-actions.d.ts +0 -23
- package/dist/src/harness/nested-actions.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/cli-config.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/cred-storage.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/index.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/schema.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/schema.zod.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/types.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/envpath.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/errors.js +0 -2
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/errutils.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/exec.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/fsutils.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/index.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/lookup.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/safety.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/auth-errors.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/exchange-vercel-oidc-token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-context.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-sync.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-vercel-oidc-token-with-refresh.js +0 -2
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/index.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/oauth.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-error.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-io.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-util.js +0 -2
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/verify-vercel-oidc-token.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/version.js +0 -1
- package/dist/src/node_modules/.pnpm/@vercel_queue@0.5.1_@opentelemetry_api@1.9.1/node_modules/@vercel/queue/dist/index.js +0 -36
- package/dist/src/node_modules/.pnpm/balanced-match@4.0.4/node_modules/balanced-match/dist/esm/index.js +0 -1
- package/dist/src/node_modules/.pnpm/brace-expansion@5.0.12/node_modules/brace-expansion/dist/esm/index.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/index.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/enoent.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/parse.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/escape.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/readShebang.js +0 -1
- package/dist/src/node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/resolveCommand.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/index.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/command.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/error.js +0 -2
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/kill.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/promise.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stdio.js +0 -1
- package/dist/src/node_modules/.pnpm/execa@5.1.1/node_modules/execa/lib/stream.js +0 -1
- package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/buffer-stream.js +0 -1
- package/dist/src/node_modules/.pnpm/get-stream@6.0.1/node_modules/get-stream/index.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/core.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/main.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/realtime.js +0 -1
- package/dist/src/node_modules/.pnpm/human-signals@2.1.0/node_modules/human-signals/build/src/signals.js +0 -1
- package/dist/src/node_modules/.pnpm/is-stream@2.0.1/node_modules/is-stream/index.js +0 -1
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js +0 -1
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js +0 -1
- package/dist/src/node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/index.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/compact/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/flattened/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwe/general/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/embedded.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwk/thumbprint.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/local.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwks/remote.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/compact/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/flattened/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jws/general/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/produce.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/unsecured.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/jwt/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/export.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_key_pair.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/generate_secret.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/key/import.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/aesgcmkw.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/buffer_utils.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/cek.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_iv_length.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_key_type.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/check_p2s.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/crypto_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/decrypt_key_management.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/encrypt_key_management.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/epoch.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/invalid_key_input.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_disjoint.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_jwk.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/is_object.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/iv.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/jwt_claims_set.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/private_symbols.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/secs.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_algorithms.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/lib/validate_crit.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/aeskw.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/asn1.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/base64url.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/cbc_tag.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_cek_length.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/check_key_length.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ciphers.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/decrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/digest.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/dsa_digest.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/ecdhes.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/encrypt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/fetch_jwks.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/generate.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_named_curve.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/get_sign_verify_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/hmac_digest.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_like.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/is_key_object.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/jwk_to_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/key_to_jwk.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/node_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/normalize_key.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/pbes2kw.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/random.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/rsaes.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/runtime.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/sign.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/timing_safe_equal.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/verify.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/runtime/webcrypto.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/base64url.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_jwt.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/decode_protected_header.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/errors.js +0 -1
- package/dist/src/node_modules/.pnpm/jose@5.10.0/node_modules/jose/dist/node/cjs/util/runtime.js +0 -1
- package/dist/src/node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js +0 -1
- package/dist/src/node_modules/.pnpm/mimic-fn@2.1.0/node_modules/mimic-fn/index.js +0 -1
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/assert-valid-pattern.js +0 -1
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/ast.js +0 -1
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/brace-expressions.js +0 -1
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/escape.js +0 -1
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/index.js +0 -1
- package/dist/src/node_modules/.pnpm/minimatch@10.2.6/node_modules/minimatch/dist/esm/unescape.js +0 -1
- package/dist/src/node_modules/.pnpm/mixpart@0.0.6/node_modules/mixpart/dist/index.js +0 -7
- package/dist/src/node_modules/.pnpm/npm-run-path@4.0.1/node_modules/npm-run-path/index.js +0 -1
- package/dist/src/node_modules/.pnpm/onetime@5.1.2/node_modules/onetime/index.js +0 -1
- package/dist/src/node_modules/.pnpm/os-paths@4.4.0/node_modules/os-paths/src/lib/index.js +0 -1
- package/dist/src/node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js +0 -1
- package/dist/src/node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js +0 -1
- package/dist/src/node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js +0 -1
- package/dist/src/node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js +0 -1
- package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js +0 -1
- package/dist/src/node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js +0 -1
- package/dist/src/node_modules/.pnpm/strip-final-newline@2.0.0/node_modules/strip-final-newline/index.js +0 -2
- package/dist/src/node_modules/.pnpm/which@2.0.2/node_modules/which/which.js +0 -1
- package/dist/src/node_modules/.pnpm/xdg-app-paths@5.5.1/node_modules/xdg-app-paths/src/lib/index.js +0 -1
- package/dist/src/node_modules/.pnpm/xdg-portable@7.3.0/node_modules/xdg-portable/src/lib/index.js +0 -1
- package/dist/src/public/tools/load-skill.d.ts +0 -3
- package/dist/src/public/tools/load-skill.js +0 -1
- package/dist/src/runtime/skills/fragment-context.d.ts +0 -4
- package/dist/src/runtime/skills/fragment-context.js +0 -1
- package/dist/src/tools/framework/connection-tools.d.ts +0 -3
- package/dist/src/tools/framework/connection-tools.js +0 -1
- package/dist/src/tools/provided/load-skill.d.ts +0 -2
- package/dist/src/tools/provided/load-skill.js +0 -1
- /package/dist/src/extensions/{code → git}/extension/lib/github-shell-schema.d.ts +0 -0
- /package/dist/src/extensions/{code → git}/extension/lib/github-shell-schema.js +0 -0
- /package/dist/src/extensions/{code → git}/extension/lib/signed-commit.d.ts +0 -0
- /package/dist/src/extensions/{code → git}/extension/lib/signed-commit.js +0 -0
- /package/dist/src/{runtime/connections/tool-signature.js → tools/signature.js} +0 -0
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{ai as e}from"./serialization-vDozzDhh.js";import{i as t}from"./attribute-changes-CSqvJx6j.js";async function n(r){let i=globalThis[e];return i||t(`sleep()`,`https://workflow-sdk.dev/docs/api-reference/workflow/sleep`,n),i(r)}export{n as t};
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import type { ContextContainer } from "#context/container.js";
|
|
2
|
-
/**
|
|
3
|
-
* Announces the agent's connections for the current step: a baseline listing
|
|
4
|
-
* the first time, then only what changed. Tool names and signatures stay out
|
|
5
|
-
* of the listing; `connection_search` returns them.
|
|
6
|
-
*/
|
|
7
|
-
export declare function announceConnections(ctx: ContextContainer): void;
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import{ConnectionRegistryKey}from"#context/providers/connection-key.js";import{setPendingAnnouncement}from"#harness/announcements.js";const ANNOUNCEMENT_KEY=`connections`;function announceConnections(e){let t=e.get(ConnectionRegistryKey);if(t===void 0){setPendingAnnouncement(e,ANNOUNCEMENT_KEY,void 0);return}let n=t.getConnections().map(e=>({description:e.description,name:e.connectionName})).sort((e,t)=>e.name.localeCompare(t.name));setPendingAnnouncement(e,ANNOUNCEMENT_KEY,{value:JSON.stringify(n),render:e=>renderConnectionsAnnouncement(parseListing(e),n)})}function renderConnectionsAnnouncement(e,t){if(e===void 0||e.length===0)return t.length===0?void 0:renderListing(t);if(t.length===0)return`Connections changed. No connections are available now; do not call connection_execute.`;let n=new Map(e.map(e=>[e.name,e])),r=new Set(t.map(e=>e.name)),i=t.filter(e=>n.get(e.name)?.description!==e.description),a=e.filter(e=>!r.has(e.name)),o=[`Connections changed.`];i.length>0&&o.push([`Added or updated:`,...i.map(formatEntry)].join(`
|
|
2
|
-
`)),a.length>0&&o.push(`No longer available, do not call: ${a.map(e=>e.name).join(`, `)}`);let s=o.join(`
|
|
3
|
-
`),c=`Connections changed. This list replaces the previous one.\n${renderListing(t)}`;return s.length<c.length?s:c}function renderListing(e){return[`Connections. Find their tools with connection_search and call them with connection_execute.`,...e.map(formatEntry)].join(`
|
|
4
|
-
`)}function formatEntry(e){return e.description.length===0?`- ${e.name}`:`- ${e.name}: ${e.description}`}function parseListing(e){if(e!==void 0)try{let t=JSON.parse(e);return Array.isArray(t)?t:void 0}catch{return}}export{announceConnections};
|
|
@@ -1,25 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Approval for `connection_execute`: each call is approved under the called
|
|
3
|
-
* connection's own policy, keyed by connection and tool, and an approved call
|
|
4
|
-
* runs only against the connection instance it was approved for.
|
|
5
|
-
*/
|
|
6
|
-
import { type Approval, type ApprovalContext, type ApprovalResponseContext, type ApprovalResponseDecision, type ApprovalStatus } from "#approval/definition.js";
|
|
7
|
-
import type { ResolvedConnectionDefinition } from "#runtime/types.js";
|
|
8
|
-
/**
|
|
9
|
-
* Delegates approval to the called connection's policy. The request and
|
|
10
|
-
* response phases exist only when some registered connection defines them,
|
|
11
|
-
* so connections without a response policy keep the default response flow
|
|
12
|
-
* unless another connection in the same agent defines one.
|
|
13
|
-
*/
|
|
14
|
-
export declare function connectionExecuteApproval(approvals: readonly Approval[]): {
|
|
15
|
-
approvalKey?: undefined;
|
|
16
|
-
approval?: undefined;
|
|
17
|
-
} | {
|
|
18
|
-
approvalKey: (input: unknown) => string;
|
|
19
|
-
approval: ((context: ApprovalContext<Record<string, unknown>>) => Promise<ApprovalStatus>) | {
|
|
20
|
-
request: (context: ApprovalContext<Record<string, unknown>>) => Promise<ApprovalStatus>;
|
|
21
|
-
response: (context: ApprovalResponseContext<Record<string, unknown>>) => Promise<ApprovalResponseDecision>;
|
|
22
|
-
};
|
|
23
|
-
};
|
|
24
|
-
/** Consumes the call's approval pin, rejecting the call if its connection changed. */
|
|
25
|
-
export declare function releaseApprovalPin(callId: string, connection: ResolvedConnectionDefinition): void;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{CONNECTION_EXECUTE_TOOL_NAME,findConnection,qualifiedToolName,readExecuteTarget}from"./connection-target.js";import{loadContext}from"#context/container.js";import{defineDurableCallback}from"#tools/durable-callbacks.js";import{ContextKey}from"#context/key.js";import{ConnectionRegistryKey}from"#context/providers/connection-key.js";import{resolveApprovalPolicy}from"#approval/definition.js";import{isApprovalRecheck}from"#harness/approval-recheck.js";const ConnectionApprovalPinsKey=new ContextKey(`eve.connectionApprovalPins`);function connectionExecuteApproval(e){if(e.length===0)return{};let t=defineDurableCallback({callback:requestConnectionApproval,closure:{}}),n=e.some(e=>typeof e!=`function`&&e.response!==void 0);return{approvalKey:defineDurableCallback({callback:connectionApprovalKey,closure:{}}),approval:n?{request:t,response:defineDurableCallback({callback:authorizeConnectionApprovalResponse,closure:{}})}:t}}function connectionApprovalKey(e,t){let n=readExecuteTarget(t);return n===void 0?CONNECTION_EXECUTE_TOOL_NAME:approvalKeyFor(n)}function approvalKeyFor(e){return JSON.stringify([e.connection,e.tool])}function policyApprovedTools(e,t){let n=qualifiedToolName(t),r=new Set([...e].filter(e=>e!==n));return e.has(approvalKeyFor(t))&&r.add(n),r}async function requestConnectionApproval(e,t){let n=readExecuteTarget(t.toolInput),r=loadContext().get(ConnectionRegistryKey);if(n===void 0||r===void 0)return`not-applicable`;let i=findConnection(r,n.connection),a=i===void 0?void 0:r.getConnectionApproval(i.connectionName);if(i===void 0||a===void 0)return`not-applicable`;isApprovalRecheck(t)&&!matchesApprovalPin(t.callId,i)&&markApprovalPinChanged(t.callId);let o=await resolveApprovalPolicy(a)({...t,approvedTools:policyApprovedTools(t.approvedTools,n),toolInput:n.input,toolName:qualifiedToolName(n)});return!isApprovalRecheck(t)&&parksForApproval(o)&&pinApprovedInstance(t.callId,i),o}function parksForApproval(e){return e===!0||e===`user-approval`||typeof e==`object`&&e.type===`user-approval`}async function authorizeConnectionApprovalResponse(e,t){let n=readExecuteTarget(t.request.toolInput),r=loadContext().get(ConnectionRegistryKey),i=n===void 0||r===void 0?void 0:findConnection(r,n.connection);if(n===void 0||r===void 0||i===void 0)return{reason:`The connection for this tool call is unavailable.`,status:`rejected`};if(!matchesApprovalPin(t.request.callId,i))return{reason:CONNECTION_CHANGED_MESSAGE,status:`rejected`};let a=r.getConnectionApproval(i.connectionName),o=a===void 0||typeof a==`function`?void 0:a.response;return o===void 0?{status:`allowed`}:await o({...t,request:{...t.request,toolInput:n.input,toolName:qualifiedToolName(n)}})}const CONNECTION_CHANGED_MESSAGE=`The connection for this tool call changed or is unavailable. Request a new tool call and approval.`;function pinApprovedInstance(e,t){let n=t.instanceId??``,r=loadContext();r.get(ConnectionApprovalPinsKey)?.[e]===void 0&&r.set(ConnectionApprovalPinsKey,(t={})=>Object.fromEntries([...Object.entries(t).slice(-49),[e,n]]))}function matchesApprovalPin(e,t){let n=loadContext().get(ConnectionApprovalPinsKey)?.[e];return n!==void 0&&n===(t.instanceId??``)}function markApprovalPinChanged(e){loadContext().set(ConnectionApprovalPinsKey,(t={})=>({...t,[e]:`\0changed`}))}function releaseApprovalPin(e,t){let n=loadContext(),r=n.get(ConnectionApprovalPinsKey);if(r?.[e]===void 0)return;let{[e]:i,...a}=r;if(n.set(ConnectionApprovalPinsKey,a),i!==(t.instanceId??``))throw Error(CONNECTION_CHANGED_MESSAGE)}export{connectionExecuteApproval,releaseApprovalPin};
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Keyword ranking for `connection_search` and for `connection_execute`'s
|
|
3
|
-
* suggestions when a tool name is unknown. Query and field text split into
|
|
4
|
-
* lowercase words (camelCase and punctuation are boundaries); a query word
|
|
5
|
-
* matches a field word when either is a prefix of the other, so `repo` finds
|
|
6
|
-
* `repositories` and `issues` finds `issue`. Each query word adds the weight of
|
|
7
|
-
* every field it matches, so broad fields rank below a tool's own name.
|
|
8
|
-
*/
|
|
9
|
-
import type { ResolvedConnectionDefinition } from "#runtime/types.js";
|
|
10
|
-
import type { ConnectionToolMetadata } from "#shared/connection-types.js";
|
|
11
|
-
export interface RankCandidate {
|
|
12
|
-
readonly connection: Pick<ResolvedConnectionDefinition, "connectionName" | "description">;
|
|
13
|
-
readonly tool: ConnectionToolMetadata;
|
|
14
|
-
}
|
|
15
|
-
/** Candidates matching `query`, best first. An empty query matches every candidate. */
|
|
16
|
-
export declare function rankConnectionTools<T extends RankCandidate>(query: string, candidates: readonly T[]): T[];
|
|
17
|
-
/**
|
|
18
|
-
* Names of one connection's tools closest to an unknown `name`. Only the tools'
|
|
19
|
-
* own fields count, since every candidate shares the connection.
|
|
20
|
-
*/
|
|
21
|
-
export declare function closestToolNames(name: string, tools: readonly ConnectionToolMetadata[], limit: number): string[];
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{isObject}from"#shared/guards.js";function rankConnectionTools(e,t){let n=tokenize(e);return t.map(e=>({candidate:e,score:n.length===0?1:scoreFields(n,[...toolFields(e.tool),[tokenize(e.connection.connectionName),4],[tokenize(e.connection.description),1]])})).filter(e=>e.score>0).sort((e,t)=>t.score-e.score||e.candidate.connection.connectionName.localeCompare(t.candidate.connection.connectionName)||e.candidate.tool.name.localeCompare(t.candidate.tool.name)).map(e=>e.candidate)}function closestToolNames(e,t,n){let r=tokenize(e);return r.length===0?[]:t.map(e=>({name:e.name,score:scoreFields(r,toolFields(e))})).filter(e=>e.score>0).sort((e,t)=>t.score-e.score||e.name.localeCompare(t.name)).slice(0,n).map(e=>e.name)}function toolFields(e){let t=isObject(e.inputSchema.properties)?Object.entries(e.inputSchema.properties):[],n=t.flatMap(([,e])=>isObject(e)&&typeof e.description==`string`?[e.description]:[]);return[[tokenize(e.name),6],[t.flatMap(([e])=>tokenize(e)),3],[tokenize(e.description),2],[n.flatMap(tokenize),1]]}function scoreFields(e,t){let n=0;for(let r of e)for(let[e,i]of t)e.some(e=>matchesWord(e,r))&&(n+=i);return n}function matchesWord(e,t){return e.startsWith(t)||e.length>=3&&t.startsWith(e)}function tokenize(e){return e.replaceAll(/([a-z0-9])([A-Z])/gu,`$1 $2`).toLowerCase().split(/[^a-z0-9]+/u).filter(e=>e.length>1)}export{closestToolNames,rankConnectionTools};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/** The `connection_execute` call target, shared by execution and approval. */
|
|
2
|
-
import type { ConnectionRegistry } from "#runtime/connections/registry-types.js";
|
|
3
|
-
import type { ResolvedConnectionDefinition } from "#runtime/types.js";
|
|
4
|
-
import type { JsonObject } from "#shared/json.js";
|
|
5
|
-
export declare const CONNECTION_EXECUTE_TOOL_NAME = "connection_execute";
|
|
6
|
-
export interface ExecuteTarget {
|
|
7
|
-
readonly connection: string;
|
|
8
|
-
readonly input: JsonObject;
|
|
9
|
-
readonly tool: string;
|
|
10
|
-
}
|
|
11
|
-
export declare function readExecuteTarget(value: unknown): ExecuteTarget | undefined;
|
|
12
|
-
export declare function qualifiedToolName(target: Pick<ExecuteTarget, "connection" | "tool">): string;
|
|
13
|
-
/**
|
|
14
|
-
* How a tool call reads to a person: `Linear: List issues` for a
|
|
15
|
-
* `connection_execute` call, otherwise the tool's display title.
|
|
16
|
-
*/
|
|
17
|
-
export declare function toolCallDisplayName(toolName: string, input: unknown): string;
|
|
18
|
-
export declare function findConnection(registry: ConnectionRegistry, name: string): ResolvedConnectionDefinition | undefined;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{isObject}from"#shared/guards.js";import{displayProperName,displayTitle}from"#shared/display-name.js";const CONNECTION_EXECUTE_TOOL_NAME=`connection_execute`;function readExecuteTarget(e){if(!isObject(e))return;let{connection:t,input:n,tool:r}=e;if(typeof t==`string`&&typeof r==`string`)return{connection:t,input:isObject(n)?n:{},tool:r}}function qualifiedToolName(e){return`${e.connection}__${e.tool}`}function toolCallDisplayName(e,t){let n=e===`connection_execute`?readExecuteTarget(t):void 0;return n===void 0?displayTitle(e):`${displayProperName(n.connection)}: ${displayTitle(n.tool)}`}function findConnection(e,t){return e.getConnections().find(e=>e.connectionName===t)}export{CONNECTION_EXECUTE_TOOL_NAME,findConnection,qualifiedToolName,readExecuteTarget,toolCallDisplayName};
|
|
@@ -1,4 +0,0 @@
|
|
|
1
|
-
import type { DynamicToolSet } from "#tools/dynamic.js";
|
|
2
|
-
export declare const CONNECTION_SEARCH_TOOL_NAME = "connection_search";
|
|
3
|
-
/** Builds both tools for the current step, or `null` when the agent has no connections. */
|
|
4
|
-
export declare function resolveConnectionTools(): DynamicToolSet | null;
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{CONNECTION_EXECUTE_TOOL_NAME,findConnection,qualifiedToolName,readExecuteTarget,toolCallDisplayName}from"./connection-target.js";import{connectionExecuteApproval,releaseApprovalPin}from"./connection-approval.js";import{closestToolNames,rankConnectionTools}from"./connection-search-rank.js";import{createLogger}from"#internal/logging.js";import{isObject}from"#shared/guards.js";import{loadContext}from"#context/container.js";import{displayProperName}from"#shared/display-name.js";import{toErrorMessage}from"#shared/errors.js";import{defineJsonSchema}from"#tools/schema.js";import{defineDurableCallback}from"#tools/durable-callbacks.js";import{ConnectionRegistryKey}from"#context/providers/connection-key.js";import{frameworkTool}from"#tools/provided/framework-tool.js";import{defineTool}from"#tools/definition.js";import{isConnectionAuthorizationFailedError,isConnectionAuthorizationRequiredError}from"#connections/errors.js";import{getAuthorizationResults}from"#harness/authorization.js";import{connectionToolStub}from"#tool-stubs/execute.js";import{createAuthorizationExecution}from"#runtime/connections/scoped-authorization.js";import{toolStubOutput}from"#tool-stubs/output.js";import{reportNestedToolAction}from"#harness/nested-actions.js";import{resolveConnectionAuthorization}from"#runtime/connections/resolve-authorization.js";import{connectionToolModelOutput,toConnectionToolResult}from"#runtime/connections/tool-result.js";import{renderToolSignature}from"#runtime/connections/tool-signature.js";import{supportsInteractiveAuthorization}from"#shared/connection-types.js";const log=createLogger(`framework.connection-tools`),CONNECTION_SEARCH_TOOL_NAME=`connection_search`,CONNECTION_SEARCH_DESCRIPTION=[`Find tools in your connected services (MCP servers and OpenAPI APIs).`,`Returns each matching tool's connection, name, description, and TypeScript signature.`,"Omit `query` to list a connection's tools. Call a found tool with connection_execute.","Connections the user has not signed in to are listed under `unavailable` with `requiresSignIn`;","when the request needs one, search it again with `connection` and `signIn: true` to ask the user to sign in.",`Prefer connected services over web search or general knowledge when a request relates to them.`].join(` `),CONNECTION_EXECUTE_DESCRIPTION=[`Call one tool from a connected service and return its result.`,"Use the exact `connection` and `tool` names returned by connection_search,","and pass `input` matching the tool's signature."].join(` `),CONNECTION_SEARCH_INPUT_SCHEMA={type:`object`,properties:{query:{type:`string`,description:`Words describing the capability, such as 'list open issues'. Omit to list every tool.`},connection:{type:`string`,description:`Only search this connection.`},signIn:{type:`boolean`,description:"Ask the user to sign in to `connection` first, then search it. Requires `connection`. Use only for a connection listed with `requiresSignIn` that the request needs."},limit:{type:`integer`,minimum:1,maximum:50,description:`Maximum results. Defaults to 10.`},offset:{type:`integer`,minimum:0,description:`Results to skip, for paging.`}},additionalProperties:!1},CONNECTION_EXECUTE_INPUT_SCHEMA={type:`object`,properties:{connection:{type:`string`,description:`Connection name from connection_search.`},tool:{type:`string`,description:`Tool name from connection_search.`},input:{type:`object`,description:`Arguments matching the tool's signature. Defaults to {}.`}},required:[`connection`,`tool`],additionalProperties:!1};function resolveConnectionTools(){let e=loadContext().get(ConnectionRegistryKey);if(e===void 0)return null;let t=e.getConnections().map(t=>e.getConnectionApproval(t.connectionName)).filter(e=>e!==void 0);return{[CONNECTION_SEARCH_TOOL_NAME]:frameworkTool(defineTool({description:CONNECTION_SEARCH_DESCRIPTION,inputSchema:CONNECTION_SEARCH_INPUT_SCHEMA,execute:defineDurableCallback({callback:searchConnectionTools,closure:{}}),label:{start:defineDurableCallback({callback:connectionSearchLabel,closure:{}})}})),[CONNECTION_EXECUTE_TOOL_NAME]:frameworkTool(defineTool({description:CONNECTION_EXECUTE_DESCRIPTION,inputSchema:CONNECTION_EXECUTE_INPUT_SCHEMA,execute:defineDurableCallback({callback:executeConnectionTool,closure:{}}),label:{start:defineDurableCallback({callback:connectionToolLabel,closure:{}})},toModelOutput:defineDurableCallback({callback:(e,t)=>connectionToolModelOutput(t),closure:{}}),...connectionExecuteApproval(t)}))}}function connectionToolLabel(e,t){return toolCallDisplayName(CONNECTION_EXECUTE_TOOL_NAME,t)}function connectionSearchLabel(e,t){let n=isObject(t)?t.connection:void 0;return typeof n!=`string`||n===``?`Search connected tools`:isObject(t)&&t.signIn===!0?`Connect ${displayProperName(n)}`:`Search ${displayProperName(n)} tools`}async function searchConnectionTools(e,t){let n=isObject(t)?t:{},r=requireRegistry(),i=n.connection===void 0||n.connection===``?void 0:n.connection;if(n.signIn===!0&&i===void 0)throw Error("connection_search with signIn: true requires `connection`. Ask the user to sign in to one connection at a time.");let a=i===void 0?r.getConnections():[requireConnection(r,i)],o=createAuthorizationExecution();await completePendingAuthorizations(r,a,o);let s=[],c=[];for(let e of a){let t=await listConnectionTools(r,e,o,n.signIn===!0);if(`signIn`in t)return t.signIn;if(`unavailable`in t)s.push(t.unavailable);else for(let n of t.tools)c.push({connection:e,tool:n})}let l=s.filter(e=>e.terminal);if(a.length>0&&l.length===a.length)throw Error(l.map(e=>e.error).join(`
|
|
2
|
-
`));let u=rankConnectionTools(n.query??``,c),d=clampInteger(n.limit,1,50,10),f=clampInteger(n.offset,0,2**53-1,0),p={tools:u.slice(f,f+d).map(({connection:e,tool:t})=>({connection:e.connectionName,description:t.description,signature:renderToolSignature({inputSchema:t.inputSchema,name:t.name,outputSchema:t.outputSchema}),tool:t.name})),total:u.length};return s.length>0&&(p.unavailable=s.map(({terminal:e,...t})=>t)),p}async function listConnectionTools(e,t,n,r){let i=t.connectionName;try{return{tools:await e.getClient(i).getToolMetadata()}}catch(t){if(isConnectionAuthorizationRequiredError(t)){let a=await resolveInteractiveAuthorization(e,i);if(a!==void 0&&n.isJustAuthorized(a))return{unavailable:{connection:i,error:`Authorization failed for "${i}": the service rejected the token immediately after authorization.`,terminal:!0}};if(a===void 0){let e=`"${i}" requires authorization and cannot start interactive sign-in.`;if(r)throw Error(e);return{unavailable:{connection:i,error:e,terminal:!1}}}return r?{signIn:await n.handleError(t,a)}:{unavailable:{connection:i,error:`Sign-in required: the user has not signed in to "${i}", so its tools cannot be listed. If the request needs "${i}", call connection_search with connection "${i}" and signIn: true to ask the user to sign in.`,requiresSignIn:!0,terminal:!1}}}return log.warn(`failed to load connection tools`,{connection:i,error:t}),{unavailable:{connection:i,error:isConnectionAuthorizationFailedError(t)?`Authorization failed for "${i}": ${t.message}`:`Failed to load tools for "${i}": ${toErrorMessage(t)}`,terminal:!0}}}}function clampInteger(e,t,n,r){return typeof e!=`number`||!Number.isFinite(e)?r:Math.min(n,Math.max(t,Math.trunc(e)))}async function executeConnectionTool(e,t,n){let r=readExecuteTarget(t);if(r===void 0)throw Error("connection_execute requires string `connection` and `tool` values.");let i=requireRegistry(),a=requireConnection(i,r.connection);releaseApprovalPin(n.callId,a),assertPendingAuthorizationInstances(i,[a]);let o=await resolveInteractiveAuthorization(i,a.connectionName),s=createAuthorizationExecution();o!==void 0&&await s.complete(o);let c=i.getClient(a.connectionName);o!==void 0&&s.isJustAuthorized(o)&&await c.close();let l;try{l=await c.getToolMetadata()}catch(e){return await s.handleError(e,o)}let u=l.find(e=>e.name===r.tool);if(u===void 0)throw Error(unknownToolMessage(a,r.tool,l));let d=await validToolInput(a,u,r.input),f=qualifiedToolName(r),p=await connectionToolStub(f,d,n.callId);if(p.kind===`error`)throw Error(p.error);let m;try{if(p.kind===`stub`){let e=toolStubOutput(p.outcome);return reportNestedToolAction(n.callId,{input:d,output:e,toolName:f}),e}m=await c.executeTool(u.name,d,{abortSignal:n.abortSignal,callId:n.callId})}catch(e){if(p.kind===`real`&&isConnectionAuthorizationRequiredError(e))return await s.handleError(e,o);throw reportNestedToolAction(n.callId,{input:d,isError:!0,output:toErrorMessage(e),toolName:f}),e}let h=toConnectionToolResult(a.protocol,u,m);if(!h.ok)throw reportNestedToolAction(n.callId,{input:d,isError:!0,output:h.error,toolName:f}),Error(h.error);return reportNestedToolAction(n.callId,{input:d,output:h.value,toolName:f}),h.value}async function validToolInput(e,t,n){let r=await defineJsonSchema(t.inputSchema)[`~standard`].validate(n);if(r.issues===void 0)return r.value;let i=r.issues.map(e=>{let t=(e.path??[]).map(e=>String(typeof e==`object`?e.key:e)).join(`.`);return t.length>0?`${t}: ${e.message}`:e.message}).join(`; `);throw Error(`Invalid input for "${t.name}" on connection "${e.connectionName}": ${i}. Signature: ${renderToolSignature({inputSchema:t.inputSchema,name:t.name,outputSchema:t.outputSchema})}`)}function unknownToolMessage(e,t,n){let r=closestToolNames(t,n,5),i=r.length>0?` Closest tools: ${r.join(`, `)}.`:` Use connection_search to find its tools.`;return`Connection "${e.connectionName}" has no tool named "${t}".${i}`}async function resolveInteractiveAuthorization(e,t){let n=findConnection(e,t);if(n===void 0)return;let r=await resolveConnectionAuthorization(n);if(r!==void 0&&supportsInteractiveAuthorization(r))return{scope:n.connectionName,instanceId:n.instanceId,connection:{url:n.url??``},authorization:r}}async function completePendingAuthorizations(e,t,n){assertPendingAuthorizationInstances(e,t);let r=getAuthorizationResults();for(let i of t){if(!r.some(e=>e.name===i.connectionName))continue;let t=await resolveInteractiveAuthorization(e,i.connectionName);t!==void 0&&(await n.complete(t),n.isJustAuthorized(t)&&await e.getClient(i.connectionName).close())}}function assertPendingAuthorizationInstances(e,t){let n=new Set(t.map(e=>e.connectionName));for(let t of getAuthorizationResults())if(t.instanceId!==void 0&&n.has(t.name)&&findConnection(e,t.name)?.instanceId!==t.instanceId)throw Error(`Authorization for "${t.name}" cannot complete because its resolved connection changed while sign-in was pending. Start sign-in again.`)}function requireRegistry(){let e=loadContext().get(ConnectionRegistryKey);if(e===void 0)throw Error(`This agent has no connections.`);return e}function requireConnection(e,t){let n=findConnection(e,t);if(n!==void 0)return n;let r=e.getConnectionNames();throw Error(r.length===0?`Connection "${t}" is not available. No connections are available right now.`:`Connection "${t}" is not available. Available connections: ${r.join(`, `)}.`)}export{CONNECTION_SEARCH_TOOL_NAME,resolveConnectionTools};
|
|
@@ -1,10 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Typed input accepted by {@link executeLoadSkillTool}.
|
|
3
|
-
*/
|
|
4
|
-
interface LoadSkillInput {
|
|
5
|
-
skill: string;
|
|
6
|
-
}
|
|
7
|
-
export declare const SKILL_INPUT_SCHEMA: import("#tools/schema.js").ToolSchema<LoadSkillInput, LoadSkillInput>;
|
|
8
|
-
export declare const SKILL_OUTPUT_SCHEMA: import("#tools/schema.js").ToolSchema<string, string>;
|
|
9
|
-
export declare function executeLoadSkill(input: unknown): Promise<unknown>;
|
|
10
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{loadContext}from"#context/container.js";import{DynamicSkillManifestKey}from"#context/keys.js";import{defineJsonSchema}from"#tools/schema.js";import{stripSkillFrontmatter}from"#shared/skill-package.js";import{ConnectionRegistryKey}from"#context/providers/connection-key.js";import{BundleKey}from"#runtime/sessions/runtime-context-keys.js";async function executeLoadSkillTool(e){let t=loadContext(),{skill:n}=e,r=Object.values(t.get(DynamicSkillManifestKey)??{}).flat(),i=t.require(BundleKey).resolvedAgent.skills,a=r.find(e=>e.name===n);if(a!==void 0)return stripSkillFrontmatter(a.markdown);let o=i.find(e=>e.name===n);if(o!==void 0)return o.markdown;let s=formatSkillNotFoundError(n,[...new Set([...r,...i].map(e=>e.name))].sort()),c=t.get(ConnectionRegistryKey)?.getConnectionNames().find(e=>e.toLowerCase()===n.toLowerCase());throw Error(c===void 0?s:`${s} "${c}" is a connection, not a skill. Find its tools with connection_search and connection "${c}", then call them with connection_execute.`)}function formatSkillNotFoundError(e,t){return`No skill named "${e}".${t.length>0?` Available skills: ${t.join(`, `)}.`:``}`}const SKILL_INPUT_SCHEMA=defineJsonSchema({type:`object`,properties:{skill:{type:`string`,description:`Available skill name or id.`}},required:[`skill`],additionalProperties:!1}),SKILL_OUTPUT_SCHEMA=defineJsonSchema({type:`string`});async function executeLoadSkill(e){return await executeLoadSkillTool(e)}export{SKILL_INPUT_SCHEMA,SKILL_OUTPUT_SCHEMA,executeLoadSkill};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{shellQuote}from"./shell.js";import{toolingPaths}from"./tooling.js";import{validateRepositoryRoot}from"./repository-root.js";import{posix}from"node:path";import{getToken}from"#compiled/@vercel/connect/index.js";const MAX_OUTPUT_BYTES=1e5,leaseQueues=new Map,ALLOWED_GIT_REMOTE_COMMANDS=new Set([`fetch`,`ls-remote`,`pull`,`push`]);function githubShellApproval(e){if(!e)return`not-applicable`;try{return validateGitHubShellInput(e),`not-applicable`}catch(e){return{type:`denied`,reason:e instanceof Error?e.message:`Invalid GitHub command.`}}}async function executeGitHubShell(e,t,n){if(!t)throw Error(`GitHub command access is not configured for this agent.`);let r=validateGitHubShellInput(e),i=await n.getSandbox(),a=resolveWorkingDirectory(i,e.workingDirectory);(r[0]===`git`||r[0]===`gh-signed-commit`)&&(a=await validateRepositoryRoot(i,a));let o=e.permissions[0].repositories,s=await assertCommandTargets(r,o,a,i),c=repositoryNames(o,t.org),l={authorizationDetails:[{type:`github_app_installation`,org:t.org,repositories:c}],subject:{type:`app`}},u=await(n.getConnectToken??getToken)(t.connector,l);if(!u)throw Error(`Connect returned an empty token for ${JSON.stringify(t.connector)}.`);let d=executablePath(r[0],i),f=s?[`-c`,`protocol.allow=never`,`-c`,`protocol.https.allow=always`,r[1],`https://github.com/${s}.git`,...r.slice(3)]:r.slice(1),p=`cd ${shellQuote(a)} && exec ${shellQuote(d)} ${f.map(shellQuote).join(` `)}`,m=`Basic ${Buffer.from(`x-access-token:${u}`).toString(`base64`)}`,h=crypto.randomUUID(),g=`eve-github-${h}`,_=`/tmp/eve-code-gh-${h}`,v=`Basic ${Buffer.from(`x-access-token:${g}`).toString(`base64`)}`,y;try{y=await withGitHubCredentialLease(i,n.sessionId,{authorization:m,placeholder:g,placeholderAuthorization:v,token:u},()=>{let e={GH_CONFIG_DIR:_,GH_PROMPT_DISABLED:`1`};return r[0]!==`git`&&(e.GH_TOKEN=g),e.GIT_CONFIG_COUNT=`2`,e.GIT_CONFIG_KEY_0=`http.https://github.com/.extraheader`,e.GIT_CONFIG_VALUE_0=`Authorization: ${v}`,e.GIT_CONFIG_KEY_1=`core.hooksPath`,e.GIT_CONFIG_VALUE_1=`/dev/null`,e.GIT_TERMINAL_PROMPT=`0`,e.PATH=`/usr/local/bin:/usr/bin:/bin`,i.run({command:p,env:e})},t.broker)}finally{await i.removePath({path:_,recursive:!0,force:!0})}let b=sanitizeOutput(y.stdout,u,m),x=sanitizeOutput(y.stderr,u,m);return{exitCode:y.exitCode,stdout:b.value,stderr:x.value,truncated:b.truncated||x.truncated}}async function withGitHubCredentialLease(e,t,n,r,i){let a=leaseQueues.get(t)??Promise.resolve(),o,s=new Promise(e=>{o=e}),c=a.then(()=>s);leaseQueues.set(t,c),await a;try{return await i(e,{"api.github.com":[{match:{headers:[{key:{exact:`authorization`},value:{regex:`^(?:token|Bearer) ${n.placeholder}$`}}]},transform:[{headers:{authorization:`Bearer ${n.token}`}}]}],"github.com":[{match:{headers:[{key:{exact:`authorization`},value:{exact:n.placeholderAuthorization}}]},transform:[{headers:{authorization:n.authorization}}]}]}),await r()}finally{try{await i(e,null)}finally{o(),leaseQueues.get(t)===c&&leaseQueues.delete(t)}}}function parseCommand(e){let t=e.trim();if(!t)throw Error(`GitHub command must not be empty.`);let n=[],r=``,i=null,a=!1,o=!1;for(let e of t){if(a){r+=e,a=!1,o=!0;continue}if(e===`\\`&&i!==`single`){a=!0,o=!0;continue}if(i===`single`){e===`'`?i=null:r+=e;continue}if(i===`double`){if(e===`"`)i=null;else if(e===`$`||e==="`")throw unsupportedSyntax();else r+=e;continue}if(e===`'`)i=`single`,o=!0;else if(e===`"`)i=`double`,o=!0;else if(/\s/u.test(e))o&&=(n.push(r),r=``,!1);else if(";&|<>$`(){}".includes(e))throw unsupportedSyntax();else r+=e,o=!0}if(a||i)throw Error(`GitHub command contains an unfinished quote or escape.`);if(o&&n.push(r),n.length===0)throw Error(`GitHub command must not be empty.`);return n}function validateGitHubShellInput(e){let t=parseCommand(e.command),n=e.permissions[0];if(e.permissions.length!==1||n?.provider!==`github`)throw Error(`Exactly one GitHub permission is required.`);if(n.access!==`write`)throw Error(`GitHub App commands require explicit write-capable access.`);if(!e.description.trim())throw Error(`description must describe the intended result.`);let[r,i]=t;if(r===`gh`){if(!i)throw Error(`A gh subcommand is required.`)}else if(r===`git`){if(!i||!ALLOWED_GIT_REMOTE_COMMANDS.has(i))throw Error(`Authenticated git supports only fetch, ls-remote, pull, and push; clone with gh repo clone.`)}else if(r!==`gh-signed-commit`)throw Error(`GitHub commands must use gh, an authenticated git remote command, or gh-signed-commit.`);return t}async function assertCommandTargets(e,t,n,r){let i=new Set(t.map(e=>e.toLowerCase())),a,o;if(e[0]===`git`){if(e[2]!==`origin`)throw Error(`Authenticated git commands must use the validated origin remote.`);let t=e[1]===`push`,i=await r.run({command:`cd ${shellQuote(n)} && git remote get-url ${t?`--push `:``}origin`,env:{GIT_TERMINAL_PROMPT:`0`,PATH:`/usr/bin:/bin`}});if(i.exitCode!==0)throw Error(`Could not resolve the origin GitHub repository.`);a=repositoryFromRemote(i.stdout.trim()),o=[a]}else if(e[0]===`gh-signed-commit`){if(o=repoFlagTargets(e.slice(1)),o.length===0)throw Error(`gh-signed-commit requires an explicit --repo owner/repository target.`)}else o=repoFlagTargets(e.slice(1)),e[1]===`repo`&&(e[2]===`clone`||e[2]===`view`||e[2]===`fork`)&&e[3]&&!e[3].startsWith(`-`)&&o.push(canonicalRepository(e[3]));for(let e of o)if(!i.has(e.toLowerCase()))throw Error(`Command target ${JSON.stringify(e)} is not in the declared repositories.`);return a}function repoFlagTargets(e){let t=[];for(let n=0;n<e.length;n+=1){let r=e[n];if(r===`--repo`||r===`-R`){let i=e[n+1];if(!i)throw Error(`${r} requires an owner/repository value.`);t.push(canonicalRepository(i)),n+=1}else r?.startsWith(`--repo=`)&&t.push(canonicalRepository(r.slice(7)))}return t}function repositoryFromRemote(e){let t=/^https:\/\/github\.com\/([^/]+\/[^/]+?)(?:\.git)?$/iu.exec(e);if(t?.[1])return canonicalRepository(t[1]);let n=/^git@github\.com:([^/]+\/[^/]+?)(?:\.git)?$/iu.exec(e);if(n?.[1])return canonicalRepository(n[1]);throw Error(`The origin remote is not a canonical GitHub repository URL.`)}function canonicalRepository(e){let t=e.replace(/\.git$/iu,``);if(!/^[A-Za-z0-9-]+\/[A-Za-z0-9._-]+$/u.test(t))throw Error(`Invalid GitHub repository ${JSON.stringify(e)}.`);return t}function repositoryNames(e,t){if(e.length!==1)throw Error(`Exactly one GitHub repository is required.`);let n=new Set;for(let r of e){let e=/^([A-Za-z0-9-]+)\/([A-Za-z0-9._-]+)$/u.exec(r);if(!e)throw Error(`Invalid GitHub repository ${JSON.stringify(r)}.`);if(e[1]?.toLowerCase()!==t.toLowerCase())throw Error(`Repository ${JSON.stringify(r)} is outside ${t}.`);n.add(e[2])}if(n.size!==1)throw Error(`Exactly one GitHub repository is required.`);return[...n]}function executablePath(e,t){return e===`gh`?toolingPaths(t).ghReal:e===`gh-signed-commit`?toolingPaths(t).trustedSignedCommit:`git`}function resolveWorkingDirectory(e,t){let n=posix.resolve(`/`,e.resolvePath(``)),r=posix.resolve(`/`,e.resolvePath(t?.trim()||``));if(r!==n&&!r.startsWith(`${n}/`))throw Error(`GitHub command workingDirectory must stay inside the sandbox workspace.`);return r}function sanitizeOutput(e,t,n){let r=e.replaceAll(t,`[redacted]`).replaceAll(n,`[redacted]`);return Buffer.byteLength(r)<=MAX_OUTPUT_BYTES?{value:r,truncated:!1}:{value:`[output truncated: showing final ${MAX_OUTPUT_BYTES} bytes]\n${Buffer.from(r).subarray(-1e5).toString()}`,truncated:!0}}function unsupportedSyntax(){return Error(`GitHub commands support argv syntax only, not pipes, redirects, substitutions, or shell operators.`)}export{executeGitHubShell,githubShellApproval,parseCommand};
|
|
@@ -1,53 +0,0 @@
|
|
|
1
|
-
---
|
|
2
|
-
name: pr
|
|
3
|
-
description: Prepare and publish a draft pull request with a signed commit, motivation-led description, testable hypothesis, and validation evidence.
|
|
4
|
-
---
|
|
5
|
-
|
|
6
|
-
# Publish a proposal
|
|
7
|
-
|
|
8
|
-
Fetch the current base immediately before publication. Rebase onto it, or replay only the intended diff onto a clean checkout when local commits are unavailable. Stop on conflicts, stale refs, unexpected paths, or unrelated reversions.
|
|
9
|
-
|
|
10
|
-
Stage only the intended changes. Repositories that require verified commits must use:
|
|
11
|
-
|
|
12
|
-
```sh
|
|
13
|
-
gh-signed-commit --repo owner/name --branch <branch> --base <base> -m "<headline>" [-b "<body>"]
|
|
14
|
-
```
|
|
15
|
-
|
|
16
|
-
The command commits only staged changes and synchronizes the checkout to the signed remote commit. Then write the PR body to a file and create one draft:
|
|
17
|
-
|
|
18
|
-
```sh
|
|
19
|
-
gh pr create --draft --title "<title>" --body-file <path> --base <base> --head <branch>
|
|
20
|
-
```
|
|
21
|
-
|
|
22
|
-
Use a specific title that names the behavior or problem. Never use placeholders such as `prepare changes`. Keep secrets, private context, credentials, and requester identity out of public metadata.
|
|
23
|
-
|
|
24
|
-
Write directly and top-down. Start with impact, then explain the essential decisions and why this shape tests the hypothesis. Prefer simple English and brief context over a wall of generated prose. Include truthful reproduction and validation evidence.
|
|
25
|
-
|
|
26
|
-
A useful description answers:
|
|
27
|
-
|
|
28
|
-
1. Why the change is necessary.
|
|
29
|
-
2. Why this approach is the smallest sound solution.
|
|
30
|
-
3. Which entry points and data flows change.
|
|
31
|
-
4. What evidence verifies the expected outcome.
|
|
32
|
-
|
|
33
|
-
Prefer this shape unless the repository has a required template:
|
|
34
|
-
|
|
35
|
-
```markdown
|
|
36
|
-
[One-line summary of what changed and why]
|
|
37
|
-
|
|
38
|
-
**Why**
|
|
39
|
-
|
|
40
|
-
[Observed problem, evidence, and impact]
|
|
41
|
-
|
|
42
|
-
**Approach**
|
|
43
|
-
|
|
44
|
-
Because [cause], changing [mechanism] should [expected outcome].
|
|
45
|
-
|
|
46
|
-
**Validation**
|
|
47
|
-
|
|
48
|
-
[Focused checks and results]
|
|
49
|
-
|
|
50
|
-
**Relevant context**
|
|
51
|
-
|
|
52
|
-
[Only the implementation or data-flow details reviewers need]
|
|
53
|
-
```
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{disableTool}from"eve/tools";var load_skill_default=disableTool();export{load_skill_default as default};
|
|
@@ -1,26 +0,0 @@
|
|
|
1
|
-
import type { ToolSet } from "ai";
|
|
2
|
-
import type { HarnessToolDefinition } from "#harness/execute-tool.js";
|
|
3
|
-
import type { HarnessSession, HarnessToolMap } from "#harness/types.js";
|
|
4
|
-
type AdvertisedToolSession = Pick<HarnessSession, "rootSessionId">;
|
|
5
|
-
type AdvertisedToolMapInput = {
|
|
6
|
-
readonly session: AdvertisedToolSession;
|
|
7
|
-
readonly tools: HarnessToolMap;
|
|
8
|
-
};
|
|
9
|
-
type AdvertisedToolDefinitionsInput = {
|
|
10
|
-
readonly session: AdvertisedToolSession;
|
|
11
|
-
readonly tools: readonly HarnessToolDefinition[];
|
|
12
|
-
};
|
|
13
|
-
type AdvertisedModelToolsInput = {
|
|
14
|
-
readonly modelTools: ToolSet;
|
|
15
|
-
readonly session: HarnessSession;
|
|
16
|
-
readonly tools: HarnessToolMap;
|
|
17
|
-
};
|
|
18
|
-
type AdvertisedModelTools = {
|
|
19
|
-
readonly harnessTools: HarnessToolMap;
|
|
20
|
-
readonly modelTools: ToolSet;
|
|
21
|
-
readonly session: HarnessSession;
|
|
22
|
-
};
|
|
23
|
-
export declare function getAdvertisedTools(input: AdvertisedModelToolsInput): Promise<AdvertisedModelTools>;
|
|
24
|
-
export declare function getAdvertisedTools(input: AdvertisedToolMapInput): HarnessToolMap;
|
|
25
|
-
export declare function getAdvertisedTools(input: AdvertisedToolDefinitionsInput): readonly HarnessToolDefinition[];
|
|
26
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
function getAdvertisedTools(e){return`modelTools`in e?getAdvertisedModelTools(e):isToolDefinitionList(e.tools)?filterUnavailableToolDefinitions(e.tools,e.session):filterUnavailableToolMap(e.tools,e.session)}async function getAdvertisedModelTools(e){return{harnessTools:filterUnavailableToolMap(e.tools,e.session),modelTools:e.modelTools,session:e.session}}function filterUnavailableToolDefinitions(e,t){let n=[];for(let r of e)shouldHideTool(r,t)||n.push(r);return n}function filterUnavailableToolMap(e,t){let n=new Map;for(let[r,i]of e)shouldHideTool(i,t)||n.set(r,i);return n}function shouldHideTool(e,t){let n=t.rootSessionId!==void 0;return e.rootOnly===!0||e.availableInSubagents===!1||e.behavior?.availability.includes(`root-session`)===!0?n:!1}function isToolDefinitionList(e){return Array.isArray(e)}export{getAdvertisedTools};
|
|
@@ -1,23 +0,0 @@
|
|
|
1
|
-
import type { TurnPosition } from "#harness/session-machine/view.js";
|
|
2
|
-
import type { HarnessEmitFn } from "#harness/types.js";
|
|
3
|
-
import type { JsonObject } from "#shared/json.js";
|
|
4
|
-
/**
|
|
5
|
-
* A call a tool made on the model's behalf, reported on the protocol as a
|
|
6
|
-
* nested action of the calling tool's action. Nested actions never enter
|
|
7
|
-
* model history; the model sees only the parent call and its result.
|
|
8
|
-
*/
|
|
9
|
-
export interface NestedToolAction {
|
|
10
|
-
readonly input: JsonObject;
|
|
11
|
-
readonly isError?: boolean;
|
|
12
|
-
/** The call's result, or its error message when `isError` is set. */
|
|
13
|
-
readonly output: unknown;
|
|
14
|
-
readonly toolName: string;
|
|
15
|
-
}
|
|
16
|
-
/** Records a nested action of the tool call `parentCallId`. */
|
|
17
|
-
export declare function reportNestedToolAction(parentCallId: string, action: NestedToolAction): void;
|
|
18
|
-
/**
|
|
19
|
-
* Emits the nested actions recorded for `parentCallId`, each as an
|
|
20
|
-
* `actions.requested` and `action.result` pair. Call ids derive from the
|
|
21
|
-
* parent's, so a re-run step reports the same ids.
|
|
22
|
-
*/
|
|
23
|
-
export declare function emitNestedToolActions(emitFn: HarnessEmitFn, state: Pick<TurnPosition, "sequence" | "stepIndex" | "turnId">, parentCallId: string): Promise<void>;
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{contextStorage}from"#context/container.js";import{createActionResultEvent,createActionsRequestedEvent}from"#protocol/message.js";import{ContextKey}from"#context/key.js";import{createRuntimeToolResultFromValue}from"#harness/action-result-helpers.js";const NestedToolActionsKey=new ContextKey(`eve.nestedToolActions`);function reportNestedToolAction(e,t){let n=contextStorage.getStore();if(n===void 0)return;let r=n.get(NestedToolActionsKey)??{};n.setVirtualContext(NestedToolActionsKey,{...r,[e]:[...r[e]??[],t]})}async function emitNestedToolActions(e,t,n){let r=contextStorage.getStore(),i=r?.get(NestedToolActionsKey),a=i?.[n];if(r===void 0||i===void 0||a===void 0)return;let{[n]:o,...s}=i;r.setVirtualContext(NestedToolActionsKey,s);for(let[r,i]of a.entries()){let a=`${n}:${r+1}`,o={sequence:t.sequence,stepIndex:t.stepIndex,turnId:t.turnId};await e(createActionsRequestedEvent({actions:[{callId:a,input:i.input,kind:`tool-call`,parentCallId:n,toolName:i.toolName}],...o})),await e(createActionResultEvent({result:createRuntimeToolResultFromValue({callId:a,isError:i.isError,output:i.output,toolName:i.toolName}),...o}))}}export{emitNestedToolActions,reportNestedToolAction};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_schema}from"./schema.js";import{require_lib}from"../../../../../xdg-app-paths@5.5.1/node_modules/xdg-app-paths/src/lib/index.js";var require_cli_config=__commonJSMin((e=>{var t=e&&e.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(e,"__esModule",{value:!0}),e.defaultAuthConfig=e.defaultGlobalConfig=void 0,e.getDefaultAuthConfig=getDefaultAuthConfig,e.parseGlobalConfig=parseGlobalConfig,e.parseAuthConfig=parseAuthConfig,e.parseAuthFileConfig=parseAuthFileConfig,e.readConfigFile=readConfigFile,e.writeConfigFile=writeConfigFile,e.getGlobalPathConfig=getGlobalPathConfig,e.getConfigFilePath=getConfigFilePath,e.getAuthConfigFilePath=getAuthConfigFilePath,e.readGlobalConfigFile=readGlobalConfigFile,e.writeGlobalConfigFile=writeGlobalConfigFile,e.readAuthConfigFile=readAuthConfigFile,e.readAuthFileConfig=readAuthFileConfig,e.readAuthConfig=readAuthConfig,e.tryReadAuthConfig=tryReadAuthConfig,e.writeAuthConfigFile=writeAuthConfigFile,e.writeAuthConfig=writeAuthConfig,e.deleteAuthConfigFile=deleteAuthConfigFile,e.deleteAuthConfig=deleteAuthConfig;let n=t(require("node:fs")),r=t(require("node:path")),i=require("node:os"),a=t(require_lib()),o=require("#compiled/zod/index.js"),s=require_schema(),c=`https://vercel.com/docs/projects/project-configuration/global-configuration`;e.defaultGlobalConfig={"// Note":`This is your Vercel config file. For more information see the global configuration documentation.`,"// Docs":`${c}#config.json`};function getDefaultAuthConfig(){return{"// Note":`This is your Vercel credentials file. DO NOT SHARE!`,"// Docs":`${c}#auth.json`}}e.defaultAuthConfig=getDefaultAuthConfig();function normalizeConfigError(e){if(e instanceof o.z.ZodError){let t=e.issues.find(e=>e.path[0]===`credStorage`);if(t)throw Error(t.message)}throw e}function parseGlobalConfig(e){try{return s.globalConfigSchema.parse(e)}catch(e){normalizeConfigError(e)}}function parseAuthConfig(e){return s.authConfigSchema.parse(e)}function parseAuthFileConfig(e){let{tokenSource:t,...n}=parseAuthConfig(e);return n}function readJsonFileSync(e){let t=n.default.readFileSync(e,`utf8`).replace(/^\uFEFF/,``);return JSON.parse(t)}function writeJsonFileSync(e,t,i={}){let a=r.default.dirname(e),o=r.default.join(a,`.${r.default.basename(e)}.${process.pid}.${Date.now()}.tmp`),s=`${JSON.stringify(t,null,i.indent??2)}\n`;n.default.mkdirSync(a,{recursive:!0});try{n.default.writeFileSync(o,s,{encoding:`utf8`,mode:i.mode}),n.default.renameSync(o,e)}catch(e){try{n.default.rmSync(o,{force:!0})}catch{}throw e}}function readConfigFile(e,t){return t.parse(readJsonFileSync(e))}function writeConfigFile(e,t,n,r){writeJsonFileSync(e,o.z.encode(t,n),{indent:2,...r})}function isReadableDirectory(e){try{return n.default.lstatSync(e).isDirectory()}catch{return!1}}function getGlobalPathConfig(){let e=(0,a.default)(`com.vercel.cli`).dataDirs();return[...e,r.default.join((0,i.homedir)(),`.now`),...(0,a.default)(`now`).dataDirs()].find(e=>isReadableDirectory(e))||e[0]}function getConfigFilePath(e){return r.default.join(e,`config.json`)}function getAuthConfigFilePath(e){return r.default.join(e,`auth.json`)}function readGlobalConfigFile(e){try{return readConfigFile(e,s.globalConfigSchema)}catch(e){normalizeConfigError(e)}}function writeGlobalConfigFile(e,t){writeConfigFile(e,s.globalConfigSchema,t)}function readAuthConfigFile(e){return readConfigFile(e,s.authConfigSchema)}function readAuthFileConfig(e){return parseAuthFileConfig(readJsonFileSync(e))}function readAuthConfig(e){return readAuthConfigFile(getAuthConfigFilePath(e))}function tryReadAuthConfig(e){try{return readAuthConfig(e)}catch{return null}}function writeAuthConfigFile(e,t){t.skipWrite||writeConfigFile(e,s.authConfigSchema,t,{mode:384})}function writeAuthConfig(e,t){writeAuthConfigFile(getAuthConfigFilePath(e),t)}function deleteAuthConfigFile(e){n.default.rmSync(e,{force:!0})}function deleteAuthConfig(e){deleteAuthConfigFile(getAuthConfigFilePath(e))}}));export default require_cli_config();export{require_cli_config};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_types}from"./types.js";import{require_cli_config}from"./cli-config.js";var require_cred_storage=__commonJSMin((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.authConfigHasUsableTokenData=authConfigHasUsableTokenData,e.getLikelyEffectiveCredStorage=getLikelyEffectiveCredStorage;let t=require_types(),n=require_cli_config(),r=`VERCEL_TOKEN_STORAGE`;function isErrnoException(e){return typeof e==`object`&&!!e&&`code`in e}function isCredStorage(e){return t.CRED_STORAGE_CONFIG_VALUES.includes(e)}function formatCredStorageError(e,n){return`Invalid value for \`${n}\`: ${JSON.stringify(e)}. Expected one of: ${t.CRED_STORAGE_CONFIG_VALUES.map(e=>JSON.stringify(e)).join(`, `)}.`}function parseCredStorage(e,t=`credStorage`){if(e!==void 0){if(isCredStorage(e))return e;throw Error(formatCredStorageError(e,t))}}function authConfigHasUsableTokenData(e){if(!e||typeof e!=`object`)return!1;let t=e;return typeof t.token==`string`&&t.token.length>0||typeof t.refreshToken==`string`&&t.refreshToken.length>0}function getLikelyAutoCredStorage(e){try{return authConfigHasUsableTokenData((0,n.readAuthConfigFile)((0,n.getAuthConfigFilePath)(e)))?`file`:`keyring`}catch{return`keyring`}}function getLikelyConfiguredCredStorage(e,n){return n===`keyring`?`keyring`:n===`auto`?getLikelyAutoCredStorage(e):t.DEFAULT_CRED_STORAGE}function getLikelyEffectiveCredStorage(e){let t={},i=process.env[r];if(i!==void 0)return getLikelyConfiguredCredStorage(e,parseCredStorage(i,r));try{let r=(0,n.readGlobalConfigFile)((0,n.getConfigFilePath)(e));t={...r,credStorage:parseCredStorage(r.credStorage)}}catch(e){if(!(isErrnoException(e)&&e.code===`ENOENT`))throw e}return getLikelyConfiguredCredStorage(e,t.credStorage)}}));export default require_cred_storage();export{require_cred_storage};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_types}from"./types.js";import{require_schema}from"./schema.js";import{require_cli_config}from"./cli-config.js";import{require_cred_storage}from"./cred-storage.js";var require_dist=__commonJSMin((e=>{var t=e&&e.__createBinding||(Object.create?(function(e,t,n,r){r===void 0&&(r=n);var i=Object.getOwnPropertyDescriptor(t,n);(!i||(`get`in i?!t.__esModule:i.writable||i.configurable))&&(i={enumerable:!0,get:function(){return t[n]}}),Object.defineProperty(e,r,i)}):(function(e,t,n,r){r===void 0&&(r=n),e[r]=t[n]})),n=e&&e.__exportStar||function(e,n){for(var r in e)r!=="default"&&!Object.prototype.hasOwnProperty.call(n,r)&&t(n,e,r)};Object.defineProperty(e,"__esModule",{value:!0}),n(require_types(),e),n(require_schema(),e),n(require_cli_config(),e),n(require_cred_storage(),e)}));export default require_dist();export{require_dist};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_types}from"./types.js";import{require_schema_zod}from"./schema.zod.js";var require_schema=__commonJSMin((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.authConfigSchema=e.globalConfigSchema=e.credStorageSchema=e.updatesConfigSchema=e.guidanceConfigSchema=e.telemetryConfigSchema=void 0;let t=require("#compiled/zod/index.js"),n=require_schema_zod(),r=require_types();function formatCredStorageError(e){return`Invalid value for \`credStorage\`: ${JSON.stringify(e)}. Expected one of: ${r.CRED_STORAGE_CONFIG_VALUES.map(e=>JSON.stringify(e)).join(`, `)}.`}e.telemetryConfigSchema=n.telemetryConfigSchema.passthrough(),e.guidanceConfigSchema=n.guidanceConfigSchema.passthrough(),e.updatesConfigSchema=n.updatesConfigSchema.passthrough(),e.credStorageSchema=t.z.enum(r.CRED_STORAGE_CONFIG_VALUES,{error:e=>formatCredStorageError(e.input)}).optional(),e.globalConfigSchema=n.globalConfigSchema.extend({credStorage:e.credStorageSchema,telemetry:e.telemetryConfigSchema.optional(),guidance:e.guidanceConfigSchema.optional(),updates:e.updatesConfigSchema.optional()}).passthrough(),e.authConfigSchema=n.authConfigSchema.passthrough()}));export default require_schema();export{require_schema};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_schema_zod=__commonJSMin((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.globalConfigSchema=e.authFileConfigSchema=e.authConfigSchema=e.credStorageSchema=e.updatesConfigSchema=e.guidanceConfigSchema=e.telemetryConfigSchema=void 0;let t=require("#compiled/zod/index.js");e.telemetryConfigSchema=t.z.object({enabled:t.z.boolean().optional()}),e.guidanceConfigSchema=t.z.object({enabled:t.z.boolean().optional()}),e.updatesConfigSchema=t.z.object({auto:t.z.boolean().optional()}),e.credStorageSchema=t.z.union([t.z.literal(`auto`),t.z.literal(`file`),t.z.literal(`keyring`)]),e.authConfigSchema=t.z.object({"// Note":t.z.string().optional(),"// Docs":t.z.string().optional(),skipWrite:t.z.boolean().optional(),token:t.z.string().optional(),userId:t.z.string().optional(),refreshToken:t.z.string().optional(),expiresAt:t.z.number().optional(),tokenSource:t.z.union([t.z.literal(`flag`),t.z.literal(`env`)]).optional()}),e.authFileConfigSchema=e.authConfigSchema.omit({tokenSource:!0}),e.globalConfigSchema=t.z.object({"// Note":t.z.string().optional(),"// Docs":t.z.string().optional(),credStorage:e.credStorageSchema.optional(),currentTeam:t.z.string().optional(),api:t.z.string().optional(),telemetry:e.telemetryConfigSchema.optional(),guidance:e.guidanceConfigSchema.optional(),updates:e.updatesConfigSchema.optional()})}));export default require_schema_zod();export{require_schema_zod};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_types=__commonJSMin((e=>{Object.defineProperty(e,"__esModule",{value:!0}),e.DEFAULT_CRED_STORAGE=e.CRED_STORAGE_VALUES=e.CRED_STORAGE_CONFIG_VALUES=void 0,e.CRED_STORAGE_CONFIG_VALUES=[`auto`,`file`,`keyring`],e.CRED_STORAGE_VALUES=e.CRED_STORAGE_CONFIG_VALUES.filter(e=>e!==`auto`),e.DEFAULT_CRED_STORAGE=`file`}));export default require_types();export{require_types};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_envpath=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{getEnvPath:()=>getEnvPath,prependPathEntries:()=>prependPathEntries,setEnvPath:()=>setEnvPath,splitPath:()=>splitPath}),t.exports=__toCommonJS(c);var l=__toESM(require("node:path"));function prependPathEntries(e,t){let n=e.split(l.default.delimiter).filter(Boolean),r=[];for(let e of t)!n.includes(e)&&!r.includes(e)&&r.push(e);return r.length===0?e:e===``||e===l.default.delimiter?`${r.join(l.default.delimiter)}${e}`:[...r,e].join(l.default.delimiter)}function splitPath(e){return e.split(l.default.delimiter).filter(Boolean)}function getEnvPath(e=process.env){if(process.platform!==`win32`)return e.PATH??``;let t=Object.keys(e).filter(e=>e.toLowerCase()===`path`);for(let n=t.length-1;n>=0;n--){let r=e[t[n]];if(r!==void 0)return r}return``}function setEnvPath(e=process.env,t){if(process.platform!==`win32`)return{...e,PATH:t};let n={...e};for(let e of Object.keys(n))e!==`PATH`&&e.toLowerCase()===`path`&&delete n[e];return n.PATH=t,n}0&&(t.exports={getEnvPath,prependPathEntries,setEnvPath,splitPath})}));export default require_envpath();export{require_envpath};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_errors=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{VercelCliError:()=>VercelCliError,assertValidCwd:()=>assertValidCwd,getCliNotFoundMessage:()=>getCliNotFoundMessage,toVercelCliError:()=>toVercelCliError}),t.exports=__toCommonJS(o);var s=require("node:fs/promises"),VercelCliError=class extends Error{constructor(e){super(e.message),this.name=`VercelCliError`,this.code=e.code,this.invocation=e.invocation,this.stdout=e.stdout,this.stderr=e.stderr,this.exitCode=e.exitCode,e.cause!==void 0&&(this.cause=e.cause)}};function getCliNotFoundMessage(e){let t=[],{localBinSearch:n}=e;n.stopReason===`project-root-marker`?t.push(`Local bin lookup stopped at ${JSON.stringify(n.stoppedAt)} (${JSON.stringify(n.markerPath)}).`):n.stopReason===`filesystem-root`&&t.push(`No project root marker was found from ${JSON.stringify(n.searchRoot)}; local bin lookup reached the filesystem root.`);for(let e of n.skippedNodeModules)t.push(`Skipped ${JSON.stringify(e.directory)}: ${e.reason}.`);for(let n of e.skippedLocalBins)t.push(`Skipped ${JSON.stringify(n.candidate)}: ${n.reason}.`);return t.length===0?`Unable to find a usable Vercel CLI installation.`:[`Unable to find a usable Vercel CLI installation.`,...t].join(`
|
|
2
|
-
`)}async function assertValidCwd(e){try{if(!(await(0,s.stat)(e)).isDirectory())throw Error(`not a directory`)}catch{throw new VercelCliError({code:`VERCEL_CLI_INVALID_CWD`,message:`Working directory ${JSON.stringify(e)} does not exist or is not a directory.`})}}function toVercelCliError(e,t){if(typeof t==`object`&&t){let n=t;if(n.code===`ENOENT`)return new VercelCliError({code:`VERCEL_CLI_NOT_FOUND`,message:`Unable to find Vercel CLI command ${JSON.stringify(e.command)}.`,invocation:e,cause:t});if(n.code===`EACCES`||n.code===`EPERM`)return new VercelCliError({code:`VERCEL_CLI_PERMISSION_DENIED`,message:`Permission denied while executing Vercel CLI command ${JSON.stringify(e.command)}.`,invocation:e,cause:t});if(n.timedOut)return new VercelCliError({code:`VERCEL_CLI_TIMED_OUT`,message:`Timed out while executing Vercel CLI command ${JSON.stringify(e.command)}.`,invocation:e,stdout:n.stdout,stderr:n.stderr,cause:t});if(n.isCanceled)return new VercelCliError({code:`VERCEL_CLI_CANCELED`,message:`Canceled while executing Vercel CLI command ${JSON.stringify(e.command)}.`,invocation:e,stdout:n.stdout,stderr:n.stderr,cause:t});if(n.signal)return new VercelCliError({code:`VERCEL_CLI_SIGNALED`,message:`Vercel CLI command ${JSON.stringify(e.command)} exited due to signal ${n.signal}.`,invocation:e,stdout:n.stdout,stderr:n.stderr,cause:t});if(typeof n.exitCode==`number`)return new VercelCliError({code:`VERCEL_CLI_ERRORED`,message:n.shortMessage??n.message??`Vercel CLI command ${JSON.stringify(e.command)} exited with code ${n.exitCode}.`,invocation:e,stdout:n.stdout,stderr:n.stderr,exitCode:n.exitCode,cause:t})}return new VercelCliError({code:`VERCEL_CLI_EXEC_FAILED`,message:`Could not execute Vercel CLI command ${JSON.stringify(e.command)}.`,invocation:e,cause:t})}0&&(t.exports={VercelCliError,assertValidCwd,getCliNotFoundMessage,toVercelCliError})}));export default require_errors();export{require_errors};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_errutils=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{getErrorMessage:()=>getErrorMessage,isMissingPathError:()=>isMissingPathError}),t.exports=__toCommonJS(o);function getErrorMessage(e){return e instanceof Error?e.message:String(e)}function isMissingPathError(e){return typeof e==`object`&&!!e&&`code`in e&&(e.code===`ENOENT`||e.code===`ENOTDIR`)}0&&(t.exports={getErrorMessage,isMissingPathError})}));export default require_errutils();export{require_errutils};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_errors}from"./errors.js";import{require_execa}from"../../../../../execa@5.1.1/node_modules/execa/index.js";import{require_envpath}from"./envpath.js";import{require_lookup}from"./lookup.js";var require_exec=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{execVercelCli:()=>execVercelCli}),t.exports=__toCommonJS(c);var l=__toESM(require("node:path")),u=__toESM(require_execa()),d=require_envpath(),f=require_errors(),p=require_lookup();async function execVercelCli(e,t={}){let n=l.default.resolve(t.cwd??process.cwd());await(0,f.assertValidCwd)(n);let r=mergeExecEnv(t.env),i=(0,d.getEnvPath)(r);try{return await execResolvedVercelCli(e,t,n,r,i)}catch(a){if(a instanceof f.VercelCliError&&a.code===`VERCEL_CLI_NOT_FOUND`)return(0,p.clearCachedCliInvocation)(n,i),await execResolvedVercelCli(e,t,n,r,i);throw a}}async function execResolvedVercelCli(e,t,n,r,i){let a=await resolveInvocationOrThrow(n,i);try{let i={input:t.input,stdio:t.stdio,stdin:t.stdin,stdout:t.stdout,stderr:t.stderr,timeout:t.timeout,cwd:n,env:await prependLocalBinsToEnvPath(n,r),windowsHide:!0};t.signal&&(i.signal=t.signal);let{stdout:o,stderr:s}=await(0,u.default)(a.command,[...a.commandArgs,...e],i);return{stdout:o,stderr:s,invocation:a}}catch(e){throw(0,f.toVercelCliError)(a,e)}}async function resolveInvocationOrThrow(e,t){let n=await(0,p.resolveCachedCliInvocation)(e,t);if(!n.found)throw new f.VercelCliError({code:`VERCEL_CLI_NOT_FOUND`,message:(0,f.getCliNotFoundMessage)(n.diagnostics)});return(0,p.toVercelCliInvocation)(n)}function mergeExecEnv(e){return e?{...process.env,...e}:process.env}async function prependLocalBinsToEnvPath(e,t=process.env){let n=await prependLocalBinsToPath(e,(0,d.getEnvPath)(t));return(0,d.setEnvPath)(t,(0,d.prependPathEntries)(n,[l.default.dirname(process.execPath)]))}async function prependLocalBinsToPath(e,t=``){return(0,d.prependPathEntries)(t,(await(0,p.getLocalBinSearch)(e)).directories)}0&&(t.exports={execVercelCli})}));export default require_exec();export{require_exec};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_errutils}from"./errutils.js";var require_fsutils=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{getCanonicalPath:()=>getCanonicalPath,getCommandBase:()=>getCommandBase,getDirectoriesBetween:()=>getDirectoriesBetween,isNodeScript:()=>isNodeScript,isSubpath:()=>isSubpath,statIfExists:()=>statIfExists}),t.exports=__toCommonJS(c);var l=require("node:fs/promises"),u=__toESM(require("node:path")),d=require_errutils();async function getCanonicalPath(e){try{return await(0,l.realpath)(e)}catch{return e}}function getDirectoriesBetween(e,t){let n=[],r=u.default.resolve(t),i=u.default.resolve(e);for(;;){if(n.push(r),r===i)return n.reverse();let e=u.default.dirname(r);if(e===r)return[];r=e}}async function statIfExists(e){try{return{stats:await(0,l.stat)(e)}}catch(e){return(0,d.isMissingPathError)(e)?{missing:!0}:{reason:`could not inspect: ${(0,d.getErrorMessage)(e)}`}}}function isNodeScript(e){return[`.js`,`.cjs`,`.mjs`].includes(u.default.extname(e))}function isSubpath(e,t){let n=u.default.relative(e,t);return n===``||n!==``&&!n.startsWith(`..`)&&!u.default.isAbsolute(n)}function getCommandBase(e){let t=u.default.extname(e).toLowerCase();return process.platform===`win32`&&[`.cmd`,`.exe`].includes(t)?u.default.basename(e,t):u.default.basename(e)}0&&(t.exports={getCanonicalPath,getCommandBase,getDirectoriesBetween,isNodeScript,isSubpath,statIfExists})}));export default require_fsutils();export{require_fsutils};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_errors}from"./errors.js";import{require_lookup}from"./lookup.js";import{require_exec}from"./exec.js";var require_dist=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{VercelCliError:()=>s.VercelCliError,clearVercelCliLookupCache:()=>l.clearVercelCliLookupCache,execVercelCli:()=>c.execVercelCli,findVercelCli:()=>l.findVercelCli}),t.exports=__toCommonJS(o);var s=require_errors(),c=require_exec(),l=require_lookup();0&&(t.exports={VercelCliError,clearVercelCliLookupCache,execVercelCli,findVercelCli})}));export default require_dist();export{require_dist};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_envpath}from"./envpath.js";import{require_errutils}from"./errutils.js";import{require_fsutils}from"./fsutils.js";import{require_safety}from"./safety.js";var require_lookup=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{clearCachedCliInvocation:()=>clearCachedCliInvocation,clearVercelCliLookupCache:()=>clearVercelCliLookupCache,findVercelCli:()=>findVercelCli,getLocalBinSearch:()=>getLocalBinSearch,resolveCachedCliInvocation:()=>resolveCachedCliInvocation,toVercelCliInvocation:()=>toVercelCliInvocation}),t.exports=__toCommonJS(c);var l=require("node:fs/promises"),u=__toESM(require("node:path")),d=require_envpath(),f=require_errutils(),p=require_fsutils(),m=require_safety();let h=new Map;async function findVercelCli(e={}){let t=await resolveCachedCliInvocation(u.default.resolve(e.cwd??process.cwd()),e.path??(0,d.getEnvPath)(process.env));return t.found?toVercelCliInvocation(t):null}function resolveCachedCliInvocation(e,t){let n=getCliInvocationCacheKey(e,t);if(h.has(n))return h.get(n);let r=resolveCliInvocation(e,t).catch(e=>{throw h.delete(n),e});return h.set(n,r),r}function toVercelCliInvocation(e){return{command:e.command,commandArgs:e.commandArgs,source:e.source}}function clearVercelCliLookupCache(){h.clear()}function clearCachedCliInvocation(e,t){h.delete(getCliInvocationCacheKey(e,t))}async function resolveCliInvocation(e,t){let n=await getLocalBinSearch(e),r={localBinSearch:n.diagnostics,skippedLocalBins:[]},i=(0,d.prependPathEntries)(t,n.directories);for(let t of getVercelCommandNames()){let a=await findCommandInPath(t,i,e,n,r);if(a)return(0,p.isNodeScript)(a.realPath)?{found:!0,command:process.execPath,commandArgs:[a.realPath],source:a.source,diagnostics:r}:{found:!0,command:a.realPath,commandArgs:[],source:a.source,diagnostics:r}}return{found:!1,diagnostics:r}}async function findCommandInPath(e,t,n,r,i){for(let a of(0,d.splitPath)(t)){let t=getPathCommandCandidate(a,e,n);try{if(await canAccessCommandCandidate(t,r,i)){let n=await resolveCommandCandidate(e,t,r,i);if(n)return n}}catch{}}return null}function getPathCommandCandidate(e,t,n){let r=u.default.isAbsolute(e)?e:u.default.resolve(n,e);return u.default.join(r,t)}async function canAccessCommandCandidate(e,t,n){try{return await(0,l.access)(e,process.platform===`win32`?l.constants.F_OK:l.constants.F_OK|l.constants.X_OK),!0}catch(r){return(0,f.isMissingPathError)(r)||await recordInaccessibleLocalBinCandidate(e,r,t,n),!1}}async function recordInaccessibleLocalBinCandidate(e,t,n,r){let i=await classifyPathLocalBinCandidate(e,n.directories);i&&recordSkippedLocalBin(r,e,`reason`in i?i.reason:`local bin is not accessible: ${(0,f.getErrorMessage)(t)}`)}async function resolveCommandCandidate(e,t,n,r){if(!(await(0,l.stat)(t)).isFile())return null;let i=await(0,l.realpath)(t),a=await classifyPathLocalBinCandidate(t,n.directories);if(!a)return{realPath:i,source:`path`};if(`reason`in a)return recordSkippedLocalBin(r,t,a.reason),null;let o=await getLocalVercelPackageBin(e,a.directory);return`reason`in o?(recordSkippedLocalBin(r,t,o.reason),null):{realPath:o.binPath,source:`local-bin`}}function recordSkippedLocalBin(e,t,n){e.skippedLocalBins.push({candidate:t,reason:n})}function getVercelCommandNames(){let e=[`vercel`];if(process.platform!==`win32`)return e;let t=[`.cmd`,`.exe`,``];return e.flatMap(e=>t.map(t=>`${e}${t}`))}async function getLocalBinSearch(e){let t=await(0,p.getCanonicalPath)(u.default.resolve(e)),n=await getAncestorDirectorySearch(t),r=[],i=[];for(let e of n.directories){let a=u.default.join(e,`node_modules`),o=n.stopReason===`project-root-marker`?(0,p.getDirectoriesBetween)(n.stoppedAt,e):(0,p.getDirectoriesBetween)(e,t),s=await(0,m.getSkippedNodeModulesReason)(a,o);if(s){r.push({directory:a,reason:s});continue}i.push(u.default.join(a,`.bin`))}return{directories:i,diagnostics:{searchRoot:t,stoppedAt:n.stoppedAt,stopReason:n.stopReason,markerPath:n.markerPath,skippedNodeModules:r}}}async function getAncestorDirectorySearch(e){let t=[],n=u.default.resolve(e);for(;;){t.push(n);let e=await getProjectRootMarker(n);if(e)return{directories:t,stoppedAt:n,stopReason:`project-root-marker`,markerPath:e.path};let r=u.default.dirname(n);if(r===n)return{directories:t,stoppedAt:n,stopReason:`filesystem-root`};n=r}}async function getProjectRootMarker(e){let t=u.default.join(e,`.git`);try{return await(0,l.stat)(t),{path:t}}catch{}return null}async function getLocalBinDirectory(e,t){let n=u.default.resolve(e),r=n;try{r=u.default.join(await(0,l.realpath)(u.default.dirname(n)),u.default.basename(n))}catch{}for(let e of t){try{e=await(0,l.realpath)(e)}catch{}if(r.startsWith(`${e}${u.default.sep}`))return e}return null}async function getNodeModulesBinDirectory(e){let t=u.default.resolve(u.default.dirname(e)),n=[t];try{let e=await(0,l.realpath)(t);n.includes(e)||n.push(e)}catch{}for(let e of n)if(u.default.basename(e)===`.bin`&&u.default.basename(u.default.dirname(e))===`node_modules`)return e;return null}async function classifyPathLocalBinCandidate(e,t){let n=await getLocalBinDirectory(e,t);if(n)return{directory:n};let r=await getNodeModulesBinDirectory(e);if(!r)return null;let i=u.default.dirname(r),a=await(0,m.getSkippedNodeModulesReason)(i);return a?{reason:`local node_modules is ${a}`}:{reason:`local bin is outside project lookup boundary`}}async function getLocalVercelPackageBin(e,t){let n=(0,p.getCommandBase)(e),r=u.default.dirname(t);if(n!==`vercel`||u.default.basename(r)!==`node_modules`)return{reason:`not a local vercel bin`};try{let e=await getLocalVercelPackage(r);if(`reason`in e)return e;let t=await readLocalVercelPackageJson(e.realPackageDirectory);return`reason`in t?t:(e.packageJson=t.packageJson,await getDeclaredLocalVercelPackageBin(e,n))}catch(e){return{reason:`could not validate local vercel package: ${(0,f.getErrorMessage)(e)}`}}}async function getLocalVercelPackage(e){let t=u.default.join(e,`vercel`),n=await(0,l.realpath)(e),r=await(0,l.realpath)(t);if(!(0,p.isSubpath)(n,r))return{reason:`local vercel package resolves outside local node_modules`};let i=await(0,m.getUnsafePackageDirectoryReason)(n,r);return i?{reason:`local vercel package is unsafe: ${i}`}:{realNodeModulesDirectory:n,realPackageDirectory:r,packageJson:{}}}async function readLocalVercelPackageJson(e){let t=u.default.join(e,`package.json`),n=await(0,l.realpath)(t);if(!(0,p.isSubpath)(e,n))return{reason:`local vercel package.json resolves outside package`};let r=await(0,m.getUnsafePackageFileReason)(e,n);if(r)return{reason:`local vercel package.json is unsafe: ${r}`};let i=JSON.parse(await(0,l.readFile)(n,`utf8`));return i.name===`vercel`?{packageJson:i}:{reason:`local vercel package.json does not have name "vercel"`}}async function getDeclaredLocalVercelPackageBin(e,t){let{packageJson:n,realNodeModulesDirectory:r,realPackageDirectory:i}=e,a=getPackageBinTarget(n,t);if(!a)return{reason:`local vercel package does not declare bin.vercel`};let o=u.default.resolve(i,a),s=await(0,l.realpath)(o);if(!(0,p.isSubpath)(i,s))return{reason:`local vercel package bin resolves outside package`};let c=await(0,m.getUnsafePackageBinReason)(r,i,s);if(c)return{reason:`local vercel package bin is unsafe: ${c}`};if(process.platform!==`win32`&&!(0,p.isNodeScript)(s))try{await(0,l.access)(s,l.constants.F_OK|l.constants.X_OK)}catch(e){return{reason:`local vercel package bin is not executable: ${(0,f.getErrorMessage)(e)}`}}return{binPath:s}}function getPackageBinTarget(e,t){let n=e.bin;if(typeof n==`string`)return t===`vercel`?n:null;if(n&&typeof n==`object`){let e=n[t];if(typeof e==`string`)return e}return null}function getCliInvocationCacheKey(e,t){return`${e}\0${t}`}0&&(t.exports={clearCachedCliInvocation,clearVercelCliLookupCache,findVercelCli,getLocalBinSearch,resolveCachedCliInvocation,toVercelCliInvocation})}));export default require_lookup();export{require_lookup};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_errutils}from"./errutils.js";import{require_fsutils}from"./fsutils.js";var require_safety=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{getSkippedNodeModulesReason:()=>getSkippedNodeModulesReason,getUnsafeDirectoryReason:()=>getUnsafeDirectoryReason,getUnsafePackageBinReason:()=>getUnsafePackageBinReason,getUnsafePackageDirectoryReason:()=>getUnsafePackageDirectoryReason,getUnsafePackageFileReason:()=>getUnsafePackageFileReason,getUnsafeStatsReason:()=>getUnsafeStatsReason}),t.exports=__toCommonJS(c);var l=require("node:fs/promises"),u=__toESM(require("node:path")),d=require_errutils(),f=require_fsutils();async function getSkippedNodeModulesReason(e,t){let n=u.default.dirname(e);t??=[n];for(let e of t){let t;try{t=await getUnsafeDirectoryReason(e)}catch(e){t=`could not inspect: ${(0,d.getErrorMessage)(e)}`}if(t)return`${e} is ${t}`}let r=await(0,f.statIfExists)(e);return`missing`in r?null:`reason`in r?r.reason:r.stats.isDirectory()?getUnsafeStatsReason(r.stats)||await getSkippedLocalBinDirectoryReason(u.default.join(e,`.bin`)):`not a directory`}async function getSkippedLocalBinDirectoryReason(e){let t=await(0,f.statIfExists)(e);if(`missing`in t)return null;if(`reason`in t)return`${e} ${t.reason}`;if(!t.stats.isDirectory())return`${e} is not a directory`;let n=getUnsafeStatsReason(t.stats);return n?`${e} is ${n}`:null}async function getUnsafePackageBinReason(e,t,n){return await getUnsafePackageDirectoryReason(e,t)||await getUnsafePackageFileReason(t,n)}async function getUnsafePackageDirectoryReason(e,t){let n=(0,f.getDirectoriesBetween)(e,t);if(n.length===0)return`${t} resolves outside local node_modules`;for(let e of n){let t=await getUnsafeDirectoryReason(e);if(t)return`${e} is ${t}`}return null}async function getUnsafePackageFileReason(e,t){let n=(0,f.getDirectoriesBetween)(e,u.default.dirname(t));if(n.length===0)return`${t} resolves outside package`;for(let e of n){let t=await getUnsafeDirectoryReason(e);if(t)return`${e} is ${t}`}let r=await getUnsafeFileReason(t);return r?`${t} is ${r}`:null}async function getUnsafeDirectoryReason(e){let t=await(0,l.stat)(e);return t.isDirectory()?getUnsafeStatsReason(t):`not a directory`}async function getUnsafeFileReason(e){let t=await(0,l.stat)(e);return t.isFile()?getUnsafeStatsReason(t):`not a file`}function getUnsafeStatsReason(e){let t=process.geteuid??process.getuid;if(typeof t!=`function`)return null;let n=t();return e.mode&18?e.mode&2?`world-writable`:`group-writable`:e.uid===n?null:`owned by uid ${e.uid}, current uid is ${n}`}0&&(t.exports={getSkippedNodeModulesReason,getUnsafeDirectoryReason,getUnsafePackageBinReason,getUnsafePackageDirectoryReason,getUnsafePackageFileReason,getUnsafeStatsReason})}));export default require_safety();export{require_safety};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/auth-errors.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_auth_errors=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{AccessTokenMissingError:()=>AccessTokenMissingError,RefreshAccessTokenFailedError:()=>RefreshAccessTokenFailedError}),t.exports=__toCommonJS(o);var AccessTokenMissingError=class extends Error{constructor(){super(`No authentication found. Please log in with the Vercel CLI (vercel login).`),this.name=`AccessTokenMissingError`}},RefreshAccessTokenFailedError=class extends Error{constructor(e){super(`Failed to refresh authentication token.`),this.name=`RefreshAccessTokenFailedError`,e!==void 0&&(this.cause=e)}};0&&(t.exports={AccessTokenMissingError,RefreshAccessTokenFailedError})}));export default require_auth_errors();export{require_auth_errors};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_version}from"./version.js";var require_exchange_vercel_oidc_token=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{exchangeVercelOidcToken:()=>exchangeVercelOidcToken}),t.exports=__toCommonJS(o);var s=require_version();let c=new class{constructor(e){this.maxEntries=e,this.entries=new Map}get(e){let t=this.entries.get(e);if(t!==void 0){if(t.expiresAt<=Date.now()){this.entries.delete(e);return}return this.entries.delete(e),this.entries.set(e,t),t.token}}set({key:e,token:t,expiresAt:n}){for(this.entries.delete(e),this.entries.set(e,{token:t,expiresAt:n});this.entries.size>this.maxEntries;){let e=this.entries.keys().next().value;if(e===void 0)break;this.entries.delete(e)}}}(1e3);async function getCacheKey(e){let t=JSON.stringify([e.token,e.audience,e.jti]),n=await crypto.subtle.digest(`SHA-256`,new TextEncoder().encode(t));return Array.from(new Uint8Array(n)).map(e=>e.toString(16).padStart(2,`0`)).join(``)}async function exchangeVercelOidcToken(e){let t=await getCacheKey(e);if(!e.skipCache){let e=c.get(t);if(e!==void 0)return e}let n=await fetch(`https://oidc.vercel.com/~token`,{method:`POST`,headers:{"Content-Type":`application/json`,Accept:`application/json`,"User-Agent":`@vercel/oidc@${s.version}`},body:JSON.stringify({token:e.token,aud:e.audience,...e.jti?{jti:e.jti}:void 0})});if(!n.ok)throw Error(`Failed to exchange token: ${await readErrorMessage(n)}`);let r;try{r=await n.json()}catch{throw Error(`Failed to exchange token: response was not valid JSON`)}if(!r||typeof r!=`object`||!(`token`in r)||typeof r.token!=`string`)throw Error(`Failed to exchange token: response did not contain a token`);let{token:i}=r,a=`expiry`in r&&typeof r.expiry==`number`?r.expiry:void 0;if(a!==void 0){let e=a*1e3;e>Date.now()&&c.set({key:t,token:i,expiresAt:e})}return i}async function readErrorMessage(e){try{let t=await e.json();if(t&&typeof t==`object`&&`error`in t&&typeof t.error==`string`)return t.error}catch{}return e.statusText||`HTTP ${e.status}`}0&&(t.exports={exchangeVercelOidcToken})}));export default require_exchange_vercel_oidc_token();export{require_exchange_vercel_oidc_token};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/get-context.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_get_context=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{SYMBOL_FOR_REQ_CONTEXT:()=>s,getContext:()=>getContext}),t.exports=__toCommonJS(o);let s=Symbol.for(`@vercel/request-context`);function getContext(){return globalThis[s]?.get?.()??{}}0&&(t.exports={SYMBOL_FOR_REQ_CONTEXT:s,getContext})}));export default require_get_context();export{require_get_context};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_get_context}from"./get-context.js";var require_get_vercel_oidc_token_sync=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{getVercelOidcTokenSync:()=>getVercelOidcTokenSync}),t.exports=__toCommonJS(o);var s=require_get_context();function getVercelOidcTokenSync(){let e=(0,s.getContext)().headers?.[`x-vercel-oidc-token`]??process.env.VERCEL_OIDC_TOKEN;if(!e)throw Error(`The 'x-vercel-oidc-token' header is missing from the request.`);return e}0&&(t.exports={getVercelOidcTokenSync})}));export default require_get_vercel_oidc_token_sync();export{require_get_vercel_oidc_token_sync};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_exchange_vercel_oidc_token}from"./exchange-vercel-oidc-token.js";import{require_get_vercel_oidc_token_sync}from"./get-vercel-oidc-token-sync.js";import{require_token_error}from"./token-error.js";var require_get_vercel_oidc_token_with_refresh=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{getVercelOidcToken:()=>getVercelOidcToken}),t.exports=__toCommonJS(c);var l=require_exchange_vercel_oidc_token(),u=require_get_vercel_oidc_token_sync(),d=require_token_error();async function getVercelOidcToken(e){let t=``,n;try{t=(0,u.getVercelOidcTokenSync)()}catch(e){n=e}try{let[{getTokenPayload:n,isExpired:r},{refreshToken:i}]=await Promise.all([await import(`./token-util.js`).then(e=>__toESM(e.default)),await import(`./token.js`).then(e=>__toESM(e.default))]);(!t||r(n(t),e?.expirationBufferMs))&&(await i(e),t=(0,u.getVercelOidcTokenSync)())}catch(e){let t=n instanceof Error?n.message:``;throw e instanceof Error&&(t=`${t}
|
|
2
|
-
${e.message}`),t?new d.VercelOidcTokenError(t):e}return e?.audience&&(t=await(0,l.exchangeVercelOidcToken)({token:t,audience:e.audience,jti:e.jti,skipCache:e.skipCache})),t}0&&(t.exports={getVercelOidcToken})}));export default require_get_vercel_oidc_token_with_refresh();export{require_get_vercel_oidc_token_with_refresh};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_exchange_vercel_oidc_token}from"./exchange-vercel-oidc-token.js";import{require_get_context}from"./get-context.js";import{require_get_vercel_oidc_token_sync}from"./get-vercel-oidc-token-sync.js";import{require_get_vercel_oidc_token_with_refresh}from"./get-vercel-oidc-token-with-refresh.js";import{require_verify_vercel_oidc_token}from"./verify-vercel-oidc-token.js";import{require_auth_errors}from"./auth-errors.js";import{require_token_util}from"./token-util.js";var require_dist=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{AccessTokenMissingError:()=>d.AccessTokenMissingError,RefreshAccessTokenFailedError:()=>d.RefreshAccessTokenFailedError,exchangeVercelOidcToken:()=>f.exchangeVercelOidcToken,getContext:()=>l.getContext,getVercelOidcToken:()=>s.getVercelOidcToken,getVercelOidcTokenSync:()=>c.getVercelOidcTokenSync,getVercelToken:()=>p.getVercelToken,verifyVercelOidcToken:()=>u.verifyVercelOidcToken}),t.exports=__toCommonJS(o);var s=require_get_vercel_oidc_token_with_refresh(),c=require_get_vercel_oidc_token_sync(),l=require_get_context(),u=require_verify_vercel_oidc_token(),d=require_auth_errors(),f=require_exchange_vercel_oidc_token(),p=require_token_util();0&&(t.exports={AccessTokenMissingError,RefreshAccessTokenFailedError,exchangeVercelOidcToken,getContext,getVercelOidcToken,getVercelOidcTokenSync,getVercelToken,verifyVercelOidcToken})}));export default require_dist();export{require_dist};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/oauth.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_oauth=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{processTokenResponse:()=>processTokenResponse,refreshTokenRequest:()=>refreshTokenRequest}),t.exports=__toCommonJS(o);var s=require("os");let c=`@vercel/oidc node-${process.version} ${(0,s.platform)()} (${(0,s.arch)()}) ${(0,s.hostname)()}`,l=null;async function getTokenEndpoint(){if(l)return l;let e=await fetch(`https://vercel.com/.well-known/openid-configuration`,{headers:{"user-agent":c}});if(!e.ok)throw Error(`Failed to discover OAuth endpoints`);let t=await e.json();if(!t||typeof t.token_endpoint!=`string`)throw Error(`Invalid OAuth discovery response`);let n=t.token_endpoint;return l=n,n}async function refreshTokenRequest(e){let t=await getTokenEndpoint();return await fetch(t,{method:`POST`,headers:{"Content-Type":`application/x-www-form-urlencoded`,"user-agent":c},body:new URLSearchParams({client_id:`cl_HYyOPBNtFMfHhaUn9L4QPfTZz6TP47bp`,grant_type:`refresh_token`,...e})})}async function processTokenResponse(e){let t=await e.json();if(!e.ok){let e=typeof t==`object`&&t&&`error`in t?String(t.error):`Token refresh failed`;return[Error(e)]}return typeof t!=`object`||!t?[Error(`Invalid token response`)]:typeof t.access_token==`string`?t.token_type===`Bearer`?typeof t.expires_in==`number`?[null,t]:[Error(`Missing expires_in in response`)]:[Error(`Invalid token_type in response`)]:[Error(`Missing access_token in response`)]}0&&(t.exports={processTokenResponse,refreshTokenRequest})}));export default require_oauth();export{require_oauth};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-error.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_token_error=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{VercelOidcTokenError:()=>VercelOidcTokenError}),t.exports=__toCommonJS(o);var VercelOidcTokenError=class extends Error{constructor(e,t){super(e),this.name=`VercelOidcTokenError`,this.cause=t}toString(){return this.cause?`${this.name}: ${this.message}: ${this.cause}`:`${this.name}: ${this.message}`}};0&&(t.exports={VercelOidcTokenError})}));export default require_token_error();export{require_token_error};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-io.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_token_error}from"./token-error.js";var require_token_io=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{findRootDir:()=>findRootDir,getUserDataDir:()=>getUserDataDir}),t.exports=__toCommonJS(c);var l=__toESM(require("path")),u=__toESM(require("fs")),d=__toESM(require("os")),f=require_token_error();function findRootDir(){try{let e=process.cwd();for(;e!==l.default.dirname(e);){let t=l.default.join(e,`.vercel`);if(u.default.existsSync(t))return e;e=l.default.dirname(e)}}catch{throw new f.VercelOidcTokenError(`Token refresh only supported in node server environments`)}return null}function getUserDataDir(){if(process.env.XDG_DATA_HOME)return process.env.XDG_DATA_HOME;switch(d.default.platform()){case`darwin`:return l.default.join(d.default.homedir(),`Library/Application Support`);case`linux`:return l.default.join(d.default.homedir(),`.local/share`);case`win32`:return process.env.LOCALAPPDATA?process.env.LOCALAPPDATA:null;default:return null}}0&&(t.exports={findRootDir,getUserDataDir})}));export default require_token_io();export{require_token_io};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token-util.js
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_token_error}from"./token-error.js";import{require_auth_errors}from"./auth-errors.js";import{require_dist}from"../../../../../@vercel_cli-exec@1.0.0/node_modules/@vercel/cli-exec/dist/index.js";import{require_dist as require_dist$1}from"../../../../../@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/index.js";import{require_token_io}from"./token-io.js";import{require_oauth}from"./oauth.js";var require_token_util=__commonJSMin(((e,t)=>{var n=Object.create,r=Object.defineProperty,i=Object.getOwnPropertyDescriptor,a=Object.getOwnPropertyNames,o=Object.getPrototypeOf,s=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var n in t)r(e,n,{get:t[n],enumerable:!0})},__copyProps=(e,t,n,o)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of a(t))!s.call(e,c)&&c!==n&&r(e,c,{get:()=>t[c],enumerable:!(o=i(t,c))||o.enumerable});return e},__toESM=(e,t,i)=>(i=e==null?{}:n(o(e)),__copyProps(t||!e||!e.__esModule?r(i,`default`,{value:e,enumerable:!0}):i,e)),__toCommonJS=e=>__copyProps(r({},`__esModule`,{value:!0}),e),c={};__export(c,{assertVercelOidcTokenResponse:()=>assertVercelOidcTokenResponse,findProjectInfo:()=>findProjectInfo,getTokenPayload:()=>getTokenPayload,getVercelOidcToken:()=>getVercelOidcToken,getVercelOidcTokenFromCli:()=>getVercelOidcTokenFromCli,getVercelToken:()=>getVercelToken,isExpired:()=>isExpired,loadToken:()=>loadToken,saveToken:()=>saveToken}),t.exports=__toCommonJS(c);var l=__toESM(require("path")),u=__toESM(require("fs")),d=require_dist(),f=require_dist$1(),p=require_token_error(),m=require_token_io(),h=require_oauth(),g=require_auth_errors();async function getVercelToken(e){let t=(0,f.getGlobalPathConfig)(),n=(0,f.tryReadAuthConfig)(t);if(!n||!n.token&&!n.refreshToken)throw new g.AccessTokenMissingError;if(isValidAccessToken(n,e?.expirationBufferMs))return n.token;if(!n.refreshToken)throw(0,f.writeAuthConfig)(t,{}),new g.RefreshAccessTokenFailedError(`No refresh token available`);try{let e=await(0,h.refreshTokenRequest)({refresh_token:n.refreshToken}),[r,i]=await(0,h.processTokenResponse)(e);if(r||!i)throw(0,f.writeAuthConfig)(t,{}),new g.RefreshAccessTokenFailedError(r);let a={token:i.access_token,expiresAt:Math.floor(Date.now()/1e3)+i.expires_in,refreshToken:i.refresh_token};return(0,f.writeAuthConfig)(t,a),a.token}catch(e){throw(0,f.writeAuthConfig)(t,{}),e instanceof g.AccessTokenMissingError||e instanceof g.RefreshAccessTokenFailedError?e:new g.RefreshAccessTokenFailedError(e)}}function isValidAccessToken(e,t=0){if(!e.token)return!1;if(typeof e.expiresAt!=`number`)return!0;let n=Math.floor(Date.now()/1e3),r=t/1e3;return e.expiresAt>=n+r}async function getVercelOidcTokenFromCli(e,t){let n=[`project`,`token`,e,`--format=json`];t&&n.push(`--scope`,t);try{let{stdout:e}=await(0,d.execVercelCli)(n),t;if(typeof e!=`string`)throw new p.VercelOidcTokenError("Failed to refresh OIDC token: `vercel project token` did not return stdout");try{t=JSON.parse(e)}catch{throw new p.VercelOidcTokenError("Failed to refresh OIDC token: `vercel project token` returned invalid JSON: "+e)}return assertVercelOidcTokenResponse(t),t}catch(e){if(e instanceof p.VercelOidcTokenError)throw e;let t=e instanceof Error?e.message:``,n=e instanceof d.VercelCliError?e.stderr?.trim():void 0;throw n&&!t.includes(n)&&(t=`${t}
|
|
2
|
-
${n}`.trim()),new p.VercelOidcTokenError(t?`Failed to refresh OIDC token with the Vercel CLI: ${t}`:`Failed to refresh OIDC token with the Vercel CLI`)}}async function getVercelOidcToken(e,t,n){let r=`https://api.vercel.com/v1/projects/${t}/token?source=vercel-oidc-refresh${n?`&teamId=${n}`:``}`,i=await fetch(r,{method:`POST`,headers:{Authorization:`Bearer ${e}`}});if(!i.ok)throw new p.VercelOidcTokenError(`Failed to refresh OIDC token: ${i.statusText}`);let a=await i.json();return assertVercelOidcTokenResponse(a),a}function assertVercelOidcTokenResponse(e){if(!e||typeof e!=`object`)throw TypeError(`Vercel OIDC token is malformed. Expected an object.`);if(!(`token`in e)||typeof e.token!=`string`)throw TypeError(`Vercel OIDC token is malformed. Expected a string-valued token property.`)}function findProjectInfo(){let e=(0,m.findRootDir)();if(!e)throw new p.VercelOidcTokenError("Unable to find project root directory. Have you linked your project with `vc link?`");let t=l.join(e,`.vercel`,`project.json`);if(!u.existsSync(t))throw new p.VercelOidcTokenError("project.json not found, have you linked your project with `vc link?`");let n=JSON.parse(u.readFileSync(t,`utf8`));if(typeof n.projectId!=`string`&&typeof n.orgId!=`string`)throw TypeError("Expected a string-valued projectId property. Try running `vc link` to re-link your project.");return{projectId:n.projectId,teamId:n.orgId}}function saveToken(e,t){let n=(0,m.getUserDataDir)();if(!n)throw new p.VercelOidcTokenError(`Unable to find user data directory. Please reach out to Vercel support.`);let r=l.join(n,`com.vercel.token`,`${t}.json`),i=JSON.stringify(e);u.mkdirSync(l.dirname(r),{mode:504,recursive:!0}),u.writeFileSync(r,i),u.chmodSync(r,432)}function loadToken(e){let t=(0,m.getUserDataDir)();if(!t)throw new p.VercelOidcTokenError(`Unable to find user data directory. Please reach out to Vercel support.`);let n=l.join(t,`com.vercel.token`,`${e}.json`);if(!u.existsSync(n))return null;let r=JSON.parse(u.readFileSync(n,`utf8`));return assertVercelOidcTokenResponse(r),r}function getTokenPayload(e){let t=e.split(`.`);if(t.length!==3)throw new p.VercelOidcTokenError(`Invalid token.`);let n=t[1].replace(/-/g,`+`).replace(/_/g,`/`),r=n.padEnd(n.length+(4-n.length%4)%4,`=`);return JSON.parse(Buffer.from(r,`base64`).toString(`utf8`))}function isExpired(e,t=0){return e.exp*1e3<Date.now()+t}0&&(t.exports={assertVercelOidcTokenResponse,findProjectInfo,getTokenPayload,getVercelOidcToken,getVercelOidcTokenFromCli,getVercelToken,isExpired,loadToken,saveToken})}));export default require_token_util();export{require_token_util};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/token.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_token_error}from"./token-error.js";import{require_dist}from"../../../../../@vercel_cli-config@0.2.0/node_modules/@vercel/cli-config/dist/index.js";import{require_token_util}from"./token-util.js";var require_token=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{refreshToken:()=>refreshToken}),t.exports=__toCommonJS(o);var s=require_dist(),c=require_token_error(),l=require_token_util();async function refreshToken(e){let t=e?.project,n=e?.team;if(!t&&!n){let e=(0,l.findProjectInfo)();t=e.projectId,n=e.teamId}else if(!t||!n){let e=(0,l.findProjectInfo)();t??=e.projectId,n??=e.teamId}if(!t)throw new c.VercelOidcTokenError("Failed to refresh OIDC token: No project specified. Try re-linking your project with `vc link`");let r=(0,l.loadToken)(t);if(!r||(0,l.isExpired)((0,l.getTokenPayload)(r.token),e?.expirationBufferMs)){let i=(0,s.getGlobalPathConfig)();if((0,s.getLikelyEffectiveCredStorage)(i)===`keyring`)r=await(0,l.getVercelOidcTokenFromCli)(t,n);else{let i=await(0,l.getVercelToken)({expirationBufferMs:e?.expirationBufferMs});r=await(0,l.getVercelOidcToken)(i,t,n)}if(!r)throw new c.VercelOidcTokenError(`Failed to refresh OIDC token`);(0,l.saveToken)(r,t)}process.env.VERCEL_OIDC_TOKEN=r.token}0&&(t.exports={refreshToken})}));export default require_token();export{};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";import{require_cjs}from"../../../../../jose@5.10.0/node_modules/jose/dist/node/cjs/index.js";var require_verify_vercel_oidc_token=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{verifyVercelOidcToken:()=>verifyVercelOidcToken}),t.exports=__toCommonJS(o);var s=require_cjs();let c=`https://oidc.vercel.com`,l=new URL(`https://oidc.vercel.com/.well-known/jwks`),u=[`RS256`],d=(0,s.createRemoteJWKSet)(l);async function verifyVercelOidcToken(e,t){let{algorithms:n,projectId:r=process.env.VERCEL_PROJECT_ID,environment:i=process.env.VERCEL_TARGET_ENV||process.env.VERCEL_ENV,ownerId:a,...o}=t??{};if(r===`*`&&a===void 0&&!hasAudienceVerification(o.audience))throw TypeError(`Expected ownerId or audience to be provided when projectId is '*'.`);let c=await(0,s.jwtVerify)(e,d,{...o,algorithms:n??u});return validateIssuer(c.payload.iss),validateClaim({actual:c.payload.project_id,claim:`project_id`,env:`VERCEL_PROJECT_ID`,expected:r,option:`projectId`}),validateClaim({actual:c.payload.environment,claim:`environment`,env:`VERCEL_TARGET_ENV or VERCEL_ENV`,expected:i,option:`environment`}),validateOptionalClaim({actual:c.payload.owner_id,claim:`owner_id`,expected:a}),c}function hasAudienceVerification(e){return Array.isArray(e)?e.length>0:e!==void 0}function validateIssuer(e){if(e!==c&&(typeof e!=`string`||!e.startsWith(`${c}/`)))throw TypeError(`Expected Vercel OIDC token iss claim to be "${c}" or to start with "${c}/".`)}function validateClaim({actual:e,claim:t,env:n,expected:r,option:i}){if(r!==`*`){if(r===void 0||r.length===0)throw TypeError(`Expected ${n} to be set or ${i} to be provided. Pass ${i}: '*' to allow any ${t} claim.`);if(!(Array.isArray(r)&&typeof e==`string`&&r.includes(e))&&e!==r)throw TypeError(Array.isArray(r)?`Expected Vercel OIDC token ${t} claim to be one of: ${r.map(e=>`"${e}"`).join(`, `)}.`:`Expected Vercel OIDC token ${t} claim to be "${r}".`)}}function validateOptionalClaim({actual:e,claim:t,expected:n}){if(n!==void 0&&e!==n)throw TypeError(`Expected Vercel OIDC token ${t} claim to be "${n}".`)}0&&(t.exports={verifyVercelOidcToken})}));export default require_verify_vercel_oidc_token();export{require_verify_vercel_oidc_token};
|
package/dist/src/node_modules/.pnpm/@vercel_oidc@3.8.0/node_modules/@vercel/oidc/dist/version.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{__commonJSMin}from"../../../../../../../_virtual/_rolldown/runtime.js";var require_version=__commonJSMin(((e,t)=>{var n=Object.defineProperty,r=Object.getOwnPropertyDescriptor,i=Object.getOwnPropertyNames,a=Object.prototype.hasOwnProperty,__export=(e,t)=>{for(var r in t)n(e,r,{get:t[r],enumerable:!0})},__copyProps=(e,t,o,s)=>{if(t&&typeof t==`object`||typeof t==`function`)for(let c of i(t))!a.call(e,c)&&c!==o&&n(e,c,{get:()=>t[c],enumerable:!(s=r(t,c))||s.enumerable});return e},__toCommonJS=e=>__copyProps(n({},`__esModule`,{value:!0}),e),o={};__export(o,{version:()=>s}),t.exports=__toCommonJS(o);let s=`3.8.0`;0&&(t.exports={version:s})}));export default require_version();export{require_version};
|