stitchkit 0.135.0 → 0.136.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 +117 -0
- package/README.md +25 -11
- package/dist/agent-executor/acp/v1-session-build.d.ts +51 -0
- package/dist/agent-executor/acp/v1-session-build.d.ts.map +1 -0
- package/dist/agent-executor/acp/v1-session.d.ts +1 -1
- package/dist/agent-executor/acp/v1-session.d.ts.map +1 -1
- package/dist/agent-executor/claude/classify.d.ts +1 -1
- package/dist/agent-executor/claude/classify.d.ts.map +1 -1
- package/dist/agent-executor/claude/events-wire.d.ts +13 -0
- package/dist/agent-executor/claude/events-wire.d.ts.map +1 -0
- package/dist/agent-executor/claude/events.d.ts +1 -11
- package/dist/agent-executor/claude/events.d.ts.map +1 -1
- package/dist/agent-executor/codex/protocol.d.ts +0 -143
- package/dist/agent-executor/codex/protocol.d.ts.map +1 -1
- package/dist/agent-executor/codex/request-answers.d.ts +1 -1
- package/dist/agent-executor/codex/request-answers.d.ts.map +1 -1
- package/dist/agent-executor/codex/server-requests.d.ts +150 -0
- package/dist/agent-executor/codex/server-requests.d.ts.map +1 -0
- package/dist/agent-executor/image-input.d.ts +10 -3
- package/dist/agent-executor/image-input.d.ts.map +1 -1
- package/dist/agent-executor/testing/replay-scenarios.d.ts.map +1 -1
- package/dist/agent-executor/testing/replay-transcript.d.ts.map +1 -1
- package/dist/agent-runtime/browser/browser-control-contract.d.ts +4 -0
- package/dist/agent-runtime/browser/browser-control-contract.d.ts.map +1 -1
- package/dist/agent-runtime/browser/control-schema.d.ts +4 -0
- package/dist/agent-runtime/browser/control-schema.d.ts.map +1 -1
- package/dist/agent-runtime/browser/control-view.d.ts.map +1 -1
- package/dist/agent-runtime/event-schema.d.ts +16 -3
- package/dist/agent-runtime/event-schema.d.ts.map +1 -1
- package/dist/agent-runtime/loop/deferred-tools.d.ts.map +1 -1
- package/dist/agent-runtime/loop/invocation-payload.d.ts.map +1 -1
- package/dist/agent-runtime/loop/invocation-stream.d.ts +9 -1
- package/dist/agent-runtime/loop/invocation-stream.d.ts.map +1 -1
- package/dist/agent-runtime/loop/provider-stream-parts.d.ts +6 -0
- package/dist/agent-runtime/loop/provider-stream-parts.d.ts.map +1 -1
- package/dist/agent-runtime/loop/provider-stream-segments.d.ts +1 -1
- package/dist/agent-runtime/loop/provider-stream-segments.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-acquisition.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-approval-signature.d.ts +34 -0
- package/dist/agent-runtime/loop/run-approval-signature.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-approval.d.ts +0 -28
- package/dist/agent-runtime/loop/run-approval.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-complete-port.d.ts +24 -0
- package/dist/agent-runtime/loop/run-complete-port.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-complete-stream.d.ts +7 -2
- package/dist/agent-runtime/loop/run-complete-stream.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-complete-types.d.ts +14 -1
- package/dist/agent-runtime/loop/run-complete-types.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-complete.d.ts +2 -2
- package/dist/agent-runtime/loop/run-complete.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-execution-state.d.ts +8 -0
- package/dist/agent-runtime/loop/run-execution-state.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-model-call.d.ts +44 -0
- package/dist/agent-runtime/loop/run-model-call.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-model-step.d.ts +25 -28
- package/dist/agent-runtime/loop/run-model-step.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-model-steps.d.ts +6 -0
- package/dist/agent-runtime/loop/run-model-steps.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-model-stream.d.ts +3 -1
- package/dist/agent-runtime/loop/run-model-stream.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-operation-lifecycle.d.ts +0 -2
- package/dist/agent-runtime/loop/run-operation-lifecycle.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-step-loop.d.ts +19 -0
- package/dist/agent-runtime/loop/run-step-loop.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-step-port.d.ts +175 -0
- package/dist/agent-runtime/loop/run-step-port.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-stream-parts.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-stream-step-text.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-tool-approval-flow.d.ts +2 -1
- package/dist/agent-runtime/loop/run-tool-approval-flow.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-tool-call-input.d.ts +39 -0
- package/dist/agent-runtime/loop/run-tool-call-input.d.ts.map +1 -0
- package/dist/agent-runtime/loop/run-tool-call.d.ts +2 -31
- package/dist/agent-runtime/loop/run-tool-call.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-tool-errors.d.ts +5 -0
- package/dist/agent-runtime/loop/run-tool-errors.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-tool-executor.d.ts +1 -1
- package/dist/agent-runtime/loop/run-tool-executor.d.ts.map +1 -1
- package/dist/agent-runtime/loop/run-tool-slots.d.ts +2 -1
- package/dist/agent-runtime/loop/run-tool-slots.d.ts.map +1 -1
- package/dist/agent-runtime/loop/runtime-state.d.ts.map +1 -1
- package/dist/agent-runtime/loop/runtime.d.ts +0 -5
- package/dist/agent-runtime/loop/runtime.d.ts.map +1 -1
- package/dist/agent-runtime/providers/ai-sdk-convert.d.ts +1 -5
- package/dist/agent-runtime/providers/ai-sdk-convert.d.ts.map +1 -1
- package/dist/agent-runtime/providers/ai-sdk-normalize.d.ts +11 -0
- package/dist/agent-runtime/providers/ai-sdk-normalize.d.ts.map +1 -0
- package/dist/agent-runtime/providers/ai-sdk-tools.d.ts +11 -0
- package/dist/agent-runtime/providers/ai-sdk-tools.d.ts.map +1 -0
- package/dist/agent-runtime/providers/ai-sdk.d.ts +1 -9
- package/dist/agent-runtime/providers/ai-sdk.d.ts.map +1 -1
- package/dist/agent-runtime/providers/anthropic-sse.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-admission.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-audio.d.ts +164 -0
- package/dist/agent-runtime/providers/openrouter-audio.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-catalog-cache.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-catalog-query.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-catalog.d.ts +4 -2
- package/dist/agent-runtime/providers/openrouter-catalog.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-client.d.ts +37 -0
- package/dist/agent-runtime/providers/openrouter-client.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-http.d.ts +120 -0
- package/dist/agent-runtime/providers/openrouter-http.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-media.d.ts +174 -0
- package/dist/agent-runtime/providers/openrouter-media.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-models.d.ts +2 -23
- package/dist/agent-runtime/providers/openrouter-models.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-options.d.ts +4 -0
- package/dist/agent-runtime/providers/openrouter-options.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-request.d.ts +23 -0
- package/dist/agent-runtime/providers/openrouter-request.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-response.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-retrieval.d.ts +145 -0
- package/dist/agent-runtime/providers/openrouter-retrieval.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-speech.d.ts +90 -0
- package/dist/agent-runtime/providers/openrouter-speech.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-spend.d.ts +7 -3
- package/dist/agent-runtime/providers/openrouter-spend.d.ts.map +1 -1
- package/dist/agent-runtime/providers/openrouter-stream.d.ts +29 -0
- package/dist/agent-runtime/providers/openrouter-stream.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-systemone.d.ts +137 -0
- package/dist/agent-runtime/providers/openrouter-systemone.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-url.d.ts +19 -0
- package/dist/agent-runtime/providers/openrouter-url.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter-wire.d.ts +45 -0
- package/dist/agent-runtime/providers/openrouter-wire.d.ts.map +1 -0
- package/dist/agent-runtime/providers/openrouter.d.ts +5 -4
- package/dist/agent-runtime/providers/openrouter.d.ts.map +1 -1
- package/dist/agent-runtime/providers/provider-http.d.ts +29 -3
- package/dist/agent-runtime/providers/provider-http.d.ts.map +1 -1
- package/dist/agent-runtime/providers/provider-json-schema-strip.d.ts.map +1 -1
- package/dist/agent-runtime/providers/provider-json-schema.d.ts.map +1 -1
- package/dist/agent-runtime/providers/provider-openai-chat-sse.d.ts.map +1 -1
- package/dist/agent-runtime/providers/provider-openai-chat-state.d.ts +42 -0
- package/dist/agent-runtime/providers/provider-openai-chat-state.d.ts.map +1 -0
- package/dist/agent-runtime/providers/provider-usage.d.ts +9 -0
- package/dist/agent-runtime/providers/provider-usage.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox/sandbox-bubblewrap-args.d.ts +9 -0
- package/dist/agent-runtime/sandbox/sandbox-bubblewrap-args.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox/sandbox-bubblewrap.d.ts +6 -0
- package/dist/agent-runtime/sandbox/sandbox-bubblewrap.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox/sandbox-contract.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox/sandbox-process-linux.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox/sandbox-process-spec.d.ts +5 -1
- package/dist/agent-runtime/sandbox/sandbox-process-spec.d.ts.map +1 -1
- package/dist/agent-runtime/sandbox/sandbox-process-wrapper.d.ts.map +1 -1
- package/dist/agent-runtime/stores/branch-messages.d.ts.map +1 -1
- package/dist/agent-runtime/stores/sql-rows.d.ts +10 -10
- package/dist/agent-runtime/terminal-commit.d.ts +10 -10
- package/dist/agent-runtime/testing/fault-bench.d.ts +5 -1
- package/dist/agent-runtime/testing/fault-bench.d.ts.map +1 -1
- package/dist/application/diagnostic-journal-contract.d.ts.map +1 -1
- package/dist/browser/client-executors.d.ts.map +1 -1
- package/dist/browser/client-url.d.ts.map +1 -1
- package/dist/contract/define.d.ts +3 -7
- package/dist/contract/define.d.ts.map +1 -1
- package/dist/contract/normalize.d.ts +17 -5
- package/dist/contract/normalize.d.ts.map +1 -1
- package/dist/entrypoints/agent-executor/acp.js +4 -2
- package/dist/entrypoints/agent-executor/claude-sdk.js +20 -20
- package/dist/entrypoints/agent-executor/claude.js +7 -7
- package/dist/entrypoints/agent-executor/codex.d.ts +2 -1
- package/dist/entrypoints/agent-executor/codex.d.ts.map +1 -1
- package/dist/entrypoints/agent-executor/codex.js +129 -35
- package/dist/entrypoints/agent-executor/testing/claude-sdk.js +2 -2
- package/dist/entrypoints/agent-executor/testing.js +17 -13
- package/dist/entrypoints/agent-executor.js +1 -1
- package/dist/entrypoints/agent-runtime/ai-sdk.d.ts +2 -1
- package/dist/entrypoints/agent-runtime/ai-sdk.d.ts.map +1 -1
- package/dist/entrypoints/agent-runtime/ai-sdk.js +10 -12
- package/dist/entrypoints/agent-runtime/anthropic.js +13 -10
- package/dist/entrypoints/agent-runtime/browser.js +8 -4
- package/dist/entrypoints/agent-runtime/harness.js +18 -19
- package/dist/entrypoints/agent-runtime/openai.js +5 -5
- package/dist/entrypoints/agent-runtime/openrouter.d.ts +11 -2
- package/dist/entrypoints/agent-runtime/openrouter.d.ts.map +1 -1
- package/dist/entrypoints/agent-runtime/openrouter.js +1940 -496
- package/dist/entrypoints/agent-runtime/postgres.js +2 -2
- package/dist/entrypoints/agent-runtime/realtime.js +5 -5
- package/dist/entrypoints/agent-runtime/sandbox.js +167 -139
- package/dist/entrypoints/agent-runtime/sqlite/bun.js +3 -3
- package/dist/entrypoints/agent-runtime/sqlite/node.js +3 -3
- package/dist/entrypoints/agent-runtime/testing.js +3 -3
- package/dist/entrypoints/agent-runtime.js +246 -360
- package/dist/entrypoints/application.js +2 -2
- package/dist/entrypoints/cli.js +36 -15
- package/dist/entrypoints/contract.js +12 -10
- package/dist/entrypoints/geo.js +1 -1
- package/dist/entrypoints/handler.js +5 -6
- package/dist/entrypoints/http.d.ts +2 -0
- package/dist/entrypoints/http.d.ts.map +1 -1
- package/dist/entrypoints/http.js +16 -4
- package/dist/entrypoints/index.js +26 -35
- package/dist/entrypoints/live.js +3 -3
- package/dist/entrypoints/node.js +7 -7
- package/dist/entrypoints/observability.js +9 -7
- package/dist/entrypoints/process.js +3 -3
- package/dist/entrypoints/remote.js +5 -5
- package/dist/entrypoints/server.js +29 -16
- package/dist/entrypoints/telegram/grammy.d.ts +1 -1
- package/dist/entrypoints/telegram/grammy.d.ts.map +1 -1
- package/dist/entrypoints/telegram/grammy.js +39 -5
- package/dist/entrypoints/telegram/screens.js +3 -0
- package/dist/entrypoints/telegram.d.ts +1 -1
- package/dist/entrypoints/telegram.d.ts.map +1 -1
- package/dist/entrypoints/telegram.js +19 -6
- package/dist/entrypoints/testing.js +10 -11
- package/dist/entrypoints/tools/agent.js +8 -9
- package/dist/entrypoints/tools/connections.js +27 -57
- package/dist/entrypoints/tools/contract.js +4 -4
- package/dist/entrypoints/tools/invoker.js +7 -8
- package/dist/entrypoints/tools/mcp.js +9 -10
- package/dist/entrypoints/tools/toolkit.js +11 -12
- package/dist/entrypoints/tools.js +20 -20
- package/dist/entrypoints/tracking/contract.js +1 -1
- package/dist/entrypoints/tracking/performance.js +1 -1
- package/dist/entrypoints/tracking.js +1 -1
- package/dist/{index-3czc3ykr.js → index-08a3qfr8.js} +1 -1
- package/dist/{index-grhhsrd5.js → index-1en7k3q5.js} +2 -1
- package/dist/{index-pdcbjd6a.js → index-1yky29qg.js} +6 -3
- package/dist/{index-b4c9dpzm.js → index-252den5a.js} +10 -11
- package/dist/{index-xtby8rj3.js → index-28kbdn63.js} +5 -47
- package/dist/{index-57sbckhv.js → index-36mtj8xm.js} +2 -2
- package/dist/{index-dm84tsd5.js → index-3kb8dw48.js} +1 -1
- package/dist/index-3tb82xr7.js +11 -0
- package/dist/{index-c24bj2r1.js → index-4243301z.js} +2 -2
- package/dist/{index-nr4fhfn4.js → index-4p2zx593.js} +2 -0
- package/dist/{index-q86qnzzf.js → index-54wp467c.js} +4 -4
- package/dist/{index-mcv7b2n0.js → index-63ctzjp4.js} +497 -495
- package/dist/{index-y0a4gt1s.js → index-65p8v81y.js} +3 -2
- package/dist/{index-z72vazf5.js → index-6y3eae97.js} +27 -83
- package/dist/{index-5awtbyns.js → index-9vj869rx.js} +1 -1
- package/dist/{index-5q0qpw3v.js → index-aqm7e864.js} +23 -8
- package/dist/{index-d4at0q09.js → index-b9mj31q7.js} +90 -88
- package/dist/{index-baba8ehy.js → index-bjrcbcn2.js} +2 -2
- package/dist/{index-fsw9wxk9.js → index-c9j8441q.js} +1 -103
- package/dist/{index-wdb5jhas.js → index-d1pdv8qc.js} +1 -1
- package/dist/{index-73wq9abg.js → index-df5xr2f9.js} +13 -59
- package/dist/{index-n9358ydy.js → index-dm50x3by.js} +1 -1
- package/dist/{index-zyyerdny.js → index-dmrx8xma.js} +3 -0
- package/dist/{index-78da4g74.js → index-dwq6a6sq.js} +17 -13
- package/dist/{index-9be3tf6r.js → index-e413q2cj.js} +49 -22
- package/dist/{index-g4gstmp1.js → index-ednf2cxs.js} +1 -1
- package/dist/{index-84tp547a.js → index-edpkm3k7.js} +29 -97
- package/dist/{index-gs0jw0hy.js → index-efbzm2se.js} +3 -3
- package/dist/{index-de7b0kvz.js → index-epwvp88y.js} +1 -1
- package/dist/{index-asnd4h2k.js → index-f0dzyskg.js} +27 -4
- package/dist/{index-xbb8ysmq.js → index-fatke81t.js} +2 -2
- package/dist/{index-6nzzj7qr.js → index-gq35s3bm.js} +1 -1
- package/dist/index-gvgtmt7a.js +102 -0
- package/dist/{index-m2b49tvc.js → index-h08xqfw9.js} +20 -21
- package/dist/{index-gk6dq9ay.js → index-ha1tv70k.js} +3 -26
- package/dist/{index-wsv11dhg.js → index-hberxns4.js} +1 -1
- package/dist/{index-rkphknhx.js → index-hpzhz1vm.js} +1 -1
- package/dist/{index-npfdymav.js → index-j5vzhj3d.js} +1 -1
- package/dist/{index-d3s070eh.js → index-jperyn0c.js} +1 -1
- package/dist/{index-yhwx4fwk.js → index-kzsetgh9.js} +1 -1
- package/dist/{index-x6sp5vpa.js → index-q4tr9vnf.js} +1 -1
- package/dist/{index-hce3hbdg.js → index-qj0sq69b.js} +6 -2
- package/dist/{index-v0j22shs.js → index-rg08syp1.js} +9 -6
- package/dist/{index-8vzh5wpv.js → index-rw1caff2.js} +14 -26
- package/dist/index-s8af9jqw.js +6 -0
- package/dist/{index-bgj9hbm3.js → index-sdppfbrh.js} +30 -16
- package/dist/{index-y0mwkgkf.js → index-shte29pg.js} +1086 -1055
- package/dist/{index-fec05c9k.js → index-ta0e2daw.js} +9 -7
- package/dist/{index-zfrysr1e.js → index-tb36xawm.js} +110 -75
- package/dist/{index-c0yym4a0.js → index-w7e402wx.js} +11 -105
- package/dist/{index-bvpevwt6.js → index-xnqab06h.js} +207 -202
- package/dist/index-xrbrvn15.js +147 -0
- package/dist/{index-ac3rfec5.js → index-y6wzzk2e.js} +21 -1
- package/dist/{index-3d2c45jn.js → index-yjx5jna7.js} +2 -2
- package/dist/internal/loopback-host.d.ts +8 -0
- package/dist/internal/loopback-host.d.ts.map +1 -0
- package/dist/internal/own-member.d.ts +7 -0
- package/dist/internal/own-member.d.ts.map +1 -0
- package/dist/internal/request.d.ts +17 -8
- package/dist/internal/request.d.ts.map +1 -1
- package/dist/internal/secret-shapes.d.ts +33 -4
- package/dist/internal/secret-shapes.d.ts.map +1 -1
- package/dist/json-schema/dialect.d.ts.map +1 -1
- package/dist/json-schema/keywords.d.ts +25 -6
- package/dist/json-schema/keywords.d.ts.map +1 -1
- package/dist/json-schema/string-format.d.ts.map +1 -1
- package/dist/live/events.d.ts.map +1 -1
- package/dist/live/watch-client.d.ts.map +1 -1
- package/dist/live/watch-delta.d.ts.map +1 -1
- package/dist/observability/context.d.ts +4 -3
- package/dist/observability/context.d.ts.map +1 -1
- package/dist/observability/sanitize.d.ts.map +1 -1
- package/dist/observability/secret-values.d.ts +0 -9
- package/dist/observability/secret-values.d.ts.map +1 -1
- package/dist/server/context.d.ts +3 -2
- package/dist/server/context.d.ts.map +1 -1
- package/dist/server/error-hook.d.ts +4 -3
- package/dist/server/error-hook.d.ts.map +1 -1
- package/dist/server/event-bus.d.ts.map +1 -1
- package/dist/server/file.d.ts +11 -3
- package/dist/server/file.d.ts.map +1 -1
- package/dist/server/handler-state.d.ts +2 -2
- package/dist/server/handler-state.d.ts.map +1 -1
- package/dist/server/middleware/jwt.d.ts +12 -1
- package/dist/server/middleware/jwt.d.ts.map +1 -1
- package/dist/server/middleware/trust-fence.d.ts +4 -0
- package/dist/server/middleware/trust-fence.d.ts.map +1 -1
- package/dist/server/multipart.d.ts +2 -3
- package/dist/server/multipart.d.ts.map +1 -1
- package/dist/server/raw.d.ts.map +1 -1
- package/dist/server/request-body.d.ts +12 -1
- package/dist/server/request-body.d.ts.map +1 -1
- package/dist/server/request-completion.d.ts.map +1 -1
- package/dist/server/types.d.ts +14 -9
- package/dist/server/types.d.ts.map +1 -1
- package/dist/telegram/crypto.d.ts.map +1 -1
- package/dist/telegram/init-data.d.ts +4 -4
- package/dist/telegram/init-data.d.ts.map +1 -1
- package/dist/telegram/outbound-cost.d.ts.map +1 -1
- package/dist/telegram/screens/test-chat.d.ts.map +1 -1
- package/dist/telegram/widget-api.d.ts +85 -13
- package/dist/telegram/widget-api.d.ts.map +1 -1
- package/dist/telegram/widget.d.ts +46 -2
- package/dist/telegram/widget.d.ts.map +1 -1
- package/dist/tools/cli/args-classify.d.ts +4 -74
- package/dist/tools/cli/args-classify.d.ts.map +1 -1
- package/dist/tools/cli/args-framework.d.ts +79 -0
- package/dist/tools/cli/args-framework.d.ts.map +1 -0
- package/dist/tools/cli/args-scan.d.ts.map +1 -1
- package/dist/tools/cli/args-tokens.d.ts.map +1 -1
- package/dist/tools/cli/checkpoint.d.ts +5 -0
- package/dist/tools/cli/checkpoint.d.ts.map +1 -1
- package/dist/tools/cli/stream.d.ts.map +1 -1
- package/dist/tools/connections/foreign-schema-join.d.ts.map +1 -1
- package/dist/tools/connections/openapi.d.ts.map +1 -1
- package/dist/tools/connections/runtime.d.ts.map +1 -1
- package/dist/tools/execute-handler.d.ts +24 -0
- package/dist/tools/execute-handler.d.ts.map +1 -0
- package/dist/tools/execute.d.ts.map +1 -1
- package/dist/tools/mcp/round.d.ts.map +1 -1
- package/dist/tools/schema/coerce.d.ts.map +1 -1
- package/dist/tools/schema/flatten.d.ts.map +1 -1
- package/dist/tools/schema/inline-references.d.ts.map +1 -1
- package/dist/tools/schema/nesting-limit.d.ts.map +1 -1
- package/dist/tools/schema/presentation.d.ts.map +1 -1
- package/dist/tracking/privacy.d.ts.map +1 -1
- package/llms/agent-runtime-openrouter.txt +14 -5
- package/llms/agent-runtime-sandbox.txt +50 -11
- package/llms/agent-runtime-testing.txt +1 -1
- package/llms/agent-runtime.2.txt +342 -230
- package/llms/agent-runtime.3.txt +225 -380
- package/llms/agent-runtime.4.txt +387 -158
- package/llms/agent-runtime.5.txt +157 -152
- package/llms/agent-runtime.6.txt +164 -0
- package/llms/agent-runtime.txt +307 -362
- package/llms/application.txt +3 -1
- package/llms/http.txt +1 -1
- package/llms/live.txt +3 -1
- package/llms/observability.txt +16 -9
- package/llms/server.2.txt +13 -8
- package/llms/server.4.txt +23 -11
- package/llms/server.5.txt +5 -5
- package/llms/server.txt +54 -1
- package/llms/spend.txt +18 -1
- package/llms/stitchkit.2.txt +4 -2
- package/llms/stitchkit.txt +113 -93
- package/llms/telegram-grammy.txt +3 -2
- package/llms/telegram.2.txt +3 -1
- package/llms/telegram.txt +35 -10
- package/llms/upgrading-0.128.0-0.129.0.txt +175 -0
- package/llms/{upgrading-0.128.0-0.135.0.txt → upgrading-0.130.0-0.136.0.txt} +353 -169
- package/llms/upgrading.txt +2 -1
- package/llms-full.txt +1035 -208
- package/llms.txt +14 -13
- package/package.json +6 -6
- package/dist/agent-runtime/loop/deferred-tools-internal.d.ts +0 -19
- package/dist/agent-runtime/loop/deferred-tools-internal.d.ts.map +0 -1
- package/dist/agent-runtime/loop/run-complete-retry.d.ts +0 -24
- package/dist/agent-runtime/loop/run-complete-retry.d.ts.map +0 -1
- package/dist/agent-runtime/loop/run-model-attempts.d.ts +0 -6
- package/dist/agent-runtime/loop/run-model-attempts.d.ts.map +0 -1
- package/dist/index-sznqf8fx.js +0 -20
- /package/dist/{index-fthw8dwa.js → index-4gbybjg6.js} +0 -0
|
@@ -84,7 +84,7 @@ import {
|
|
|
84
84
|
diff,
|
|
85
85
|
deltaWins,
|
|
86
86
|
watchKeyString2
|
|
87
|
-
} from "../index-
|
|
87
|
+
} from "../index-1yky29qg.js";
|
|
88
88
|
import {
|
|
89
89
|
rollbackSqliteFailure,
|
|
90
90
|
rollbackSqliteFailureAsync
|
|
@@ -98,7 +98,7 @@ import {
|
|
|
98
98
|
} from "../index-kyejf658.js";
|
|
99
99
|
import {
|
|
100
100
|
measureSize2
|
|
101
|
-
} from "../index-
|
|
101
|
+
} from "../index-28kbdn63.js";
|
|
102
102
|
import {
|
|
103
103
|
AppError2
|
|
104
104
|
} from "../index-7fjbdga8.js";
|
package/dist/entrypoints/cli.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import"../index-dsa676h8.js";
|
|
2
|
-
import"../index-
|
|
3
|
-
import"../index-
|
|
4
|
-
import"../index-
|
|
2
|
+
import"../index-ha1tv70k.js";
|
|
3
|
+
import"../index-d1pdv8qc.js";
|
|
4
|
+
import"../index-dm50x3by.js";
|
|
5
5
|
import {
|
|
6
6
|
coerceJsonArgs2
|
|
7
|
-
} from "../index-
|
|
7
|
+
} from "../index-qj0sq69b.js";
|
|
8
8
|
import {
|
|
9
9
|
CliArgumentError2,
|
|
10
10
|
DEFAULT_EXIT_CODES2,
|
|
@@ -23,10 +23,9 @@ import {
|
|
|
23
23
|
extractCliGlobalOptions2,
|
|
24
24
|
pollUntilDone2,
|
|
25
25
|
createCli2
|
|
26
|
-
} from "../index-
|
|
27
|
-
import"../index-
|
|
28
|
-
import"../index-
|
|
29
|
-
import"../index-d4at0q09.js";
|
|
26
|
+
} from "../index-63ctzjp4.js";
|
|
27
|
+
import"../index-edpkm3k7.js";
|
|
28
|
+
import"../index-b9mj31q7.js";
|
|
30
29
|
import"../index-yt1gg11x.js";
|
|
31
30
|
import"../index-werjqesf.js";
|
|
32
31
|
import"../index-0x4mnwg5.js";
|
|
@@ -63,8 +62,8 @@ import"../index-rjs94dny.js";
|
|
|
63
62
|
import"../index-xrgn784x.js";
|
|
64
63
|
import {
|
|
65
64
|
stringifyJsonSafe
|
|
66
|
-
} from "../index-
|
|
67
|
-
import"../index-
|
|
65
|
+
} from "../index-9vj869rx.js";
|
|
66
|
+
import"../index-bjrcbcn2.js";
|
|
68
67
|
import"../index-7csn6pva.js";
|
|
69
68
|
import {
|
|
70
69
|
safeJsonParse
|
|
@@ -72,6 +71,9 @@ import {
|
|
|
72
71
|
import {
|
|
73
72
|
AppError2
|
|
74
73
|
} from "../index-7fjbdga8.js";
|
|
74
|
+
import {
|
|
75
|
+
setOwnMember
|
|
76
|
+
} from "../index-3tb82xr7.js";
|
|
75
77
|
import {
|
|
76
78
|
argumentsDigest
|
|
77
79
|
} from "../index-3dq8466w.js";
|
|
@@ -137,7 +139,7 @@ function emptyCheckpoint(entries) {
|
|
|
137
139
|
entries,
|
|
138
140
|
digestOf: (line) => argumentsDigest({ command: line.command, args: line.args }),
|
|
139
141
|
record(id, digest, answer) {
|
|
140
|
-
entries
|
|
142
|
+
setOwnMember(entries, id, { digest, answer });
|
|
141
143
|
}
|
|
142
144
|
};
|
|
143
145
|
}
|
|
@@ -145,12 +147,12 @@ function readCliCheckpoint(path) {
|
|
|
145
147
|
if (!existsSync(path))
|
|
146
148
|
return emptyCheckpoint({});
|
|
147
149
|
try {
|
|
148
|
-
const parsed =
|
|
150
|
+
const parsed = JSON.parse(readFileSync(path, "utf8"));
|
|
149
151
|
const entries = {};
|
|
150
152
|
if (isRecord(parsed) && isRecord(parsed.entries)) {
|
|
151
153
|
for (const [id, value] of Object.entries(parsed.entries)) {
|
|
152
154
|
if (isRecord(value) && typeof value.digest === "string") {
|
|
153
|
-
entries
|
|
155
|
+
setOwnMember(entries, id, { digest: value.digest, answer: value.answer });
|
|
154
156
|
}
|
|
155
157
|
}
|
|
156
158
|
}
|
|
@@ -381,6 +383,12 @@ function missingMessage(name, path, config) {
|
|
|
381
383
|
}
|
|
382
384
|
// src/tools/cli/stream.ts
|
|
383
385
|
import { z } from "zod";
|
|
386
|
+
var RecordedAnswerSchema = z.object({
|
|
387
|
+
ok: z.literal(true),
|
|
388
|
+
exitCode: z.number(),
|
|
389
|
+
data: z.unknown().optional(),
|
|
390
|
+
written: z.object({ stdout: z.string().optional(), stderr: z.string().optional() }).optional()
|
|
391
|
+
});
|
|
384
392
|
var LineSchema = z.object({
|
|
385
393
|
id: z.string().min(1),
|
|
386
394
|
command: z.string().min(1),
|
|
@@ -483,6 +491,8 @@ function defineCliBatchCommand(config) {
|
|
|
483
491
|
}, {
|
|
484
492
|
before: (id, line) => {
|
|
485
493
|
const digest = checkpoint.digestOf(line);
|
|
494
|
+
if (!Object.hasOwn(checkpoint.entries, id))
|
|
495
|
+
return;
|
|
486
496
|
const recorded = checkpoint.entries[id];
|
|
487
497
|
if (!recorded)
|
|
488
498
|
return;
|
|
@@ -497,8 +507,19 @@ function defineCliBatchCommand(config) {
|
|
|
497
507
|
}
|
|
498
508
|
};
|
|
499
509
|
}
|
|
500
|
-
const replay =
|
|
501
|
-
|
|
510
|
+
const replay = RecordedAnswerSchema.safeParse(recorded.answer);
|
|
511
|
+
if (!replay.success) {
|
|
512
|
+
return {
|
|
513
|
+
id,
|
|
514
|
+
ok: false,
|
|
515
|
+
exitCode: 2,
|
|
516
|
+
error: {
|
|
517
|
+
code: "CONFLICT",
|
|
518
|
+
message: "this id is recorded as done but its recorded answer is unreadable — change the id or start a new checkpoint"
|
|
519
|
+
}
|
|
520
|
+
};
|
|
521
|
+
}
|
|
522
|
+
return { ...replay.data, id, replayed: true };
|
|
502
523
|
},
|
|
503
524
|
after: (id, line, outcome) => {
|
|
504
525
|
if (!outcome.ok)
|
|
@@ -1,21 +1,28 @@
|
|
|
1
1
|
import {
|
|
2
|
-
ContractFingerprintSchema2,
|
|
3
|
-
contractFingerprint2,
|
|
4
|
-
contractIdentityContract2,
|
|
5
2
|
defineErrors2,
|
|
6
3
|
createContractFactory2,
|
|
7
4
|
paginatedSchema2,
|
|
8
5
|
encodeCursor2,
|
|
9
6
|
decodeCursor2
|
|
10
|
-
} from "../index-
|
|
7
|
+
} from "../index-w7e402wx.js";
|
|
11
8
|
import {
|
|
12
9
|
ManagedFilePathSchema2,
|
|
13
10
|
ManagedFileRefSchema2
|
|
14
11
|
} from "../index-xqhede6x.js";
|
|
12
|
+
import {
|
|
13
|
+
ContractFingerprintSchema2,
|
|
14
|
+
contractFingerprint2,
|
|
15
|
+
contractIdentityContract2
|
|
16
|
+
} from "../index-gvgtmt7a.js";
|
|
15
17
|
import {
|
|
16
18
|
withToolView2,
|
|
17
19
|
defineContract2
|
|
18
|
-
} from "../index-
|
|
20
|
+
} from "../index-dmrx8xma.js";
|
|
21
|
+
import"../index-m38ej7e5.js";
|
|
22
|
+
import {
|
|
23
|
+
DEFAULT_CONTRACT_STREAM_FRAME_BYTES2,
|
|
24
|
+
ContractStreamFrameSchema2
|
|
25
|
+
} from "../index-yrhw10ef.js";
|
|
19
26
|
import {
|
|
20
27
|
ALL_TRANSPORTS2,
|
|
21
28
|
TOOL_TRANSPORTS2
|
|
@@ -25,11 +32,6 @@ import {
|
|
|
25
32
|
contractOperationEffects2,
|
|
26
33
|
requireContractOperationEffects2
|
|
27
34
|
} from "../index-werjqesf.js";
|
|
28
|
-
import"../index-m38ej7e5.js";
|
|
29
|
-
import {
|
|
30
|
-
DEFAULT_CONTRACT_STREAM_FRAME_BYTES2,
|
|
31
|
-
ContractStreamFrameSchema2
|
|
32
|
-
} from "../index-yrhw10ef.js";
|
|
33
35
|
import {
|
|
34
36
|
AppError2,
|
|
35
37
|
notFound2,
|
package/dist/entrypoints/geo.js
CHANGED
|
@@ -7,24 +7,23 @@ import {
|
|
|
7
7
|
} from "../index-w3s79kcb.js";
|
|
8
8
|
import"../index-7mjsb7zv.js";
|
|
9
9
|
import"../index-m38ej7e5.js";
|
|
10
|
-
import"../index-78da4g74.js";
|
|
11
10
|
import"../index-yrhw10ef.js";
|
|
12
11
|
import"../index-yt1gg11x.js";
|
|
13
12
|
import {
|
|
14
13
|
createErrorHook2
|
|
15
|
-
} from "../index-
|
|
14
|
+
} from "../index-ednf2cxs.js";
|
|
16
15
|
import {
|
|
17
16
|
isTrustProxyHandler,
|
|
18
17
|
createHandler2
|
|
19
|
-
} from "../index-
|
|
18
|
+
} from "../index-h08xqfw9.js";
|
|
20
19
|
import {
|
|
21
20
|
secretsEqual
|
|
22
21
|
} from "../index-apv5xfef.js";
|
|
23
22
|
import {
|
|
24
23
|
implement2,
|
|
25
24
|
createImplement2
|
|
26
|
-
} from "../index-
|
|
27
|
-
import"../index-
|
|
25
|
+
} from "../index-gq35s3bm.js";
|
|
26
|
+
import"../index-4gbybjg6.js";
|
|
28
27
|
import {
|
|
29
28
|
AppError2,
|
|
30
29
|
notFound2,
|
|
@@ -268,7 +267,7 @@ function handleInboundMessage(runtime, message) {
|
|
|
268
267
|
}
|
|
269
268
|
function serveBridge(port, handler, config) {
|
|
270
269
|
if (isTrustProxyHandler(handler)) {
|
|
271
|
-
throw new Error("[stitchkit] serveBridge cannot wrap a handler configured with trustProxy
|
|
270
|
+
throw new Error("[stitchkit] serveBridge cannot wrap a handler configured with trustProxy");
|
|
272
271
|
}
|
|
273
272
|
if (config.origins.length === 0) {
|
|
274
273
|
throw new TypeError("[stitchkit] serveBridge requires at least one allowed origin");
|
|
@@ -5,8 +5,10 @@ export { type BridgeClientPort, type BridgeFetch, type BridgeFetchOptions, type
|
|
|
5
5
|
export type { BridgeDropReason } from '../browser/bridge-inbound.js';
|
|
6
6
|
export { type ChunkedUploadConfig, type ChunkedUploadPart, type ChunkedUploadProgress, type ChunkedUploadStart, type ChunkSource, uploadInChunks, } from '../browser/chunked-upload.js';
|
|
7
7
|
export { type ClientConfig, type ClientContract, type ClientFetch, type ClientRegistryValue, type ContractClientConfig, contractEndpointMatchers, createClient, createClients, createScopedClients, createScopedUrlBuilders, createUrlBuilder, createUrlBuilders, type PathPrefixArgs, type RegistryScope, type ScopeClientConfigs, type ScopedClientRegistry, type ScopedUrlBuilderRegistry, type UrlBuilderConfig, } from '../browser/client.js';
|
|
8
|
+
export { type ContractIdentity, readContractIdentity } from '../browser/contract-identity.js';
|
|
8
9
|
export { type ApiEvent, type ApiEventListener, type ConfiguredHttpClient, createHttpClient, type HeaderProvider, type HttpClient, type HttpClientConfig, type RequestOptions, type UnauthorizedMatcher, } from '../browser/http.js';
|
|
9
10
|
export { BRIDGE_ORIGIN, type BridgeAbortFrame, BridgeAbortFrameSchema, type BridgeFailureCode, BridgeFailureCodeSchema, type BridgeFailureFrame, BridgeFailureFrameSchema, type BridgeFrame, BridgeFrameSchema, type BridgeHeaderEntry, BridgeHeaderEntrySchema, type BridgeHelloFrame, BridgeHelloFrameSchema, type BridgeRequestFrame, BridgeRequestFrameSchema, type BridgeResponseFrame, BridgeResponseFrameSchema, DEFAULT_BRIDGE_MAX_FRAME_BYTES, } from '../contract/bridge-envelope.js';
|
|
10
11
|
export { type BoundedBodyOptions, readBoundedBody } from '../internal/bounded-body.js';
|
|
12
|
+
export { StreamLineLimitError, StreamTruncatedLineError } from '../internal/bounded-lines.js';
|
|
11
13
|
export type { StreamByteSource } from '../internal/stream-chunks.js';
|
|
12
14
|
//# sourceMappingURL=http.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/entrypoints/http.ts"],"names":[],"mappings":"AAAA,4FAA4F;AAC5F,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,kBAAkB,EACvB,KAAK,YAAY,EACjB,iBAAiB,GAClB,MAAM,yBAAyB,CAAC;AACjC,YAAY,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAClE,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,WAAW,EAChB,cAAc,GACf,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,wBAAwB,EACxB,YAAY,EACZ,aAAa,EACb,mBAAmB,EACnB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,gBAAgB,GACtB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EACL,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,gBAAgB,EAChB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,mBAAmB,GACzB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,aAAa,EACb,KAAK,gBAAgB,EACrB,sBAAsB,EACtB,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,KAAK,kBAAkB,EACvB,wBAAwB,EACxB,KAAK,WAAW,EAChB,iBAAiB,EACjB,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,KAAK,gBAAgB,EACrB,sBAAsB,EACtB,KAAK,kBAAkB,EACvB,wBAAwB,EACxB,KAAK,mBAAmB,EACxB,yBAAyB,EACzB,8BAA8B,GAC/B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,KAAK,kBAAkB,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AACpF,YAAY,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC"}
|
|
1
|
+
{"version":3,"file":"http.d.ts","sourceRoot":"","sources":["../../src/entrypoints/http.ts"],"names":[],"mappings":"AAAA,4FAA4F;AAC5F,OAAO,EAAE,QAAQ,EAAE,MAAM,sBAAsB,CAAC;AAChD,OAAO,EAAE,kBAAkB,EAAE,MAAM,0BAA0B,CAAC;AAC9D,OAAO,EACL,KAAK,gBAAgB,EACrB,KAAK,WAAW,EAChB,KAAK,kBAAkB,EACvB,KAAK,YAAY,EACjB,iBAAiB,GAClB,MAAM,yBAAyB,CAAC;AACjC,YAAY,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC;AAClE,OAAO,EACL,KAAK,mBAAmB,EACxB,KAAK,iBAAiB,EACtB,KAAK,qBAAqB,EAC1B,KAAK,kBAAkB,EACvB,KAAK,WAAW,EAChB,cAAc,GACf,MAAM,2BAA2B,CAAC;AACnC,OAAO,EACL,KAAK,YAAY,EACjB,KAAK,cAAc,EACnB,KAAK,WAAW,EAChB,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,wBAAwB,EACxB,YAAY,EACZ,aAAa,EACb,mBAAmB,EACnB,uBAAuB,EACvB,gBAAgB,EAChB,iBAAiB,EACjB,KAAK,cAAc,EACnB,KAAK,aAAa,EAClB,KAAK,kBAAkB,EACvB,KAAK,oBAAoB,EACzB,KAAK,wBAAwB,EAC7B,KAAK,gBAAgB,GACtB,MAAM,mBAAmB,CAAC;AAC3B,OAAO,EAAE,KAAK,gBAAgB,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAC3F,OAAO,EACL,KAAK,QAAQ,EACb,KAAK,gBAAgB,EACrB,KAAK,oBAAoB,EACzB,gBAAgB,EAChB,KAAK,cAAc,EACnB,KAAK,UAAU,EACf,KAAK,gBAAgB,EACrB,KAAK,cAAc,EACnB,KAAK,mBAAmB,GACzB,MAAM,iBAAiB,CAAC;AACzB,OAAO,EACL,aAAa,EACb,KAAK,gBAAgB,EACrB,sBAAsB,EACtB,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,KAAK,kBAAkB,EACvB,wBAAwB,EACxB,KAAK,WAAW,EAChB,iBAAiB,EACjB,KAAK,iBAAiB,EACtB,uBAAuB,EACvB,KAAK,gBAAgB,EACrB,sBAAsB,EACtB,KAAK,kBAAkB,EACvB,wBAAwB,EACxB,KAAK,mBAAmB,EACxB,yBAAyB,EACzB,8BAA8B,GAC/B,MAAM,6BAA6B,CAAC;AACrC,OAAO,EAAE,KAAK,kBAAkB,EAAE,eAAe,EAAE,MAAM,0BAA0B,CAAC;AACpF,OAAO,EAAE,oBAAoB,EAAE,wBAAwB,EAAE,MAAM,2BAA2B,CAAC;AAC3F,YAAY,EAAE,gBAAgB,EAAE,MAAM,2BAA2B,CAAC"}
|
package/dist/entrypoints/http.js
CHANGED
|
@@ -22,9 +22,6 @@ import {
|
|
|
22
22
|
createUnusableReplyError,
|
|
23
23
|
createHttpClient2
|
|
24
24
|
} from "../index-cgjtj8zh.js";
|
|
25
|
-
import {
|
|
26
|
-
uploadInChunks2
|
|
27
|
-
} from "../index-ac3rfec5.js";
|
|
28
25
|
import {
|
|
29
26
|
contractEndpointMatchers2,
|
|
30
27
|
createClient2,
|
|
@@ -33,7 +30,19 @@ import {
|
|
|
33
30
|
createUrlBuilder2,
|
|
34
31
|
createUrlBuilders2,
|
|
35
32
|
createScopedUrlBuilders2
|
|
36
|
-
} from "../index-
|
|
33
|
+
} from "../index-f0dzyskg.js";
|
|
34
|
+
import"../index-gvgtmt7a.js";
|
|
35
|
+
import"../index-yt1gg11x.js";
|
|
36
|
+
import"../index-werjqesf.js";
|
|
37
|
+
import"../index-dmrx8xma.js";
|
|
38
|
+
import {
|
|
39
|
+
uploadInChunks2,
|
|
40
|
+
readContractIdentity2
|
|
41
|
+
} from "../index-y6wzzk2e.js";
|
|
42
|
+
import {
|
|
43
|
+
StreamLineLimitError2,
|
|
44
|
+
StreamTruncatedLineError2
|
|
45
|
+
} from "../index-mfe9a266.js";
|
|
37
46
|
import {
|
|
38
47
|
ApiError2
|
|
39
48
|
} from "../index-kfjkb396.js";
|
|
@@ -428,6 +437,8 @@ export {
|
|
|
428
437
|
BridgeRequestFrameSchema2 as BridgeRequestFrameSchema,
|
|
429
438
|
BridgeResponseFrameSchema2 as BridgeResponseFrameSchema,
|
|
430
439
|
DEFAULT_BRIDGE_MAX_FRAME_BYTES2 as DEFAULT_BRIDGE_MAX_FRAME_BYTES,
|
|
440
|
+
StreamLineLimitError2 as StreamLineLimitError,
|
|
441
|
+
StreamTruncatedLineError2 as StreamTruncatedLineError,
|
|
431
442
|
contractEndpointMatchers2 as contractEndpointMatchers,
|
|
432
443
|
createBridgeFetch,
|
|
433
444
|
createClient2 as createClient,
|
|
@@ -438,5 +449,6 @@ export {
|
|
|
438
449
|
createUrlBuilder2 as createUrlBuilder,
|
|
439
450
|
createUrlBuilders2 as createUrlBuilders,
|
|
440
451
|
readBoundedBody2 as readBoundedBody,
|
|
452
|
+
readContractIdentity2 as readContractIdentity,
|
|
441
453
|
uploadInChunks2 as uploadInChunks
|
|
442
454
|
};
|
|
@@ -10,16 +10,23 @@ import {
|
|
|
10
10
|
import {
|
|
11
11
|
createHttpClient2
|
|
12
12
|
} from "../index-cgjtj8zh.js";
|
|
13
|
+
import {
|
|
14
|
+
parseNDJSON2,
|
|
15
|
+
createNDJSONDecoder2,
|
|
16
|
+
parseSSE2,
|
|
17
|
+
contractEndpointMatchers2,
|
|
18
|
+
createClient2,
|
|
19
|
+
createClients2,
|
|
20
|
+
createScopedClients2,
|
|
21
|
+
createUrlBuilder2,
|
|
22
|
+
createUrlBuilders2,
|
|
23
|
+
createScopedUrlBuilders2
|
|
24
|
+
} from "../index-f0dzyskg.js";
|
|
13
25
|
import {
|
|
14
26
|
ContractFingerprintSchema2,
|
|
15
27
|
contractFingerprint2,
|
|
16
|
-
contractIdentityContract2
|
|
17
|
-
|
|
18
|
-
createContractFactory2,
|
|
19
|
-
paginatedSchema2,
|
|
20
|
-
encodeCursor2,
|
|
21
|
-
decodeCursor2
|
|
22
|
-
} from "../index-c0yym4a0.js";
|
|
28
|
+
contractIdentityContract2
|
|
29
|
+
} from "../index-gvgtmt7a.js";
|
|
23
30
|
import {
|
|
24
31
|
ALL_TRANSPORTS2,
|
|
25
32
|
TOOL_TRANSPORTS2
|
|
@@ -32,7 +39,7 @@ import {
|
|
|
32
39
|
import {
|
|
33
40
|
withToolView2,
|
|
34
41
|
defineContract2
|
|
35
|
-
} from "../index-
|
|
42
|
+
} from "../index-dmrx8xma.js";
|
|
36
43
|
import"../index-02kdtrcd.js";
|
|
37
44
|
import {
|
|
38
45
|
LiveStatePhaseSchema2,
|
|
@@ -55,6 +62,13 @@ import {
|
|
|
55
62
|
import {
|
|
56
63
|
defineRealtimeContract2
|
|
57
64
|
} from "../index-814xpr6d.js";
|
|
65
|
+
import {
|
|
66
|
+
defineErrors2,
|
|
67
|
+
createContractFactory2,
|
|
68
|
+
paginatedSchema2,
|
|
69
|
+
encodeCursor2,
|
|
70
|
+
decodeCursor2
|
|
71
|
+
} from "../index-w7e402wx.js";
|
|
58
72
|
import {
|
|
59
73
|
ManagedFilePathSchema2,
|
|
60
74
|
ManagedFileRefSchema2
|
|
@@ -71,20 +85,9 @@ import {
|
|
|
71
85
|
messageOf
|
|
72
86
|
} from "../index-r9kq5ark.js";
|
|
73
87
|
import {
|
|
74
|
-
uploadInChunks2
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
parseNDJSON2,
|
|
78
|
-
createNDJSONDecoder2,
|
|
79
|
-
parseSSE2,
|
|
80
|
-
contractEndpointMatchers2,
|
|
81
|
-
createClient2,
|
|
82
|
-
createClients2,
|
|
83
|
-
createScopedClients2,
|
|
84
|
-
createUrlBuilder2,
|
|
85
|
-
createUrlBuilders2,
|
|
86
|
-
createScopedUrlBuilders2
|
|
87
|
-
} from "../index-asnd4h2k.js";
|
|
88
|
+
uploadInChunks2,
|
|
89
|
+
readContractIdentity2
|
|
90
|
+
} from "../index-y6wzzk2e.js";
|
|
88
91
|
import {
|
|
89
92
|
StreamLineLimitError2,
|
|
90
93
|
StreamTruncatedLineError2
|
|
@@ -143,18 +146,6 @@ import {
|
|
|
143
146
|
import {
|
|
144
147
|
abortError
|
|
145
148
|
} from "../index-wz392jyz.js";
|
|
146
|
-
// src/browser/contract-identity.ts
|
|
147
|
-
async function readContractIdentity(contracts, configOrClient) {
|
|
148
|
-
const client = contractFingerprint2(contracts);
|
|
149
|
-
const api = createClient2(contractIdentityContract2, configOrClient);
|
|
150
|
-
try {
|
|
151
|
-
return { client, server: await api.read() };
|
|
152
|
-
} catch (error) {
|
|
153
|
-
if (error instanceof ApiError2 && error.status === 404)
|
|
154
|
-
return { client, server: undefined };
|
|
155
|
-
throw error;
|
|
156
|
-
}
|
|
157
|
-
}
|
|
158
149
|
// src/browser/resumable.ts
|
|
159
150
|
var DEFAULT_RETRY = { minDelayMs: 100, maxDelayMs: 30000, jitter: 0.5 };
|
|
160
151
|
async function* resumableIterator(config) {
|
|
@@ -1022,7 +1013,7 @@ export {
|
|
|
1022
1013
|
parseTraceparent2 as parseTraceparent,
|
|
1023
1014
|
rateLimited2 as rateLimited,
|
|
1024
1015
|
readBoundedBody2 as readBoundedBody,
|
|
1025
|
-
readContractIdentity,
|
|
1016
|
+
readContractIdentity2 as readContractIdentity,
|
|
1026
1017
|
repeatLimited2 as repeatLimited,
|
|
1027
1018
|
requireContractOperationEffects2 as requireContractOperationEffects,
|
|
1028
1019
|
resumableIterator,
|
package/dist/entrypoints/live.js
CHANGED
|
@@ -16,7 +16,7 @@ import {
|
|
|
16
16
|
WATCH_STATE2,
|
|
17
17
|
watchContract2,
|
|
18
18
|
watchKeyString2
|
|
19
|
-
} from "../index-
|
|
19
|
+
} from "../index-1yky29qg.js";
|
|
20
20
|
import {
|
|
21
21
|
argumentsDigest
|
|
22
22
|
} from "../index-3dq8466w.js";
|
|
@@ -66,8 +66,8 @@ function defineEvents(config, topics) {
|
|
|
66
66
|
}
|
|
67
67
|
function toRealtimeContract(declaration) {
|
|
68
68
|
const serverToClient = {};
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
const topics = declaration.topics;
|
|
70
|
+
for (const [topic, { schema }] of Object.entries(topics)) {
|
|
71
71
|
serverToClient[topic] = { args: z.tuple([schema]) };
|
|
72
72
|
}
|
|
73
73
|
return { serverToClient, clientToServer: {} };
|
package/dist/entrypoints/node.js
CHANGED
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import"../index-78da4g74.js";
|
|
2
1
|
import"../index-yrhw10ef.js";
|
|
3
2
|
import"../index-7mjsb7zv.js";
|
|
4
3
|
import"../index-m38ej7e5.js";
|
|
@@ -12,7 +11,7 @@ import {
|
|
|
12
11
|
defineRequestIngress2,
|
|
13
12
|
createSocketIOServer2,
|
|
14
13
|
createUnixClientTransport2
|
|
15
|
-
} from "../index-
|
|
14
|
+
} from "../index-ta0e2daw.js";
|
|
16
15
|
import {
|
|
17
16
|
ShutdownStateSchema2,
|
|
18
17
|
ShutdownOptionsSchema2,
|
|
@@ -26,23 +25,24 @@ import"../index-6kec3b14.js";
|
|
|
26
25
|
import"../index-673drwkn.js";
|
|
27
26
|
import"../index-jwtmw39p.js";
|
|
28
27
|
import"../index-werjqesf.js";
|
|
29
|
-
import"../index-
|
|
30
|
-
import"../index-
|
|
28
|
+
import"../index-dmrx8xma.js";
|
|
29
|
+
import"../index-w7e402wx.js";
|
|
31
30
|
import"../index-xqhede6x.js";
|
|
31
|
+
import"../index-gvgtmt7a.js";
|
|
32
32
|
import"../index-kp1j7cc8.js";
|
|
33
33
|
import {
|
|
34
34
|
bindRealtimeServer2
|
|
35
35
|
} from "../index-y68gavb5.js";
|
|
36
36
|
import {
|
|
37
37
|
createHandler2
|
|
38
|
-
} from "../index-
|
|
38
|
+
} from "../index-h08xqfw9.js";
|
|
39
39
|
import {
|
|
40
40
|
createMultipartStream2,
|
|
41
41
|
implement2,
|
|
42
42
|
createImplement2,
|
|
43
43
|
createScopedImplement2
|
|
44
|
-
} from "../index-
|
|
45
|
-
import"../index-
|
|
44
|
+
} from "../index-gq35s3bm.js";
|
|
45
|
+
import"../index-4gbybjg6.js";
|
|
46
46
|
import {
|
|
47
47
|
AppError2,
|
|
48
48
|
notFound2,
|
|
@@ -1,6 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
recordedErrorMessage
|
|
3
|
-
} from "../index-78da4g74.js";
|
|
4
1
|
import {
|
|
5
2
|
ObservabilitySinkStatusSchema2,
|
|
6
3
|
ObservabilityStatusSchema2,
|
|
@@ -19,7 +16,10 @@ import {
|
|
|
19
16
|
truncatePreview2,
|
|
20
17
|
sanitizePayload2,
|
|
21
18
|
measureSize2
|
|
22
|
-
} from "../index-
|
|
19
|
+
} from "../index-28kbdn63.js";
|
|
20
|
+
import {
|
|
21
|
+
isSecretQueryName
|
|
22
|
+
} from "../index-xrbrvn15.js";
|
|
23
23
|
import {
|
|
24
24
|
runWithRequestContext2,
|
|
25
25
|
getRequestContext2,
|
|
@@ -30,7 +30,10 @@ import {
|
|
|
30
30
|
setRequestDimensions2,
|
|
31
31
|
setRequestError2,
|
|
32
32
|
wrapInRequestContext2
|
|
33
|
-
} from "../index-
|
|
33
|
+
} from "../index-q4tr9vnf.js";
|
|
34
|
+
import {
|
|
35
|
+
recordedErrorMessage
|
|
36
|
+
} from "../index-dwq6a6sq.js";
|
|
34
37
|
import {
|
|
35
38
|
DEFAULT_REPEAT_WINDOW_MS2,
|
|
36
39
|
DEFAULT_REPEAT_MAX_KINDS2,
|
|
@@ -588,14 +591,13 @@ function createJsonLogger(options = {}) {
|
|
|
588
591
|
}
|
|
589
592
|
// src/observability/secret-values.ts
|
|
590
593
|
var SECRET_NAME = /(?:TOKEN|SECRET|KEY|PASSWORD|PASSWD|CREDENTIALS?)(?:_ID)?$/;
|
|
591
|
-
var SECRET_PARAMETER = /^(?:key|api[_-]?key|token|access[_-]?token|secret|password|passwd|sig|signature)$/i;
|
|
592
594
|
function urlSecrets(value) {
|
|
593
595
|
if (!/^[a-z][a-z0-9+.-]*:\/\//i.test(value) || !URL.canParse(value))
|
|
594
596
|
return [];
|
|
595
597
|
const url = new URL(value);
|
|
596
598
|
const secrets = url.password === "" ? [] : [url.password, decodeURIComponent(url.password)];
|
|
597
599
|
for (const [name, parameter] of url.searchParams) {
|
|
598
|
-
if (
|
|
600
|
+
if (isSecretQueryName(name) && parameter !== "")
|
|
599
601
|
secrets.push(parameter);
|
|
600
602
|
}
|
|
601
603
|
return secrets;
|
|
@@ -11,15 +11,15 @@ import"../index-5c4m8zdf.js";
|
|
|
11
11
|
import {
|
|
12
12
|
ContractStreamErrorSchema
|
|
13
13
|
} from "../index-yrhw10ef.js";
|
|
14
|
-
import {
|
|
15
|
-
normalizeError2
|
|
16
|
-
} from "../index-78da4g74.js";
|
|
17
14
|
import {
|
|
18
15
|
streamNativeCommand2
|
|
19
16
|
} from "../index-8cek82ar.js";
|
|
20
17
|
import {
|
|
21
18
|
runNativeCommand2
|
|
22
19
|
} from "../index-0sxj3y45.js";
|
|
20
|
+
import {
|
|
21
|
+
normalizeError2
|
|
22
|
+
} from "../index-dwq6a6sq.js";
|
|
23
23
|
import {
|
|
24
24
|
StreamLineLimitError2,
|
|
25
25
|
readBoundedUtf8Lines
|
|
@@ -2,15 +2,15 @@ import"../index-m38ej7e5.js";
|
|
|
2
2
|
import"../index-q46b16xz.js";
|
|
3
3
|
import"../index-yrhw10ef.js";
|
|
4
4
|
import"../index-cgjtj8zh.js";
|
|
5
|
+
import {
|
|
6
|
+
endpointHasArguments,
|
|
7
|
+
createClient2
|
|
8
|
+
} from "../index-f0dzyskg.js";
|
|
5
9
|
import"../index-yt1gg11x.js";
|
|
6
10
|
import {
|
|
7
11
|
contractMethodFields,
|
|
8
12
|
withDeclaredRefusals
|
|
9
|
-
} from "../index-
|
|
10
|
-
import {
|
|
11
|
-
endpointHasArguments,
|
|
12
|
-
createClient2
|
|
13
|
-
} from "../index-asnd4h2k.js";
|
|
13
|
+
} from "../index-4gbybjg6.js";
|
|
14
14
|
import {
|
|
15
15
|
AppError2,
|
|
16
16
|
STITCH_ERROR_STATUS2
|
|
@@ -1,10 +1,6 @@
|
|
|
1
1
|
import"../index-6kec3b14.js";
|
|
2
2
|
import"../index-673drwkn.js";
|
|
3
3
|
import"../index-jwtmw39p.js";
|
|
4
|
-
import {
|
|
5
|
-
errorCode2,
|
|
6
|
-
normalizeError2
|
|
7
|
-
} from "../index-78da4g74.js";
|
|
8
4
|
import {
|
|
9
5
|
DEFAULT_CONTRACT_STREAM_FRAME_BYTES2
|
|
10
6
|
} from "../index-yrhw10ef.js";
|
|
@@ -28,10 +24,10 @@ import {
|
|
|
28
24
|
import {
|
|
29
25
|
fingerprintOperations,
|
|
30
26
|
contractIdentityContract2
|
|
31
|
-
} from "../index-
|
|
27
|
+
} from "../index-gvgtmt7a.js";
|
|
32
28
|
import"../index-yt1gg11x.js";
|
|
33
29
|
import"../index-werjqesf.js";
|
|
34
|
-
import"../index-
|
|
30
|
+
import"../index-dmrx8xma.js";
|
|
35
31
|
import"../index-814xpr6d.js";
|
|
36
32
|
import {
|
|
37
33
|
DEFAULT_DEVICE_PRESENCE_COMMAND_TIMEOUT_MS2
|
|
@@ -53,12 +49,13 @@ import {
|
|
|
53
49
|
createSocketIOServer2,
|
|
54
50
|
socketIoLane2,
|
|
55
51
|
createUnixClientTransport2
|
|
56
|
-
} from "../index-
|
|
57
|
-
import"../index-
|
|
52
|
+
} from "../index-ta0e2daw.js";
|
|
53
|
+
import"../index-ha1tv70k.js";
|
|
58
54
|
import {
|
|
59
55
|
toJsonSchema,
|
|
60
56
|
jsonSchemaFields
|
|
61
|
-
} from "../index-
|
|
57
|
+
} from "../index-d1pdv8qc.js";
|
|
58
|
+
import"../index-w7e402wx.js";
|
|
62
59
|
import"../index-xqhede6x.js";
|
|
63
60
|
import {
|
|
64
61
|
createFileStateStore2
|
|
@@ -78,7 +75,7 @@ import {
|
|
|
78
75
|
} from "../index-y68gavb5.js";
|
|
79
76
|
import {
|
|
80
77
|
createErrorHook2
|
|
81
|
-
} from "../index-
|
|
78
|
+
} from "../index-ednf2cxs.js";
|
|
82
79
|
import {
|
|
83
80
|
contextContributionDelta,
|
|
84
81
|
prepareContextContribution,
|
|
@@ -89,7 +86,7 @@ import {
|
|
|
89
86
|
ndjsonRoute2,
|
|
90
87
|
sseRoute2,
|
|
91
88
|
createHandler2
|
|
92
|
-
} from "../index-
|
|
89
|
+
} from "../index-h08xqfw9.js";
|
|
93
90
|
import {
|
|
94
91
|
secretsEqual
|
|
95
92
|
} from "../index-apv5xfef.js";
|
|
@@ -97,7 +94,7 @@ import {
|
|
|
97
94
|
verifyJwt2,
|
|
98
95
|
signJwt2,
|
|
99
96
|
verifyPkce2
|
|
100
|
-
} from "../index-
|
|
97
|
+
} from "../index-4p2zx593.js";
|
|
101
98
|
import {
|
|
102
99
|
deriveCodeChallenge2
|
|
103
100
|
} from "../index-ap3gqe56.js";
|
|
@@ -111,8 +108,8 @@ import {
|
|
|
111
108
|
implement2,
|
|
112
109
|
createImplement2,
|
|
113
110
|
createScopedImplement2
|
|
114
|
-
} from "../index-
|
|
115
|
-
import"../index-
|
|
111
|
+
} from "../index-gq35s3bm.js";
|
|
112
|
+
import"../index-4gbybjg6.js";
|
|
116
113
|
import {
|
|
117
114
|
jsonResponse
|
|
118
115
|
} from "../index-kyejf658.js";
|
|
@@ -125,7 +122,11 @@ import {
|
|
|
125
122
|
extractIp2,
|
|
126
123
|
getClientInfo2,
|
|
127
124
|
isPublicIp2
|
|
128
|
-
} from "../index-
|
|
125
|
+
} from "../index-aqm7e864.js";
|
|
126
|
+
import {
|
|
127
|
+
errorCode2,
|
|
128
|
+
normalizeError2
|
|
129
|
+
} from "../index-dwq6a6sq.js";
|
|
129
130
|
import {
|
|
130
131
|
bytesToBase64Url
|
|
131
132
|
} from "../index-dwfv9a85.js";
|
|
@@ -1364,7 +1365,7 @@ function createEventBus(options = {}) {
|
|
|
1364
1365
|
return;
|
|
1365
1366
|
throw new Error(`[stitchkit] event bus: ${verb}("${event}") needs declared topics — pass \`topics\` from defineEvents. Its delivery deadline and undecided outcome come from the declaration, and neither has a default.`);
|
|
1366
1367
|
}
|
|
1367
|
-
const topic =
|
|
1368
|
+
const topic = Object.hasOwn(declared, event) ? declared[event] : undefined;
|
|
1368
1369
|
if (topic === undefined) {
|
|
1369
1370
|
throw new Error(`[stitchkit] event bus: "${event}" is not a declared topic. Declared: ${Object.keys(declared).join(", ") || "(none)"}.`);
|
|
1370
1371
|
}
|
|
@@ -1521,9 +1522,18 @@ function mimeForPath(path) {
|
|
|
1521
1522
|
}
|
|
1522
1523
|
|
|
1523
1524
|
// src/server/file.ts
|
|
1525
|
+
function assertDotNames(names) {
|
|
1526
|
+
for (const name of names) {
|
|
1527
|
+
if (!/^\.[^/\\]+$/.test(name) || name === "..") {
|
|
1528
|
+
throw new Error(`staticRoute: allowedDotNames entry ${JSON.stringify(name)} is not one dot-segment name (like ".well-known")`);
|
|
1529
|
+
}
|
|
1530
|
+
}
|
|
1531
|
+
return new Set(names);
|
|
1532
|
+
}
|
|
1524
1533
|
function staticRoute(prefix, dir, options = {}) {
|
|
1525
1534
|
const cleanPrefix = prefix.replace(/\/+$/, "");
|
|
1526
1535
|
const root = resolve(dir.replace(/\/+$/, ""));
|
|
1536
|
+
const allowedDotNames = assertDotNames(options.allowedDotNames ?? []);
|
|
1527
1537
|
return {
|
|
1528
1538
|
method: "GET",
|
|
1529
1539
|
path: `${cleanPrefix}/*filePath`,
|
|
@@ -1538,6 +1548,9 @@ function staticRoute(prefix, dir, options = {}) {
|
|
|
1538
1548
|
const target = resolve(root, rel);
|
|
1539
1549
|
if (!isWithinDir2(root, target))
|
|
1540
1550
|
return new Response("Forbidden", { status: 403 });
|
|
1551
|
+
const hidden = rel.split("/").some((segment) => segment.startsWith(".") && !allowedDotNames.has(segment));
|
|
1552
|
+
if (hidden)
|
|
1553
|
+
return new Response("Not found", { status: 404 });
|
|
1541
1554
|
const realTarget = await realPathWithinDir(root, target);
|
|
1542
1555
|
if (realTarget === null)
|
|
1543
1556
|
return new Response("Not found", { status: 404 });
|