openrod 0.0.0 → 0.1.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/LICENSE +201 -0
- package/NOTICE +8 -0
- package/README.md +58 -2
- package/SETUPS.md +75 -0
- package/THIRD_PARTY_NOTICES.md +15823 -0
- package/dist/assets/geist-cyrillic-ext-wght-normal-DjL33-gN.woff2 +0 -0
- package/dist/assets/geist-cyrillic-wght-normal-BEAKL7Jp.woff2 +0 -0
- package/dist/assets/geist-latin-ext-wght-normal-DC-KSUi6.woff2 +0 -0
- package/dist/assets/geist-latin-wght-normal-BgDaEnEv.woff2 +0 -0
- package/dist/assets/geist-vietnamese-wght-normal-6IgcOCM7.woff2 +0 -0
- package/dist/assets/index-CEZ0R3YS.js +522 -0
- package/dist/assets/index-DYjVZRjW.css +1 -0
- package/dist/assets/index.esm-BVqeoYDn.js +376 -0
- package/dist/assets/index.esm-CXAOoF3i.js +16 -0
- package/dist/assets/index.esm-D0s8MSqt.js +1666 -0
- package/dist/assets/pixelify-sans-cyrillic-wght-normal-BfQLqnEI.woff2 +0 -0
- package/dist/assets/pixelify-sans-latin-ext-wght-normal-CsF3XSp0.woff2 +0 -0
- package/dist/assets/pixelify-sans-latin-wght-normal-Cbhn5ptY.woff2 +0 -0
- package/dist/assets/terminal-view-6GBZ9nXN.css +32 -0
- package/dist/assets/terminal-view-CkPFNoXi.js +40 -0
- package/dist/favicon.png +0 -0
- package/dist/index.html +16 -0
- package/dist/logos/SOURCES.md +133 -0
- package/dist/logos/agents/aider.svg +1 -0
- package/dist/logos/agents/antigravity.svg +1 -0
- package/dist/logos/agents/claudecode.svg +1 -0
- package/dist/logos/agents/codex.svg +1 -0
- package/dist/logos/agents/copilot.svg +1 -0
- package/dist/logos/agents/cursor.svg +1 -0
- package/dist/logos/agents/factory.svg +1 -0
- package/dist/logos/agents/gemini.svg +1 -0
- package/dist/logos/agents/kiro.svg +1 -0
- package/dist/logos/agents/openclaw-color.svg +1 -0
- package/dist/logos/agents/opencode.svg +1 -0
- package/dist/logos/agents/pi.svg +1 -0
- package/dist/logos/anthropic.svg +1 -0
- package/dist/logos/aws-bedrock.svg +1 -0
- package/dist/logos/aws-s3.svg +1 -0
- package/dist/logos/aws.svg +1 -0
- package/dist/logos/claude-code.svg +1 -0
- package/dist/logos/codex.svg +1 -0
- package/dist/logos/copilot.svg +1 -0
- package/dist/logos/cursor.svg +1 -0
- package/dist/logos/deepinfra.svg +1 -0
- package/dist/logos/github.svg +1 -0
- package/dist/logos/google-cloud.svg +1 -0
- package/dist/logos/google-vertex-ai.svg +1 -0
- package/dist/logos/nvidia.svg +1 -0
- package/dist/logos/openai.svg +1 -0
- package/dist/logos/openrouter.svg +1 -0
- package/dist/logos/pypi.svg +1 -0
- package/dist/logos/templates/debian.svg +1 -0
- package/dist/logos/templates/nodejs.svg +1 -0
- package/dist/logos/templates/python.svg +1 -0
- package/dist/logos/templates/ubuntu.svg +1 -0
- package/dist/logos/vscode.svg +1 -0
- package/dist/openrod.png +0 -0
- package/node_modules/@bufbuild/protobuf/README.md +41 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/clone.d.ts +6 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/clone.js +66 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/boot.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/boot.js +18 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/enum.js +31 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/extension.js +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/file.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/file.js +18 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/index.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/message.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/message.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/service.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/symbols.d.ts +140 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/symbols.js +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/types.d.ts +79 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv1/types.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/boot.d.ts +63 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/boot.js +105 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/embed.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/embed.js +244 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/enum.d.ts +29 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/enum.js +58 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/extension.js +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/file.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/file.js +35 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/index.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/message.d.ts +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/message.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/restore-json-names.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/restore-json-names.js +29 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/scalar.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/scalar.js +67 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/service.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/symbols.d.ts +145 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/symbols.js +74 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/types.d.ts +85 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/codegenv2/types.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/create.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/create.js +296 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/descriptors.d.ts +634 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/descriptors.js +53 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/equals.d.ts +46 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/equals.js +209 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/extensions.d.ts +60 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/extensions.js +168 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/fields.d.ts +23 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/fields.js +45 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-binary.d.ts +48 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-binary.js +415 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-json.d.ts +73 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/from-json.js +1037 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/index.js +55 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/is-message.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/is-message.js +33 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/json-value.d.ts +16 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/json-value.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/merge.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/merge.js +70 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/package.json +4 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/proto-int64.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/proto-int64.js +131 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/error.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/error.js +36 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/guard.d.ts +20 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/guard.js +78 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/index.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/index.js +41 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/message.d.ts +49 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/message.js +157 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/names.d.ts +30 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/names.js +115 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/nested-types.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/nested-types.js +110 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/path.d.ts +107 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/path.js +376 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-check.d.ts +45 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-check.js +292 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-types.d.ts +217 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect-types.js +16 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/reflect.js +469 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/scalar.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/scalar.js +129 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/unsafe.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/reflect/unsafe.js +149 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/registry.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/registry.js +954 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-binary.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-binary.js +437 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-json.d.ts +67 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/to-json.js +625 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/from-text.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/from-text.js +684 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/index.d.ts +4 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/index.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/is-group-like.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/is-group-like.js +47 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/reader.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/reader.js +481 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/to-text.d.ts +34 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/to-text.js +358 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/writer.d.ts +76 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/txtpb/writer.js +220 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/types.d.ts +135 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/types.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/unknown-enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/unknown-enum.js +26 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/base64-encoding.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/base64-encoding.js +188 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/binary-encoding.d.ts +286 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/binary-encoding.js +726 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/index.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/index.js +37 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/size-delimited.d.ts +69 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/size-delimited.js +191 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-encoding.d.ts +53 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-encoding.js +106 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-format.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/text-format.js +199 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/varint.d.ts +70 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wire/varint.js +334 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/any.d.ts +38 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/any.js +75 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/duration.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/duration.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/any_pb.d.ts +238 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/any_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/api_pb.d.ts +537 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/api_pb.js +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/compiler/plugin_pb.d.ts +490 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/compiler/plugin_pb.js +68 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/cpp_features_pb.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/cpp_features_pb.js +60 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/descriptor_pb.d.ts +4143 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/descriptor_pb.js +892 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/duration_pb.d.ts +161 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/duration_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/empty_pb.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/empty_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/field_mask_pb.d.ts +424 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/field_mask_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/go_features_pb.d.ts +189 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/go_features_pb.js +126 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/java_features_pb.d.ts +194 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/java_features_pb.js +106 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/source_context_pb.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/source_context_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/struct_pb.d.ts +195 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/struct_pb.js +59 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/timestamp_pb.d.ts +222 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/timestamp_pb.js +27 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/type_pb.d.ts +722 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/type_pb.js +242 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/wrappers_pb.d.ts +330 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/gen/google/protobuf/wrappers_pb.js +67 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/index.js +48 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/json.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/json.js +44 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/timestamp.d.ts +21 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/timestamp.js +57 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/wrappers.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/commonjs/wkt/wrappers.js +66 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/clone.d.ts +6 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/clone.js +63 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/boot.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/boot.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/enum.js +26 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/extension.js +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/file.d.ts +1 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/file.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/index.js +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/message.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/message.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/service.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/symbols.d.ts +140 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/symbols.js +40 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/types.d.ts +79 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv1/types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/boot.d.ts +63 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/boot.js +101 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/embed.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/embed.js +239 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/enum.d.ts +29 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/enum.js +53 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/extension.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/extension.js +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/file.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/file.js +32 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/index.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/index.js +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/message.d.ts +15 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/message.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/restore-json-names.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/restore-json-names.js +26 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/scalar.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/scalar.js +63 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/service.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/service.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/symbols.d.ts +145 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/symbols.js +71 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/types.d.ts +85 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/codegenv2/types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/create.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/create.js +293 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/descriptors.d.ts +634 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/descriptors.js +50 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/equals.d.ts +46 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/equals.js +206 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/extensions.d.ts +60 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/extensions.js +159 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/fields.d.ts +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/fields.js +41 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-binary.d.ts +48 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-binary.js +409 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-json.d.ts +73 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/from-json.js +1029 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/index.js +29 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/is-message.d.ts +7 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/is-message.js +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/json-value.d.ts +16 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/json-value.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/merge.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/merge.js +67 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/package.json +4 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/proto-int64.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/proto-int64.js +128 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/error.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/error.js +31 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/guard.d.ts +20 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/guard.js +71 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/index.d.ts +8 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/index.js +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/message.d.ts +49 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/message.js +152 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/names.d.ts +30 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/names.js +109 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/nested-types.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/nested-types.js +105 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/path.d.ts +107 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/path.js +369 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-check.d.ts +45 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-check.js +284 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-types.d.ts +217 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect-types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/reflect.js +464 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/scalar.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/scalar.js +124 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/unsafe.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/reflect/unsafe.js +140 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/registry.d.ts +98 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/registry.js +948 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-binary.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-binary.js +433 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-json.d.ts +67 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/to-json.js +620 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/from-text.d.ts +35 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/from-text.js +680 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/index.d.ts +4 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/index.js +15 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/is-group-like.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/is-group-like.js +44 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/reader.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/reader.js +477 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/to-text.d.ts +34 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/to-text.js +355 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/writer.d.ts +76 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/txtpb/writer.js +214 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/types.d.ts +135 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/types.js +14 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/unknown-enum.d.ts +10 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/unknown-enum.js +23 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/base64-encoding.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/base64-encoding.js +184 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/binary-encoding.d.ts +286 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/binary-encoding.js +721 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/index.d.ts +5 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/index.js +18 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/size-delimited.d.ts +69 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/size-delimited.js +186 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-encoding.d.ts +53 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-encoding.js +101 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-format.d.ts +13 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/text-format.js +195 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/varint.d.ts +70 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wire/varint.js +325 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/any.d.ts +38 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/any.js +69 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/duration.d.ts +9 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/duration.js +35 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/any_pb.d.ts +238 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/any_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/api_pb.d.ts +537 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/api_pb.js +36 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/compiler/plugin_pb.d.ts +490 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/compiler/plugin_pb.js +65 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/cpp_features_pb.d.ts +91 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/cpp_features_pb.js +57 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/descriptor_pb.d.ts +4143 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/descriptor_pb.js +888 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/duration_pb.d.ts +161 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/duration_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/empty_pb.d.ts +39 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/empty_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/field_mask_pb.d.ts +424 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/field_mask_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/go_features_pb.d.ts +189 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/go_features_pb.js +123 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/java_features_pb.d.ts +194 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/java_features_pb.js +103 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/source_context_pb.d.ts +43 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/source_context_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/struct_pb.d.ts +195 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/struct_pb.js +56 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/timestamp_pb.d.ts +222 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/timestamp_pb.js +24 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/type_pb.d.ts +722 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/type_pb.js +239 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/wrappers_pb.d.ts +330 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/gen/google/protobuf/wrappers_pb.js +64 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/index.d.ts +19 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/index.js +32 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/json.d.ts +28 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/json.js +41 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/timestamp.d.ts +21 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/timestamp.js +50 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/wrappers.d.ts +25 -0
- package/node_modules/@bufbuild/protobuf/dist/esm/wkt/wrappers.js +61 -0
- package/node_modules/@bufbuild/protobuf/package.json +147 -0
- package/node_modules/@connectrpc/connect/README.md +62 -0
- package/node_modules/@connectrpc/connect/dist/cjs/any-client.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/any-client.js +33 -0
- package/node_modules/@connectrpc/connect/dist/cjs/call-options.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/cjs/call-options.js +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/callback-client.d.ts +31 -0
- package/node_modules/@connectrpc/connect/dist/cjs/callback-client.js +116 -0
- package/node_modules/@connectrpc/connect/dist/cjs/code.d.ts +75 -0
- package/node_modules/@connectrpc/connect/dist/cjs/code.js +92 -0
- package/node_modules/@connectrpc/connect/dist/cjs/connect-error.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/cjs/connect-error.js +141 -0
- package/node_modules/@connectrpc/connect/dist/cjs/context-values.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/cjs/context-values.js +41 -0
- package/node_modules/@connectrpc/connect/dist/cjs/cors.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/cjs/cors.js +82 -0
- package/node_modules/@connectrpc/connect/dist/cjs/http-headers.d.ts +37 -0
- package/node_modules/@connectrpc/connect/dist/cjs/http-headers.js +63 -0
- package/node_modules/@connectrpc/connect/dist/cjs/implementation.d.ts +159 -0
- package/node_modules/@connectrpc/connect/dist/cjs/implementation.js +78 -0
- package/node_modules/@connectrpc/connect/dist/cjs/index.d.ts +22 -0
- package/node_modules/@connectrpc/connect/dist/cjs/index.js +46 -0
- package/node_modules/@connectrpc/connect/dist/cjs/interceptor.d.ts +170 -0
- package/node_modules/@connectrpc/connect/dist/cjs/interceptor.js +30 -0
- package/node_modules/@connectrpc/connect/dist/cjs/package.json +1 -0
- package/node_modules/@connectrpc/connect/dist/cjs/promise-client.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/cjs/promise-client.js +135 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/async-iterable.d.ts +527 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/async-iterable.js +913 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/compression.d.ts +48 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/compression.js +75 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/content-type-matcher.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/content-type-matcher.js +43 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/create-method-url.d.ts +17 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/create-method-url.js +36 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/envelope.d.ts +90 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/envelope.js +214 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/index.d.ts +25 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/index.js +95 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/invoke-implementation.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/invoke-implementation.js +178 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/limit-io.d.ts +24 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/limit-io.js +80 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/normalize.d.ts +11 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/normalize.js +55 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-handler-factory.d.ts +18 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-handler-factory.js +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-headers.d.ts +9 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/protocol-headers.js +67 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/run-call.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/run-call.js +125 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/serialization.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/serialization.js +149 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/signals.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/signals.js +100 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/transport-options.d.ts +98 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/transport-options.js +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-fetch.d.ts +35 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-fetch.js +150 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler-client.d.ts +7 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler-client.js +88 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler.d.ts +167 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal-handler.js +130 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal.d.ts +102 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol/universal.js +78 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/code-string.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/code-string.js +52 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/content-type.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/content-type.js +71 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/end-stream.d.ts +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/end-stream.js +137 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/error-json.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/error-json.js +166 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/get-request.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/get-request.js +66 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/handler-factory.js +296 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/headers.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/headers.js +32 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/http-status.d.ts +15 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/http-status.js +90 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/index.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/index.js +81 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/parse-timeout.js +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/query-params.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/query-params.js +24 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/request-header.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/request-header.js +70 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/trailer-mux.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/trailer-mux.js +53 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/transport.js +210 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/validate-response.d.ts +30 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/validate-response.js +71 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/version.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-connect/version.js +58 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/content-type.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/content-type.js +38 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/gen/status_pb.d.ts +91 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/gen/status_pb.js +27 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/handler-factory.js +124 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/headers.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/headers.js +29 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/http-status.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/http-status.js +46 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/index.d.ts +10 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/index.js +61 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/parse-timeout.js +53 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/request-header.js +56 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/trailer-status.d.ts +28 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/trailer-status.js +118 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/transport.js +185 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-response.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-response.js +75 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-trailer.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc/validate-trailer.js +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/content-type.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/content-type.js +41 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/handler-factory.js +130 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/headers.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/headers.js +44 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/index.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/index.js +61 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/request-header.js +59 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/trailer.d.ts +27 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/trailer.js +71 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/transport.js +234 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/validate-response.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/cjs/protocol-grpc-web/validate-response.js +73 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router-transport.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router-transport.js +32 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router.d.ts +81 -0
- package/node_modules/@connectrpc/connect/dist/cjs/router.js +68 -0
- package/node_modules/@connectrpc/connect/dist/cjs/transport.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/cjs/transport.js +15 -0
- package/node_modules/@connectrpc/connect/dist/esm/any-client.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/any-client.js +30 -0
- package/node_modules/@connectrpc/connect/dist/esm/call-options.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/call-options.js +14 -0
- package/node_modules/@connectrpc/connect/dist/esm/callback-client.d.ts +31 -0
- package/node_modules/@connectrpc/connect/dist/esm/callback-client.js +113 -0
- package/node_modules/@connectrpc/connect/dist/esm/code.d.ts +75 -0
- package/node_modules/@connectrpc/connect/dist/esm/code.js +89 -0
- package/node_modules/@connectrpc/connect/dist/esm/connect-error.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/esm/connect-error.js +137 -0
- package/node_modules/@connectrpc/connect/dist/esm/context-values.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/context-values.js +37 -0
- package/node_modules/@connectrpc/connect/dist/esm/cors.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/esm/cors.js +79 -0
- package/node_modules/@connectrpc/connect/dist/esm/http-headers.d.ts +37 -0
- package/node_modules/@connectrpc/connect/dist/esm/http-headers.js +58 -0
- package/node_modules/@connectrpc/connect/dist/esm/implementation.d.ts +159 -0
- package/node_modules/@connectrpc/connect/dist/esm/implementation.js +73 -0
- package/node_modules/@connectrpc/connect/dist/esm/index.d.ts +22 -0
- package/node_modules/@connectrpc/connect/dist/esm/index.js +27 -0
- package/node_modules/@connectrpc/connect/dist/esm/interceptor.d.ts +170 -0
- package/node_modules/@connectrpc/connect/dist/esm/interceptor.js +27 -0
- package/node_modules/@connectrpc/connect/dist/esm/promise-client.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/esm/promise-client.js +128 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/async-iterable.d.ts +527 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/async-iterable.js +891 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/compression.d.ts +48 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/compression.js +71 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/content-type-matcher.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/content-type-matcher.js +40 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/create-method-url.d.ts +17 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/create-method-url.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/envelope.d.ts +90 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/envelope.js +206 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/index.d.ts +25 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/index.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/invoke-implementation.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/invoke-implementation.js +173 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/limit-io.d.ts +24 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/limit-io.js +75 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/normalize.d.ts +11 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/normalize.js +51 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-handler-factory.d.ts +18 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-handler-factory.js +14 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-headers.d.ts +9 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/protocol-headers.js +64 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/run-call.d.ts +45 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/run-call.js +121 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/serialization.d.ts +104 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/serialization.js +141 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/signals.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/signals.js +95 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/transport-options.d.ts +98 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/transport-options.js +14 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-fetch.d.ts +35 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-fetch.js +142 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler-client.d.ts +7 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler-client.js +85 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler.d.ts +167 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal-handler.js +124 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal.d.ts +102 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol/universal.js +74 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/code-string.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/code-string.js +48 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/content-type.d.ts +40 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/content-type.js +66 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/end-stream.d.ts +44 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/end-stream.js +131 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/error-json.d.ts +36 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/error-json.js +160 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/get-request.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/get-request.js +63 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/handler-factory.js +293 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/headers.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/headers.js +29 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/http-status.d.ts +15 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/http-status.js +86 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/index.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/index.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/parse-timeout.js +41 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/query-params.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/query-params.js +21 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/request-header.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/request-header.js +66 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/trailer-mux.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/trailer-mux.js +49 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/transport.js +207 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/validate-response.d.ts +30 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/validate-response.js +67 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/version.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-connect/version.js +53 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/content-type.d.ts +16 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/content-type.js +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/gen/status_pb.d.ts +91 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/gen/status_pb.js +24 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/handler-factory.js +121 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/headers.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/headers.js +26 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/http-status.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/http-status.js +43 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/index.d.ts +10 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/index.js +28 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/parse-timeout.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/parse-timeout.js +50 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/request-header.js +52 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/trailer-status.d.ts +28 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/trailer-status.js +113 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/transport.js +182 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-response.d.ts +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-response.js +71 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-trailer.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc/validate-trailer.js +41 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/content-type.d.ts +19 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/content-type.js +37 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/handler-factory.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/handler-factory.js +127 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/headers.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/headers.js +33 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/index.d.ts +8 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/index.js +26 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/request-header.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/request-header.js +55 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/trailer.d.ts +27 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/trailer.js +65 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/transport.d.ts +6 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/transport.js +231 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/validate-response.d.ts +34 -0
- package/node_modules/@connectrpc/connect/dist/esm/protocol-grpc-web/validate-response.js +69 -0
- package/node_modules/@connectrpc/connect/dist/esm/router-transport.d.ts +13 -0
- package/node_modules/@connectrpc/connect/dist/esm/router-transport.js +29 -0
- package/node_modules/@connectrpc/connect/dist/esm/router.d.ts +81 -0
- package/node_modules/@connectrpc/connect/dist/esm/router.js +65 -0
- package/node_modules/@connectrpc/connect/dist/esm/transport.d.ts +20 -0
- package/node_modules/@connectrpc/connect/dist/esm/transport.js +14 -0
- package/node_modules/@connectrpc/connect/package.json +67 -0
- package/node_modules/@connectrpc/connect-node/README.md +144 -0
- package/node_modules/@connectrpc/connect-node/buf.gen.yaml +10 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/compression.d.ts +15 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/compression.js +96 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-node-adapter.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-node-adapter.js +60 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-transport.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/connect-transport.js +25 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-transport.d.ts +95 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-transport.js +24 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-web-transport.d.ts +96 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/grpc-web-transport.js +25 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/http2-session-manager.d.ts +146 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/http2-session-manager.js +543 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/index.d.ts +14 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/index.js +34 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-error.d.ts +45 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-error.js +153 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-transport-options.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-transport-options.js +58 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-client.d.ts +54 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-client.js +347 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-handler.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-handler.js +225 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-header.d.ts +20 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/node-universal-header.js +117 -0
- package/node_modules/@connectrpc/connect-node/dist/cjs/package.json +1 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/compression.d.ts +15 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/compression.js +93 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-node-adapter.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-node-adapter.js +57 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-transport.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/connect-transport.js +22 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-transport.d.ts +95 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-transport.js +21 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-web-transport.d.ts +96 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/grpc-web-transport.js +22 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/http2-session-manager.d.ts +146 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/http2-session-manager.js +539 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/index.d.ts +14 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/index.js +21 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-error.d.ts +45 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-error.js +146 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-transport-options.d.ts +100 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-transport-options.js +55 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-client.d.ts +54 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-client.js +344 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-handler.d.ts +42 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-handler.js +221 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-header.d.ts +20 -0
- package/node_modules/@connectrpc/connect-node/dist/esm/node-universal-header.js +113 -0
- package/node_modules/@connectrpc/connect-node/package.json +44 -0
- package/node_modules/@nvidia/openshell-sdk/README.md +303 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.d.ts +1243 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.js +1321 -0
- package/node_modules/@nvidia/openshell-sdk/dist/client.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.d.ts +35 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.js +79 -0
- package/node_modules/@nvidia/openshell-sdk/dist/errors.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.d.ts +301 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.js +69 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/datamodel_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.d.ts +581 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.js +90 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/google/rpc/error_details_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.d.ts +9131 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.js +1898 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/openshell_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.d.ts +58 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.js +24 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/options_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.d.ts +1203 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.js +277 -0
- package/node_modules/@nvidia/openshell-sdk/dist/gen/sandbox_pb.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.d.ts +7 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.js +6 -0
- package/node_modules/@nvidia/openshell-sdk/dist/index.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.d.ts +14 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.js +177 -0
- package/node_modules/@nvidia/openshell-sdk/dist/oidc.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.d.ts +6 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.js +15 -0
- package/node_modules/@nvidia/openshell-sdk/dist/raw.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.d.ts +11 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.js +58 -0
- package/node_modules/@nvidia/openshell-sdk/dist/ssh-validate.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.d.ts +35 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.d.ts.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.js +97 -0
- package/node_modules/@nvidia/openshell-sdk/dist/transport.js.map +1 -0
- package/node_modules/@nvidia/openshell-sdk/package.json +58 -0
- package/package.json +93 -4
- package/server/activity-delivery.js +143 -0
- package/server/activity-store.js +168 -0
- package/server/agent-inventory.js +76 -0
- package/server/agent-resources.py +60 -0
- package/server/api.js +648 -0
- package/server/cli.js +168 -0
- package/server/cloud-connections.js +56 -0
- package/server/cloud-origin.js +11 -0
- package/server/cloud-proxy.js +122 -0
- package/server/cloud-ssh-proxy.cjs +73 -0
- package/server/cloud-ssh.js +135 -0
- package/server/cloud-transfer.js +221 -0
- package/server/compute.js +50 -0
- package/server/editor.js +114 -0
- package/server/egress.js +204 -0
- package/server/files.js +489 -0
- package/server/gateway-install.js +64 -0
- package/server/gateway.js +415 -0
- package/server/image-templates.js +393 -0
- package/server/ingress.js +185 -0
- package/server/launch-token.js +55 -0
- package/server/local-catalog.js +111 -0
- package/server/local-cloud-native.js +152 -0
- package/server/local-cloud.js +123 -0
- package/server/location-inventory.js +94 -0
- package/server/machines.js +84 -0
- package/server/openshell-cli.js +144 -0
- package/server/org.js +536 -0
- package/server/orphan-processes.js +42 -0
- package/server/paths.js +28 -0
- package/server/policy-template-store.js +92 -0
- package/server/policy.js +583 -0
- package/server/remote-gateway-state.js +123 -0
- package/server/remote-gateway.js +420 -0
- package/server/remote-hosts.js +354 -0
- package/server/remote-http.js +14 -0
- package/server/remote-image-engine.js +47 -0
- package/server/remote-runtime.js +65 -0
- package/server/remote-runtime.py +162 -0
- package/server/sandbox-identity.js +14 -0
- package/server/security.js +139 -0
- package/server/session-revocations.js +20 -0
- package/server/setup-artifact-installer.py +54 -0
- package/server/setup-artifacts.js +23 -0
- package/server/setup-auth-discovery.js +24 -0
- package/server/setup-credentials.js +54 -0
- package/server/setup-deployment.js +299 -0
- package/server/setup-discovery.js +289 -0
- package/server/setup-egress.js +133 -0
- package/server/setup-http.js +47 -0
- package/server/setup-installer.py +289 -0
- package/server/setup-json.py +8 -0
- package/server/setup-members.js +77 -0
- package/server/setup-packages.js +214 -0
- package/server/setup-preparation.js +144 -0
- package/server/setup-python.js +8 -0
- package/server/setup-remote-check.js +35 -0
- package/server/setup-transfer.js +17 -0
- package/server/setup-verifier.cjs +43 -0
- package/server/setups.js +172 -0
- package/server/ssh-hosts.js +184 -0
- package/server/ssh.js +153 -0
- package/server/start.js +71 -0
- package/server/terminal.js +173 -0
- package/server/worker-auth.js +18 -0
- package/shared/agent-access.js +103 -0
- package/shared/antigravity-network-guidance.js +9 -0
- package/shared/group-membership.js +33 -0
- package/shared/group-network.js +29 -0
- package/shared/policy-templates.js +79 -0
- package/shared/secret-fields.js +35 -0
- package/shared/setup-launch.js +25 -0
- package/shared/setup-targets.js +11 -0
- package/shared/setup-targets.json +12 -0
- package/src/lib/activity-export.js +52 -0
- package/src/lib/activity-inventory.js +45 -0
- package/src/lib/agents.js +41 -0
- package/src/lib/api.js +173 -0
- package/src/lib/cloud-machine.js +9 -0
- package/src/lib/cloud-origin.js +6 -0
- package/src/lib/cloud-transfer.js +22 -0
- package/src/lib/compute-target.js +46 -0
- package/src/lib/delete-network-policies.js +15 -0
- package/src/lib/egress-groups.js +24 -0
- package/src/lib/egress.js +28 -0
- package/src/lib/files.js +24 -0
- package/src/lib/fleet.js +100 -0
- package/src/lib/format.js +24 -0
- package/src/lib/groups.js +16 -0
- package/src/lib/image-templates.js +139 -0
- package/src/lib/import-setup.js +36 -0
- package/src/lib/local-cloud.js +118 -0
- package/src/lib/location-inventory.js +20 -0
- package/src/lib/locations.js +5 -0
- package/src/lib/placement.js +9 -0
- package/src/lib/policy-editor.js +58 -0
- package/src/lib/policy-sources.js +33 -0
- package/src/lib/quick-setup.js +110 -0
- package/src/lib/sandbox-creations.js +59 -0
- package/src/lib/sandbox-images.js +38 -0
- package/src/lib/sandbox-session.js +140 -0
- package/src/lib/sandboxes.js +78 -0
- package/src/lib/secret-inventory.js +26 -0
- package/src/lib/services.js +41 -0
- package/src/lib/setup-import-jobs.js +62 -0
- package/src/lib/setup-imports.js +4 -0
- package/src/lib/setup-network.js +39 -0
- package/src/lib/setup-template-build.js +17 -0
- package/src/lib/utils.js +6 -0
- package/vendor/OPENSHELL-LICENSE +203 -0
- package/vendor/nvidia-openshell-sdk-0.0.0.tgz +0 -0
|
@@ -0,0 +1,214 @@
|
|
|
1
|
+
import fs from 'node:fs/promises'
|
|
2
|
+
import path from 'node:path'
|
|
3
|
+
import { createHash, randomUUID } from 'node:crypto'
|
|
4
|
+
import { gateway, workspaceName, workspaceScope, contextSelection, runWithContext, sandboxView } from './gateway.js'
|
|
5
|
+
import { scopedStateDirectory } from './paths.js'
|
|
6
|
+
import { listPolicies, blockedByPolicy } from './egress.js'
|
|
7
|
+
import { hostMatches } from '../src/lib/egress.js'
|
|
8
|
+
import { planSandbox, readOrg, blockedBy } from './org.js'
|
|
9
|
+
const fail = (message, status = 400) => Object.assign(new Error(message), { status })
|
|
10
|
+
const unavailable = message => Object.assign(fail(message, 503), { preparationUnavailable: true })
|
|
11
|
+
|
|
12
|
+
const artifactDirectory = () => path.join(scopedStateDirectory(), 'setup-artifacts')
|
|
13
|
+
// Official multi-platform Node 22 Bookworm image. Update the digest deliberately
|
|
14
|
+
// so a floating tag cannot change the runtime behind a persistent cache entry.
|
|
15
|
+
const BUILDER_IMAGE = 'node:22-bookworm-slim@sha256:43ac6c60b8f89723f746e8a92ce91abd5017e627ce1ddfe4238355d3a30b772c'
|
|
16
|
+
const PACKAGE = /^(?:@[a-z0-9][a-z0-9._-]*\/)?[a-z0-9][a-z0-9._-]*(?:@[a-zA-Z0-9.*^~+_-]+)?$/
|
|
17
|
+
export function packageLaunch(command, args = []) {
|
|
18
|
+
if (!['npx', 'npm'].includes(path.basename(command || ''))) return null
|
|
19
|
+
if (!Array.isArray(args) || args.some((v) => typeof v !== 'string')) return null
|
|
20
|
+
const words = [...args]
|
|
21
|
+
if (path.basename(command) === 'npm') { if (!['exec', 'x'].includes(words.shift())) return null }
|
|
22
|
+
while (['-y', '--yes', '--'].includes(words[0])) words.shift()
|
|
23
|
+
const spec = words.shift()
|
|
24
|
+
if (!PACKAGE.test(spec || '') || words.length > 32 || words.some((v) => v.length > 512 || /[\x00-\x1f]/.test(v) || /token|password|secret|api.?key|authorization|cookie|\/Users\/|\/Applications\/|^~\//i.test(v))) return null
|
|
25
|
+
const split = spec.lastIndexOf('@')
|
|
26
|
+
const name = split > 0 ? spec.slice(0, split) : spec
|
|
27
|
+
return { ecosystem: 'npm', name, requested: split > 0 ? spec.slice(split + 1) : 'latest', args: words, registry: 'registry.npmjs.org' }
|
|
28
|
+
}
|
|
29
|
+
export { packageRuntimeRequirements } from '../shared/setup-launch.js'
|
|
30
|
+
export const packageLocation = (artifact) => `/sandbox/.openshell/packages/${artifact.digest}`
|
|
31
|
+
|
|
32
|
+
// Only official registry metadata is fetched by this process. Package code runs
|
|
33
|
+
// exclusively inside a disposable OpenShell sandbox without user credentials.
|
|
34
|
+
export async function resolvePackage(plan, fetcher = fetch, signal) {
|
|
35
|
+
if (!PACKAGE.test(plan.name) || !/^[a-zA-Z0-9.*^~+_-]+$/.test(plan.requested)) throw fail('Unsupported package specifier.')
|
|
36
|
+
let response, text
|
|
37
|
+
try {
|
|
38
|
+
const deadline = AbortSignal.timeout(20000)
|
|
39
|
+
response = await fetcher(`https://registry.npmjs.org/${encodeURIComponent(plan.name)}/${encodeURIComponent(plan.requested)}`, { redirect: 'error', signal: signal ? AbortSignal.any([signal, deadline]) : deadline })
|
|
40
|
+
text = await response.text()
|
|
41
|
+
} catch {
|
|
42
|
+
signal?.throwIfAborted()
|
|
43
|
+
throw unavailable('The console cannot reach the npm registry to resolve package metadata. Check registry connectivity before retrying.')
|
|
44
|
+
}
|
|
45
|
+
if (response.status === 429 || response.status >= 500) throw unavailable('The npm registry is temporarily unavailable or rate limiting requests. Retry preparation later.')
|
|
46
|
+
if (!response.ok) throw fail('Package version could not be resolved. Choose an exact version or a published tag.')
|
|
47
|
+
if (text.length > 2_000_000) throw fail('Registry metadata is too large.')
|
|
48
|
+
const value = JSON.parse(text)
|
|
49
|
+
if (value.name !== plan.name || !/^\d+\.\d+\.\d+[a-zA-Z0-9.+-]*$/.test(value.version) || !/^sha512-[A-Za-z0-9+/]{86}==$/.test(value.dist?.integrity || '')) throw fail('Package metadata lacks a verifiable version or integrity hash.')
|
|
50
|
+
const bins = typeof value.bin === 'string' ? { [plan.name.split('/').pop()]: value.bin } : value.bin || {}
|
|
51
|
+
const preferred = plan.name.split('/').pop()
|
|
52
|
+
const bin = bins[preferred] ? preferred : Object.keys(bins).length === 1 ? Object.keys(bins)[0] : null
|
|
53
|
+
if (!bin || !/^[a-zA-Z0-9._-]+$/.test(bin)) throw fail('Package exposes multiple or no executables. A supported launcher adapter is required.')
|
|
54
|
+
return { ...plan, version: value.version, integrity: value.dist.integrity, bin }
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
export async function waitReady(client, name, signal, { workspace = workspaceName(), attempts = 90, wait = ms => new Promise(resolve => setTimeout(resolve, ms)) } = {}) {
|
|
58
|
+
const scope = workspaceScope(workspace)
|
|
59
|
+
let sandbox
|
|
60
|
+
for (let i = 0; i < attempts; i++) {
|
|
61
|
+
signal?.throwIfAborted()
|
|
62
|
+
sandbox = sandboxView((await client.raw.getSandbox({ name, workspaceScope: scope })).sandbox)
|
|
63
|
+
if (sandbox.phase === 'ready') return sandbox
|
|
64
|
+
if (['error', 'deleting', 'stopped', 'completed'].includes(sandbox.phase)) break
|
|
65
|
+
await wait(1500)
|
|
66
|
+
}
|
|
67
|
+
signal?.throwIfAborted()
|
|
68
|
+
const config = await client.raw.getSandboxConfig({ name, workspaceScope: scope }).catch(() => null)
|
|
69
|
+
const reason = config?.configurationAdmitted
|
|
70
|
+
? 'The gateway admitted its policy, but the VM did not start. Check the gateway image registry and VM startup logs.'
|
|
71
|
+
: config?.configurationError || sandbox?.problem || 'Check gateway and image registry availability.'
|
|
72
|
+
throw Object.assign(fail(`Preparation sandbox could not start. ${reason}`, 503), { preparationUnavailable: true })
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export async function checkPreparationRegistry(client, name, signal, { workspace = workspaceName() } = {}) {
|
|
76
|
+
const script = "fetch('https://registry.npmjs.org/', {signal:AbortSignal.timeout(10000)}).then(r=>{if(!r.ok)process.exit(1)}).catch(()=>process.exit(1))"
|
|
77
|
+
let result
|
|
78
|
+
try {
|
|
79
|
+
result = await client.sandbox.exec(name, ['/usr/local/bin/node', '-e', script], { workspace, noLoginShell: true, timeoutSecs: 15, signal })
|
|
80
|
+
} catch {
|
|
81
|
+
signal?.throwIfAborted()
|
|
82
|
+
throw unavailable('The preparation sandbox registry check could not finish. Check gateway availability before retrying.')
|
|
83
|
+
}
|
|
84
|
+
if (result.exitCode !== 0) throw unavailable('The preparation sandbox started, but cannot reach registry.npmjs.org over HTTPS. Check gateway network connectivity before retrying.')
|
|
85
|
+
}
|
|
86
|
+
|
|
87
|
+
const INSTALL = `const fs=require('fs'),cp=require('child_process'),path=require('path');
|
|
88
|
+
const p=JSON.parse(fs.readFileSync(0,'utf8')); const root='/sandbox/package';fs.mkdirSync(root,{recursive:true});
|
|
89
|
+
fs.writeFileSync(root+'/package.json',JSON.stringify({private:true,dependencies:{[p.name]:p.version}}));
|
|
90
|
+
const options={cwd:root,env:{PATH:'/usr/local/bin:/usr/bin:/bin',HOME:'/sandbox',NODE_EXTRA_CA_CERTS:process.env.NODE_EXTRA_CA_CERTS||'',npm_config_cache:'/sandbox/cache',npm_config_registry:'https://registry.npmjs.org/',npm_config_fetch_retries:'1',npm_config_fetch_retry_mintimeout:'1000',npm_config_fetch_timeout:'30000',npm_config_update_notifier:'false'},encoding:'utf8',timeout:120000,killSignal:'SIGKILL',maxBuffer:2000000};
|
|
91
|
+
for(const args of [['install','--package-lock-only','--ignore-scripts','--no-audit','--no-fund'],['ci','--ignore-scripts','--no-audit','--no-fund']]){
|
|
92
|
+
if(args[0]==='ci') { const lock=JSON.parse(fs.readFileSync(root+'/package-lock.json')); for(const [k,v] of Object.entries(lock.packages||{})){if(!k)continue;if(v.link||!v.integrity||!v.resolved||new URL(v.resolved).hostname!=='registry.npmjs.org'||new URL(v.resolved).protocol!=='https:')throw Error('dependency source is not approved');} }
|
|
93
|
+
const r=cp.spawnSync('/usr/local/bin/npm',args,options); if(r.status!==0){const code=(r.stderr||'').match(/npm error code ([A-Z0-9_]+)/)?.[1]||r.error?.code||'UNKNOWN';console.log(JSON.stringify({error:'Package installation failed',code}));process.exit(1);}
|
|
94
|
+
}
|
|
95
|
+
const pkg=JSON.parse(fs.readFileSync(root+'/node_modules/'+p.name+'/package.json'));if(pkg.version!==p.version)throw Error('Version mismatch');
|
|
96
|
+
const lock=JSON.parse(fs.readFileSync(root+'/package-lock.json'));if(lock.packages['node_modules/'+p.name].integrity!==p.integrity)throw Error('Integrity mismatch');
|
|
97
|
+
const bin=fs.realpathSync(root+'/node_modules/.bin/'+p.bin);if(!bin.startsWith(root+'/node_modules/'))throw Error('Executable escapes the bundle');
|
|
98
|
+
let size=0;function walk(d){for(const n of fs.readdirSync(d)){const f=path.join(d,n),s=fs.lstatSync(f);if(s.isSymbolicLink()){const dest=fs.realpathSync(f);if(!dest.startsWith(root+'/'))throw Error('Link escapes bundle');}else if(s.isDirectory())walk(f);else if(s.isFile()){size+=s.size;if(size>200*1024*1024)throw Error('Package exceeds 200 MB');}else throw Error('Unsupported file');}}walk(root);
|
|
99
|
+
console.log(JSON.stringify({bin:bin.slice(root.length+1),bytes:size,node:process.versions.node,arch:process.arch,platform:process.platform,libc:'glibc',lockDigest:require('crypto').createHash('sha256').update(fs.readFileSync(root+'/package-lock.json')).digest('hex')}));`
|
|
100
|
+
|
|
101
|
+
// npm already retries each download once. Re-running the entire installation
|
|
102
|
+
// multiplies an outage across every selected MCP and discards useful diagnostics.
|
|
103
|
+
export async function installPackage(client, name, pinned, signal, { workspace = workspaceName() } = {}) {
|
|
104
|
+
const deadline = AbortSignal.timeout(250000)
|
|
105
|
+
const bounded = signal ? AbortSignal.any([signal, deadline]) : deadline
|
|
106
|
+
let result
|
|
107
|
+
try {
|
|
108
|
+
result = await client.sandbox.exec(name, ['/usr/local/bin/node', '-e', INSTALL], {
|
|
109
|
+
workspace, noLoginShell: true, stdin: Buffer.from(JSON.stringify(pinned)), timeoutSecs: 250, signal: bounded,
|
|
110
|
+
})
|
|
111
|
+
} catch (error) {
|
|
112
|
+
signal?.throwIfAborted()
|
|
113
|
+
if (deadline.aborted) throw unavailable('Package preparation exceeded its time limit. Check gateway and registry availability before retrying.')
|
|
114
|
+
throw unavailable('The gateway interrupted package preparation. Check gateway availability before retrying.')
|
|
115
|
+
}
|
|
116
|
+
let metadata
|
|
117
|
+
try { metadata = JSON.parse(result.stdout.toString()) } catch {}
|
|
118
|
+
if (result.exitCode !== 0) {
|
|
119
|
+
const code = /^[A-Z0-9_]+$/.test(metadata?.code || '') ? metadata.code : 'UNKNOWN'
|
|
120
|
+
if (['ECONNRESET', 'ETIMEDOUT', 'ECONNREFUSED', 'ENETUNREACH', 'EHOSTUNREACH', 'EAI_AGAIN', 'ENOTFOUND', 'E429', 'E500', 'E502', 'E503', 'E504'].includes(code) || [124, 137, 143].includes(result.exitCode)) {
|
|
121
|
+
throw unavailable(`Package preparation lost registry access or exceeded its time limit (${code}). Check gateway and registry availability before retrying.`)
|
|
122
|
+
}
|
|
123
|
+
throw fail(`Package preparation failed (${code}). Registry access or dependency requirements need review.`)
|
|
124
|
+
}
|
|
125
|
+
if (!metadata || typeof metadata !== 'object' || Array.isArray(metadata)) throw fail('Package preparation returned an invalid result.')
|
|
126
|
+
return metadata
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
// The gateway may move to a different architecture, including behind the same
|
|
130
|
+
// endpoint. Probe this builder before reusing anything; npm and MCP checks are
|
|
131
|
+
// skipped only for an identical pinned image and actual runtime.
|
|
132
|
+
const cacheIndex = (pinned, runtime, dir) => path.join(dir, 'index', createHash('sha256').update(JSON.stringify({ v: 2, name: pinned.name, version: pinned.version, integrity: pinned.integrity, args: pinned.args, image: BUILDER_IMAGE, runtime })).digest('hex') + '.json')
|
|
133
|
+
async function builderRuntime(client, name, signal, workspace) {
|
|
134
|
+
const script = "console.log(JSON.stringify({node:process.versions.node,arch:process.arch,platform:process.platform,libc:process.report.getReport().header.glibcVersionRuntime?'glibc':null}))"
|
|
135
|
+
const result = await client.sandbox.exec(name, ['/usr/local/bin/node', '-e', script], { workspace, noLoginShell: true, timeoutSecs: 10, signal })
|
|
136
|
+
let runtime
|
|
137
|
+
try { runtime = JSON.parse(result.stdout.toString()) } catch {}
|
|
138
|
+
if (result.exitCode !== 0 || !/^22\.\d+\.\d+$/.test(runtime?.node || '') || !/^[a-z0-9_]+$/.test(runtime?.arch || '') || runtime?.platform !== 'linux' || runtime?.libc !== 'glibc') throw fail('Could not establish the preparation builder runtime. Retry preparation.', 409)
|
|
139
|
+
return { node: runtime.node, arch: runtime.arch, platform: runtime.platform, libc: runtime.libc }
|
|
140
|
+
}
|
|
141
|
+
async function cachedArtifact(index, pinned, runtime, dir) {
|
|
142
|
+
try {
|
|
143
|
+
const artifact = JSON.parse(await fs.readFile(index, 'utf8'))
|
|
144
|
+
if (!/^[a-f0-9]{64}$/.test(artifact?.digest || '') || typeof artifact.bin !== 'string' || artifact.name !== pinned.name || artifact.version !== pinned.version || artifact.integrity !== pinned.integrity || artifact.verification?.status !== 'connected' || Object.entries(runtime).some(([key, value]) => artifact[key] !== value)) throw fail('Invalid prepared package index.')
|
|
145
|
+
await artifactFile(artifact, dir)
|
|
146
|
+
return { ...artifact, requested: pinned.requested }
|
|
147
|
+
} catch { await fs.rm(index, { force: true }).catch(() => {}); return null }
|
|
148
|
+
}
|
|
149
|
+
async function saveCached(index, artifact) {
|
|
150
|
+
const tmp = index + '.' + randomUUID() + '.tmp'
|
|
151
|
+
try { await fs.mkdir(path.dirname(index), { recursive: true, mode: 0o700 }); await fs.writeFile(tmp, JSON.stringify(artifact), { mode: 0o600, flag: 'wx' }); await fs.rename(tmp, index) } catch { await fs.rm(tmp, { force: true }).catch(() => {}) }
|
|
152
|
+
}
|
|
153
|
+
|
|
154
|
+
export function buildPackage(plan, options = {}) {
|
|
155
|
+
return runWithContext(contextSelection(), () => buildInContext(plan, options))
|
|
156
|
+
}
|
|
157
|
+
|
|
158
|
+
async function buildInContext(plan, { signal, progress = async () => {}, dir = artifactDirectory(), connect = gateway, fetcher = fetch, settle = 12000 } = {}) {
|
|
159
|
+
const org = await readOrg()
|
|
160
|
+
if (blockedBy(org, ['registry.npmjs.org']) || blockedByPolicy(await listPolicies(), {name:'',group:null}, ['registry.npmjs.org'], hostMatches)) throw fail('Organization policy blocks the npm registry.', 403)
|
|
161
|
+
await progress('Looking up the package on npm')
|
|
162
|
+
const pinned = await resolvePackage(plan, fetcher, signal)
|
|
163
|
+
const { client, workspace, workspaceScope } = await connect()
|
|
164
|
+
const name = 'sp-' + randomUUID().slice(0, 12)
|
|
165
|
+
const base = await planSandbox({ name, systemBaseline: true })
|
|
166
|
+
base.policy.networkPolicies = {}
|
|
167
|
+
base.policy.networkPolicies.setup_registry = { name:'setup_registry', binaries:[{path:'/usr/local/bin/node'}],endpoints:[{host:'registry.npmjs.org',port:443,protocol:'rest',access:1,enforcement:1,allowEncodedSlash:true}] }
|
|
168
|
+
let created = false, temporary
|
|
169
|
+
try {
|
|
170
|
+
await progress('Starting a temporary sandbox')
|
|
171
|
+
await client.sandbox.create({ name, workspace, image:BUILDER_IMAGE, command:['/bin/sleep','infinity'],providers:[],policy:base.policy,labels:{'openshell.console/setup-builder':'true'} });created=true
|
|
172
|
+
await waitReady(client,name,signal,{workspace})
|
|
173
|
+
const effective=await client.raw.getSandboxConfig({name,workspaceScope})
|
|
174
|
+
if(effective.policySource===2)throw fail('Gateway global policy overrides isolated preparation. Ask the administrator for a dedicated preparation gateway.',403)
|
|
175
|
+
await progress('Checking the package runtime')
|
|
176
|
+
const runtime = await builderRuntime(client, name, signal, workspace)
|
|
177
|
+
const index = cacheIndex(pinned, runtime, dir), cached = await cachedArtifact(index, pinned, runtime, dir)
|
|
178
|
+
signal?.throwIfAborted()
|
|
179
|
+
if (cached) { await progress('Using the package prepared earlier'); signal?.throwIfAborted(); return cached }
|
|
180
|
+
// The supervisor's first provider-environment poll replaces synthetic DNS
|
|
181
|
+
// mappings. Start npm after that initial refresh so its DNS cache is fresh.
|
|
182
|
+
await progress('Waiting for the sandbox network to be ready')
|
|
183
|
+
await new Promise((resolve,reject)=>{const done=()=>{signal?.removeEventListener('abort',stop);resolve()};const timer=setTimeout(done,settle);const stop=()=>{clearTimeout(timer);reject(signal.reason)};if(signal?.aborted)stop();else signal?.addEventListener('abort',stop,{once:true})})
|
|
184
|
+
await progress('Checking access to the npm registry')
|
|
185
|
+
await checkPreparationRegistry(client, name, signal, { workspace })
|
|
186
|
+
await progress(`Downloading ${pinned.name}@${pinned.version} (install scripts off)`)
|
|
187
|
+
const metadata = await installPackage(client, name, pinned, signal, { workspace })
|
|
188
|
+
await progress('Saving the package')
|
|
189
|
+
await fs.mkdir(dir,{recursive:true,mode:0o700})
|
|
190
|
+
temporary=path.join(dir,randomUUID()+'.tmp')
|
|
191
|
+
const handle=await fs.open(temporary,'wx',0o600);const digest=createHash('sha256');let bytes=0,exit=null
|
|
192
|
+
try{for await(const event of client.sandbox.execStream(name,['tar','-czf','-','-C','/sandbox/package','.'],{workspace,noLoginShell:true,timeoutSecs:120,signal})){
|
|
193
|
+
if(event.stream==='stdout'){bytes+=event.data.length;if(bytes>100*1024*1024)throw fail('Compressed package exceeds 100 MB.');digest.update(event.data);await handle.write(event.data)}
|
|
194
|
+
if(event.type==='exit')exit=event.exitCode
|
|
195
|
+
}}finally{await handle.close()}
|
|
196
|
+
if(exit!==0)throw fail('Could not export the prepared package.')
|
|
197
|
+
const id=digest.digest('hex');await fs.rename(temporary,path.join(dir,id+'.tar.gz'));temporary=null
|
|
198
|
+
await progress('Checking that the MCP starts')
|
|
199
|
+
const verifier=await fs.readFile(path.join(import.meta.dirname,'setup-verifier.cjs'),'utf8')
|
|
200
|
+
const check=await client.sandbox.exec(name,['/usr/local/bin/node','-e',verifier],{workspace,noLoginShell:true,stdin:Buffer.from(JSON.stringify({config:{command:'/usr/local/bin/node',args:['/sandbox/package/'+metadata.bin,...pinned.args]}})),timeoutSecs:35,signal})
|
|
201
|
+
let verification={status:'unverified',reason:'Initialization check did not finish.'}
|
|
202
|
+
try{verification=JSON.parse(check.stdout.toString())}catch{}
|
|
203
|
+
const artifact={ ...pinned,...metadata,digest:id,compressedBytes:bytes,verification,preparedAt:new Date().toISOString() }
|
|
204
|
+
if(verification?.status==='connected')await saveCached(index,artifact)
|
|
205
|
+
return artifact
|
|
206
|
+
}finally{if(temporary)await fs.rm(temporary,{force:true});if(created)await client.sandbox.delete(name,{workspace}).catch(()=>{})}
|
|
207
|
+
}
|
|
208
|
+
|
|
209
|
+
export async function artifactFile(artifact, dir = artifactDirectory()) {
|
|
210
|
+
if(!/^[a-f0-9]{64}$/.test(artifact?.digest||''))throw fail('Invalid prepared artifact.')
|
|
211
|
+
const file=path.join(dir,artifact.digest+'.tar.gz');const data=await fs.readFile(file)
|
|
212
|
+
if(createHash('sha256').update(data).digest('hex')!==artifact.digest)throw fail('Prepared artifact integrity check failed.',409)
|
|
213
|
+
return {file,data}
|
|
214
|
+
}
|
|
@@ -0,0 +1,144 @@
|
|
|
1
|
+
import fs from 'node:fs/promises'
|
|
2
|
+
import path from 'node:path'
|
|
3
|
+
import { randomUUID } from 'node:crypto'
|
|
4
|
+
import { buildPackage, packageLocation, packageRuntimeRequirements } from './setup-packages.js'
|
|
5
|
+
import { discoverSignIn } from './setup-auth-discovery.js'
|
|
6
|
+
import { checkRemote } from './setup-remote-check.js'
|
|
7
|
+
import { connectCredentials } from './setup-credentials.js'
|
|
8
|
+
import { canPrepareAtLaunch, isPackagePending } from '../shared/setup-launch.js'
|
|
9
|
+
import { fail, publicItem, hash } from './setup-discovery.js'
|
|
10
|
+
import { readOrg, blockedBy } from './org.js'
|
|
11
|
+
import { listPolicies, blockedByPolicy } from './egress.js'
|
|
12
|
+
import { hostMatches } from '../src/lib/egress.js'
|
|
13
|
+
import { contextSelection, runWithContext } from './gateway.js'
|
|
14
|
+
import { scopedStateDirectory } from './paths.js'
|
|
15
|
+
|
|
16
|
+
const states=globalThis[Symbol.for('openshell.setup.preparation-contexts.v1')]??=new Map()
|
|
17
|
+
function preparationState() {
|
|
18
|
+
const dir=path.join(scopedStateDirectory(),'setup-preparations')
|
|
19
|
+
let state=states.get(dir)
|
|
20
|
+
if(!state){state={jobs:new Map(),controllers:new Map()};states.set(dir,state)}
|
|
21
|
+
return state
|
|
22
|
+
}
|
|
23
|
+
const valid=(id)=>{if(!/^[a-f0-9-]{36}$/.test(id))throw fail('Unknown preparation.',404);return path.join(scopedStateDirectory(),'setup-preparations',id+'.json')}
|
|
24
|
+
const publicJob=({preparedItems,...job})=>job
|
|
25
|
+
// Prepared items can hold up to 64 MB of skill files and live only in memory; a restarted job is re-reviewed.
|
|
26
|
+
const persist=async(job)=>{const p=valid(job.id),tmp=p+'.'+randomUUID()+'.tmp';await fs.mkdir(path.dirname(p),{recursive:true,mode:0o700});await fs.writeFile(tmp,JSON.stringify(publicJob(job)),{mode:0o600});await fs.rename(tmp,p)}
|
|
27
|
+
export async function preparationStatus(id){
|
|
28
|
+
const state=preparationState()
|
|
29
|
+
if(state.jobs.has(id))return publicJob(state.jobs.get(id))
|
|
30
|
+
let job;try{job=JSON.parse(await fs.readFile(valid(id),'utf8'))}catch(e){if(e.code==='ENOENT')throw fail('Unknown preparation.',404);throw e}
|
|
31
|
+
if((job.status==='complete'&&!job.setup)||job.status==='cancelled'){job.status='interrupted';job.message='The console restarted. Re-scan or prepare the saved Setup again; package artifacts and gateway credentials were retained.';delete job.review}
|
|
32
|
+
if(job.status==='running'){delete job.current;return {...publicJob(job),status:'interrupted',message:'The console restarted. Review the selection again; completed package artifacts were retained.'}}
|
|
33
|
+
return publicJob(job)
|
|
34
|
+
}
|
|
35
|
+
export async function cancelPreparation(id){const controller=preparationState().controllers.get(id);if(controller)controller.abort();return {cancelled:!!controller}}
|
|
36
|
+
export function runtimeRequirements(hosts){
|
|
37
|
+
if(!Array.isArray(hosts)||hosts.length>20)throw fail('Add up to 20 exact runtime hosts.')
|
|
38
|
+
return [...new Set(hosts.map(h=>String(h).trim()).filter(Boolean))].map(host=>{
|
|
39
|
+
if(!/^(?=.{1,253}$)[a-z0-9](?:[a-z0-9.-]*[a-z0-9])?\.[a-z]{2,63}$/i.test(host)||host.includes('..')||host.includes('*')||host.endsWith('.local'))throw fail('Runtime hosts must be exact public DNS names. Private services require a connection adapter.')
|
|
40
|
+
return {phase:'runtime',host:host.toLowerCase(),port:443,reason:'You chose this as where the MCP sends its credentials.'}
|
|
41
|
+
})
|
|
42
|
+
}
|
|
43
|
+
export function clearPreparationIssues(item) {
|
|
44
|
+
const previous = new Set(item.preparationIssues || [])
|
|
45
|
+
return { ...item, issues: item.issues.filter(issue => !previous.has(issue)), preparationIssues: [] }
|
|
46
|
+
}
|
|
47
|
+
export const CONNECT_FAILED='Couldn’t connect to this MCP from a sandbox. Check that its URL is right and the server is up, then try the import again.'
|
|
48
|
+
// Only an explicit agent OAuth configuration can skip the sandbox check.
|
|
49
|
+
// Host-wide metadata also exists for public and token-authenticated endpoints.
|
|
50
|
+
export async function checkConnection(item,signal,step=async()=>{},{discover=discoverSignIn,check=checkRemote}={}){
|
|
51
|
+
const agentSignIn=item.auth?.mode==='agent-session'&&!item.credentialRef
|
|
52
|
+
if(agentSignIn){
|
|
53
|
+
await step('Looking up sign-in details')
|
|
54
|
+
item={...await discover(item),verification:{status:'needs-sign-in',reason:'This MCP uses account sign-in. Sign in from the agent inside the sandbox.',checkedAt:new Date().toISOString()}}
|
|
55
|
+
}else{
|
|
56
|
+
await step('Checking the connection in a temporary sandbox')
|
|
57
|
+
item={...item,verification:await check(item,signal)}
|
|
58
|
+
if(item.verification.status==='needs-sign-in'&&!item.credentialRef){await step('Looking up sign-in details');item=await discover(item)}
|
|
59
|
+
// A working dedicated credential must continue through deployment checks.
|
|
60
|
+
if(item.credentialRef&&item.verification.status==='connected')delete item.auth
|
|
61
|
+
}
|
|
62
|
+
item.issues=item.issues.filter(i=>!i.startsWith('Account sign-in')&&!i.startsWith('Connection check')&&i!==CONNECT_FAILED)
|
|
63
|
+
if(item.verification.status!=='connected'&&(item.verification.status!=='needs-sign-in'||item.credentialRef)){
|
|
64
|
+
item.issues.push(CONNECT_FAILED);item.preparationIssues=[...(item.preparationIssues||[]).filter(i=>i!==CONNECT_FAILED),CONNECT_FAILED]
|
|
65
|
+
}
|
|
66
|
+
return item
|
|
67
|
+
}
|
|
68
|
+
export async function prepareLaunch(store, id, input) {
|
|
69
|
+
const source = await store.get(id)
|
|
70
|
+
if (input.revision !== source.revision) throw fail('Setup changed. Review the selection again.',409)
|
|
71
|
+
if (!source.items.some(canPrepareAtLaunch)) return {status:'complete', setup:{...source,items:source.items.map(publicItem)}}
|
|
72
|
+
const cachedId=hash('quick-setup:'+source.id+':'+source.revision).slice(0,24)
|
|
73
|
+
try { const cached=await store.get(cachedId);return {status:'complete',setup:{...cached,items:cached.items.map(publicItem)}} }
|
|
74
|
+
catch(e){if(e.status!==404)throw e}
|
|
75
|
+
const review=store.stage(source.items)
|
|
76
|
+
return prepareImport(store,{token:review.token,approved:true},{source,packagesOnly:true})
|
|
77
|
+
}
|
|
78
|
+
export async function prepareImport(store,input,{source,packagesOnly=false}={}){
|
|
79
|
+
return runWithContext(contextSelection(),async()=>{
|
|
80
|
+
const state=preparationState()
|
|
81
|
+
if(input.approved!==true)throw fail('Review and approve preparation and requested access first.')
|
|
82
|
+
const preview=store.preview(input.token)
|
|
83
|
+
if([...state.controllers.values()].length>=2)throw fail('Two imports are already preparing. Wait or cancel one.',429)
|
|
84
|
+
const choices=input.items||{}
|
|
85
|
+
const org=await readOrg(),scoped=await listPolicies()
|
|
86
|
+
const items=preview.items.map(original=>{
|
|
87
|
+
if(packagesOnly&&!canPrepareAtLaunch(original))return original
|
|
88
|
+
const item=clearPreparationIssues(original)
|
|
89
|
+
const choice=choices[item.id]
|
|
90
|
+
const credentialsProvided=Boolean(choice?.useSourceSecrets||choice?.provider||Object.values(choice?.secrets||{}).some(Boolean))
|
|
91
|
+
// Rows that cannot become usable in this import need no runtime preflight.
|
|
92
|
+
// Keep package downloads and supplied credentials eligible for policy checks.
|
|
93
|
+
if(item.disabled||item.issues.some(issue=>!isPackagePending(issue)&&!(issue.startsWith('Connect credentials')&&credentialsProvided)))return {...item,preparationBlocked:true}
|
|
94
|
+
const extra=[...packageRuntimeRequirements(item.package),...runtimeRequirements(choices[item.id]?.hosts||[])]
|
|
95
|
+
const requirements=[...item.requirements,...extra.filter(r=>!item.requirements.some(o=>o.host===r.host&&o.phase===r.phase))]
|
|
96
|
+
const blocked=requirements.find(r=>blockedBy(org,[r.host])||blockedByPolicy(scoped,{name:'',group:null},[r.host],hostMatches))
|
|
97
|
+
const preparationIssues=blocked?[`Your organization blocks ${blocked.host}, so this MCP can’t be used in sandboxes.`]:[]
|
|
98
|
+
return {...item,requirements,preparationIssues,issues:[...item.issues,...preparationIssues],preparationBlocked:!!blocked}
|
|
99
|
+
})
|
|
100
|
+
const id=randomUUID(),controller=new AbortController()
|
|
101
|
+
const job={id,status:'running',createdAt:new Date().toISOString(),message:'Preparing selected tools',items:items.map(publicItem)}
|
|
102
|
+
state.jobs.set(id,job);state.controllers.set(id,controller);await persist(job)
|
|
103
|
+
const context=contextSelection()
|
|
104
|
+
void runWithContext(context,async()=>{
|
|
105
|
+
const prepared=[]
|
|
106
|
+
let startupFailure=null
|
|
107
|
+
for(const original of items){
|
|
108
|
+
if(controller.signal.aborted)break
|
|
109
|
+
let item=structuredClone(original)
|
|
110
|
+
const step=async(message)=>{job.current={id:item.id,name:item.name,message};job.message=`${item.name}: ${message}`;await persist(job)}
|
|
111
|
+
try{
|
|
112
|
+
if(!item.preparationBlocked&&!item.disabled&&(!packagesOnly||canPrepareAtLaunch(item))){
|
|
113
|
+
if(item.package&&!item.artifact){
|
|
114
|
+
const artifact=await buildPackage(item.package,{signal:controller.signal,progress:step})
|
|
115
|
+
item={...item,artifact,config:{command:'node',args:[`${packageLocation(artifact)}/${artifact.bin}`,...artifact.args],...(item.environment?{env:item.environment}:{})},issues:item.issues.filter(i=>!isPackagePending(i))}
|
|
116
|
+
}
|
|
117
|
+
if(item.credentialFields?.length&&(choices[item.id]?.useSourceSecrets||choices[item.id]?.provider||Object.values(choices[item.id]?.secrets||{}).some(Boolean))){
|
|
118
|
+
await step('Connecting credentials')
|
|
119
|
+
item=await connectCredentials(item,choices[item.id],preview.credentials?.[item.id])
|
|
120
|
+
}
|
|
121
|
+
// Known incompatible rows remain inactive; an irrelevant check must not block compatible imports.
|
|
122
|
+
if(!packagesOnly&&item.config?.url&&!item.credentialFields?.length&&!item.issues.length)item=await checkConnection(item,controller.signal,step)
|
|
123
|
+
}
|
|
124
|
+
}catch(e){if(e.preparationUnavailable)startupFailure=e.message;const message=e.status?e.message:'Preparation failed. Retry this item; no imported code ran on your computer.';item.preparationIssues=[message];item.issues=[...item.issues.filter(i=>!isPackagePending(i)),message]}
|
|
125
|
+
item.state=item.disabled?'disabled':item.issues.length?'needs-attention':item.auth?.mode==='agent-session'?'sign-in-in-sandbox':'prepared'
|
|
126
|
+
delete job.current
|
|
127
|
+
prepared.push(item);job.preparedItems=[...prepared,...items.slice(prepared.length)];job.items=job.preparedItems.map(publicItem);await persist(job)
|
|
128
|
+
if(startupFailure)break
|
|
129
|
+
}
|
|
130
|
+
delete job.current
|
|
131
|
+
if(controller.signal.aborted){job.status='cancelled';job.message='Preparation cancelled. Completed items are retained for review; destination sandboxes were not modified.';job.review=store.stage(job.preparedItems||items,preview.credentials)}
|
|
132
|
+
else if(startupFailure){job.status='failed';job.message=startupFailure+' Remaining tools were not attempted. Restore connectivity and retry.';job.review=store.stage(job.preparedItems||items,preview.credentials)}
|
|
133
|
+
else if(packagesOnly){
|
|
134
|
+
const failed=prepared.find(item=>source.items.some(old=>old.id===item.id&&canPrepareAtLaunch(old))&&(!item.artifact||item.issues.length))
|
|
135
|
+
if(failed){job.status='failed';job.message=`${failed.name}: ${failed.issues.join(' ') || 'Package preparation failed.'}`}
|
|
136
|
+
else{job.setup=await store.buildSnapshot(source,prepared);job.status='complete';job.message='MCP packages prepared. Baking the sandbox image…'}
|
|
137
|
+
}
|
|
138
|
+
else{job.status='complete';job.message='Review the prepared items. Items needing attention remain inactive.';job.review=store.stage(prepared,preview.credentials)}
|
|
139
|
+
await persist(job)
|
|
140
|
+
// A finished job keeps only its public view; the staged review or snapshot holds the prepared items.
|
|
141
|
+
}).catch((e)=>runWithContext(context,async()=>{job.status='failed';job.message=e?.status?e.message:'Preparation failed. Retry the import.';delete job.current;try{await persist(job)}catch{}})).finally(()=>{state.controllers.delete(id);delete job.preparedItems})
|
|
142
|
+
return publicJob(job)
|
|
143
|
+
})
|
|
144
|
+
}
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import fs from 'node:fs'
|
|
2
|
+
import { SETUP_AGENTS } from '../shared/setup-targets.js'
|
|
3
|
+
|
|
4
|
+
// Embed the trusted catalog: scripts also run via python -c in the sandbox,
|
|
5
|
+
// where the console's source files are not present.
|
|
6
|
+
export function setupPython(filename) {
|
|
7
|
+
return `SETUP_TARGET_CATALOG = ${JSON.stringify(JSON.stringify(SETUP_AGENTS))}\n` + fs.readFileSync(new URL('./setup-json.py', import.meta.url), 'utf8') + '\n' + fs.readFileSync(new URL(filename, import.meta.url), 'utf8')
|
|
8
|
+
}
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
import fs from 'node:fs/promises'
|
|
2
|
+
import { randomUUID } from 'node:crypto'
|
|
3
|
+
import { gateway, contextSelection, runWithContext } from './gateway.js'
|
|
4
|
+
import { planSandbox, readOrg, blockedBy } from './org.js'
|
|
5
|
+
import { listPolicies, blockedByPolicy } from './egress.js'
|
|
6
|
+
import { hostMatches } from '../src/lib/egress.js'
|
|
7
|
+
import { waitReady } from './setup-packages.js'
|
|
8
|
+
import { fail } from './setup-discovery.js'
|
|
9
|
+
const verifier = await fs.readFile(new URL('./setup-verifier.cjs', import.meta.url), 'utf8')
|
|
10
|
+
export function checkRemote(item, signal) {
|
|
11
|
+
return runWithContext(contextSelection(), () => checkInContext(item, signal))
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
async function checkInContext(item, signal) {
|
|
15
|
+
const url = new URL(item.config.url)
|
|
16
|
+
const org = await readOrg(), policies = await listPolicies()
|
|
17
|
+
if (blockedBy(org, [url.hostname]) || blockedByPolicy(policies, {name:'',group:null}, [url.hostname], hostMatches)) throw fail('Organization policy blocks this MCP.',403)
|
|
18
|
+
const { client, workspace, workspaceScope } = await gateway(), name = 'sc-' + randomUUID().slice(0,12)
|
|
19
|
+
if (item.credentialRef) {
|
|
20
|
+
const provider = (await client.raw.getProvider({name:item.credentialRef.provider,workspaceScope})).provider
|
|
21
|
+
const profile = (await client.raw.getProviderProfile({id:provider.type,workspaceScope})).profile
|
|
22
|
+
if (!profile || profile.endpoints.length) throw fail('Reconnect a dedicated MCP credential; the profile changed.')
|
|
23
|
+
}
|
|
24
|
+
const base = await planSandbox({name,systemBaseline:true})
|
|
25
|
+
base.policy.networkPolicies = { setup_check: {name:'setup_check',binaries:[{path:'/usr/local/bin/node'}],endpoints:[{host:url.hostname,port:Number(url.port||443),path:url.pathname,protocol:'rest',enforcement:1,access:2,...(item.credentialRef?{credentialBinding:{provider:item.credentialRef.provider}}:{})}]} }
|
|
26
|
+
let created = false
|
|
27
|
+
try {
|
|
28
|
+
await client.sandbox.create({name,workspace,image:'node:22-bookworm-slim',command:['/bin/sleep','infinity'],providers:item.credentialRef?[item.credentialRef.provider]:[],policy:base.policy,labels:{'openshell.console/setup-check':'true'}});created=true
|
|
29
|
+
await waitReady(client,name,signal,{workspace})
|
|
30
|
+
const effective = await client.raw.getSandboxConfig({name,workspaceScope})
|
|
31
|
+
if (effective.policySource === 2) throw fail('Global gateway policy prevents an isolated connection check.',403)
|
|
32
|
+
const result = await client.sandbox.exec(name,['node','-e',verifier],{workspace,noLoginShell:true,stdin:Buffer.from(JSON.stringify({config:item.config})),timeoutSecs:35,signal})
|
|
33
|
+
try { return JSON.parse(result.stdout.toString()) } catch { return {status:'unverified',reason:'Connection check could not complete.'} }
|
|
34
|
+
} finally { if(created) await client.sandbox.delete(name,{workspace}).catch(()=>{}) }
|
|
35
|
+
}
|
|
@@ -0,0 +1,17 @@
|
|
|
1
|
+
import { randomUUID } from 'node:crypto'
|
|
2
|
+
import { fail } from './setup-discovery.js'
|
|
3
|
+
// ExecSandbox messages are limited to 1 MB. Stage bounded chunks rather than
|
|
4
|
+
// sending package archives or large skill snapshots in a single RPC.
|
|
5
|
+
export async function withSandboxInput(client, sandbox, data, use) {
|
|
6
|
+
const file = '/tmp/openshell-setup-' + randomUUID()
|
|
7
|
+
try {
|
|
8
|
+
for (let offset = 0; offset < data.length; offset += 512 * 1024) {
|
|
9
|
+
const script = `import os,sys,stat\np=sys.argv[1];offset=int(sys.argv[2]);fd=os.open(p,os.O_WRONLY|os.O_NOFOLLOW|(os.O_CREAT|os.O_EXCL if offset==0 else os.O_APPEND),0o600)\nwith os.fdopen(fd,'ab') as f:\n s=os.fstat(f.fileno())\n if not stat.S_ISREG(s.st_mode) or s.st_size!=offset: raise ValueError('Invalid staged input')\n f.write(sys.stdin.buffer.read())`
|
|
10
|
+
const result = await client.sandbox.exec(sandbox.name, ['python3', '-c', script, file, String(offset)], { workspace: sandbox.workspace, noLoginShell: true, stdin: data.subarray(offset, offset + 512 * 1024), timeoutSecs: 30 })
|
|
11
|
+
if (result.exitCode !== 0) throw fail('Could not stage Setup files. Check Python and writable temporary storage.', 409)
|
|
12
|
+
}
|
|
13
|
+
return await use(file)
|
|
14
|
+
} finally {
|
|
15
|
+
await client.sandbox.exec(sandbox.name, ['python3', '-c', 'import os,sys;os.unlink(sys.argv[1])', file], { workspace: sandbox.workspace, noLoginShell: true, timeoutSecs: 10 }).catch(() => {})
|
|
16
|
+
}
|
|
17
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
// Runs inside the sandbox. Never calls tools/call, prompts/get or resources/read.
|
|
2
|
+
const fs=require('fs'),cp=require('child_process'),readline=require('readline');
|
|
3
|
+
const input=JSON.parse(fs.readFileSync(0,'utf8'));
|
|
4
|
+
let child,session,version='2025-03-26',next=1;
|
|
5
|
+
const pending=new Map();
|
|
6
|
+
const config=input.config;
|
|
7
|
+
let credentialMissing=false;
|
|
8
|
+
for(const area of ['env','headers'])for(const [key,value] of Object.entries(config[area]||{})){config[area][key]=value.replace(/openshell:resolve:env:([A-Za-z0-9_]+)/g,(_,alias)=>{const handle=process.env[alias];if(!handle?.startsWith('openshell:resolve:env:')){credentialMissing=true;return ''}return handle})}
|
|
9
|
+
const output=(v)=>process.stdout.write(JSON.stringify(v)+'\n');
|
|
10
|
+
const timeout=setTimeout(()=>{finish({status:'unverified',reason:'MCP did not respond within 25 seconds.'})},25000);
|
|
11
|
+
let finished=false;
|
|
12
|
+
function finish(result){if(finished)return;finished=true;clearTimeout(timeout);if(child){try{process.kill(-child.pid,'SIGKILL')}catch{child.kill('SIGKILL')}}output(result);process.exit(0)}
|
|
13
|
+
async function remote(message){
|
|
14
|
+
const headers={'content-type':'application/json',accept:'application/json, text/event-stream',...config.headers};
|
|
15
|
+
if(session)headers['Mcp-Session-Id']=session;
|
|
16
|
+
if(message.method!=='initialize')headers['MCP-Protocol-Version']=version;
|
|
17
|
+
const response=await fetch(config.url,{method:'POST',headers,body:JSON.stringify(message),redirect:'error',signal:AbortSignal.timeout(15000)});
|
|
18
|
+
if(response.status===401||response.status===403)throw Error('AUTH');
|
|
19
|
+
if(!response.ok)throw Error('HTTP');
|
|
20
|
+
if(response.headers.get('mcp-session-id'))session=response.headers.get('mcp-session-id');
|
|
21
|
+
if(message.id===undefined){await response.body?.cancel();return}
|
|
22
|
+
let text='';const reader=response.body.getReader();
|
|
23
|
+
try{while(true){const {value,done}=await reader.read();if(done)break;text+=Buffer.from(value).toString();if(text.length>1000000)throw Error('SIZE');
|
|
24
|
+
if((response.headers.get('content-type')||'').includes('text/event-stream')){for(const block of text.split(/\r?\n\r?\n/).slice(0,-1)){const data=block.split(/\r?\n/).filter(l=>l.startsWith('data:')).map(l=>l.slice(5).trim()).join('\n');if(!data)continue;try{const parsed=JSON.parse(data);if(parsed.id===message.id)return parsed}catch{}}}
|
|
25
|
+
}}finally{await reader.cancel().catch(()=>{})}
|
|
26
|
+
return JSON.parse(text)
|
|
27
|
+
}
|
|
28
|
+
function local(message){if(message.id===undefined){child.stdin.write(JSON.stringify(message)+'\n');return Promise.resolve()}
|
|
29
|
+
return new Promise((resolve,reject)=>{pending.set(message.id,{resolve,reject});child.stdin.write(JSON.stringify(message)+'\n')})
|
|
30
|
+
}
|
|
31
|
+
async function request(method,params,notification=false){const id=notification?undefined:next++;const value=await(config.url?remote:local)({jsonrpc:'2.0',...(id===undefined?{}:{id}),method,...(params===undefined?{}:{params})});if(value?.error)throw Error('RPC');return value?.result}
|
|
32
|
+
(async()=>{
|
|
33
|
+
if(credentialMissing){finish({status:'needs-credentials',reason:'Gateway credential handles are not available. Reconnect or reapply after the provider loads.'});return}
|
|
34
|
+
if(!config.url){child=cp.spawn(config.command,config.args||[],{cwd:'/sandbox',detached:true,env:{PATH:process.env.PATH,HOME:'/sandbox',NODE_EXTRA_CA_CERTS:process.env.NODE_EXTRA_CA_CERTS||'',...config.env},stdio:['pipe','pipe','pipe']});
|
|
35
|
+
let bytes=0;child.stdout.on('data',chunk=>{bytes+=chunk.length;if(bytes>1000000)finish({status:'unverified',reason:'MCP response exceeded the inspection limit.'})});child.stderr.resume();
|
|
36
|
+
readline.createInterface({input:child.stdout}).on('line',line=>{try{const v=JSON.parse(line),p=pending.get(v.id);if(p){pending.delete(v.id);p.resolve(v)}}catch{}});
|
|
37
|
+
child.on('error',()=>finish({status:'unverified',reason:'MCP executable could not start.'}));child.on('exit',()=>{if(pending.size)finish({status:'unverified',reason:'MCP exited before completing initialization.'})})}
|
|
38
|
+
const init=await request('initialize',{protocolVersion:version,capabilities:{},clientInfo:{name:'openshell-setup-check',version:'1.0.0'}});
|
|
39
|
+
if(!init||!['2024-11-05','2025-03-26','2025-06-18','2025-11-25'].includes(init.protocolVersion))throw Error('VERSION');
|
|
40
|
+
version=init.protocolVersion;await request('notifications/initialized',undefined,true);
|
|
41
|
+
let tools=[],moreToolsPossible=false;if(init.capabilities?.tools){const listed=await request('tools/list',{});if(!Array.isArray(listed?.tools)||listed.tools.length>1000)throw Error('TOOLS');moreToolsPossible=Boolean(listed.nextCursor);tools=listed.tools.map(t=>String(t.name).slice(0,100))}
|
|
42
|
+
finish({status:'connected',protocolVersion:version,toolCount:tools.length,tools,moreToolsPossible,toolCallsVerified:false,checkedAt:new Date().toISOString()})
|
|
43
|
+
})().catch(e=>finish({status:e.message==='AUTH'?'needs-sign-in':'unverified',reason:e.message==='AUTH'?'The MCP requires sign-in or additional account permissions.':'MCP initialization or capability discovery failed. Check access, dependencies and authentication.'}));
|