├── .changeset ├── README.md └── config.json ├── .eslintrc.js ├── .github ├── CODEOWNERS ├── PULL_REQUEST_TEMPLATE.md ├── dependabot.yml └── workflows │ ├── ci.yml │ ├── git-sync.yml │ ├── release-npm-packages.yml │ ├── release-npm-ssdk-libs.yml │ └── update-smithy-gradle-plugin.yml ├── .gitignore ├── .prettierignore ├── .yarn └── releases │ └── yarn-4.5.3.cjs ├── .yarnrc.yml ├── CHANGELOG.md ├── CODE_OF_CONDUCT.md ├── CONTRIBUTING.md ├── LICENSE ├── Makefile ├── NOTICE ├── README.md ├── api-extractor.json ├── api-extractor.packages.json ├── build.gradle.kts ├── config ├── checkstyle │ ├── checkstyle.xml │ └── suppressions.xml └── spotbugs │ └── filter.xml ├── gradle.properties ├── gradle └── wrapper │ ├── gradle-wrapper.jar │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── jest.config.base.js ├── package.json ├── packages ├── abort-controller │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── AbortController.spec.ts │ │ ├── AbortController.ts │ │ ├── AbortSignal.spec.ts │ │ ├── AbortSignal.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── chunked-blob-reader-native │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── chunked-blob-reader │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── config-resolver │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── endpointsConfig │ │ │ ├── NodeUseDualstackEndpointConfigOptions.spec.ts │ │ │ ├── NodeUseDualstackEndpointConfigOptions.ts │ │ │ ├── NodeUseFipsEndpointConfigOptions.spec.ts │ │ │ ├── NodeUseFipsEndpointConfigOptions.ts │ │ │ ├── index.ts │ │ │ ├── resolveCustomEndpointsConfig.spec.ts │ │ │ ├── resolveCustomEndpointsConfig.ts │ │ │ ├── resolveEndpointsConfig.spec.ts │ │ │ ├── resolveEndpointsConfig.ts │ │ │ └── utils │ │ │ │ ├── getEndpointFromRegion.spec.ts │ │ │ │ └── getEndpointFromRegion.ts │ │ ├── index.ts │ │ ├── regionConfig │ │ │ ├── config.spec.ts │ │ │ ├── config.ts │ │ │ ├── getRealRegion.spec.ts │ │ │ ├── getRealRegion.ts │ │ │ ├── index.ts │ │ │ ├── isFipsRegion.spec.ts │ │ │ ├── isFipsRegion.ts │ │ │ ├── resolveRegionConfig.spec.ts │ │ │ └── resolveRegionConfig.ts │ │ └── regionInfo │ │ │ ├── EndpointVariant.ts │ │ │ ├── EndpointVariantTag.ts │ │ │ ├── PartitionHash.ts │ │ │ ├── RegionHash.ts │ │ │ ├── getHostnameFromVariants.spec.ts │ │ │ ├── getHostnameFromVariants.ts │ │ │ ├── getRegionInfo.spec.ts │ │ │ ├── getRegionInfo.ts │ │ │ ├── getResolvedHostname.spec.ts │ │ │ ├── getResolvedHostname.ts │ │ │ ├── getResolvedPartition.spec.ts │ │ │ ├── getResolvedPartition.ts │ │ │ ├── getResolvedSigningRegion.spec.ts │ │ │ ├── getResolvedSigningRegion.ts │ │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── core │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── cbor.d.ts │ ├── cbor.js │ ├── package.json │ ├── protocols.d.ts │ ├── protocols.js │ ├── schema.d.ts │ ├── schema.js │ ├── scripts │ │ ├── cbor-perf.mjs │ │ └── lint.js │ ├── serde.d.ts │ ├── serde.js │ ├── src │ │ ├── getSmithyContext.ts │ │ ├── index.ts │ │ ├── middleware-http-auth-scheme │ │ │ ├── getHttpAuthSchemeEndpointRuleSetPlugin.ts │ │ │ ├── getHttpAuthSchemePlugin.ts │ │ │ ├── httpAuthSchemeMiddleware.ts │ │ │ ├── index.ts │ │ │ ├── resolveAuthOptions.spec.ts │ │ │ └── resolveAuthOptions.ts │ │ ├── middleware-http-signing │ │ │ ├── getHttpSigningMiddleware.ts │ │ │ ├── httpSigningMiddleware.ts │ │ │ └── index.ts │ │ ├── normalizeProvider.spec.ts │ │ ├── normalizeProvider.ts │ │ ├── pagination │ │ │ ├── createPaginator.spec.ts │ │ │ └── createPaginator.ts │ │ ├── protocols │ │ │ └── requestBuilder.ts │ │ ├── setFeature.spec.ts │ │ ├── setFeature.ts │ │ ├── submodules │ │ │ ├── cbor │ │ │ │ ├── CborCodec.ts │ │ │ │ ├── SmithyRpcV2CborProtocol.spec.ts │ │ │ │ ├── SmithyRpcV2CborProtocol.ts │ │ │ │ ├── byte-printer.ts │ │ │ │ ├── cbor-decode.ts │ │ │ │ ├── cbor-encode.ts │ │ │ │ ├── cbor-types.ts │ │ │ │ ├── cbor.spec.ts │ │ │ │ ├── cbor.ts │ │ │ │ ├── index.ts │ │ │ │ ├── parseCborBody.spec.ts │ │ │ │ ├── parseCborBody.ts │ │ │ │ └── test-data │ │ │ │ │ ├── decode-error-tests.json │ │ │ │ │ └── success-tests.json │ │ │ ├── protocols │ │ │ │ ├── HttpBindingProtocol.spec.ts │ │ │ │ ├── HttpBindingProtocol.ts │ │ │ │ ├── HttpProtocol.spec.ts │ │ │ │ ├── HttpProtocol.ts │ │ │ │ ├── RpcProtocol.ts │ │ │ │ ├── collect-stream-body.spec.ts │ │ │ │ ├── collect-stream-body.ts │ │ │ │ ├── extended-encode-uri-component.spec.ts │ │ │ │ ├── extended-encode-uri-component.ts │ │ │ │ ├── index.ts │ │ │ │ ├── requestBuilder.spec.ts │ │ │ │ ├── requestBuilder.ts │ │ │ │ ├── resolve-path.ts │ │ │ │ └── serde │ │ │ │ │ ├── FromStringShapeDeserializer.ts │ │ │ │ │ ├── HttpInterceptingShapeDeserializer.ts │ │ │ │ │ ├── HttpInterceptingShapeSerializer.ts │ │ │ │ │ ├── ToStringShapeSerializer.ts │ │ │ │ │ └── determineTimestampFormat.ts │ │ │ ├── schema │ │ │ │ ├── TypeRegistry.spec.ts │ │ │ │ ├── TypeRegistry.ts │ │ │ │ ├── deref.ts │ │ │ │ ├── index.ts │ │ │ │ ├── middleware │ │ │ │ │ ├── getSchemaSerdePlugin.ts │ │ │ │ │ ├── schema-middleware-types.ts │ │ │ │ │ ├── schemaDeserializationMiddleware.spec.ts │ │ │ │ │ ├── schemaDeserializationMiddleware.ts │ │ │ │ │ ├── schemaSerializationMiddleware.spec.ts │ │ │ │ │ └── schemaSerializationMiddleware.ts │ │ │ │ └── schemas │ │ │ │ │ ├── ErrorSchema.ts │ │ │ │ │ ├── ListSchema.ts │ │ │ │ │ ├── MapSchema.ts │ │ │ │ │ ├── NormalizedSchema.spec.ts │ │ │ │ │ ├── NormalizedSchema.ts │ │ │ │ │ ├── OperationSchema.ts │ │ │ │ │ ├── Schema.ts │ │ │ │ │ ├── SimpleSchema.ts │ │ │ │ │ ├── StructureSchema.ts │ │ │ │ │ ├── schemas.spec.ts │ │ │ │ │ └── sentinels.ts │ │ │ └── serde │ │ │ │ ├── copyDocumentWithTransform.ts │ │ │ │ ├── date-utils.spec.ts │ │ │ │ ├── date-utils.ts │ │ │ │ ├── index.ts │ │ │ │ ├── lazy-json.spec.ts │ │ │ │ ├── lazy-json.ts │ │ │ │ ├── parse-utils.spec.ts │ │ │ │ ├── parse-utils.ts │ │ │ │ ├── quote-header.spec.ts │ │ │ │ ├── quote-header.ts │ │ │ │ ├── split-every.spec.ts │ │ │ │ ├── split-every.ts │ │ │ │ ├── split-header.spec.ts │ │ │ │ ├── split-header.ts │ │ │ │ └── value │ │ │ │ ├── NumericValue.spec.ts │ │ │ │ └── NumericValue.ts │ │ └── util-identity-and-auth │ │ │ ├── DefaultIdentityProviderConfig.ts │ │ │ ├── httpAuthSchemes │ │ │ ├── httpApiKeyAuth.ts │ │ │ ├── httpBearerAuth.ts │ │ │ ├── index.ts │ │ │ └── noAuth.ts │ │ │ ├── index.ts │ │ │ └── memoizeIdentityProvider.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── credential-provider-imds │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── config │ │ │ ├── Endpoint.ts │ │ │ ├── EndpointConfigOptions.spec.ts │ │ │ ├── EndpointConfigOptions.ts │ │ │ ├── EndpointMode.ts │ │ │ ├── EndpointModeConfigOptions.spec.ts │ │ │ └── EndpointModeConfigOptions.ts │ │ ├── error │ │ │ └── InstanceMetadataV1FallbackError.ts │ │ ├── fromContainerMetadata.spec.ts │ │ ├── fromContainerMetadata.ts │ │ ├── fromInstanceMetadata.spec.ts │ │ ├── fromInstanceMetadata.ts │ │ ├── index.ts │ │ ├── remoteProvider │ │ │ ├── ImdsCredentials.spec.ts │ │ │ ├── ImdsCredentials.ts │ │ │ ├── RemoteProviderInit.spec.ts │ │ │ ├── RemoteProviderInit.ts │ │ │ ├── httpRequest.spec.ts │ │ │ ├── httpRequest.ts │ │ │ ├── index.ts │ │ │ ├── retry.spec.ts │ │ │ └── retry.ts │ │ ├── types.ts │ │ └── utils │ │ │ ├── getExtendedInstanceMetadataCredentials.spec.ts │ │ │ ├── getExtendedInstanceMetadataCredentials.ts │ │ │ ├── getInstanceMetadataEndpoint.spec.ts │ │ │ ├── getInstanceMetadataEndpoint.ts │ │ │ ├── staticStabilityProvider.spec.ts │ │ │ └── staticStabilityProvider.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── eventstream-codec │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── scripts │ │ └── buildTestVectorsFixture.js │ ├── src │ │ ├── EventStreamCodec.spec.ts │ │ ├── EventStreamCodec.ts │ │ ├── HeaderMarshaller.spec.ts │ │ ├── HeaderMarshaller.ts │ │ ├── Int64.spec.ts │ │ ├── Int64.ts │ │ ├── Message.ts │ │ ├── MessageDecoderStream.spec.ts │ │ ├── MessageDecoderStream.ts │ │ ├── MessageEncoderStream.spec.ts │ │ ├── MessageEncoderStream.ts │ │ ├── SmithyMessageDecoderStream.spec.ts │ │ ├── SmithyMessageDecoderStream.ts │ │ ├── SmithyMessageEncoderStream.spec.ts │ │ ├── SmithyMessageEncoderStream.ts │ │ ├── TestVectors.fixture.ts │ │ ├── index.ts │ │ ├── splitMessage.spec.ts │ │ ├── splitMessage.ts │ │ └── vectorTypes.fixture.ts │ ├── test_vectors │ │ ├── decoded │ │ │ ├── negative │ │ │ │ ├── corrupted_header_len │ │ │ │ ├── corrupted_headers │ │ │ │ ├── corrupted_length │ │ │ │ └── corrupted_payload │ │ │ └── positive │ │ │ │ ├── all_headers │ │ │ │ ├── empty_message │ │ │ │ ├── int32_header │ │ │ │ ├── payload_no_headers │ │ │ │ └── payload_one_str_header │ │ └── encoded │ │ │ ├── negative │ │ │ ├── corrupted_header_len │ │ │ ├── corrupted_headers │ │ │ ├── corrupted_length │ │ │ └── corrupted_payload │ │ │ └── positive │ │ │ ├── all_headers │ │ │ ├── empty_message │ │ │ ├── int32_header │ │ │ ├── payload_no_headers │ │ │ └── payload_one_str_header │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── eventstream-serde-browser │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── EventStreamMarshaller.ts │ │ ├── index.ts │ │ ├── provider.ts │ │ └── utils.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── eventstream-serde-config-resolver │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── EventStreamSerdeConfig.spec.ts │ │ ├── EventStreamSerdeConfig.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── eventstream-serde-node │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── EventStreamMarshaller.ts │ │ ├── index.ts │ │ ├── provider.ts │ │ └── utils.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── eventstream-serde-universal │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── EventStreamMarshaller.ts │ │ ├── getChunkedStream.spec.ts │ │ ├── getChunkedStream.ts │ │ ├── getUnmarshalledStream.spec.ts │ │ ├── getUnmarshalledStream.ts │ │ ├── index.ts │ │ └── provider.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── experimental-identity-and-auth │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── HttpAuthScheme.ts │ │ ├── HttpAuthSchemeProvider.ts │ │ ├── HttpSigner.ts │ │ ├── IdentityProviderConfig.ts │ │ ├── SigV4Signer.ts │ │ ├── apiKeyIdentity.ts │ │ ├── endpointRuleSet.ts │ │ ├── httpApiKeyAuth.ts │ │ ├── httpBearerAuth.ts │ │ ├── index.ts │ │ ├── integration │ │ │ ├── httpApiKeyAuth.integ.spec.ts │ │ │ └── httpBearerAuth.integ.spec.ts │ │ ├── memoizeIdentityProvider.ts │ │ ├── middleware-http-auth-scheme │ │ │ ├── getHttpAuthSchemeEndpointRuleSetPlugin.ts │ │ │ ├── getHttpAuthSchemePlugin.ts │ │ │ ├── httpAuthSchemeMiddleware.ts │ │ │ └── index.ts │ │ ├── middleware-http-signing │ │ │ ├── getHttpSigningMiddleware.ts │ │ │ ├── httpSigningMiddleware.ts │ │ │ └── index.ts │ │ ├── noAuth.ts │ │ └── tokenIdentity.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.test.json │ ├── tsconfig.types.json │ ├── vitest.config.integ.ts │ └── vitest.config.ts ├── fetch-http-handler │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── create-request.ts │ │ ├── fetch-http-handler.browser.spec.ts │ │ ├── fetch-http-handler.spec.ts │ │ ├── fetch-http-handler.ts │ │ ├── index.spec.ts │ │ ├── index.ts │ │ ├── request-timeout.ts │ │ ├── stream-collector.browser.spec.ts │ │ ├── stream-collector.spec.ts │ │ └── stream-collector.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ ├── vitest.config.browser.ts │ └── vitest.config.ts ├── hash-blob-browser │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── hash-node │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── hash-stream-node │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── HashCalculator.spec.ts │ │ ├── HashCalculator.ts │ │ ├── fileStreamHasher.spec.ts │ │ ├── fileStreamHasher.ts │ │ ├── index.ts │ │ ├── readableStreamHasher.spec.ts │ │ └── readableStreamHasher.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── invalid-dependency │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.ts │ │ ├── invalidFunction.spec.ts │ │ ├── invalidFunction.ts │ │ ├── invalidProvider.spec.ts │ │ └── invalidProvider.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── is-array-buffer │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── md5-js │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── constants.ts │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── middleware-apply-body-checksum │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── applyMd5BodyChecksumMiddleware.spec.ts │ │ ├── applyMd5BodyChecksumMiddleware.ts │ │ ├── index.spec.ts │ │ ├── index.ts │ │ ├── md5Configuration.ts │ │ └── middleware-apply-body-checksum.integ.spec.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ ├── vitest.config.integ.ts │ └── vitest.config.ts ├── middleware-compression │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── NODE_DISABLE_REQUEST_COMPRESSION_CONFIG_OPTIONS.spec.ts │ │ ├── NODE_DISABLE_REQUEST_COMPRESSION_CONFIG_OPTIONS.ts │ │ ├── NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_CONFIG_OPTIONS.spec.ts │ │ ├── NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_CONFIG_OPTIONS.ts │ │ ├── compressStream.browser.spec.ts │ │ ├── compressStream.browser.ts │ │ ├── compressStream.spec.ts │ │ ├── compressStream.ts │ │ ├── compressString.browser.spec.ts │ │ ├── compressString.browser.ts │ │ ├── compressString.spec.ts │ │ ├── compressString.ts │ │ ├── compressionMiddleware.spec.ts │ │ ├── compressionMiddleware.ts │ │ ├── configurations.ts │ │ ├── constants.ts │ │ ├── getCompressionPlugin.spec.ts │ │ ├── getCompressionPlugin.ts │ │ ├── index.ts │ │ ├── isStreaming.spec.ts │ │ ├── isStreaming.ts │ │ ├── resolveCompressionConfig.spec.ts │ │ └── resolveCompressionConfig.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── middleware-content-length │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.ts │ │ └── middleware-content-length.integ.spec.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.integ.ts ├── middleware-endpoint │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── adaptors │ │ │ ├── createConfigValueProvider.spec.ts │ │ │ ├── createConfigValueProvider.ts │ │ │ ├── getEndpointFromConfig.browser.ts │ │ │ ├── getEndpointFromConfig.ts │ │ │ ├── getEndpointFromInstructions.spec.ts │ │ │ ├── getEndpointFromInstructions.ts │ │ │ ├── getEndpointUrlConfig.spec.ts │ │ │ ├── getEndpointUrlConfig.ts │ │ │ ├── index.ts │ │ │ └── toEndpointV1.ts │ │ ├── endpointMiddleware.ts │ │ ├── getEndpointPlugin.ts │ │ ├── index.ts │ │ ├── resolveEndpointConfig.spec.ts │ │ ├── resolveEndpointConfig.ts │ │ ├── resolveEndpointRequiredConfig.spec.ts │ │ ├── resolveEndpointRequiredConfig.ts │ │ ├── service-customizations │ │ │ ├── index.ts │ │ │ ├── s3.spec.ts │ │ │ └── s3.ts │ │ └── types.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── middleware-retry │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── AdaptiveRetryStrategy.spec.ts │ │ ├── AdaptiveRetryStrategy.ts │ │ ├── StandardRetryStrategy.spec.ts │ │ ├── StandardRetryStrategy.ts │ │ ├── configurations.spec.ts │ │ ├── configurations.ts │ │ ├── defaultRetryQuota.spec.ts │ │ ├── defaultRetryQuota.ts │ │ ├── delayDecider.spec.ts │ │ ├── delayDecider.ts │ │ ├── index.ts │ │ ├── isStreamingPayload │ │ │ ├── isStreamingPayload.browser.ts │ │ │ └── isStreamingPayload.ts │ │ ├── middleware-retry.integ.spec.ts │ │ ├── omitRetryHeadersMiddleware.spec.ts │ │ ├── omitRetryHeadersMiddleware.ts │ │ ├── retryDecider.spec.ts │ │ ├── retryDecider.ts │ │ ├── retryMiddleware.spec.ts │ │ ├── retryMiddleware.ts │ │ ├── types.ts │ │ └── util.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ ├── vitest.config.integ.ts │ └── vitest.config.ts ├── middleware-serde │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── deserializerMiddleware.spec.ts │ │ ├── deserializerMiddleware.ts │ │ ├── index.ts │ │ ├── middleware-serde.integ.spec.ts │ │ ├── serdePlugin.ts │ │ ├── serializerMiddleware.spec.ts │ │ └── serializerMiddleware.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ ├── vitest.config.integ.ts │ └── vitest.config.ts ├── middleware-stack │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── MiddlewareStack.spec.ts │ │ ├── MiddlewareStack.ts │ │ ├── index.ts │ │ └── types.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── node-config-provider │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── configLoader.spec.ts │ │ ├── configLoader.ts │ │ ├── fromEnv.spec.ts │ │ ├── fromEnv.ts │ │ ├── fromSharedConfigFiles.spec.ts │ │ ├── fromSharedConfigFiles.ts │ │ ├── fromStatic.spec.ts │ │ ├── fromStatic.ts │ │ ├── getSelectorName.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── node-http-handler │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── fixtures │ │ ├── test-server-cert.pem │ │ └── test-server-key.pem │ ├── package.json │ ├── src │ │ ├── constants.ts │ │ ├── get-transformed-headers.ts │ │ ├── index.spec.ts │ │ ├── index.ts │ │ ├── node-http-handler.mock-server.spec.ts │ │ ├── node-http-handler.spec.ts │ │ ├── node-http-handler.ts │ │ ├── node-http2-connection-manager.ts │ │ ├── node-http2-connection-pool.ts │ │ ├── node-http2-handler.spec.ts │ │ ├── node-http2-handler.ts │ │ ├── readable.mock.ts │ │ ├── server.mock.ts │ │ ├── set-connection-timeout.spec.ts │ │ ├── set-connection-timeout.ts │ │ ├── set-socket-keep-alive.spec.ts │ │ ├── set-socket-keep-alive.ts │ │ ├── set-socket-timeout.spec.ts │ │ ├── set-socket-timeout.ts │ │ ├── stream-collector │ │ │ ├── collector.spec.ts │ │ │ ├── collector.ts │ │ │ ├── index.spec.ts │ │ │ ├── index.ts │ │ │ └── readable.mock.ts │ │ ├── timing.ts │ │ ├── write-request-body.spec.ts │ │ └── write-request-body.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── property-provider │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── CredentialsProviderError.spec.ts │ │ ├── CredentialsProviderError.ts │ │ ├── ProviderError.spec.ts │ │ ├── ProviderError.ts │ │ ├── TokenProviderError.spec.ts │ │ ├── TokenProviderError.ts │ │ ├── chain.spec.ts │ │ ├── chain.ts │ │ ├── fromStatic.spec.ts │ │ ├── fromStatic.ts │ │ ├── index.ts │ │ ├── memoize.spec.ts │ │ └── memoize.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── protocol-http │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── Field.ts │ │ ├── Fields.ts │ │ ├── extensions │ │ │ ├── httpExtensionConfiguration.ts │ │ │ └── index.ts │ │ ├── httpHandler.ts │ │ ├── httpRequest.spec.ts │ │ ├── httpRequest.ts │ │ ├── httpResponse.ts │ │ ├── index.ts │ │ ├── isValidHostname.spec.ts │ │ ├── isValidHostname.ts │ │ └── types.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── querystring-builder │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── querystring-parser │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── service-client-documentation-generator │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.ts │ │ ├── sdk-client-toc-plugin.ts │ │ └── utils.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── service-error-classification │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── constants.ts │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── shared-ini-file-loader │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── getConfigData.spec.ts │ │ ├── getConfigData.ts │ │ ├── getConfigFilepath.spec.ts │ │ ├── getConfigFilepath.ts │ │ ├── getCredentialsFilepath.spec.ts │ │ ├── getCredentialsFilepath.ts │ │ ├── getHomeDir.spec.ts │ │ ├── getHomeDir.ts │ │ ├── getProfileName.spec.ts │ │ ├── getProfileName.ts │ │ ├── getSSOTokenFilepath.spec.ts │ │ ├── getSSOTokenFilepath.ts │ │ ├── getSSOTokenFromFile.spec.ts │ │ ├── getSSOTokenFromFile.ts │ │ ├── getSsoSessionData.spec.ts │ │ ├── getSsoSessionData.ts │ │ ├── index.ts │ │ ├── loadSharedConfigFiles.spec.ts │ │ ├── loadSharedConfigFiles.ts │ │ ├── loadSsoSessionData.spec.ts │ │ ├── loadSsoSessionData.ts │ │ ├── mergeConfigFiles.spec.ts │ │ ├── mergeConfigFiles.ts │ │ ├── parseIni.spec.ts │ │ ├── parseIni.ts │ │ ├── parseKnownFiles.spec.ts │ │ ├── parseKnownFiles.ts │ │ ├── slurpFile.spec.ts │ │ ├── slurpFile.ts │ │ └── types.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── signature-v4 │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── HeaderFormatter.spec.ts │ │ ├── HeaderFormatter.ts │ │ ├── SignatureV4.spec.ts │ │ ├── SignatureV4.ts │ │ ├── SignatureV4Base.ts │ │ ├── constants.ts │ │ ├── credentialDerivation.spec.ts │ │ ├── credentialDerivation.ts │ │ ├── getCanonicalHeaders.spec.ts │ │ ├── getCanonicalHeaders.ts │ │ ├── getCanonicalQuery.spec.ts │ │ ├── getCanonicalQuery.ts │ │ ├── getPayloadHash.spec.ts │ │ ├── getPayloadHash.ts │ │ ├── headerUtil.ts │ │ ├── index.ts │ │ ├── moveHeadersToQuery.spec.ts │ │ ├── moveHeadersToQuery.ts │ │ ├── prepareRequest.spec.ts │ │ ├── prepareRequest.ts │ │ ├── signature-v4a-container.ts │ │ ├── suite.fixture.ts │ │ ├── suite.spec.ts │ │ ├── utilDate.spec.ts │ │ └── utilDate.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── signature-v4a │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── scripts │ │ ├── Ec.js │ │ └── esbuild.mjs │ ├── src │ │ ├── SignatureV4a.spec.ts │ │ ├── SignatureV4a.ts │ │ ├── constants.ts │ │ ├── credentialDerivation.spec.ts │ │ ├── credentialDerivation.ts │ │ ├── elliptic │ │ │ └── Ec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.js ├── smithy-client │ ├── .eslintrc.json │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── scripts │ │ └── fix-api-extractor.js │ ├── src │ │ ├── NoOpLogger.ts │ │ ├── client.spec.ts │ │ ├── client.ts │ │ ├── collect-stream-body.ts │ │ ├── command.spec.ts │ │ ├── command.ts │ │ ├── constants.ts │ │ ├── create-aggregated-client.spec.ts │ │ ├── create-aggregated-client.ts │ │ ├── default-error-handler.ts │ │ ├── defaults-mode.ts │ │ ├── emitWarningIfUnsupportedVersion.spec.ts │ │ ├── emitWarningIfUnsupportedVersion.ts │ │ ├── exceptions.spec.ts │ │ ├── exceptions.ts │ │ ├── extended-encode-uri-component.ts │ │ ├── extensions │ │ │ ├── checksum.ts │ │ │ ├── defaultExtensionConfiguration.ts │ │ │ ├── index.ts │ │ │ └── retry.ts │ │ ├── get-array-if-single-item.ts │ │ ├── get-value-from-text-node.spec.ts │ │ ├── get-value-from-text-node.ts │ │ ├── index.ts │ │ ├── is-serializable-header-value.spec.ts │ │ ├── is-serializable-header-value.ts │ │ ├── object-mapping.spec.ts │ │ ├── object-mapping.ts │ │ ├── resolve-path.ts │ │ ├── ser-utils.spec.ts │ │ ├── ser-utils.ts │ │ ├── serde-json.spec.ts │ │ └── serde-json.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── types │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── scripts │ │ └── downlevel.js │ ├── src │ │ ├── abort-handler.ts │ │ ├── abort.ts │ │ ├── auth │ │ │ ├── HttpApiKeyAuth.ts │ │ │ ├── HttpAuthScheme.ts │ │ │ ├── HttpAuthSchemeProvider.ts │ │ │ ├── HttpSigner.ts │ │ │ ├── IdentityProviderConfig.ts │ │ │ ├── auth.ts │ │ │ └── index.ts │ │ ├── blob │ │ │ └── blob-payload-input-types.ts │ │ ├── checksum.ts │ │ ├── client.ts │ │ ├── command.ts │ │ ├── connection │ │ │ ├── config.ts │ │ │ ├── index.ts │ │ │ ├── manager.ts │ │ │ └── pool.ts │ │ ├── crypto.ts │ │ ├── downlevel-ts3.4 │ │ │ └── transform │ │ │ │ └── type-transform.ts │ │ ├── encode.ts │ │ ├── endpoint.ts │ │ ├── endpoints │ │ │ ├── EndpointRuleObject.ts │ │ │ ├── ErrorRuleObject.ts │ │ │ ├── RuleSetObject.ts │ │ │ ├── TreeRuleObject.ts │ │ │ ├── index.ts │ │ │ └── shared.ts │ │ ├── eventStream.ts │ │ ├── extensions │ │ │ ├── checksum.ts │ │ │ ├── defaultClientConfiguration.ts │ │ │ ├── defaultExtensionConfiguration.ts │ │ │ ├── index.ts │ │ │ └── retry.ts │ │ ├── externals-check │ │ │ └── browser-externals-check.ts │ │ ├── feature-ids.ts │ │ ├── http.ts │ │ ├── http │ │ │ └── httpHandlerInitialization.ts │ │ ├── identity │ │ │ ├── apiKeyIdentity.ts │ │ │ ├── awsCredentialIdentity.ts │ │ │ ├── identity.ts │ │ │ ├── index.ts │ │ │ └── tokenIdentity.ts │ │ ├── index.ts │ │ ├── logger.ts │ │ ├── middleware.ts │ │ ├── pagination.ts │ │ ├── profile.ts │ │ ├── response.ts │ │ ├── retry.ts │ │ ├── schema │ │ │ ├── schema.ts │ │ │ ├── sentinels.ts │ │ │ └── traits.ts │ │ ├── serde.ts │ │ ├── shapes.ts │ │ ├── signature.ts │ │ ├── stream.ts │ │ ├── streaming-payload │ │ │ ├── streaming-blob-common-types.ts │ │ │ ├── streaming-blob-payload-input-types.ts │ │ │ └── streaming-blob-payload-output-types.ts │ │ ├── transfer.ts │ │ ├── transform │ │ │ ├── client-method-transforms.ts │ │ │ ├── client-payload-blob-type-narrow.spec.ts │ │ │ ├── client-payload-blob-type-narrow.ts │ │ │ ├── exact.ts │ │ │ ├── mutable.ts │ │ │ ├── no-undefined.spec.ts │ │ │ ├── no-undefined.ts │ │ │ ├── type-transform.spec.ts │ │ │ └── type-transform.ts │ │ ├── uri.ts │ │ ├── util.spec.ts │ │ ├── util.ts │ │ └── waiter.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.test.json │ └── tsconfig.types.json ├── url-parser │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-base64 │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── __mocks__ │ │ │ └── testCases.json │ │ ├── constants.browser.ts │ │ ├── fromBase64.browser.spec.ts │ │ ├── fromBase64.browser.ts │ │ ├── fromBase64.spec.ts │ │ ├── fromBase64.ts │ │ ├── index.ts │ │ ├── toBase64.browser.spec.ts │ │ ├── toBase64.browser.ts │ │ ├── toBase64.spec.ts │ │ └── toBase64.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-body-length-browser │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── calculateBodyLength.spec.ts │ │ ├── calculateBodyLength.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-body-length-node │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── calculateBodyLength.spec.ts │ │ ├── calculateBodyLength.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-buffer-from │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-config-provider │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── booleanSelector.spec.ts │ │ ├── booleanSelector.ts │ │ ├── index.ts │ │ ├── numberSelector.spec.ts │ │ ├── numberSelector.ts │ │ └── types.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-defaults-mode-browser │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── constants.ts │ │ ├── index.ts │ │ ├── resolveDefaultsModeConfig.native.spec.ts │ │ ├── resolveDefaultsModeConfig.native.ts │ │ ├── resolveDefaultsModeConfig.spec.ts │ │ └── resolveDefaultsModeConfig.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-defaults-mode-node │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── constants.ts │ │ ├── defaultsModeConfig.ts │ │ ├── index.ts │ │ ├── resolveDefaultsModeConfig.spec.ts │ │ └── resolveDefaultsModeConfig.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-endpoints │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── __mocks__ │ │ │ ├── test-cases │ │ │ │ ├── aws-region.json │ │ │ │ ├── default-values.json │ │ │ │ ├── headers.json │ │ │ │ ├── local-region-override.json │ │ │ │ ├── parse-url.json │ │ │ │ ├── substring.json │ │ │ │ ├── uri-encode.json │ │ │ │ └── valid-hostlabel.json │ │ │ └── valid-rules │ │ │ │ ├── aws-region.json │ │ │ │ ├── default-values.json │ │ │ │ ├── headers.json │ │ │ │ ├── local-region-override.json │ │ │ │ ├── parse-url.json │ │ │ │ ├── substring.json │ │ │ │ ├── uri-encode.json │ │ │ │ └── valid-hostlabel.json │ │ ├── cache │ │ │ ├── EndpointCache.spec.ts │ │ │ └── EndpointCache.ts │ │ ├── debug │ │ │ ├── debugId.ts │ │ │ ├── index.ts │ │ │ └── toDebugString.ts │ │ ├── getEndpointUrlConfig.spec.ts │ │ ├── getEndpointUrlConfig.ts │ │ ├── index.ts │ │ ├── lib │ │ │ ├── booleanEquals.spec.ts │ │ │ ├── booleanEquals.ts │ │ │ ├── getAttr.spec.ts │ │ │ ├── getAttr.ts │ │ │ ├── getAttrPathList.spec.ts │ │ │ ├── getAttrPathList.ts │ │ │ ├── index.ts │ │ │ ├── isIpAddress.spec.ts │ │ │ ├── isIpAddress.ts │ │ │ ├── isSet.spec.ts │ │ │ ├── isSet.ts │ │ │ ├── isValidHostLabel.spec.ts │ │ │ ├── isValidHostLabel.ts │ │ │ ├── not.spec.ts │ │ │ ├── not.ts │ │ │ ├── parseURL.spec.ts │ │ │ ├── parseURL.ts │ │ │ ├── stringEquals.spec.ts │ │ │ ├── stringEquals.ts │ │ │ ├── substring.spec.ts │ │ │ ├── substring.ts │ │ │ ├── uriEncode.spec.ts │ │ │ └── uriEncode.ts │ │ ├── resolveEndpoint.integ.spec.ts │ │ ├── resolveEndpoint.spec.ts │ │ ├── resolveEndpoint.ts │ │ ├── types │ │ │ ├── EndpointError.ts │ │ │ ├── EndpointFunctions.ts │ │ │ ├── EndpointRuleObject.ts │ │ │ ├── ErrorRuleObject.ts │ │ │ ├── RuleSetObject.ts │ │ │ ├── TreeRuleObject.ts │ │ │ ├── index.ts │ │ │ └── shared.ts │ │ └── utils │ │ │ ├── callFunction.spec.ts │ │ │ ├── callFunction.ts │ │ │ ├── customEndpointFunctions.ts │ │ │ ├── endpointFunctions.ts │ │ │ ├── evaluateCondition.spec.ts │ │ │ ├── evaluateCondition.ts │ │ │ ├── evaluateConditions.spec.ts │ │ │ ├── evaluateConditions.ts │ │ │ ├── evaluateEndpointRule.spec.ts │ │ │ ├── evaluateEndpointRule.ts │ │ │ ├── evaluateErrorRule.spec.ts │ │ │ ├── evaluateErrorRule.ts │ │ │ ├── evaluateExpression.spec.ts │ │ │ ├── evaluateExpression.ts │ │ │ ├── evaluateRules.spec.ts │ │ │ ├── evaluateRules.ts │ │ │ ├── evaluateTemplate.spec.ts │ │ │ ├── evaluateTemplate.ts │ │ │ ├── evaluateTreeRule.spec.ts │ │ │ ├── evaluateTreeRule.ts │ │ │ ├── getEndpointHeaders.spec.ts │ │ │ ├── getEndpointHeaders.ts │ │ │ ├── getEndpointProperties.spec.ts │ │ │ ├── getEndpointProperties.ts │ │ │ ├── getEndpointProperty.spec.ts │ │ │ ├── getEndpointProperty.ts │ │ │ ├── getEndpointUrl.spec.ts │ │ │ ├── getEndpointUrl.ts │ │ │ ├── getReferenceValue.spec.ts │ │ │ ├── getReferenceValue.ts │ │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ ├── vitest.config.integ.ts │ └── vitest.config.ts ├── util-hex-encoding │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── index.spec.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-middleware │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── getSmithyContext.ts │ │ ├── index.ts │ │ ├── normalizeProvider.spec.ts │ │ └── normalizeProvider.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-retry │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── AdaptiveRetryStrategy.spec.ts │ │ ├── AdaptiveRetryStrategy.ts │ │ ├── ConfiguredRetryStrategy.spec.ts │ │ ├── ConfiguredRetryStrategy.ts │ │ ├── DefaultRateLimiter.spec.ts │ │ ├── DefaultRateLimiter.ts │ │ ├── StandardRetryStrategy.spec.ts │ │ ├── StandardRetryStrategy.ts │ │ ├── config.ts │ │ ├── constants.ts │ │ ├── defaultRetryBackoffStrategy.spec.ts │ │ ├── defaultRetryBackoffStrategy.ts │ │ ├── defaultRetryToken.spec.ts │ │ ├── defaultRetryToken.ts │ │ ├── index.ts │ │ └── types.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-stream-browser │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── getAwsChunkedEncodingStream.ts │ │ ├── index.ts │ │ └── sdk-stream-mixin.ts │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── util-stream-node │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── getAwsChunkedEncodingStream.ts │ │ ├── index.ts │ │ └── sdk-stream-mixin.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── util-stream │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── api-extractor.json │ ├── package.json │ ├── src │ │ ├── ByteArrayCollector.ts │ │ ├── blob │ │ │ ├── Uint8ArrayBlobAdapter.spec.ts │ │ │ ├── Uint8ArrayBlobAdapter.ts │ │ │ └── transforms.ts │ │ ├── checksum │ │ │ ├── ChecksumStream.browser.ts │ │ │ ├── ChecksumStream.ts │ │ │ ├── createChecksumStream.browser.spec.ts │ │ │ ├── createChecksumStream.browser.ts │ │ │ ├── createChecksumStream.spec.ts │ │ │ └── createChecksumStream.ts │ │ ├── createBufferedReadable.spec.ts │ │ ├── createBufferedReadable.ts │ │ ├── createBufferedReadableStream.browser.spec.ts │ │ ├── createBufferedReadableStream.spec.ts │ │ ├── createBufferedReadableStream.ts │ │ ├── getAwsChunkedEncodingStream.browser.spec.ts │ │ ├── getAwsChunkedEncodingStream.browser.ts │ │ ├── getAwsChunkedEncodingStream.spec.ts │ │ ├── getAwsChunkedEncodingStream.ts │ │ ├── headStream.browser.ts │ │ ├── headStream.spec.ts │ │ ├── headStream.ts │ │ ├── index.ts │ │ ├── sdk-stream-mixin.browser.spec.ts │ │ ├── sdk-stream-mixin.browser.ts │ │ ├── sdk-stream-mixin.spec.ts │ │ ├── sdk-stream-mixin.ts │ │ ├── splitStream.browser.ts │ │ ├── splitStream.spec.ts │ │ ├── splitStream.ts │ │ ├── stream-type-check.ts │ │ └── util-stream.integ.spec.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ ├── vitest.config.browser.ts │ ├── vitest.config.integ.ts │ └── vitest.config.ts ├── util-uri-escape │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── escape-uri-path.spec.ts │ │ ├── escape-uri-path.ts │ │ ├── escape-uri.spec.ts │ │ ├── escape-uri.ts │ │ └── index.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── util-utf8 │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ │ ├── fromUtf8.browser.spec.ts │ │ ├── fromUtf8.browser.ts │ │ ├── fromUtf8.spec.ts │ │ ├── fromUtf8.ts │ │ ├── index.ts │ │ ├── toUint8Array.spec.ts │ │ ├── toUint8Array.ts │ │ ├── toUtf8.browser.spec.ts │ │ ├── toUtf8.browser.ts │ │ ├── toUtf8.spec.ts │ │ └── toUtf8.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts └── util-waiter │ ├── .eslintrc.json │ ├── .gitignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── package.json │ ├── src │ ├── createWaiter.spec.ts │ ├── createWaiter.ts │ ├── index.spec.ts │ ├── index.ts │ ├── poller.spec.ts │ ├── poller.ts │ ├── utils │ │ ├── index.ts │ │ ├── sleep.ts │ │ ├── validate.spec.ts │ │ └── validate.ts │ ├── waiter.spec.ts │ └── waiter.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.types.json │ └── vitest.config.ts ├── prettier.config.js ├── private ├── my-local-model │ ├── package.json │ ├── src │ │ ├── XYZService.ts │ │ ├── XYZServiceClient.ts │ │ ├── auth │ │ │ ├── httpAuthExtensionConfiguration.ts │ │ │ └── httpAuthSchemeProvider.ts │ │ ├── commands │ │ │ ├── GetNumbersCommand.ts │ │ │ └── index.ts │ │ ├── endpoint │ │ │ ├── EndpointParameters.ts │ │ │ ├── endpointResolver.ts │ │ │ └── ruleset.ts │ │ ├── extensionConfiguration.ts │ │ ├── index.ts │ │ ├── models │ │ │ ├── XYZServiceServiceException.ts │ │ │ ├── index.ts │ │ │ └── models_0.ts │ │ ├── protocols │ │ │ └── Rpcv2cbor.ts │ │ ├── runtimeConfig.browser.ts │ │ ├── runtimeConfig.native.ts │ │ ├── runtimeConfig.shared.ts │ │ ├── runtimeConfig.ts │ │ └── runtimeExtensions.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.json │ └── tsconfig.types.json ├── smithy-rpcv2-cbor-schema │ ├── package.json │ ├── src │ │ ├── RpcV2Protocol.ts │ │ ├── RpcV2ProtocolClient.ts │ │ ├── auth │ │ │ ├── httpAuthExtensionConfiguration.ts │ │ │ └── httpAuthSchemeProvider.ts │ │ ├── commands │ │ │ ├── EmptyInputOutputCommand.ts │ │ │ ├── Float16Command.ts │ │ │ ├── FractionalSecondsCommand.ts │ │ │ ├── GreetingWithErrorsCommand.ts │ │ │ ├── NoInputOutputCommand.ts │ │ │ ├── OperationWithDefaultsCommand.ts │ │ │ ├── OptionalInputOutputCommand.ts │ │ │ ├── RecursiveShapesCommand.ts │ │ │ ├── RpcV2CborDenseMapsCommand.ts │ │ │ ├── RpcV2CborListsCommand.ts │ │ │ ├── RpcV2CborSparseMapsCommand.ts │ │ │ ├── SimpleScalarPropertiesCommand.ts │ │ │ ├── SparseNullsOperationCommand.ts │ │ │ └── index.ts │ │ ├── endpoint │ │ │ ├── EndpointParameters.ts │ │ │ ├── endpointResolver.ts │ │ │ └── ruleset.ts │ │ ├── extensionConfiguration.ts │ │ ├── index.ts │ │ ├── models │ │ │ ├── RpcV2ProtocolServiceException.ts │ │ │ ├── index.ts │ │ │ └── models_0.ts │ │ ├── protocols │ │ │ └── Rpcv2cbor.ts │ │ ├── runtimeConfig.browser.ts │ │ ├── runtimeConfig.native.ts │ │ ├── runtimeConfig.shared.ts │ │ ├── runtimeConfig.ts │ │ ├── runtimeExtensions.ts │ │ └── schemas │ │ │ └── schemas.ts │ ├── test │ │ └── functional │ │ │ └── rpcv2cbor.spec.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.json │ ├── tsconfig.types.json │ └── vite.config.js ├── smithy-rpcv2-cbor │ ├── package.json │ ├── src │ │ ├── RpcV2Protocol.ts │ │ ├── RpcV2ProtocolClient.ts │ │ ├── auth │ │ │ ├── httpAuthExtensionConfiguration.ts │ │ │ └── httpAuthSchemeProvider.ts │ │ ├── commands │ │ │ ├── EmptyInputOutputCommand.ts │ │ │ ├── Float16Command.ts │ │ │ ├── FractionalSecondsCommand.ts │ │ │ ├── GreetingWithErrorsCommand.ts │ │ │ ├── NoInputOutputCommand.ts │ │ │ ├── OperationWithDefaultsCommand.ts │ │ │ ├── OptionalInputOutputCommand.ts │ │ │ ├── RecursiveShapesCommand.ts │ │ │ ├── RpcV2CborDenseMapsCommand.ts │ │ │ ├── RpcV2CborListsCommand.ts │ │ │ ├── RpcV2CborSparseMapsCommand.ts │ │ │ ├── SimpleScalarPropertiesCommand.ts │ │ │ ├── SparseNullsOperationCommand.ts │ │ │ └── index.ts │ │ ├── endpoint │ │ │ ├── EndpointParameters.ts │ │ │ ├── endpointResolver.ts │ │ │ └── ruleset.ts │ │ ├── extensionConfiguration.ts │ │ ├── index.ts │ │ ├── models │ │ │ ├── RpcV2ProtocolServiceException.ts │ │ │ ├── index.ts │ │ │ └── models_0.ts │ │ ├── protocols │ │ │ └── Rpcv2cbor.ts │ │ ├── runtimeConfig.browser.ts │ │ ├── runtimeConfig.native.ts │ │ ├── runtimeConfig.shared.ts │ │ ├── runtimeConfig.ts │ │ └── runtimeExtensions.ts │ ├── test │ │ └── functional │ │ │ └── rpcv2cbor.spec.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.json │ ├── tsconfig.types.json │ └── vite.config.js └── util-test │ ├── .gitignore │ ├── CHANGELOG.md │ ├── package.json │ ├── src │ ├── index.ts │ └── test-http-handler.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ └── tsconfig.types.json ├── scripts ├── build-generated-test-packages.js ├── check-dependencies.js ├── cli-dispatcher │ ├── index.js │ ├── lib │ │ ├── Package.js │ │ ├── findFolders.js │ │ ├── findScripts.js │ │ ├── matchSorter.js │ │ └── matcher.js │ ├── readme.md │ ├── set-alias.sh │ └── workspace.js ├── compilation │ ├── Inliner.js │ └── tmp │ │ └── .gitignore ├── example.js ├── inline.js ├── package-json-enforcement.js ├── post-protocol-test-codegen.js ├── retry.js ├── runtime-dep-version-check.js ├── set-engines.js └── utils │ ├── spawn-process.js │ └── walk.js ├── settings.gradle.kts ├── smithy-typescript-codegen-test ├── build.gradle.kts ├── example-weather-customizations │ ├── build.gradle.kts │ └── src │ │ └── main │ │ ├── java │ │ └── example │ │ │ └── weather │ │ │ ├── ExampleWeatherCustomEndpointsRuntimeConfig.java │ │ │ └── SupportWeatherSigV4Auth.java │ │ └── resources │ │ └── META-INF │ │ └── services │ │ └── software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration ├── model │ ├── common │ │ ├── fakeAuth.smithy │ │ └── fakeProtocol.smithy │ ├── identity-and-auth │ │ ├── httpApiKeyAuth │ │ │ └── HttpApiKeyAuthService.smithy │ │ └── httpBearerAuth │ │ │ └── HttpBearerAuthService.smithy │ └── weather │ │ ├── main.smithy │ │ ├── more-nesting.smithy │ │ └── nested.smithy ├── released-version-test │ ├── build.gradle.kts │ └── smithy-build.json └── smithy-build.json ├── smithy-typescript-codegen ├── build.gradle.kts └── src │ ├── main │ ├── java │ │ └── software │ │ │ └── amazon │ │ │ └── smithy │ │ │ └── typescript │ │ │ └── codegen │ │ │ ├── ApplicationProtocol.java │ │ │ ├── CodegenUtils.java │ │ │ ├── CommandGenerator.java │ │ │ ├── Dependency.java │ │ │ ├── DirectedTypeScriptCodegen.java │ │ │ ├── EnumGenerator.java │ │ │ ├── ExtensionConfigurationGenerator.java │ │ │ ├── FrameworkErrorModel.java │ │ │ ├── HttpProtocolTestGenerator.java │ │ │ ├── ImportDeclarations.java │ │ │ ├── IndexGenerator.java │ │ │ ├── IntEnumGenerator.java │ │ │ ├── LanguageTarget.java │ │ │ ├── PackageContainer.java │ │ │ ├── PackageJsonGenerator.java │ │ │ ├── PaginationGenerator.java │ │ │ ├── RuntimeConfigGenerator.java │ │ │ ├── RuntimeExtensionsGenerator.java │ │ │ ├── ServerCommandGenerator.java │ │ │ ├── ServerGenerator.java │ │ │ ├── ServerSymbolVisitor.java │ │ │ ├── ServiceAggregatedClientGenerator.java │ │ │ ├── ServiceBareBonesClientGenerator.java │ │ │ ├── SmithyCoreSubmodules.java │ │ │ ├── StructureGenerator.java │ │ │ ├── StructuredMemberWriter.java │ │ │ ├── SymbolVisitor.java │ │ │ ├── TypeScriptClientCodegenPlugin.java │ │ │ ├── TypeScriptCodegenContext.java │ │ │ ├── TypeScriptCodegenPlugin.java │ │ │ ├── TypeScriptDelegator.java │ │ │ ├── TypeScriptDependency.java │ │ │ ├── TypeScriptJmesPathVisitor.java │ │ │ ├── TypeScriptSSDKCodegenPlugin.java │ │ │ ├── TypeScriptServerCodegenPlugin.java │ │ │ ├── TypeScriptSettings.java │ │ │ ├── TypeScriptUtils.java │ │ │ ├── TypeScriptWriter.java │ │ │ ├── UnionGenerator.java │ │ │ ├── UnresolvableProtocolException.java │ │ │ ├── WaiterGenerator.java │ │ │ ├── auth │ │ │ ├── AuthUtils.java │ │ │ └── http │ │ │ │ ├── ConfigField.java │ │ │ │ ├── HttpAuthOptionProperty.java │ │ │ │ ├── HttpAuthScheme.java │ │ │ │ ├── HttpAuthSchemeParameter.java │ │ │ │ ├── HttpAuthSchemeProviderGenerator.java │ │ │ │ ├── ResolveConfigFunction.java │ │ │ │ ├── SupportedHttpAuthSchemesIndex.java │ │ │ │ ├── integration │ │ │ │ ├── AddHttpAuthSchemePlugin.java │ │ │ │ ├── AddHttpSigningPlugin.java │ │ │ │ ├── HttpAuthExtensionConfigurationInterface.java │ │ │ │ ├── HttpAuthRuntimeExtensionIntegration.java │ │ │ │ ├── HttpAuthTypeScriptIntegration.java │ │ │ │ ├── SupportHttpApiKeyAuth.java │ │ │ │ ├── SupportHttpBearerAuth.java │ │ │ │ └── SupportNoAuth.java │ │ │ │ └── sections │ │ │ │ ├── DefaultHttpAuthSchemeParametersProviderFunctionCodeSection.java │ │ │ │ ├── DefaultHttpAuthSchemeProviderFunctionCodeSection.java │ │ │ │ ├── HttpAuthOptionFunctionCodeSection.java │ │ │ │ ├── HttpAuthOptionFunctionsCodeSection.java │ │ │ │ ├── HttpAuthSchemeInputConfigInterfaceCodeSection.java │ │ │ │ ├── HttpAuthSchemeParametersInterfaceCodeSection.java │ │ │ │ ├── HttpAuthSchemeParametersProviderInterfaceCodeSection.java │ │ │ │ ├── HttpAuthSchemeProviderInterfaceCodeSection.java │ │ │ │ ├── HttpAuthSchemeResolvedConfigInterfaceCodeSection.java │ │ │ │ ├── ResolveHttpAuthSchemeConfigFunctionCodeSection.java │ │ │ │ ├── ResolveHttpAuthSchemeConfigFunctionConfigFieldsCodeSection.java │ │ │ │ └── ResolveHttpAuthSchemeConfigFunctionReturnBlockCodeSection.java │ │ │ ├── documentation │ │ │ ├── DocumentationExampleGenerator.java │ │ │ └── StructureExampleGenerator.java │ │ │ ├── endpointsV2 │ │ │ ├── AddDefaultEndpointRuleSet.java │ │ │ ├── EndpointsParamNameMap.java │ │ │ ├── EndpointsV2Generator.java │ │ │ ├── OmitEndpointParams.java │ │ │ ├── ParameterGenerator.java │ │ │ ├── RuleSetParameterFinder.java │ │ │ ├── RuleSetParametersVisitor.java │ │ │ └── RuleSetSerializer.java │ │ │ ├── extensions │ │ │ ├── DefaultExtensionConfigurationInterface.java │ │ │ ├── ExtensionConfigurationInterface.java │ │ │ └── HttpHandlerExtensionConfigurationInterface.java │ │ │ ├── integration │ │ │ ├── AddBaseServiceExceptionClass.java │ │ │ ├── AddBuiltinPlugins.java │ │ │ ├── AddChecksumRequiredDependency.java │ │ │ ├── AddClientRuntimeConfig.java │ │ │ ├── AddCompressionDependency.java │ │ │ ├── AddDefaultsModeDependency.java │ │ │ ├── AddEventStreamDependency.java │ │ │ ├── AddHttpApiKeyAuthPlugin.java │ │ │ ├── AddProtocolConfig.java │ │ │ ├── AddSdkStreamMixinDependency.java │ │ │ ├── DefaultReadmeGenerator.java │ │ │ ├── DocumentMemberDeserVisitor.java │ │ │ ├── DocumentMemberSerVisitor.java │ │ │ ├── DocumentShapeDeserVisitor.java │ │ │ ├── DocumentShapeSerVisitor.java │ │ │ ├── EventStreamGenerator.java │ │ │ ├── HttpBindingProtocolGenerator.java │ │ │ ├── HttpProtocolGeneratorUtils.java │ │ │ ├── HttpRpcProtocolGenerator.java │ │ │ ├── ProtocolGenerator.java │ │ │ ├── RuntimeClientPlugin.java │ │ │ └── TypeScriptIntegration.java │ │ │ ├── knowledge │ │ │ └── SerdeElisionIndex.java │ │ │ ├── protocols │ │ │ ├── AddProtocols.java │ │ │ ├── ProtocolPriorityConfig.java │ │ │ ├── SmithyProtocolUtils.java │ │ │ └── cbor │ │ │ │ ├── CborMemberDeserVisitor.java │ │ │ │ ├── CborMemberSerVisitor.java │ │ │ │ ├── CborShapeDeserVisitor.java │ │ │ │ ├── CborShapeSerVisitor.java │ │ │ │ └── SmithyRpcV2Cbor.java │ │ │ ├── schema │ │ │ ├── SchemaGenerationAllowlist.java │ │ │ ├── SchemaGenerator.java │ │ │ ├── SchemaReferenceIndex.java │ │ │ ├── SchemaTraitExtension.java │ │ │ ├── SchemaTraitFilterIndex.java │ │ │ ├── SchemaTraitGenerator.java │ │ │ └── SchemaTraitWriter.java │ │ │ ├── sections │ │ │ ├── ClientBodyExtraCodeSection.java │ │ │ ├── ClientConfigCodeSection.java │ │ │ ├── ClientConstructorCodeSection.java │ │ │ ├── ClientDestroyCodeSection.java │ │ │ ├── ClientPropertiesCodeSection.java │ │ │ ├── CommandBodyExtraCodeSection.java │ │ │ ├── CommandConstructorCodeSection.java │ │ │ ├── CommandContextCodeSection.java │ │ │ ├── CommandPropertiesCodeSection.java │ │ │ ├── PreCommandClassCodeSection.java │ │ │ └── SmithyContextCodeSection.java │ │ │ ├── util │ │ │ ├── ClientWriterConsumer.java │ │ │ ├── CommandWriterConsumer.java │ │ │ ├── PropertyAccessor.java │ │ │ └── StringStore.java │ │ │ └── validation │ │ │ ├── ImportFrom.java │ │ │ ├── LongValidator.java │ │ │ ├── ReplaceLast.java │ │ │ ├── SensitiveDataFinder.java │ │ │ └── UnaryFunctionCall.java │ └── resources │ │ ├── META-INF │ │ └── services │ │ │ ├── software.amazon.smithy.build.SmithyBuildPlugin │ │ │ └── software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration │ │ └── software │ │ └── amazon │ │ └── smithy │ │ └── typescript │ │ └── codegen │ │ ├── base-package.json │ │ ├── extensionConfiguration.template │ │ ├── framework-errors.smithy │ │ ├── integration │ │ ├── default_readme_client.md.template │ │ ├── default_readme_server.md.template │ │ └── http-api-key-auth.ts │ │ ├── malformed-request-test-regex-json-stub.ts │ │ ├── protocol-test-cbor-stub.ts │ │ ├── protocol-test-form-urlencoded-stub.ts │ │ ├── protocol-test-json-stub.ts │ │ ├── protocol-test-octet-stream-stub.ts │ │ ├── protocol-test-stub.ts │ │ ├── protocol-test-text-stub.ts │ │ ├── protocol-test-unknown-type-stub.ts │ │ ├── protocol-test-xml-stub.ts │ │ ├── reserved-words-members.txt │ │ ├── reserved-words.txt │ │ ├── resolveRuntimeExtensions1.template │ │ ├── resolveRuntimeExtensions2.template │ │ ├── runtimeConfig.browser.ts.template │ │ ├── runtimeConfig.native.ts.template │ │ ├── runtimeConfig.shared.ts.template │ │ ├── runtimeConfig.ts.template │ │ ├── runtimeExtensions1.template │ │ ├── runtimeExtensions2.template │ │ ├── tsconfig.cjs.json │ │ ├── tsconfig.es.json │ │ ├── tsconfig.json │ │ ├── tsconfig.types.json │ │ ├── typedoc.json │ │ └── vite.config.js │ └── test │ ├── java │ └── software │ │ └── amazon │ │ └── smithy │ │ └── typescript │ │ └── codegen │ │ ├── ApplicationProtocolTest.java │ │ ├── CodegenUtilsTest.java │ │ ├── CommandGeneratorTest.java │ │ ├── DefaultDefaultReadmeGeneratorTest.java │ │ ├── EnumGeneratorTest.java │ │ ├── ImportDeclarationsTest.java │ │ ├── IndexGeneratorTest.java │ │ ├── IntEnumGeneratorTest.java │ │ ├── PackageJsonGeneratorTest.java │ │ ├── RuntimeConfigGeneratorTest.java │ │ ├── ServiceBareBonesClientGeneratorTest.java │ │ ├── StructureGeneratorTest.java │ │ ├── SymbolDecoratorIntegration.java │ │ ├── SymbolProviderTest.java │ │ ├── TypeScriptCodegenPluginTest.java │ │ ├── TypeScriptDelegatorTest.java │ │ ├── TypeScriptDependencyTest.java │ │ ├── TypeScriptJmesPathVisitorTest.java │ │ ├── TypeScriptSettingsTest.java │ │ ├── TypeScriptUtilsTest.java │ │ ├── TypeScriptWriterTest.java │ │ ├── UnionGeneratorTest.java │ │ ├── documentation │ │ ├── DocumentationExampleGeneratorTest.java │ │ └── StructureExampleGeneratorTest.java │ │ ├── endpointsV2 │ │ ├── EndpointsV2GeneratorTest.java │ │ └── RuleSetParameterFinderTest.java │ │ ├── integration │ │ ├── AddHttpApiKeyAuthPluginTest.java │ │ ├── DocumentMemberDeserVisitorTest.java │ │ ├── DocumentMemberSerVisitorTest.java │ │ ├── EventStreamGeneratorTest.java │ │ ├── HttpProtocolGeneratorUtilsTest.java │ │ ├── ProtocolGeneratorTest.java │ │ └── RuntimeClientPluginTest.java │ │ ├── knowledge │ │ └── SerdeElisionIndexTest.java │ │ ├── protocols │ │ └── cbor │ │ │ ├── CborMemberDeserVisitorTest.java │ │ │ ├── CborMemberSerVisitorTest.java │ │ │ ├── CborShapeDeserVisitorTest.java │ │ │ └── CborShapeSerVisitorTest.java │ │ ├── schema │ │ ├── SchemaReferenceIndexTest.java │ │ ├── SchemaTraitExtensionTest.java │ │ ├── SchemaTraitFilterIndexTest.java │ │ ├── SchemaTraitGeneratorTest.java │ │ └── SchemaTraitWriterTest.java │ │ ├── util │ │ ├── PropertyAccessorTest.java │ │ └── StringStoreTest.java │ │ └── validation │ │ ├── ImportFromTest.java │ │ ├── LongValidatorTest.java │ │ ├── ReplaceLastTest.java │ │ ├── SensitiveDataFinderTest.java │ │ └── UnaryFunctionCallTest.java │ └── resources │ ├── META-INF │ └── services │ │ └── software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration │ └── software │ └── amazon │ └── smithy │ └── typescript │ └── codegen │ ├── endpointsV2 │ ├── endpoints-operation-context-params.smithy │ └── endpoints.smithy │ ├── error-test-empty.smithy │ ├── error-test-optional-member-no-message.smithy │ ├── error-test-optional-message.smithy │ ├── error-test-required-member-no-message.smithy │ ├── error-test-required-message.smithy │ ├── error-test-retryable-throttling.smithy │ ├── error-test-retryable.smithy │ ├── integration │ ├── endpoint-trait.smithy │ ├── http-api-key-auth-trait-all-optional.smithy │ ├── http-api-key-auth-trait-no-scheme.smithy │ ├── http-api-key-auth-trait-on-operation.smithy │ └── http-api-key-auth-trait.smithy │ ├── knowledge │ └── serde-elision.smithy │ ├── output-structure.smithy │ ├── simple-service-with-operation.smithy │ ├── simple-service.smithy │ ├── test-insensitive-list.smithy │ ├── test-insensitive-map.smithy │ ├── test-insensitive-simple-shape.smithy │ ├── test-list-with-sensitive-member.smithy │ ├── test-list-with-structure-with-sensitive-data.smithy │ ├── test-list-with-union-with-sensitive-data.smithy │ ├── test-map-with-sensitive-member.smithy │ ├── test-map-with-structure-with-sensitive-data.smithy │ ├── test-map-with-union-with-sensitive-data.smithy │ ├── test-recursive-shapes.smithy │ ├── test-required-member.smithy │ ├── test-sensitive-list.smithy │ ├── test-sensitive-map.smithy │ ├── test-sensitive-simple-shape.smithy │ ├── test-sensitive-structure.smithy │ ├── test-sensitive-union.smithy │ ├── test-streaming-union.smithy │ ├── test-structure-with-sensitive-data.smithy │ ├── test-structure-without-sensitive-data.smithy │ ├── test-union-with-list.smithy │ ├── test-union-with-map.smithy │ ├── test-union-with-sensitive-data.smithy │ ├── test-union-with-structure.smithy │ ├── test-union-without-sensitive-data.smithy │ ├── testmodel.smithy │ └── validation │ └── long-validation.smithy ├── smithy-typescript-protocol-test-codegen ├── build.gradle.kts ├── model │ └── my-local-model │ │ └── main.smithy └── smithy-build.json ├── smithy-typescript-ssdk-codegen-test-utils ├── build.gradle.kts └── src │ └── main │ ├── java │ └── software │ │ └── amazon │ │ └── smithy │ │ └── typescript │ │ └── ssdk │ │ └── codegen │ │ └── test │ │ └── utils │ │ ├── AddProtocols.java │ │ └── TestProtocolGenerator.java │ └── resources │ └── META-INF │ └── services │ └── software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration ├── smithy-typescript-ssdk-libs ├── README.md ├── server-apigateway │ ├── .gitignore │ ├── .npmignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── jest.config.js │ ├── package.json │ ├── src │ │ ├── index.ts │ │ └── lambda.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.json │ └── tsconfig.types.json ├── server-common │ ├── .gitignore │ ├── .npmignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── jest.config.js │ ├── package.json │ ├── src │ │ ├── accept.spec.ts │ │ ├── accept.ts │ │ ├── errors.ts │ │ ├── httpbinding │ │ │ ├── index.ts │ │ │ ├── mux.spec.ts │ │ │ └── mux.ts │ │ ├── index.ts │ │ ├── unique.spec.ts │ │ ├── unique.ts │ │ └── validation │ │ │ ├── index.spec.ts │ │ │ ├── index.ts │ │ │ ├── validators.spec.ts │ │ │ └── validators.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.json │ └── tsconfig.types.json └── server-node │ ├── .gitignore │ ├── .npmignore │ ├── CHANGELOG.md │ ├── LICENSE │ ├── README.md │ ├── jest.config.js │ ├── package.json │ ├── src │ ├── index.spec.ts │ ├── index.ts │ └── node.ts │ ├── tsconfig.cjs.json │ ├── tsconfig.es.json │ ├── tsconfig.json │ └── tsconfig.types.json ├── tsconfig.cjs.json ├── tsconfig.es.json ├── tsconfig.json ├── tsconfig.test.json ├── tsconfig.types.json ├── turbo.json ├── vitest.config.browser.ts ├── vitest.config.integ.ts ├── vitest.config.ts └── yarn.lock /.changeset/config.json: -------------------------------------------------------------------------------- 1 | { 2 | "$schema": "https://unpkg.com/@changesets/config@2.3.0/schema.json", 3 | "changelog": "@changesets/cli/changelog", 4 | "commit": false, 5 | "fixed": [], 6 | "linked": [], 7 | "access": "public", 8 | "baseBranch": "main", 9 | "updateInternalDependencies": "patch", 10 | "ignore": ["@aws-smithy/*"], 11 | "privatePackages": { 12 | "tag": false, 13 | "version": false 14 | } 15 | } 16 | -------------------------------------------------------------------------------- /.github/CODEOWNERS: -------------------------------------------------------------------------------- 1 | * @smithy-lang/aws-sdk-js-team 2 | 3 | -------------------------------------------------------------------------------- /.prettierignore: -------------------------------------------------------------------------------- 1 | ./packages/**/dist/* 2 | ./packages/**/dist-types/* 3 | ./packages/**/dist-es/* 4 | ./packages/**/dist-cjs/* 5 | **/dist/* 6 | **/dist-types/* 7 | **/dist-es/* 8 | **/dist-cjs/* 9 | -------------------------------------------------------------------------------- /.yarnrc.yml: -------------------------------------------------------------------------------- 1 | nodeLinker: node-modules 2 | 3 | yarnPath: .yarn/releases/yarn-4.5.3.cjs 4 | -------------------------------------------------------------------------------- /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | ## Code of Conduct 2 | This project has adopted the [Amazon Open Source Code of Conduct](https://aws.github.io/code-of-conduct). 3 | For more information see the [Code of Conduct FAQ](https://aws.github.io/code-of-conduct-faq) or contact 4 | opensource-codeofconduct@amazon.com with any additional questions or comments. 5 | -------------------------------------------------------------------------------- /NOTICE: -------------------------------------------------------------------------------- 1 | Smithy Typescript 2 | Copyright 2019 Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | -------------------------------------------------------------------------------- /api-extractor.packages.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./api-extractor.json", 3 | "docModel": { 4 | "apiJsonFilePath": "./api-extractor-packages/.api.json" 5 | }, 6 | "apiReport": { 7 | "reportFolder": "./api-extractor-packages/", 8 | "reportTempFolder": "./api-extractor-packages/" 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /gradle.properties: -------------------------------------------------------------------------------- 1 | smithyVersion=1.60.3 2 | smithyGradleVersion=1.2.0 3 | -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | distributionBase=GRADLE_USER_HOME 2 | distributionPath=wrapper/dists 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-8.13-bin.zip 4 | zipStoreBase=GRADLE_USER_HOME 5 | zipStorePath=wrapper/dists 6 | -------------------------------------------------------------------------------- /packages/abort-controller/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/abort-controller/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/abort-controller 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/abort-controller/latest.svg)](https://www.npmjs.com/package/@smithy/abort-controller) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/abort-controller.svg)](https://www.npmjs.com/package/@smithy/abort-controller) 5 | -------------------------------------------------------------------------------- /packages/abort-controller/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/abort-controller/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src", 6 | "stripInternal": true 7 | }, 8 | "extends": "../../tsconfig.cjs.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/abort-controller/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src", 7 | "stripInternal": true 8 | }, 9 | "extends": "../../tsconfig.es.json", 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /packages/abort-controller/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/abort-controller/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader-native/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader-native/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader-native/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader-native/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader-native/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/chunked-blob-reader/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/config-resolver/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/config-resolver/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/config-resolver/src/endpointsConfig/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./NodeUseDualstackEndpointConfigOptions"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./NodeUseFipsEndpointConfigOptions"; 9 | /** 10 | * @internal 11 | */ 12 | export * from "./resolveCustomEndpointsConfig"; 13 | /** 14 | * @internal 15 | */ 16 | export * from "./resolveEndpointsConfig"; 17 | -------------------------------------------------------------------------------- /packages/config-resolver/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./endpointsConfig"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./regionConfig"; 9 | /** 10 | * @internal 11 | */ 12 | export * from "./regionInfo"; 13 | -------------------------------------------------------------------------------- /packages/config-resolver/src/regionConfig/getRealRegion.ts: -------------------------------------------------------------------------------- 1 | import { isFipsRegion } from "./isFipsRegion"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const getRealRegion = (region: string) => 7 | isFipsRegion(region) 8 | ? ["fips-aws-global", "aws-fips"].includes(region) 9 | ? "us-east-1" 10 | : region.replace(/fips-(dkr-|prod-)?|-fips/, "") 11 | : region; 12 | -------------------------------------------------------------------------------- /packages/config-resolver/src/regionConfig/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./config"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./resolveRegionConfig"; 9 | -------------------------------------------------------------------------------- /packages/config-resolver/src/regionConfig/isFipsRegion.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const isFipsRegion = (region: string) => 5 | typeof region === "string" && (region.startsWith("fips-") || region.endsWith("-fips")); 6 | -------------------------------------------------------------------------------- /packages/config-resolver/src/regionInfo/EndpointVariant.ts: -------------------------------------------------------------------------------- 1 | import { EndpointVariantTag } from "./EndpointVariantTag"; 2 | 3 | /** 4 | * Provides hostname information for specific host label. 5 | * 6 | * @internal 7 | * @deprecated unused as of endpointsRuleSets. 8 | */ 9 | export type EndpointVariant = { 10 | hostname: string; 11 | tags: EndpointVariantTag[]; 12 | }; 13 | -------------------------------------------------------------------------------- /packages/config-resolver/src/regionInfo/EndpointVariantTag.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * 3 | * 4 | * The tag which mentions which area variant is providing information for. 5 | * Can be either "fips" or "dualstack". 6 | * 7 | * @internal 8 | * @deprecated unused for endpointRuleSets. 9 | */ 10 | export type EndpointVariantTag = "fips" | "dualstack"; 11 | -------------------------------------------------------------------------------- /packages/config-resolver/src/regionInfo/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./PartitionHash"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./RegionHash"; 9 | /** 10 | * @internal 11 | */ 12 | export * from "./getRegionInfo"; 13 | -------------------------------------------------------------------------------- /packages/config-resolver/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/config-resolver/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/config-resolver/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/config-resolver/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/core/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | !*.d.ts -------------------------------------------------------------------------------- /packages/core/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/core/cbor.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Do not edit: 3 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 4 | */ 5 | declare module "@smithy/core/cbor" { 6 | export * from "@smithy/core/dist-types/submodules/cbor/index.d"; 7 | } 8 | -------------------------------------------------------------------------------- /packages/core/cbor.js: -------------------------------------------------------------------------------- 1 | 2 | /** 3 | * Do not edit: 4 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 5 | */ 6 | module.exports = require("./dist-cjs/submodules/cbor/index.js"); 7 | -------------------------------------------------------------------------------- /packages/core/protocols.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Do not edit: 3 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 4 | */ 5 | declare module "@smithy/core/protocols" { 6 | export * from "@smithy/core/dist-types/submodules/protocols/index.d"; 7 | } 8 | -------------------------------------------------------------------------------- /packages/core/protocols.js: -------------------------------------------------------------------------------- 1 | 2 | /** 3 | * Do not edit: 4 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 5 | */ 6 | module.exports = require("./dist-cjs/submodules/protocols/index.js"); 7 | -------------------------------------------------------------------------------- /packages/core/schema.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Do not edit: 3 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 4 | */ 5 | declare module "@smithy/core/schema" { 6 | export * from "@smithy/core/dist-types/submodules/schema/index.d"; 7 | } 8 | -------------------------------------------------------------------------------- /packages/core/schema.js: -------------------------------------------------------------------------------- 1 | 2 | /** 3 | * Do not edit: 4 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 5 | */ 6 | module.exports = require("./dist-cjs/submodules/schema/index.js"); 7 | -------------------------------------------------------------------------------- /packages/core/serde.d.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Do not edit: 3 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 4 | */ 5 | declare module "@smithy/core/serde" { 6 | export * from "@smithy/core/dist-types/submodules/serde/index.d"; 7 | } 8 | -------------------------------------------------------------------------------- /packages/core/serde.js: -------------------------------------------------------------------------------- 1 | 2 | /** 3 | * Do not edit: 4 | * This is a compatibility redirect for contexts that do not understand package.json exports field. 5 | */ 6 | module.exports = require("./dist-cjs/submodules/serde/index.js"); 7 | -------------------------------------------------------------------------------- /packages/core/src/getSmithyContext.ts: -------------------------------------------------------------------------------- 1 | import { HandlerExecutionContext, SMITHY_CONTEXT_KEY } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const getSmithyContext = (context: HandlerExecutionContext): Record => 7 | context[SMITHY_CONTEXT_KEY] || (context[SMITHY_CONTEXT_KEY] = {}); 8 | -------------------------------------------------------------------------------- /packages/core/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./getSmithyContext"; 2 | export * from "./middleware-http-auth-scheme"; 3 | export * from "./middleware-http-signing"; 4 | export * from "./normalizeProvider"; 5 | export { createPaginator } from "./pagination/createPaginator"; 6 | export * from "./protocols/requestBuilder"; 7 | export * from "./setFeature"; 8 | export * from "./util-identity-and-auth"; 9 | -------------------------------------------------------------------------------- /packages/core/src/middleware-http-auth-scheme/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./httpAuthSchemeMiddleware"; 2 | export * from "./getHttpAuthSchemeEndpointRuleSetPlugin"; 3 | export * from "./getHttpAuthSchemePlugin"; 4 | -------------------------------------------------------------------------------- /packages/core/src/middleware-http-signing/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./httpSigningMiddleware"; 2 | export * from "./getHttpSigningMiddleware"; 3 | -------------------------------------------------------------------------------- /packages/core/src/protocols/requestBuilder.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * Backwards compatibility re-export. 4 | */ 5 | export { requestBuilder } from "@smithy/core/protocols"; 6 | -------------------------------------------------------------------------------- /packages/core/src/submodules/cbor/byte-printer.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Prints bytes as binary string with numbers. 3 | * @param bytes - to print. 4 | * @deprecated for testing only, do not use in runtime. 5 | */ 6 | export function printBytes(bytes: Uint8Array) { 7 | return [...bytes].map((n) => ("0".repeat(8) + n.toString(2)).slice(-8) + ` (${n})`); 8 | } 9 | -------------------------------------------------------------------------------- /packages/core/src/submodules/cbor/index.ts: -------------------------------------------------------------------------------- 1 | export { cbor } from "./cbor"; 2 | export { tag, tagSymbol } from "./cbor-types"; 3 | export * from "./parseCborBody"; 4 | export * from "./SmithyRpcV2CborProtocol"; 5 | export * from "./CborCodec"; 6 | -------------------------------------------------------------------------------- /packages/core/src/submodules/schema/deref.ts: -------------------------------------------------------------------------------- 1 | import type { Schema, SchemaRef } from "@smithy/types"; 2 | 3 | /** 4 | * Dereferences a SchemaRef if needed. 5 | * @internal 6 | */ 7 | export const deref = (schemaRef: SchemaRef): Schema => { 8 | if (typeof schemaRef === "function") { 9 | return schemaRef(); 10 | } 11 | return schemaRef; 12 | }; 13 | -------------------------------------------------------------------------------- /packages/core/src/submodules/schema/middleware/schema-middleware-types.ts: -------------------------------------------------------------------------------- 1 | import type { ClientProtocol, SerdeContext, UrlParser } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export type PreviouslyResolved = Omit< 7 | SerdeContext & { 8 | urlParser: UrlParser; 9 | protocol: ClientProtocol; 10 | }, 11 | "endpoint" 12 | >; 13 | -------------------------------------------------------------------------------- /packages/core/src/submodules/schema/schemas/Schema.ts: -------------------------------------------------------------------------------- 1 | import type { SchemaTraits, TraitsSchema } from "@smithy/types"; 2 | 3 | /** 4 | * Abstract base for class-based Schema except NormalizedSchema. 5 | * 6 | * @alpha 7 | */ 8 | export abstract class Schema implements TraitsSchema { 9 | protected constructor( 10 | public name: string, 11 | public traits: SchemaTraits 12 | ) {} 13 | } 14 | -------------------------------------------------------------------------------- /packages/core/src/submodules/serde/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./copyDocumentWithTransform"; 2 | export * from "./date-utils"; 3 | export * from "./lazy-json"; 4 | export * from "./parse-utils"; 5 | export * from "./quote-header"; 6 | export * from "./split-every"; 7 | export * from "./split-header"; 8 | export * from "./value/NumericValue"; 9 | -------------------------------------------------------------------------------- /packages/core/src/submodules/serde/quote-header.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @public 3 | * @param part - header list element 4 | * @returns quoted string if part contains delimiter. 5 | */ 6 | export function quoteHeader(part: string) { 7 | if (part.includes(",") || part.includes('"')) { 8 | part = `"${part.replace(/"/g, '\\"')}"`; 9 | } 10 | return part; 11 | } 12 | -------------------------------------------------------------------------------- /packages/core/src/util-identity-and-auth/httpAuthSchemes/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./httpApiKeyAuth"; 2 | export * from "./httpBearerAuth"; 3 | export * from "./noAuth"; 4 | -------------------------------------------------------------------------------- /packages/core/src/util-identity-and-auth/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./DefaultIdentityProviderConfig"; 2 | export * from "./httpAuthSchemes"; 3 | export * from "./memoizeIdentityProvider"; 4 | -------------------------------------------------------------------------------- /packages/core/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | hideSkippedTests: true, 9 | }, 10 | }); 11 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/src/config/Endpoint.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export enum Endpoint { 5 | IPv4 = "http://169.254.169.254", 6 | IPv6 = "http://[fd00:ec2::254]", 7 | } 8 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/src/config/EndpointMode.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export enum EndpointMode { 5 | IPv4 = "IPv4", 6 | IPv6 = "IPv6", 7 | } 8 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/src/remoteProvider/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./ImdsCredentials"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./RemoteProviderInit"; 9 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/src/types.ts: -------------------------------------------------------------------------------- 1 | import { AwsCredentialIdentity } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export interface InstanceMetadataCredentials extends AwsCredentialIdentity { 7 | readonly originalExpiration?: Date; 8 | } 9 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/credential-provider-imds/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/eventstream-codec/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/eventstream-codec/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/eventstream-codec 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/eventstream-codec/latest.svg)](https://www.npmjs.com/package/@smithy/eventstream-codec) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/eventstream-codec.svg)](https://www.npmjs.com/package/@smithy/eventstream-codec) 5 | -------------------------------------------------------------------------------- /packages/eventstream-codec/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./EventStreamCodec"; 2 | export * from "./HeaderMarshaller"; 3 | export * from "./Int64"; 4 | export * from "./Message"; 5 | export * from "./MessageDecoderStream"; 6 | export * from "./MessageEncoderStream"; 7 | export * from "./SmithyMessageDecoderStream"; 8 | export * from "./SmithyMessageEncoderStream"; 9 | -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/negative/corrupted_header_len: -------------------------------------------------------------------------------- 1 | Prelude checksum mismatch -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/negative/corrupted_headers: -------------------------------------------------------------------------------- 1 | Message checksum mismatch -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/negative/corrupted_length: -------------------------------------------------------------------------------- 1 | Prelude checksum mismatch -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/negative/corrupted_payload: -------------------------------------------------------------------------------- 1 | Message checksum mismatch -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/positive/empty_message: -------------------------------------------------------------------------------- 1 | { 2 | "total_length": 16, 3 | "headers_length": 0, 4 | "prelude_crc": 96618731, 5 | "headers": [ ], 6 | "payload": "", 7 | "message_crc": 2107164927 8 | } 9 | -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/positive/int32_header: -------------------------------------------------------------------------------- 1 | { 2 | "total_length": 45, 3 | "headers_length": 16, 4 | "prelude_crc": 1103373496, 5 | "headers": [ { 6 | "name": "event-type", 7 | "type": 4, 8 | "value": 40972 9 | } 10 | ], 11 | "payload": "eydmb28nOidiYXInfQ==", 12 | "message_crc": 921993376 13 | } 14 | -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/positive/payload_no_headers: -------------------------------------------------------------------------------- 1 | { 2 | "total_length": 29, 3 | "headers_length": 0, 4 | "prelude_crc": -44921766, 5 | "headers": [ ], 6 | "payload": "eydmb28nOidiYXInfQ==", 7 | "message_crc": -1016776394 8 | } 9 | -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/decoded/positive/payload_one_str_header: -------------------------------------------------------------------------------- 1 | { 2 | "total_length": 61, 3 | "headers_length": 32, 4 | "prelude_crc": 134054806, 5 | "headers": [ { 6 | "name": "content-type", 7 | "type": 7, 8 | "value": "YXBwbGljYXRpb24vanNvbg==" 9 | } 10 | ], 11 | "payload": "eydmb28nOidiYXInfQ==", 12 | "message_crc": -1919153999 13 | } 14 | -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/negative/corrupted_header_len: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/negative/corrupted_header_len -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/negative/corrupted_headers: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/negative/corrupted_headers -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/negative/corrupted_length: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/negative/corrupted_length -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/negative/corrupted_payload: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/negative/corrupted_payload -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/positive/all_headers: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/positive/all_headers -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/positive/empty_message: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/positive/empty_message -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/positive/int32_header: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/positive/int32_header -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/positive/payload_no_headers: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/positive/payload_no_headers -------------------------------------------------------------------------------- /packages/eventstream-codec/test_vectors/encoded/positive/payload_one_str_header: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/smithy-lang/smithy-typescript/d633bf1fb52c0ed2e4f3fb0fbbd0dfd74f7ff266/packages/eventstream-codec/test_vectors/encoded/positive/payload_one_str_header -------------------------------------------------------------------------------- /packages/eventstream-codec/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-codec/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/eventstream-codec/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-codec/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-browser/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/eventstream-serde-browser/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./EventStreamMarshaller"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./provider"; 9 | /** 10 | * @internal 11 | */ 12 | export * from "./utils"; 13 | -------------------------------------------------------------------------------- /packages/eventstream-serde-browser/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-browser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["DOM"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/eventstream-serde-browser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./EventStreamSerdeConfig"; 5 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-config-resolver/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-node/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/eventstream-serde-node/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./EventStreamMarshaller"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./provider"; 9 | -------------------------------------------------------------------------------- /packages/eventstream-serde-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/eventstream-serde-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-universal/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/eventstream-serde-universal/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./EventStreamMarshaller"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./provider"; 9 | -------------------------------------------------------------------------------- /packages/eventstream-serde-universal/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-universal/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/eventstream-serde-universal/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/eventstream-serde-universal/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/src/apiKeyIdentity.ts: -------------------------------------------------------------------------------- 1 | import { Identity, IdentityProvider } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export interface ApiKeyIdentity extends Identity { 7 | readonly apiKey: string; 8 | } 9 | 10 | /** 11 | * @internal 12 | */ 13 | export type ApiKeyIdentityProvider = IdentityProvider; 14 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/src/middleware-http-auth-scheme/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./httpAuthSchemeMiddleware"; 2 | export * from "./getHttpAuthSchemeEndpointRuleSetPlugin"; 3 | export * from "./getHttpAuthSchemePlugin"; 4 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/src/middleware-http-signing/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./httpSigningMiddleware"; 2 | export * from "./getHttpSigningMiddleware"; 3 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/src/tokenIdentity.ts: -------------------------------------------------------------------------------- 1 | import { Identity, IdentityProvider } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export interface TokenIdentity extends Identity { 7 | /** 8 | * The literal token string 9 | */ 10 | readonly token: string; 11 | } 12 | 13 | /** 14 | * @internal 15 | */ 16 | export type TokenIdentityProvider = IdentityProvider; 17 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/tsconfig.test.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "rootDir": "src", 5 | "noEmit": true 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"], 9 | "exclude": [] 10 | } 11 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/experimental-identity-and-auth/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/src/create-request.ts: -------------------------------------------------------------------------------- 1 | import { AdditionalRequestParameters } from "./fetch-http-handler"; 2 | 3 | /** 4 | * @internal 5 | * For mocking/interception. 6 | */ 7 | export function createRequest(url: string, requestOptions?: RequestInit & AdditionalRequestParameters) { 8 | return new Request(url, requestOptions); 9 | } 10 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/src/index.spec.ts: -------------------------------------------------------------------------------- 1 | import { describe, expect, test as it } from "vitest"; 2 | 3 | import { FetchHttpHandler } from "./index"; 4 | 5 | describe("index", () => { 6 | it("exports FetchHttpHandler", () => { 7 | expect(typeof FetchHttpHandler).toBe("function"); 8 | }); 9 | }); 10 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./fetch-http-handler"; 2 | export * from "./stream-collector"; 3 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/vitest.config.browser.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/fetch-http-handler/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/hash-blob-browser/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/hash-blob-browser/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/hash-blob-browser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/hash-blob-browser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/hash-blob-browser/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/hash-node/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/hash-node/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/md5-node 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/hash-node/latest.svg)](https://www.npmjs.com/package/@smithy/hash-node) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/hash-node.svg)](https://www.npmjs.com/package/@smithy/hash-node) 5 | 6 | > An internal package 7 | 8 | ## Usage 9 | 10 | You probably shouldn't, at least directly. 11 | -------------------------------------------------------------------------------- /packages/hash-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/hash-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/hash-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/hash-node/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/hash-stream-node/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/hash-stream-node/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./fileStreamHasher"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./readableStreamHasher"; 9 | -------------------------------------------------------------------------------- /packages/hash-stream-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/hash-stream-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/hash-stream-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/hash-stream-node/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/invalid-dependency/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/invalid-dependency/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./invalidFunction"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./invalidProvider"; 9 | -------------------------------------------------------------------------------- /packages/invalid-dependency/src/invalidFunction.spec.ts: -------------------------------------------------------------------------------- 1 | import { describe, expect, test as it } from "vitest"; 2 | 3 | import { invalidFunction } from "./invalidFunction"; 4 | 5 | describe("invalidFunction", () => { 6 | it("throws error with message", () => { 7 | const message = "Error"; 8 | expect(invalidFunction(message)).toThrowError(new Error(message)); 9 | }); 10 | }); 11 | -------------------------------------------------------------------------------- /packages/invalid-dependency/src/invalidFunction.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const invalidFunction = (message: string) => () => { 5 | throw new Error(message); 6 | }; 7 | -------------------------------------------------------------------------------- /packages/invalid-dependency/src/invalidProvider.ts: -------------------------------------------------------------------------------- 1 | import { Provider } from "@smithy/types"; 2 | /** 3 | * @internal 4 | */ 5 | export const invalidProvider: (message: string) => Provider = (message: string) => () => Promise.reject(message); 6 | -------------------------------------------------------------------------------- /packages/invalid-dependency/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/invalid-dependency/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/invalid-dependency/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/invalid-dependency/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/is-array-buffer/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/is-array-buffer/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const isArrayBuffer = (arg: any): arg is ArrayBuffer => 5 | (typeof ArrayBuffer === "function" && arg instanceof ArrayBuffer) || 6 | Object.prototype.toString.call(arg) === "[object ArrayBuffer]"; 7 | -------------------------------------------------------------------------------- /packages/is-array-buffer/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/is-array-buffer/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/is-array-buffer/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/is-array-buffer/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/md5-js/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/md5-js/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/md5-js 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/md5-js/latest.svg)](https://www.npmjs.com/package/@smithy/md5-js) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/md5-js.svg)](https://www.npmjs.com/package/@smithy/md5-js) 5 | 6 | > An internal package 7 | 8 | ## Usage 9 | 10 | You probably shouldn't, at least directly. 11 | -------------------------------------------------------------------------------- /packages/md5-js/src/constants.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const BLOCK_SIZE = 64; 5 | 6 | /** 7 | * @internal 8 | */ 9 | export const DIGEST_LENGTH = 16; 10 | 11 | /** 12 | * @internal 13 | */ 14 | export const INIT = [0x67452301, 0xefcdab89, 0x98badcfe, 0x10325476]; 15 | -------------------------------------------------------------------------------- /packages/md5-js/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "include": ["src/"], 8 | "extends": "../../tsconfig.cjs.json" 9 | } 10 | -------------------------------------------------------------------------------- /packages/md5-js/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "include": ["src/"], 9 | "extends": "../../tsconfig.es.json" 10 | } 11 | -------------------------------------------------------------------------------- /packages/md5-js/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/md5-js/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./applyMd5BodyChecksumMiddleware"; 2 | export * from "./md5Configuration"; 3 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/middleware-apply-body-checksum/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/middleware-compression/src/compressStream.ts: -------------------------------------------------------------------------------- 1 | import { Readable } from "stream"; 2 | import { createGzip } from "zlib"; 3 | 4 | export const compressStream = async (body: Readable): Promise => body.pipe(createGzip()); 5 | -------------------------------------------------------------------------------- /packages/middleware-compression/src/constants.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Compression Algorithms supported by the SDK. 3 | */ 4 | export enum CompressionAlgorithm { 5 | GZIP = "gzip", 6 | } 7 | 8 | export const CLIENT_SUPPORTED_ALGORITHMS: CompressionAlgorithm[] = [CompressionAlgorithm.GZIP]; 9 | -------------------------------------------------------------------------------- /packages/middleware-compression/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./NODE_DISABLE_REQUEST_COMPRESSION_CONFIG_OPTIONS"; 2 | export * from "./NODE_REQUEST_MIN_COMPRESSION_SIZE_BYTES_CONFIG_OPTIONS"; 3 | export * from "./compressionMiddleware"; 4 | export * from "./configurations"; 5 | export * from "./getCompressionPlugin"; 6 | export * from "./resolveCompressionConfig"; 7 | -------------------------------------------------------------------------------- /packages/middleware-compression/src/isStreaming.ts: -------------------------------------------------------------------------------- 1 | import { isArrayBuffer } from "@smithy/is-array-buffer"; 2 | 3 | /** 4 | * Returns true if the given value is a streaming response. 5 | */ 6 | export const isStreaming = (body: unknown) => 7 | body !== undefined && typeof body !== "string" && !ArrayBuffer.isView(body) && !isArrayBuffer(body); 8 | -------------------------------------------------------------------------------- /packages/middleware-compression/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-compression/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-compression/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-compression/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | 9 | }, 10 | }); 11 | -------------------------------------------------------------------------------- /packages/middleware-content-length/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/middleware-content-length/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/middleware-content-length 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/middleware-content-length/latest.svg)](https://www.npmjs.com/package/@smithy/middleware-content-length) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/middleware-content-length.svg)](https://www.npmjs.com/package/@smithy/middleware-content-length) 5 | -------------------------------------------------------------------------------- /packages/middleware-content-length/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-content-length/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-content-length/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-content-length/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/src/adaptors/getEndpointFromConfig.browser.ts: -------------------------------------------------------------------------------- 1 | // eslint-disable-next-line @typescript-eslint/no-unused-vars 2 | export const getEndpointFromConfig = async (serviceId: string) => undefined; 3 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/src/adaptors/getEndpointFromConfig.ts: -------------------------------------------------------------------------------- 1 | import { loadConfig } from "@smithy/node-config-provider"; 2 | 3 | import { getEndpointUrlConfig } from "./getEndpointUrlConfig"; 4 | 5 | /** 6 | * @internal 7 | */ 8 | export const getEndpointFromConfig = async (serviceId?: string) => loadConfig(getEndpointUrlConfig(serviceId ?? ""))(); 9 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/src/adaptors/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./getEndpointFromInstructions"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./toEndpointV1"; 9 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./adaptors"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./endpointMiddleware"; 9 | /** 10 | * @internal 11 | */ 12 | export * from "./getEndpointPlugin"; 13 | export * from "./resolveEndpointConfig"; 14 | export * from "./resolveEndpointRequiredConfig"; 15 | /** 16 | * @internal 17 | */ 18 | export * from "./types"; 19 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/src/service-customizations/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./s3"; 5 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-endpoint/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/middleware-retry/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/middleware-retry/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/middleware-retry/src/delayDecider.ts: -------------------------------------------------------------------------------- 1 | import { MAXIMUM_RETRY_DELAY } from "@smithy/util-retry"; 2 | 3 | /** 4 | * @internal 5 | * Calculate a capped, fully-jittered exponential backoff time. 6 | */ 7 | export const defaultDelayDecider = (delayBase: number, attempts: number) => 8 | Math.floor(Math.min(MAXIMUM_RETRY_DELAY, Math.random() * 2 ** attempts * delayBase)); 9 | -------------------------------------------------------------------------------- /packages/middleware-retry/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./AdaptiveRetryStrategy"; 2 | export * from "./StandardRetryStrategy"; 3 | export * from "./configurations"; 4 | export * from "./delayDecider"; 5 | export * from "./omitRetryHeadersMiddleware"; 6 | export * from "./retryDecider"; 7 | export * from "./retryMiddleware"; 8 | -------------------------------------------------------------------------------- /packages/middleware-retry/src/isStreamingPayload/isStreamingPayload.browser.ts: -------------------------------------------------------------------------------- 1 | import type { HttpRequest } from "@smithy/protocol-http"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const isStreamingPayload = (request: HttpRequest): boolean => request?.body instanceof ReadableStream; 7 | -------------------------------------------------------------------------------- /packages/middleware-retry/src/isStreamingPayload/isStreamingPayload.ts: -------------------------------------------------------------------------------- 1 | import type { HttpRequest } from "@smithy/protocol-http"; 2 | import { Readable } from "stream"; 3 | 4 | /** 5 | * @internal 6 | */ 7 | export const isStreamingPayload = (request: HttpRequest): boolean => 8 | request?.body instanceof Readable || 9 | (typeof ReadableStream !== "undefined" && request?.body instanceof ReadableStream); 10 | -------------------------------------------------------------------------------- /packages/middleware-retry/src/util.ts: -------------------------------------------------------------------------------- 1 | import { SdkError } from "@smithy/types"; 2 | 3 | export const asSdkError = (error: unknown): SdkError => { 4 | if (error instanceof Error) return error; 5 | if (error instanceof Object) return Object.assign(new Error(), error); 6 | if (typeof error === "string") return new Error(error); 7 | return new Error(`AWS SDK error wrapper for ${error}`); 8 | }; 9 | -------------------------------------------------------------------------------- /packages/middleware-retry/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "noUnusedLocals": true, 5 | "outDir": "dist-cjs", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.cjs.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-retry/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "noUnusedLocals": true, 6 | "outDir": "dist-es", 7 | "rootDir": "src" 8 | }, 9 | "extends": "../../tsconfig.es.json", 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /packages/middleware-retry/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-retry/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/middleware-retry/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/middleware-serde/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/middleware-serde/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/middleware-serde 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/middleware-serde/latest.svg)](https://www.npmjs.com/package/@smithy/middleware-serde) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/middleware-serde.svg)](https://www.npmjs.com/package/@smithy/middleware-serde) 5 | -------------------------------------------------------------------------------- /packages/middleware-serde/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./deserializerMiddleware"; 2 | export * from "./serdePlugin"; 3 | export * from "./serializerMiddleware"; 4 | -------------------------------------------------------------------------------- /packages/middleware-serde/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-serde/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-serde/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-serde/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/middleware-serde/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/middleware-stack/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/middleware-stack/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/middleware-stack/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./MiddlewareStack"; 2 | -------------------------------------------------------------------------------- /packages/middleware-stack/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-stack/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/middleware-stack/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/middleware-stack/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/node-config-provider/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./configLoader"; 2 | export { EnvOptions, GetterFromEnv } from "./fromEnv"; 3 | export { GetterFromConfig, SharedConfigInit } from "./fromSharedConfigFiles"; 4 | export { FromStaticConfig } from "./fromStatic"; 5 | -------------------------------------------------------------------------------- /packages/node-config-provider/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/node-config-provider/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/node-config-provider/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/node-config-provider/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/node-http-handler/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/node-http-handler/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/node-http-handler/src/constants.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Node.js system error codes that indicate timeout. 3 | * @deprecated use NODEJS_TIMEOUT_ERROR_CODES from @smithy/service-error-classification/constants 4 | */ 5 | export const NODEJS_TIMEOUT_ERROR_CODES = ["ECONNRESET", "EPIPE", "ETIMEDOUT"]; 6 | -------------------------------------------------------------------------------- /packages/node-http-handler/src/index.spec.ts: -------------------------------------------------------------------------------- 1 | import { describe, expect, test as it } from "vitest"; 2 | 3 | import { NodeHttpHandler } from "./index"; 4 | 5 | describe("index", () => { 6 | it("exports NodeHttpHandler", () => { 7 | expect(typeof NodeHttpHandler).toBe("function"); 8 | }); 9 | }); 10 | -------------------------------------------------------------------------------- /packages/node-http-handler/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./node-http-handler"; 2 | export * from "./node-http2-handler"; 3 | export * from "./stream-collector"; 4 | -------------------------------------------------------------------------------- /packages/node-http-handler/src/stream-collector/collector.ts: -------------------------------------------------------------------------------- 1 | import { Writable } from "stream"; 2 | export class Collector extends Writable { 3 | public readonly bufferedBytes: Buffer[] = []; 4 | _write(chunk: Buffer, encoding: string, callback: (err?: Error) => void) { 5 | this.bufferedBytes.push(chunk); 6 | callback(); 7 | } 8 | } 9 | -------------------------------------------------------------------------------- /packages/node-http-handler/src/timing.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * For test spies. 4 | */ 5 | export const timing = { 6 | setTimeout: (cb: (...ignored: any[]) => void | unknown, ms?: number) => setTimeout(cb, ms), 7 | clearTimeout: (timeoutId: string | number | undefined | unknown) => 8 | clearTimeout(timeoutId as Parameters[0]), 9 | }; 10 | -------------------------------------------------------------------------------- /packages/node-http-handler/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/node-http-handler/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/node-http-handler/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/node-http-handler/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/property-provider/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/property-provider/src/fromStatic.ts: -------------------------------------------------------------------------------- 1 | import { Provider } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const fromStatic = 7 | (staticValue: T): Provider => 8 | () => 9 | Promise.resolve(staticValue); 10 | -------------------------------------------------------------------------------- /packages/property-provider/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/property-provider/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/property-provider/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/property-provider/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/protocol-http/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/protocol-http/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/protocol-http 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/protocol-http/latest.svg)](https://www.npmjs.com/package/@smithy/protocol-http) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/protocol-http.svg)](https://www.npmjs.com/package/@smithy/protocol-http) 5 | -------------------------------------------------------------------------------- /packages/protocol-http/src/extensions/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./httpExtensionConfiguration"; 2 | -------------------------------------------------------------------------------- /packages/protocol-http/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./extensions"; 2 | export * from "./Field"; 3 | export * from "./Fields"; 4 | export * from "./httpHandler"; 5 | export * from "./httpRequest"; 6 | export * from "./httpResponse"; 7 | export * from "./isValidHostname"; 8 | export * from "./types"; 9 | -------------------------------------------------------------------------------- /packages/protocol-http/src/isValidHostname.ts: -------------------------------------------------------------------------------- 1 | export function isValidHostname(hostname: string): boolean { 2 | const hostPattern = /^[a-z0-9][a-z0-9\.\-]*[a-z0-9]$/; 3 | return hostPattern.test(hostname); 4 | } 5 | -------------------------------------------------------------------------------- /packages/protocol-http/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/protocol-http/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/protocol-http/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/protocol-http/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/querystring-builder/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/querystring-builder/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/querystring-builder/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/querystring-builder/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/querystring-parser/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/querystring-parser/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/querystring-parser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/querystring-parser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/querystring-parser/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/service-client-documentation-generator/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/service-client-documentation-generator/src/utils.ts: -------------------------------------------------------------------------------- 1 | import { sep } from "path"; 2 | import { Reflection } from "typedoc"; 3 | 4 | /** 5 | * @internal 6 | */ 7 | export const isClientModel = (model: Reflection | undefined) => 8 | model?.sources?.[0]?.fullFileName.includes(`${sep}clients${sep}`); 9 | -------------------------------------------------------------------------------- /packages/service-client-documentation-generator/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "experimentalDecorators": true, 5 | "outDir": "dist-cjs", 6 | "pretty": true, 7 | "rootDir": "src", 8 | "strict": false 9 | }, 10 | "extends": "../../tsconfig.cjs.json", 11 | "include": ["src/"] 12 | } 13 | -------------------------------------------------------------------------------- /packages/service-client-documentation-generator/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "experimentalDecorators": true, 5 | "lib": [], 6 | "outDir": "dist-es", 7 | "pretty": true, 8 | "rootDir": "src", 9 | "strict": false 10 | }, 11 | "extends": "../../tsconfig.es.json", 12 | "include": ["src/"] 13 | } 14 | -------------------------------------------------------------------------------- /packages/service-client-documentation-generator/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "experimentalDecorators": true, 6 | "rootDir": "src", 7 | "strict": false 8 | }, 9 | "extends": "../../tsconfig.types.json", 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /packages/service-error-classification/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/service-error-classification/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/service-error-classification 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/service-error-classification/latest.svg)](https://www.npmjs.com/package/@smithy/service-error-classification) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/service-error-classification.svg)](https://www.npmjs.com/package/@smithy/service-error-classification) 5 | -------------------------------------------------------------------------------- /packages/service-error-classification/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "noUnusedLocals": true, 5 | "outDir": "dist-cjs", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.cjs.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/service-error-classification/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "noUnusedLocals": true, 6 | "outDir": "dist-es", 7 | "rootDir": "src" 8 | }, 9 | "extends": "../../tsconfig.es.json", 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /packages/service-error-classification/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/service-error-classification/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/src/getConfigFilepath.ts: -------------------------------------------------------------------------------- 1 | import { join } from "path"; 2 | 3 | import { getHomeDir } from "./getHomeDir"; 4 | 5 | export const ENV_CONFIG_PATH = "AWS_CONFIG_FILE"; 6 | 7 | export const getConfigFilepath = () => process.env[ENV_CONFIG_PATH] || join(getHomeDir(), ".aws", "config"); 8 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/src/getCredentialsFilepath.ts: -------------------------------------------------------------------------------- 1 | import { join } from "path"; 2 | 3 | import { getHomeDir } from "./getHomeDir"; 4 | 5 | export const ENV_CREDENTIALS_PATH = "AWS_SHARED_CREDENTIALS_FILE"; 6 | 7 | export const getCredentialsFilepath = () => 8 | process.env[ENV_CREDENTIALS_PATH] || join(getHomeDir(), ".aws", "credentials"); 9 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./getHomeDir"; 2 | export * from "./getProfileName"; 3 | export * from "./getSSOTokenFilepath"; 4 | export * from "./getSSOTokenFromFile"; 5 | export * from "./loadSharedConfigFiles"; 6 | export * from "./loadSsoSessionData"; 7 | export * from "./parseKnownFiles"; 8 | export * from "./types"; 9 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/shared-ini-file-loader/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/signature-v4/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /dist/ 4 | /coverage/ 5 | /docs/ 6 | *.tsbuildinfo 7 | *.tgz 8 | *.log 9 | package-lock.json 10 | -------------------------------------------------------------------------------- /packages/signature-v4/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/signature-v4/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src", 6 | "stripInternal": true 7 | }, 8 | "extends": "../../tsconfig.cjs.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/signature-v4/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "noUnusedLocals": true, 6 | "outDir": "dist-es", 7 | "rootDir": "src", 8 | "stripInternal": true 9 | }, 10 | "extends": "../../tsconfig.es.json", 11 | "include": ["src/"] 12 | } 13 | -------------------------------------------------------------------------------- /packages/signature-v4/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/signature-v4/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/signature-v4a/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /dist/ 4 | /coverage/ 5 | /docs/ 6 | *.tsbuildinfo 7 | *.tgz 8 | *.log 9 | package-lock.json 10 | -------------------------------------------------------------------------------- /packages/signature-v4a/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/signature-v4a 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/signature-v4a/latest.svg)](https://www.npmjs.com/package/@smithy/signature-v4a) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/signature-v4a.svg)](https://www.npmjs.com/package/@smithy/signature-v4a) 5 | 6 | This package is an internal SigV4a addon for AWS Signature Version 4 (SigV4). 7 | -------------------------------------------------------------------------------- /packages/signature-v4a/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/signature-v4a/scripts/Ec.js: -------------------------------------------------------------------------------- 1 | export { ec as Ec } from "elliptic"; 2 | -------------------------------------------------------------------------------- /packages/signature-v4a/src/index.ts: -------------------------------------------------------------------------------- 1 | import { signatureV4aContainer } from "@smithy/signature-v4"; 2 | 3 | import { SignatureV4a } from "./SignatureV4a"; 4 | 5 | signatureV4aContainer.SignatureV4a = SignatureV4a; 6 | 7 | export * from "./SignatureV4a"; 8 | -------------------------------------------------------------------------------- /packages/signature-v4a/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src", 6 | "stripInternal": true 7 | }, 8 | "extends": "../../tsconfig.cjs.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/signature-v4a/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "noUnusedLocals": true, 6 | "outDir": "dist-es", 7 | "rootDir": "src", 8 | "stripInternal": true 9 | }, 10 | "extends": "../../tsconfig.es.json", 11 | "include": ["src/"] 12 | } 13 | -------------------------------------------------------------------------------- /packages/signature-v4a/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/signature-v4a/vitest.config.js: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vitest/config'; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ['**/node_modules/**', '**/es/**'], 6 | }, 7 | }); 8 | -------------------------------------------------------------------------------- /packages/smithy-client/.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "plugins": ["eslint-plugin-tsdoc"], 3 | "rules": { 4 | "tsdoc/syntax": "warn" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /packages/smithy-client/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/smithy-client/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/smithy-client 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/smithy-client/latest.svg)](https://www.npmjs.com/package/@smithy/smithy-client) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/smithy-client.svg)](https://www.npmjs.com/package/@smithy/smithy-client) 5 | 6 | > An internal package 7 | 8 | ## Usage 9 | 10 | You probably shouldn't, at least directly. 11 | -------------------------------------------------------------------------------- /packages/smithy-client/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/smithy-client/src/NoOpLogger.ts: -------------------------------------------------------------------------------- 1 | import { Logger } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export class NoOpLogger implements Logger { 7 | public trace() {} 8 | public debug() {} 9 | public info() {} 10 | public warn() {} 11 | public error() {} 12 | } 13 | -------------------------------------------------------------------------------- /packages/smithy-client/src/collect-stream-body.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * Backwards compatibility re-export. 4 | */ 5 | export { collectBody } from "@smithy/core/protocols"; 6 | -------------------------------------------------------------------------------- /packages/smithy-client/src/constants.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const SENSITIVE_STRING = "***SensitiveInformation***"; 5 | -------------------------------------------------------------------------------- /packages/smithy-client/src/extended-encode-uri-component.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * Backwards compatibility re-export. 4 | */ 5 | export { extendedEncodeURIComponent } from "@smithy/core/protocols"; 6 | -------------------------------------------------------------------------------- /packages/smithy-client/src/extensions/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./defaultExtensionConfiguration"; 2 | -------------------------------------------------------------------------------- /packages/smithy-client/src/get-array-if-single-item.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * 4 | * The XML parser will set one K:V for a member that could 5 | * return multiple entries but only has one. 6 | */ 7 | export const getArrayIfSingleItem = (mayBeArray: T): T | T[] => 8 | Array.isArray(mayBeArray) ? mayBeArray : [mayBeArray]; 9 | -------------------------------------------------------------------------------- /packages/smithy-client/src/is-serializable-header-value.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * @returns whether the header value is serializable. 4 | */ 5 | export const isSerializableHeaderValue = (value: any) => { 6 | return value != null; 7 | }; 8 | -------------------------------------------------------------------------------- /packages/smithy-client/src/resolve-path.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * Backwards compatibility re-export. 4 | */ 5 | export { resolvedPath } from "@smithy/core/protocols"; 6 | -------------------------------------------------------------------------------- /packages/smithy-client/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "noUnusedLocals": true, 5 | "outDir": "dist-cjs", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.cjs.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/smithy-client/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "noUnusedLocals": true, 6 | "outDir": "dist-es", 7 | "rootDir": "src" 8 | }, 9 | "extends": "../../tsconfig.es.json", 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /packages/smithy-client/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/smithy-client/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/types/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/types/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/types/src/abort-handler.ts: -------------------------------------------------------------------------------- 1 | import type { AbortSignal as DeprecatedAbortSignal } from "./abort"; 2 | 3 | /** 4 | * @public 5 | */ 6 | export interface AbortHandler { 7 | (this: AbortSignal | DeprecatedAbortSignal, ev: any): any; 8 | } 9 | -------------------------------------------------------------------------------- /packages/types/src/auth/HttpApiKeyAuth.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export enum HttpApiKeyAuthLocation { 5 | HEADER = "header", 6 | QUERY = "query", 7 | } 8 | -------------------------------------------------------------------------------- /packages/types/src/auth/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./auth"; 2 | export * from "./HttpApiKeyAuth"; 3 | export * from "./HttpAuthScheme"; 4 | export * from "./HttpAuthSchemeProvider"; 5 | export * from "./HttpSigner"; 6 | export * from "./IdentityProviderConfig"; 7 | -------------------------------------------------------------------------------- /packages/types/src/connection/config.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @public 3 | */ 4 | export interface ConnectConfiguration { 5 | /** 6 | * The maximum time in milliseconds that the connection phase of a request 7 | * may take before the connection attempt is abandoned. 8 | */ 9 | requestTimeout?: number; 10 | } 11 | -------------------------------------------------------------------------------- /packages/types/src/connection/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./config"; 2 | export * from "./manager"; 3 | export * from "./pool"; 4 | -------------------------------------------------------------------------------- /packages/types/src/endpoints/ErrorRuleObject.ts: -------------------------------------------------------------------------------- 1 | import { ConditionObject, Expression } from "./shared"; 2 | 3 | /** 4 | * @public 5 | */ 6 | export type ErrorRuleObject = { 7 | type: "error"; 8 | conditions?: ConditionObject[]; 9 | error: Expression; 10 | documentation?: string; 11 | }; 12 | -------------------------------------------------------------------------------- /packages/types/src/endpoints/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./EndpointRuleObject"; 2 | export * from "./ErrorRuleObject"; 3 | export * from "./RuleSetObject"; 4 | export * from "./shared"; 5 | export * from "./TreeRuleObject"; 6 | -------------------------------------------------------------------------------- /packages/types/src/extensions/defaultExtensionConfiguration.ts: -------------------------------------------------------------------------------- 1 | import { ChecksumConfiguration } from "./checksum"; 2 | import { RetryStrategyConfiguration } from "./retry"; 3 | 4 | /** 5 | * @internal 6 | * 7 | * Default extension configuration consisting various configurations for modifying a service client 8 | */ 9 | export interface DefaultExtensionConfiguration extends ChecksumConfiguration, RetryStrategyConfiguration {} 10 | -------------------------------------------------------------------------------- /packages/types/src/extensions/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./defaultClientConfiguration"; 2 | export * from "./defaultExtensionConfiguration"; 3 | export { AlgorithmId, ChecksumAlgorithm, ChecksumConfiguration } from "./checksum"; 4 | export { RetryStrategyConfiguration } from "./retry"; 5 | -------------------------------------------------------------------------------- /packages/types/src/identity/apiKeyIdentity.ts: -------------------------------------------------------------------------------- 1 | import { Identity, IdentityProvider } from "../identity/identity"; 2 | 3 | /** 4 | * @public 5 | */ 6 | export interface ApiKeyIdentity extends Identity { 7 | /** 8 | * The literal API Key 9 | */ 10 | readonly apiKey: string; 11 | } 12 | 13 | /** 14 | * @public 15 | */ 16 | export type ApiKeyIdentityProvider = IdentityProvider; 17 | -------------------------------------------------------------------------------- /packages/types/src/identity/identity.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @public 3 | */ 4 | export interface Identity { 5 | /** 6 | * A `Date` when the identity or credential will no longer be accepted. 7 | */ 8 | readonly expiration?: Date; 9 | } 10 | 11 | /** 12 | * @public 13 | */ 14 | export interface IdentityProvider { 15 | (identityProperties?: Record): Promise; 16 | } 17 | -------------------------------------------------------------------------------- /packages/types/src/identity/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./apiKeyIdentity"; 2 | export * from "./awsCredentialIdentity"; 3 | export * from "./identity"; 4 | export * from "./tokenIdentity"; 5 | -------------------------------------------------------------------------------- /packages/types/src/identity/tokenIdentity.ts: -------------------------------------------------------------------------------- 1 | import { Identity, IdentityProvider } from "../identity/identity"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export interface TokenIdentity extends Identity { 7 | /** 8 | * The literal token string 9 | */ 10 | readonly token: string; 11 | } 12 | 13 | /** 14 | * @internal 15 | */ 16 | export type TokenIdentityProvider = IdentityProvider; 17 | -------------------------------------------------------------------------------- /packages/types/src/logger.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @public 3 | * 4 | * Represents a logger object that is available in HandlerExecutionContext 5 | * throughout the middleware stack. 6 | */ 7 | export interface Logger { 8 | trace?: (...content: any[]) => void; 9 | debug: (...content: any[]) => void; 10 | info: (...content: any[]) => void; 11 | warn: (...content: any[]) => void; 12 | error: (...content: any[]) => void; 13 | } 14 | -------------------------------------------------------------------------------- /packages/types/src/transform/exact.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | * 4 | * Checks that A and B extend each other. 5 | */ 6 | export type Exact = [A] extends [B] ? ([B] extends [A] ? true : false) : false; 7 | -------------------------------------------------------------------------------- /packages/types/src/transform/mutable.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export type Mutable = { 5 | -readonly [Property in keyof Type]: Type[Property]; 6 | }; 7 | -------------------------------------------------------------------------------- /packages/types/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/types/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/types/tsconfig.test.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "rootDir": "src", 5 | "noEmit": true 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"], 9 | "exclude": [] 10 | } 11 | -------------------------------------------------------------------------------- /packages/types/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/url-parser/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/url-parser/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/url-parser 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/url-parser/latest.svg)](https://www.npmjs.com/package/@smithy/url-parser) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/url-parser.svg)](https://www.npmjs.com/package/@smithy/url-parser) 5 | 6 | > An internal package 7 | 8 | ## Usage 9 | 10 | You probably shouldn't, at least directly. 11 | -------------------------------------------------------------------------------- /packages/url-parser/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/url-parser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/url-parser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/url-parser/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-base64/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-base64/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/util-base64 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/util-base64/latest.svg)](https://www.npmjs.com/package/@smithy/util-base64) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/util-base64.svg)](https://www.npmjs.com/package/@smithy/util-base64) 5 | -------------------------------------------------------------------------------- /packages/util-base64/src/__mocks__/testCases.json: -------------------------------------------------------------------------------- 1 | [ 2 | ["double padded", "3q2+7w==", [222, 173, 190, 239]], 3 | ["single padded", "3q2+7/o=", [222, 173, 190, 239, 250]], 4 | ["unpadded", "3q2+7/rO", [222, 173, 190, 239, 250, 206]], 5 | ["AAAA", "AAAA", [0, 0, 0]], 6 | ["AAAB", "AAAB", [0, 0, 1]], 7 | ["AAH/", "AAH/", [0, 1, -1]], 8 | ["AQEB", "AQEB", [1, 1, 1]], 9 | ["ALcX", "ALcX", [0, -73, 23]] 10 | ] 11 | -------------------------------------------------------------------------------- /packages/util-base64/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./fromBase64"; 2 | export * from "./toBase64"; 3 | -------------------------------------------------------------------------------- /packages/util-base64/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-base64/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-es", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.es.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-base64/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-base64/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-body-length-browser/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-body-length-browser/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./calculateBodyLength"; 5 | -------------------------------------------------------------------------------- /packages/util-body-length-browser/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-body-length-browser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": ["dom"], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-body-length-browser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-body-length-browser/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-body-length-node/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-body-length-node/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./calculateBodyLength"; 5 | -------------------------------------------------------------------------------- /packages/util-body-length-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-body-length-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/util-body-length-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-body-length-node/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-buffer-from/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-buffer-from/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-buffer-from/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-buffer-from/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-buffer-from/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-config-provider/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/util-config-provider 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/util-config-provider/latest.svg)](https://www.npmjs.com/package/@smithy/util-config-provider) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/util-config-provider.svg)](https://www.npmjs.com/package/@smithy/util-config-provider) 5 | -------------------------------------------------------------------------------- /packages/util-config-provider/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./booleanSelector"; 2 | export * from "./numberSelector"; 3 | export * from "./types"; 4 | -------------------------------------------------------------------------------- /packages/util-config-provider/src/types.ts: -------------------------------------------------------------------------------- 1 | export enum SelectorType { 2 | ENV = "env", 3 | CONFIG = "shared config entry", 4 | } 5 | -------------------------------------------------------------------------------- /packages/util-config-provider/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-config-provider/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-config-provider/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-config-provider/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-browser/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./resolveDefaultsModeConfig"; 5 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-browser/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-browser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-browser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-browser/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-node/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./resolveDefaultsModeConfig"; 5 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-defaults-mode-node/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/debug/debugId.ts: -------------------------------------------------------------------------------- 1 | export const debugId = "endpoints"; 2 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/debug/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./debugId"; 2 | export * from "./toDebugString"; 3 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./cache/EndpointCache"; 2 | export * from "./lib/isIpAddress"; 3 | export * from "./lib/isValidHostLabel"; 4 | export * from "./utils/customEndpointFunctions"; 5 | export * from "./resolveEndpoint"; 6 | export * from "./types"; 7 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/booleanEquals.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Evaluates two boolean values value1 and value2 for equality and returns 3 | * true if both values match. 4 | */ 5 | export const booleanEquals = (value1: boolean, value2: boolean): boolean => value1 === value2; 6 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./booleanEquals"; 2 | export * from "./getAttr"; 3 | export * from "./isSet"; 4 | export * from "./isValidHostLabel"; 5 | export * from "./not"; 6 | export * from "./parseURL"; 7 | export * from "./stringEquals"; 8 | export * from "./substring"; 9 | export * from "./uriEncode"; 10 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/isIpAddress.ts: -------------------------------------------------------------------------------- 1 | const IP_V4_REGEX = new RegExp( 2 | `^(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)(?:\\.(?:25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]\\d|\\d)){3}$` 3 | ); 4 | 5 | /** 6 | * Validates if the provided value is an IP address. 7 | */ 8 | export const isIpAddress = (value: string): boolean => 9 | IP_V4_REGEX.test(value) || (value.startsWith("[") && value.endsWith("]")); 10 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/isSet.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Evaluates whether a value is set (aka not null or undefined). 3 | * Returns true if the value is set, otherwise returns false. 4 | */ 5 | export const isSet = (value: unknown) => value != null; 6 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/not.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Performs logical negation on the provided boolean value, 3 | * returning the negated value. 4 | */ 5 | export const not = (value: boolean) => !value; 6 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/stringEquals.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Evaluates two string values value1 and value2 for equality and returns 3 | * true if both values match. 4 | */ 5 | export const stringEquals = (value1: string, value2: string): boolean => value1 === value2; 6 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/lib/uriEncode.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * Performs percent-encoding per RFC3986 section 2.1 3 | */ 4 | export const uriEncode = (value: string) => 5 | encodeURIComponent(value).replace(/[!*'()]/g, (c) => `%${c.charCodeAt(0).toString(16).toUpperCase()}`); 6 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/types/EndpointError.ts: -------------------------------------------------------------------------------- 1 | export class EndpointError extends Error { 2 | constructor(message: string) { 3 | super(message); 4 | this.name = "EndpointError"; 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/types/EndpointFunctions.ts: -------------------------------------------------------------------------------- 1 | import { FunctionReturn } from "./shared"; 2 | 3 | export type EndpointFunctions = Record FunctionReturn>; 4 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/types/ErrorRuleObject.ts: -------------------------------------------------------------------------------- 1 | import { ErrorRuleObject as __ErrorRuleObject } from "@smithy/types"; 2 | 3 | export type ErrorRuleObject = __ErrorRuleObject; 4 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/types/RuleSetObject.ts: -------------------------------------------------------------------------------- 1 | import { 2 | DeprecatedObject as __DeprecatedObject, 3 | ParameterObject as __ParameterObject, 4 | RuleSetObject as __RuleSetObject, 5 | } from "@smithy/types"; 6 | 7 | export type DeprecatedObject = __DeprecatedObject; 8 | 9 | export type ParameterObject = __ParameterObject; 10 | 11 | export type RuleSetObject = __RuleSetObject; 12 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/types/TreeRuleObject.ts: -------------------------------------------------------------------------------- 1 | import { RuleSetRules as __RuleSetRules, TreeRuleObject as __TreeRuleObject } from "@smithy/types"; 2 | 3 | export type RuleSetRules = __RuleSetRules; 4 | 5 | export type TreeRuleObject = __TreeRuleObject; 6 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/types/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./EndpointError"; 2 | export * from "./EndpointFunctions"; 3 | export * from "./EndpointRuleObject"; 4 | export * from "./ErrorRuleObject"; 5 | export * from "./RuleSetObject"; 6 | export * from "./TreeRuleObject"; 7 | export * from "./shared"; 8 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/utils/customEndpointFunctions.ts: -------------------------------------------------------------------------------- 1 | import { EndpointFunctions } from "../types/EndpointFunctions"; 2 | 3 | export const customEndpointFunctions: { [key: string]: EndpointFunctions } = {}; 4 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/utils/getReferenceValue.ts: -------------------------------------------------------------------------------- 1 | import { EvaluateOptions, ReferenceObject } from "../types"; 2 | 3 | export const getReferenceValue = ({ ref }: ReferenceObject, options: EvaluateOptions) => { 4 | const referenceRecord = { 5 | ...options.endpointParams, 6 | ...options.referenceRecord, 7 | }; 8 | return referenceRecord[ref]; 9 | }; 10 | -------------------------------------------------------------------------------- /packages/util-endpoints/src/utils/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./customEndpointFunctions"; 2 | export * from "./evaluateRules"; 3 | -------------------------------------------------------------------------------- /packages/util-endpoints/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-endpoints/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-endpoints/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-endpoints/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/util-endpoints/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-hex-encoding/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-hex-encoding/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/util-hex-encoding 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/util-hex-encoding/latest.svg)](https://www.npmjs.com/package/@smithy/util-hex-encoding) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/util-hex-encoding.svg)](https://www.npmjs.com/package/@smithy/util-hex-encoding) 5 | -------------------------------------------------------------------------------- /packages/util-hex-encoding/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-hex-encoding/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-hex-encoding/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-hex-encoding/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-middleware/src/getSmithyContext.ts: -------------------------------------------------------------------------------- 1 | import { HandlerExecutionContext, SMITHY_CONTEXT_KEY } from "@smithy/types"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const getSmithyContext = (context: HandlerExecutionContext): Record => 7 | context[SMITHY_CONTEXT_KEY] || (context[SMITHY_CONTEXT_KEY] = {}); 8 | -------------------------------------------------------------------------------- /packages/util-middleware/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./getSmithyContext"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./normalizeProvider"; 9 | -------------------------------------------------------------------------------- /packages/util-middleware/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-middleware/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-middleware/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-middleware/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-retry/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/util-retry/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./AdaptiveRetryStrategy"; 2 | export * from "./ConfiguredRetryStrategy"; 3 | export * from "./DefaultRateLimiter"; 4 | export * from "./StandardRetryStrategy"; 5 | export * from "./config"; 6 | export * from "./constants"; 7 | export * from "./types"; 8 | -------------------------------------------------------------------------------- /packages/util-retry/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-retry/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-retry/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-retry/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-stream-browser/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-stream-browser/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./getAwsChunkedEncodingStream"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./sdk-stream-mixin"; 9 | -------------------------------------------------------------------------------- /packages/util-stream-browser/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/util-stream-browser/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-stream-node/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-stream-node/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./getAwsChunkedEncodingStream"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./sdk-stream-mixin"; 9 | -------------------------------------------------------------------------------- /packages/util-stream-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-stream-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/util-stream-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-stream/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-stream/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/util-stream 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/util-stream/latest.svg)](https://www.npmjs.com/package/@smithy/util-stream) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/util-stream.svg)](https://www.npmjs.com/package/@smithy/util-stream) 5 | 6 | Package with utilities to operate on streams. 7 | -------------------------------------------------------------------------------- /packages/util-stream/api-extractor.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../api-extractor.packages.json", 3 | "mainEntryPointFilePath": "./dist-types/index.d.ts" 4 | } 5 | -------------------------------------------------------------------------------- /packages/util-stream/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./blob/Uint8ArrayBlobAdapter"; 2 | export * from "./checksum/ChecksumStream"; 3 | export * from "./checksum/createChecksumStream"; 4 | export * from "./createBufferedReadable"; 5 | export * from "./getAwsChunkedEncodingStream"; 6 | export * from "./headStream"; 7 | export * from "./sdk-stream-mixin"; 8 | export * from "./splitStream"; 9 | export * from "./stream-type-check"; 10 | -------------------------------------------------------------------------------- /packages/util-stream/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-stream/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { "baseUrl": ".", "outDir": "dist-es", "rootDir": "src" }, 3 | "extends": "../../tsconfig.es.json", 4 | "include": ["src/"] 5 | } 6 | -------------------------------------------------------------------------------- /packages/util-stream/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-stream/vitest.config.browser.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e}.spec.ts"], 6 | include: ["**/*.browser.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-stream/vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.integ.spec.ts"], 6 | environment: "node", 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /packages/util-stream/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-uri-escape/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-uri-escape/src/escape-uri-path.ts: -------------------------------------------------------------------------------- 1 | import { escapeUri } from "./escape-uri"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const escapeUriPath = (uri: string): string => uri.split("/").map(escapeUri).join("/"); 7 | -------------------------------------------------------------------------------- /packages/util-uri-escape/src/escape-uri.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const escapeUri = (uri: string): string => 5 | // AWS percent-encodes some extra non-standard characters in a URI 6 | encodeURIComponent(uri).replace(/[!'()*]/g, hexEncode); 7 | 8 | const hexEncode = (c: string) => `%${c.charCodeAt(0).toString(16).toUpperCase()}`; 9 | -------------------------------------------------------------------------------- /packages/util-uri-escape/src/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./escape-uri"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./escape-uri-path"; 9 | -------------------------------------------------------------------------------- /packages/util-uri-escape/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-uri-escape/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-uri-escape/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-uri-escape/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-utf8/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-utf8/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/util-utf8 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/util-utf8/latest.svg)](https://www.npmjs.com/package/@smithy/util-utf8) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/util-utf8.svg)](https://www.npmjs.com/package/@smithy/util-utf8) 5 | -------------------------------------------------------------------------------- /packages/util-utf8/src/fromUtf8.browser.ts: -------------------------------------------------------------------------------- 1 | export const fromUtf8 = (input: string): Uint8Array => new TextEncoder().encode(input); 2 | -------------------------------------------------------------------------------- /packages/util-utf8/src/fromUtf8.ts: -------------------------------------------------------------------------------- 1 | import { fromString } from "@smithy/util-buffer-from"; 2 | 3 | export const fromUtf8 = (input: string): Uint8Array => { 4 | const buf = fromString(input, "utf8"); 5 | return new Uint8Array(buf.buffer, buf.byteOffset, buf.byteLength / Uint8Array.BYTES_PER_ELEMENT); 6 | }; 7 | -------------------------------------------------------------------------------- /packages/util-utf8/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./fromUtf8"; 2 | export * from "./toUint8Array"; 3 | export * from "./toUtf8"; 4 | -------------------------------------------------------------------------------- /packages/util-utf8/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-utf8/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-utf8/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-utf8/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-waiter/.eslintrc.json: -------------------------------------------------------------------------------- 1 | { 2 | "plugins": ["eslint-plugin-tsdoc"], 3 | "rules": { 4 | "tsdoc/syntax": "warn" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /packages/util-waiter/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /packages/util-waiter/README.md: -------------------------------------------------------------------------------- 1 | # @smithy/util-waiter 2 | 3 | [![NPM version](https://img.shields.io/npm/v/@smithy/util-waiter/latest.svg)](https://www.npmjs.com/package/@smithy/util-waiter) 4 | [![NPM downloads](https://img.shields.io/npm/dm/@smithy/util-waiter.svg)](https://www.npmjs.com/package/@smithy/util-waiter) 5 | 6 | > An internal package 7 | 8 | ## Usage 9 | 10 | You probably shouldn't, at least directly. 11 | -------------------------------------------------------------------------------- /packages/util-waiter/src/index.spec.ts: -------------------------------------------------------------------------------- 1 | import { describe, expect, test as it } from "vitest"; 2 | 3 | import * as exported from "./index"; 4 | 5 | describe("Waiter util module exports", () => { 6 | it("should export the proper functions", () => { 7 | expect(exported.createWaiter).toBeDefined(); 8 | }); 9 | }); 10 | -------------------------------------------------------------------------------- /packages/util-waiter/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./createWaiter"; 2 | export * from "./waiter"; 3 | -------------------------------------------------------------------------------- /packages/util-waiter/src/utils/index.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export * from "./sleep"; 5 | /** 6 | * @internal 7 | */ 8 | export * from "./validate"; 9 | -------------------------------------------------------------------------------- /packages/util-waiter/src/utils/sleep.ts: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export const sleep = (seconds: number) => { 5 | return new Promise((resolve) => setTimeout(resolve, seconds * 1000)); 6 | }; 7 | -------------------------------------------------------------------------------- /packages/util-waiter/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.cjs.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-waiter/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src" 7 | }, 8 | "extends": "../../tsconfig.es.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /packages/util-waiter/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src" 6 | }, 7 | "extends": "../../tsconfig.types.json", 8 | "include": ["src/"] 9 | } 10 | -------------------------------------------------------------------------------- /packages/util-waiter/vitest.config.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["**/*.{integ,e2e,browser}.spec.ts"], 6 | include: ["**/*.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /prettier.config.js: -------------------------------------------------------------------------------- 1 | module.exports = { 2 | // Custom 3 | printWidth: 120, 4 | trailingComma: "es5" 5 | }; 6 | -------------------------------------------------------------------------------- /private/my-local-model/src/commands/index.ts: -------------------------------------------------------------------------------- 1 | // smithy-typescript generated code 2 | export * from "./GetNumbersCommand"; 3 | -------------------------------------------------------------------------------- /private/my-local-model/src/models/index.ts: -------------------------------------------------------------------------------- 1 | // smithy-typescript generated code 2 | export * from "./models_0"; 3 | -------------------------------------------------------------------------------- /private/my-local-model/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist-cjs", 5 | "noCheck": true 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /private/my-local-model/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "lib": ["dom"], 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "outDir": "dist-es", 8 | "noCheck": true 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /private/my-local-model/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@tsconfig/node18/tsconfig.json", 3 | "compilerOptions": { 4 | "downlevelIteration": true, 5 | "importHelpers": true, 6 | "incremental": true, 7 | "removeComments": true, 8 | "resolveJsonModule": true, 9 | "rootDir": "src", 10 | "useUnknownInCatchVariables": false 11 | }, 12 | "exclude": ["test/"] 13 | } 14 | -------------------------------------------------------------------------------- /private/my-local-model/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist-types", 7 | "emitDeclarationOnly": true, 8 | "noCheck": false 9 | }, 10 | "exclude": ["test/**/*", "dist-types/**/*"] 11 | } 12 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor-schema/src/models/index.ts: -------------------------------------------------------------------------------- 1 | // smithy-typescript generated code 2 | export * from "./models_0"; 3 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor-schema/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist-cjs", 5 | "noCheck": true 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor-schema/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "lib": ["dom"], 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "outDir": "dist-es", 8 | "noCheck": true 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor-schema/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@tsconfig/node18/tsconfig.json", 3 | "compilerOptions": { 4 | "downlevelIteration": true, 5 | "importHelpers": true, 6 | "incremental": true, 7 | "removeComments": true, 8 | "resolveJsonModule": true, 9 | "rootDir": "src", 10 | "useUnknownInCatchVariables": false 11 | }, 12 | "exclude": ["test/"] 13 | } 14 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor-schema/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist-types", 7 | "emitDeclarationOnly": true, 8 | "noCheck": false 9 | }, 10 | "exclude": ["test/**/*", "dist-types/**/*"] 11 | } 12 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor-schema/vite.config.js: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vite"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.spec.ts"], 6 | globals: true, 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor/src/models/index.ts: -------------------------------------------------------------------------------- 1 | // smithy-typescript generated code 2 | export * from "./models_0"; 3 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist-cjs", 5 | "noCheck": true 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "lib": ["dom"], 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "outDir": "dist-es", 8 | "noCheck": true 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "@tsconfig/node18/tsconfig.json", 3 | "compilerOptions": { 4 | "downlevelIteration": true, 5 | "importHelpers": true, 6 | "incremental": true, 7 | "removeComments": true, 8 | "resolveJsonModule": true, 9 | "rootDir": "src", 10 | "useUnknownInCatchVariables": false 11 | }, 12 | "exclude": ["test/"] 13 | } 14 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist-types", 7 | "emitDeclarationOnly": true, 8 | "noCheck": false 9 | }, 10 | "exclude": ["test/**/*", "dist-types/**/*"] 11 | } 12 | -------------------------------------------------------------------------------- /private/smithy-rpcv2-cbor/vite.config.js: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vite"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ["**/*.spec.ts"], 6 | globals: true, 7 | }, 8 | }); 9 | -------------------------------------------------------------------------------- /private/util-test/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | -------------------------------------------------------------------------------- /private/util-test/src/index.ts: -------------------------------------------------------------------------------- 1 | export * from "./test-http-handler"; 2 | -------------------------------------------------------------------------------- /private/util-test/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "outDir": "dist-cjs", 5 | "rootDir": "src", 6 | "stripInternal": true, 7 | "skipLibCheck": true 8 | }, 9 | "extends": "../../tsconfig.cjs.json", 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /private/util-test/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "lib": [], 5 | "outDir": "dist-es", 6 | "rootDir": "src", 7 | "stripInternal": true, 8 | "skipLibCheck": true 9 | }, 10 | "extends": "../../tsconfig.es.json", 11 | "include": ["src/"] 12 | } 13 | -------------------------------------------------------------------------------- /private/util-test/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "declarationDir": "dist-types", 5 | "rootDir": "src", 6 | "skipLibCheck": true 7 | }, 8 | "extends": "../../tsconfig.types.json", 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /scripts/cli-dispatcher/lib/Package.js: -------------------------------------------------------------------------------- 1 | module.exports = class Package { 2 | constructor(name, location) { 3 | this.name = name; 4 | this.location = location; 5 | } 6 | }; 7 | -------------------------------------------------------------------------------- /scripts/cli-dispatcher/readme.md: -------------------------------------------------------------------------------- 1 | ## CLI dispatcher 2 | 3 | These scripts provide CLI helpers to send shorthand commands to a matching package. 4 | 5 | ### Usage 6 | 7 | First, alias the script entry point. An example is provided in `./set-alias.sh`. 8 | 9 | Then, run the script with the new alias `b` with no arguments to see the help message detailing usage. 10 | -------------------------------------------------------------------------------- /scripts/cli-dispatcher/set-alias.sh: -------------------------------------------------------------------------------- 1 | #!/bin/bash 2 | 3 | # Set a command line alias to make running the dispatcher easier. 4 | 5 | alias b="node ./scripts/cli-dispatcher/index.js" 6 | alias r="node ./scripts/cli-dispatcher/workspace.js" -------------------------------------------------------------------------------- /scripts/compilation/tmp/.gitignore: -------------------------------------------------------------------------------- 1 | *.mjs -------------------------------------------------------------------------------- /scripts/example.js: -------------------------------------------------------------------------------- 1 | /** 2 | * Example script for iterating packages. 3 | */ 4 | 5 | const fs = require("node:fs"); 6 | const path = require("node:path"); 7 | 8 | const root = path.join(__dirname, ".."); 9 | const packages = path.join(root, "packages"); 10 | 11 | for (const folder of fs.readdirSync(packages)) { 12 | const pkgJson = require(path.join(packages, folder, "package.json")); 13 | } 14 | -------------------------------------------------------------------------------- /smithy-typescript-codegen-test/example-weather-customizations/src/main/resources/META-INF/services/software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration: -------------------------------------------------------------------------------- 1 | example.weather.ExampleWeatherCustomEndpointsRuntimeConfig 2 | example.weather.SupportWeatherSigV4Auth 3 | -------------------------------------------------------------------------------- /smithy-typescript-codegen-test/model/common/fakeAuth.smithy: -------------------------------------------------------------------------------- 1 | $version: "2.0" 2 | 3 | namespace common 4 | 5 | @trait 6 | @authDefinition 7 | structure fakeAuth {} 8 | -------------------------------------------------------------------------------- /smithy-typescript-codegen-test/model/common/fakeProtocol.smithy: -------------------------------------------------------------------------------- 1 | $version: "2.0" 2 | 3 | namespace common 4 | 5 | @trait 6 | @protocolDefinition 7 | structure fakeProtocol {} 8 | -------------------------------------------------------------------------------- /smithy-typescript-codegen-test/model/weather/more-nesting.smithy: -------------------------------------------------------------------------------- 1 | $version: "2.0" 2 | 3 | namespace example.weather.nested.more 4 | 5 | structure Baz { 6 | baz: String 7 | bar: String 8 | } 9 | -------------------------------------------------------------------------------- /smithy-typescript-codegen-test/model/weather/nested.smithy: -------------------------------------------------------------------------------- 1 | $version: "2.0" 2 | 3 | namespace example.weather.nested 4 | 5 | structure Foo { 6 | baz: String 7 | bar: String 8 | } 9 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/META-INF/services/software.amazon.smithy.build.SmithyBuildPlugin: -------------------------------------------------------------------------------- 1 | software.amazon.smithy.typescript.codegen.TypeScriptClientCodegenPlugin 2 | software.amazon.smithy.typescript.codegen.TypeScriptServerCodegenPlugin 3 | software.amazon.smithy.typescript.codegen.TypeScriptCodegenPlugin 4 | software.amazon.smithy.typescript.codegen.TypeScriptSSDKCodegenPlugin 5 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/extensionConfiguration.template: -------------------------------------------------------------------------------- 1 | /** 2 | * @internal 3 | */ 4 | export interface ${extensionConfigName} extends ${extensionConfigInterfaces} {} 5 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/resolveRuntimeExtensions2.template: -------------------------------------------------------------------------------- 1 | return Object.assign(runtimeConfig, 2 | ${resolvePartialRuntimeConfigs} 3 | ); 4 | } 5 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/runtimeConfig.shared.ts.template: -------------------------------------------------------------------------------- 1 | import { ${clientConfigName} } from "${clientModuleName}"; 2 | 3 | /** 4 | * @internal 5 | */ 6 | export const getRuntimeConfig = (config: ${clientConfigName}) => { 7 | ${prepareCustomizations}return { 8 | apiVersion: "${apiVersion}", 9 | ${customizations} 10 | } 11 | }; 12 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/runtimeExtensions2.template: -------------------------------------------------------------------------------- 1 | return Object.assign(runtimeConfig, 2 | ${resolvePartialRuntimeConfigs} 3 | ); 4 | } 5 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist-cjs", 5 | "noCheck": true 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "lib": ["dom"], 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "outDir": "dist-es", 8 | "noCheck": true 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist-types", 7 | "emitDeclarationOnly": true, 8 | "noCheck": false 9 | }, 10 | "exclude": ["test/**/*", "dist-types/**/*"] 11 | } 12 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/typedoc.json: -------------------------------------------------------------------------------- 1 | { 2 | "entryPoints": ["src/index.ts"], 3 | "out": "docs", 4 | "readme": "README.md" 5 | } 6 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/main/resources/software/amazon/smithy/typescript/codegen/vite.config.js: -------------------------------------------------------------------------------- 1 | import { defineConfig } from 'vite' 2 | 3 | export default defineConfig({ 4 | test: { 5 | include: ['**/*.spec.ts'], 6 | globals: true 7 | }, 8 | }) 9 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/META-INF/services/software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration: -------------------------------------------------------------------------------- 1 | software.amazon.smithy.typescript.codegen.SymbolDecoratorIntegration 2 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-empty.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething{ 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | structure Err {} 14 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-optional-member-no-message.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething { 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | structure Err { 14 | foo: String, 15 | } 16 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-optional-message.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething { 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | structure Err { 14 | message: String, 15 | } 16 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-required-member-no-message.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething { 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | structure Err { 14 | @required 15 | foo: String, 16 | } 17 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-required-message.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething { 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | structure Err { 14 | @required 15 | message: String, 16 | } 17 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-retryable-throttling.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething { 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | @retryable(throttling: true) 14 | structure Err {} 15 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/error-test-retryable.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [DoSomething] 6 | } 7 | 8 | operation DoSomething { 9 | errors: [Err] 10 | } 11 | 12 | @error("client") 13 | @retryable 14 | structure Err {} 15 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/simple-service-with-operation.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [GetFoo] 6 | } 7 | 8 | operation GetFoo {} 9 | 10 | 11 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/simple-service.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0" 5 | } 6 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/test-insensitive-list.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [GetFoo] 6 | } 7 | 8 | operation GetFoo { 9 | input: GetFooInput 10 | } 11 | 12 | structure GetFooInput { 13 | foo: NamesList 14 | } 15 | 16 | list NamesList { 17 | member: String 18 | } 19 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/test-insensitive-map.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [GetFoo] 6 | } 7 | 8 | operation GetFoo { 9 | input: GetFooInput 10 | } 11 | 12 | structure GetFooInput { 13 | foo: NamesMap 14 | } 15 | 16 | map NamesMap { 17 | key: String, 18 | value: String 19 | } 20 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/test-insensitive-simple-shape.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [GetFoo] 6 | } 7 | 8 | operation GetFoo { 9 | input: GetFooInput 10 | } 11 | 12 | structure GetFooInput { 13 | firstname: String, 14 | lastname: String 15 | } 16 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/testmodel.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | structure Foo { 4 | @required 5 | foo: String, 6 | } 7 | -------------------------------------------------------------------------------- /smithy-typescript-codegen/src/test/resources/software/amazon/smithy/typescript/codegen/validation/long-validation.smithy: -------------------------------------------------------------------------------- 1 | namespace smithy.example 2 | 3 | service Example { 4 | version: "1.0.0", 5 | operations: [ExampleOperation] 6 | } 7 | 8 | operation ExampleOperation { 9 | input: ExampleOperationInput 10 | } 11 | 12 | structure ExampleOperationInput { 13 | longInput: Long 14 | } 15 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-codegen-test-utils/src/main/resources/META-INF/services/software.amazon.smithy.typescript.codegen.integration.TypeScriptIntegration: -------------------------------------------------------------------------------- 1 | software.amazon.smithy.typescript.ssdk.codegen.test.utils.AddProtocols 2 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/README.md: -------------------------------------------------------------------------------- 1 | # Smithy Typescript Server SDK Libraries 2 | 3 | These libraries support the use of the Smithy TypeScript Server SDKs. 4 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | src/*.js 10 | dist/ 11 | types/ 12 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/.npmignore: -------------------------------------------------------------------------------- 1 | /coverage/ 2 | tsconfig.test.json 3 | *.tsbuildinfo 4 | jest.config.js 5 | 6 | *.spec.js 7 | *.spec.ts 8 | *.spec.d.ts 9 | *.spec.js.map 10 | 11 | *.mock.js 12 | *.mock.d.ts 13 | *.mock.js.map 14 | 15 | *.fixture.js 16 | *.fixture.d.ts 17 | *.fixture.js.map 18 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/jest.config.js: -------------------------------------------------------------------------------- 1 | const base = require("../../jest.config.base.js"); 2 | 3 | module.exports = { 4 | preset: "ts-jest", 5 | ...base, 6 | }; 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist/cjs" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "module": "ESNext", 5 | "outDir": "dist/es" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../tsconfig.json", 3 | "compilerOptions": { 4 | "stripInternal": true, 5 | "removeComments": true, 6 | "rootDir": "src", 7 | "baseUrl": "." 8 | }, 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-apigateway/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist/types", 7 | "emitDeclarationOnly": true 8 | }, 9 | "exclude": ["test/**/*", "dist/types/**/*"] 10 | } 11 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | src/*.js 10 | dist/ 11 | types/ 12 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/.npmignore: -------------------------------------------------------------------------------- 1 | /coverage/ 2 | tsconfig.test.json 3 | *.tsbuildinfo 4 | jest.config.js 5 | 6 | *.spec.js 7 | *.spec.ts 8 | *.spec.d.ts 9 | *.spec.js.map 10 | 11 | *.mock.js 12 | *.mock.d.ts 13 | *.mock.js.map 14 | 15 | *.fixture.js 16 | *.fixture.d.ts 17 | *.fixture.js.map 18 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/README.md: -------------------------------------------------------------------------------- 1 | # smithy-typescript/server-common 2 | 3 | This library provides common interfaces and utilities needed for building a 4 | server sdk. 5 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/jest.config.js: -------------------------------------------------------------------------------- 1 | const base = require("../../jest.config.base.js"); 2 | 3 | module.exports = { 4 | preset: "ts-jest", 5 | ...base, 6 | }; 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist/cjs" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "module": "ESNext", 5 | "outDir": "dist/es" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../tsconfig.json", 3 | "compilerOptions": { 4 | "stripInternal": true, 5 | "removeComments": true, 6 | "rootDir": "src", 7 | "baseUrl": "." 8 | }, 9 | "include": ["src/"] 10 | } 11 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-common/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist/types", 7 | "emitDeclarationOnly": true 8 | }, 9 | "exclude": ["test/**/*", "dist/types/**/*"] 10 | } 11 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/.gitignore: -------------------------------------------------------------------------------- 1 | /node_modules/ 2 | /build/ 3 | /coverage/ 4 | /docs/ 5 | *.tsbuildinfo 6 | *.tgz 7 | *.log 8 | package-lock.json 9 | src/*.js 10 | dist/ 11 | types/ 12 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/.npmignore: -------------------------------------------------------------------------------- 1 | /coverage/ 2 | tsconfig.test.json 3 | *.tsbuildinfo 4 | jest.config.js 5 | 6 | *.spec.js 7 | *.spec.ts 8 | *.spec.d.ts 9 | *.spec.js.map 10 | 11 | *.mock.js 12 | *.mock.d.ts 13 | *.mock.js.map 14 | 15 | *.fixture.js 16 | *.fixture.d.ts 17 | *.fixture.js.map 18 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/CHANGELOG.md: -------------------------------------------------------------------------------- 1 | # server-node Changelog 2 | 3 | ## 1.0.0-alpha.10 (2023-04-18) 4 | 5 | ## 1.0.0-alpha.9 (2023-03-16) 6 | 7 | ### Features 8 | 9 | Module created. 10 | 11 | ### Other 12 | 13 | - Upgraded to Yarn 3. ([#705](https://github.com/awslabs/smithy-typescript/pull/705)) 14 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/jest.config.js: -------------------------------------------------------------------------------- 1 | const base = require("../../jest.config.base.js"); 2 | 3 | module.exports = { 4 | preset: "ts-jest", 5 | ...base, 6 | }; 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/src/index.ts: -------------------------------------------------------------------------------- 1 | /* 2 | * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. 3 | * SPDX-License-Identifier: Apache-2.0 4 | */ 5 | 6 | export * from "./node"; 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "outDir": "dist/cjs" 5 | } 6 | } 7 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "module": "ESNext", 5 | "outDir": "dist/es" 6 | } 7 | } 8 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/tsconfig.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "../../tsconfig.json", 3 | "compilerOptions": { 4 | "stripInternal": true, 5 | "removeComments": true, 6 | "rootDir": "src", 7 | "baseUrl": ".", 8 | "lib": ["es2019.object", "dom"] 9 | }, 10 | "include": ["src/"] 11 | } 12 | -------------------------------------------------------------------------------- /smithy-typescript-ssdk-libs/server-node/tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig", 3 | "compilerOptions": { 4 | "removeComments": false, 5 | "declaration": true, 6 | "declarationDir": "dist/types", 7 | "emitDeclarationOnly": true 8 | }, 9 | "exclude": ["test/**/*", "dist/types/**/*"] 10 | } 11 | -------------------------------------------------------------------------------- /tsconfig.cjs.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "compilerOptions": { 4 | "importHelpers": true, 5 | "module": "commonjs", 6 | "noEmitHelpers": false, 7 | "target": "ES2018", 8 | "noCheck": true 9 | } 10 | } 11 | -------------------------------------------------------------------------------- /tsconfig.es.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "compilerOptions": { 4 | "importHelpers": true, 5 | "module": "ESNext", 6 | "moduleResolution": "bundler", 7 | "noEmitHelpers": false, 8 | "target": "ES2020", 9 | "noCheck": true 10 | } 11 | } 12 | -------------------------------------------------------------------------------- /tsconfig.test.json: -------------------------------------------------------------------------------- 1 | { 2 | "compilerOptions": { 3 | "baseUrl": ".", 4 | "noEmit": true, 5 | "noCheck": false, 6 | "skipLibCheck": true 7 | }, 8 | "extends": "./tsconfig.types.json", 9 | "include": ["packages/**/*.spec.ts", "private/**/*.spec.ts"], 10 | "exclude": [ 11 | "node_modules/", 12 | "node_modules", 13 | "vitest.*.ts" 14 | ] 15 | } 16 | -------------------------------------------------------------------------------- /tsconfig.types.json: -------------------------------------------------------------------------------- 1 | { 2 | "extends": "./tsconfig.json", 3 | "compilerOptions": { 4 | "declaration": true, 5 | "emitDeclarationOnly": true, 6 | "removeComments": false, 7 | "strict": true 8 | } 9 | } 10 | -------------------------------------------------------------------------------- /vitest.config.browser.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["node_modules"], 6 | include: ["{packages,private}/**/*.browser.spec.ts"], 7 | environment: "happy-dom", 8 | }, 9 | }); 10 | -------------------------------------------------------------------------------- /vitest.config.integ.ts: -------------------------------------------------------------------------------- 1 | import { defineConfig } from "vitest/config"; 2 | 3 | export default defineConfig({ 4 | test: { 5 | exclude: ["node_modules", "**/*.{e2e,browser}.spec.ts"], 6 | include: ["{packages,private}/**/*.integ.spec.ts"], 7 | environment: "node", 8 | }, 9 | }); 10 | --------------------------------------------------------------------------------