@shawnstack/quickforge 1.3.20 → 1.3.21
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +348 -348
- package/dist/assets/{anthropic-Bj3HAZgj.js → anthropic--qj3xmqE.js} +1 -1
- package/dist/assets/{azure-openai-responses-IdZZrSrI.js → azure-openai-responses-DDRaS-MZ.js} +1 -1
- package/dist/assets/{google-Brt_lS1J.js → google-C-8-FIZS.js} +1 -1
- package/dist/assets/{google-vertex-B6HsoZ34.js → google-vertex-Dw2y_nqS.js} +1 -1
- package/dist/assets/{index-D0W9hAl_.css → index-B-WkttzD.css} +1 -1
- package/dist/assets/{index-D0CVLdX_.js → index-DRGbHzkd.js} +4 -4
- package/dist/assets/{mistral-CenXqwPz.js → mistral-u_5S4wj6.js} +1 -1
- package/dist/assets/{openai-codex-responses-D9ffGwbj.js → openai-codex-responses-CWZGpchs.js} +1 -1
- package/dist/assets/{openai-completions-eWdeSGBG.js → openai-completions-C_DdwPuH.js} +1 -1
- package/dist/assets/{openai-responses-Cavpmjeu.js → openai-responses-CMp0ziUV.js} +1 -1
- package/dist/assets/{openai-responses-shared-DF3ZGaUx.js → openai-responses-shared-CORWeerT.js} +1 -1
- package/dist/index.html +2 -2
- package/node_modules/@aws-sdk/client-bedrock-runtime/package.json +2 -2
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/LICENSE +201 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/README.md +62 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-cjs/index.js +156 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/constants.js +2 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromEnvSigningName.js +16 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromSso.js +80 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/fromStatic.js +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/getNewSsoOidcToken.js +11 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/getSsoOidcClient.js +10 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/index.js +4 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/nodeProvider.js +5 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/validateTokenExpiry.js +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/validateTokenKey.js +7 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/dist-es/writeSSOTokenToFile.js +8 -0
- package/node_modules/@aws-sdk/credential-provider-sso/node_modules/@aws-sdk/token-providers/package.json +69 -0
- package/node_modules/@aws-sdk/token-providers/package.json +1 -1
- package/node_modules/@smithy/core/dist-cjs/index.js +3 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/client/index.js +3 -11
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.browser.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/config/index.native.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.browser.js +9 -40
- package/node_modules/@smithy/core/dist-cjs/submodules/endpoints/index.js +9 -40
- package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +12 -142
- package/node_modules/@smithy/core/dist-cjs/submodules/schema/index.js +7 -9
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.browser.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/serde/index.native.js +2 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/transport/index.js +184 -0
- package/node_modules/@smithy/core/dist-es/index.js +6 -6
- package/node_modules/@smithy/core/dist-es/submodules/client/index.js +2 -2
- package/node_modules/@smithy/core/dist-es/submodules/config/config-resolver/regionConfig/checkRegion.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/index.browser.js +2 -2
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/index.js +2 -2
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/adaptors/toEndpointV1.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/middleware-endpoint/resolveEndpointConfig.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/endpoints/util-endpoints/lib/index.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpBindingProtocol.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/RpcProtocol.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/index.js +5 -5
- package/node_modules/@smithy/core/dist-es/submodules/protocols/middleware-content-length/contentLengthMiddleware.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/protocols/requestBuilder.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaDeserializationMiddleware.js +3 -4
- package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaSerializationMiddleware.js +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/serde/middleware-serde/deserializerMiddleware.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/transport/index.js +9 -0
- package/node_modules/@smithy/core/dist-es/submodules/{protocols/url-parser → transport}/parseUrl.js +1 -1
- package/node_modules/@smithy/core/dist-es/submodules/{endpoints → transport}/toEndpointV1.js +1 -1
- package/node_modules/@smithy/core/package.json +19 -10
- package/node_modules/@smithy/core/transport.js +5 -0
- package/node_modules/@smithy/credential-provider-imds/package.json +2 -2
- package/node_modules/@smithy/fetch-http-handler/package.json +2 -2
- package/node_modules/@smithy/node-http-handler/package.json +2 -2
- package/node_modules/@smithy/signature-v4/package.json +2 -2
- package/node_modules/eventsource-parser/README.md +31 -0
- package/node_modules/eventsource-parser/dist/index.cjs +21 -10
- package/node_modules/eventsource-parser/dist/index.js +21 -10
- package/node_modules/eventsource-parser/dist/stream.cjs +4 -3
- package/node_modules/eventsource-parser/dist/stream.js +4 -3
- package/node_modules/eventsource-parser/package.json +8 -8
- package/package.json +1 -1
- package/node_modules/@smithy/core/dist-cjs/getSmithyContext.js +0 -6
- package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/getHttpAuthSchemeEndpointRuleSetPlugin.js +0 -21
- package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/getHttpAuthSchemePlugin.js +0 -21
- package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/httpAuthSchemeMiddleware.js +0 -46
- package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/index.js +0 -6
- package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/resolveAuthOptions.js +0 -24
- package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/getHttpSigningMiddleware.js +0 -19
- package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/httpSigningMiddleware.js +0 -27
- package/node_modules/@smithy/core/dist-cjs/middleware-http-signing/index.js +0 -5
- package/node_modules/@smithy/core/dist-cjs/normalizeProvider.js +0 -10
- package/node_modules/@smithy/core/dist-cjs/pagination/createPaginator.js +0 -44
- package/node_modules/@smithy/core/dist-cjs/request-builder/requestBuilder.js +0 -5
- package/node_modules/@smithy/core/dist-cjs/setFeature.js +0 -14
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/DefaultIdentityProviderConfig.js +0 -18
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/httpApiKeyAuth.js +0 -38
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/httpBearerAuth.js +0 -15
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/index.js +0 -6
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/httpAuthSchemes/noAuth.js +0 -9
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/index.js +0 -6
- package/node_modules/@smithy/core/dist-cjs/util-identity-and-auth/memoizeIdentityProvider.js +0 -61
- package/node_modules/@smithy/core/dist-es/request-builder/requestBuilder.js +0 -1
- package/node_modules/@smithy/core/dist-es/submodules/client/util-middleware/getSmithyContext.js +0 -2
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/TestVectors.fixture.js +0 -146
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/eventstream-codec/vectorTypes.fixture.js +0 -1
- package/node_modules/@smithy/credential-provider-imds/dist-es/remoteProvider/index.js +0 -2
- package/node_modules/@smithy/node-http-handler/dist-es/readable.mock.js +0 -21
- package/node_modules/@smithy/node-http-handler/dist-es/server.mock.js +0 -88
- package/node_modules/@smithy/node-http-handler/dist-es/stream-collector/readable.mock.js +0 -21
- package/node_modules/@smithy/signature-v4/dist-es/suite.fixture.js +0 -399
- /package/node_modules/@smithy/core/dist-es/{middleware-http-auth-scheme → legacy-root-exports/middleware-http-auth-scheme}/getHttpAuthSchemeEndpointRuleSetPlugin.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-auth-scheme → legacy-root-exports/middleware-http-auth-scheme}/getHttpAuthSchemePlugin.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-auth-scheme → legacy-root-exports/middleware-http-auth-scheme}/httpAuthSchemeMiddleware.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-auth-scheme → legacy-root-exports/middleware-http-auth-scheme}/index.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-auth-scheme → legacy-root-exports/middleware-http-auth-scheme}/resolveAuthOptions.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-signing → legacy-root-exports/middleware-http-signing}/getHttpSigningMiddleware.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-signing → legacy-root-exports/middleware-http-signing}/httpSigningMiddleware.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{middleware-http-signing → legacy-root-exports/middleware-http-signing}/index.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{pagination → legacy-root-exports/pagination}/createPaginator.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/DefaultIdentityProviderConfig.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/httpAuthSchemes/httpApiKeyAuth.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/httpAuthSchemes/httpBearerAuth.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/httpAuthSchemes/index.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/httpAuthSchemes/noAuth.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/index.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{util-identity-and-auth → legacy-root-exports/util-identity-and-auth}/memoizeIdentityProvider.js +0 -0
- /package/node_modules/@smithy/core/dist-es/{getSmithyContext.js → submodules/transport/getSmithyContext.js} +0 -0
- /package/node_modules/@smithy/core/dist-es/submodules/{protocols/protocol-http → transport}/httpRequest.js +0 -0
- /package/node_modules/@smithy/core/dist-es/submodules/{protocols/protocol-http → transport}/httpResponse.js +0 -0
- /package/node_modules/@smithy/core/dist-es/submodules/{endpoints/util-endpoints/lib → transport}/isValidHostLabel.js +0 -0
- /package/node_modules/@smithy/core/dist-es/submodules/{protocols/protocol-http → transport}/isValidHostname.js +0 -0
- /package/node_modules/@smithy/core/dist-es/submodules/{client/util-middleware → transport}/normalizeProvider.js +0 -0
- /package/node_modules/@smithy/core/dist-es/submodules/{protocols/querystring-parser → transport}/parseQueryString.js +0 -0
|
@@ -3,12 +3,12 @@ import { bindGetEndpointFromInstructions } from "./middleware-endpoint/adaptors/
|
|
|
3
3
|
import { bindEndpointMiddleware } from "./middleware-endpoint/endpointMiddleware";
|
|
4
4
|
import { bindGetEndpointPlugin } from "./middleware-endpoint/getEndpointPlugin";
|
|
5
5
|
import { bindResolveEndpointConfig } from "./middleware-endpoint/resolveEndpointConfig";
|
|
6
|
-
export
|
|
6
|
+
export { toEndpointV1 } from "@smithy/core/transport";
|
|
7
7
|
export { BinaryDecisionDiagram } from "./util-endpoints/bdd/BinaryDecisionDiagram";
|
|
8
8
|
export { EndpointCache } from "./util-endpoints/cache/EndpointCache";
|
|
9
9
|
export { decideEndpoint } from "./util-endpoints/decideEndpoint";
|
|
10
10
|
export { isIpAddress } from "./util-endpoints/lib/isIpAddress";
|
|
11
|
-
export { isValidHostLabel } from "
|
|
11
|
+
export { isValidHostLabel } from "@smithy/core/transport";
|
|
12
12
|
export { customEndpointFunctions } from "./util-endpoints/utils/customEndpointFunctions";
|
|
13
13
|
export { resolveEndpoint } from "./util-endpoints/resolveEndpoint";
|
|
14
14
|
export * from "./util-endpoints/types";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
export { toEndpointV1 } from "
|
|
1
|
+
export { toEndpointV1 } from "@smithy/core/transport";
|
|
@@ -2,7 +2,7 @@ export * from "./booleanEquals";
|
|
|
2
2
|
export * from "./coalesce";
|
|
3
3
|
export * from "./getAttr";
|
|
4
4
|
export * from "./isSet";
|
|
5
|
-
export
|
|
5
|
+
export { isValidHostLabel } from "@smithy/core/transport";
|
|
6
6
|
export * from "./ite";
|
|
7
7
|
export * from "./not";
|
|
8
8
|
export * from "./parseURL";
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import { NormalizedSchema, translateTraits } from "@smithy/core/schema";
|
|
2
2
|
import { sdkStreamMixin, splitEvery, splitHeader } from "@smithy/core/serde";
|
|
3
|
+
import { HttpRequest } from "@smithy/core/transport";
|
|
3
4
|
import { HttpProtocol } from "./HttpProtocol";
|
|
4
5
|
import { collectBody } from "./collect-stream-body";
|
|
5
6
|
import { extendedEncodeURIComponent } from "./extended-encode-uri-component";
|
|
6
|
-
import { HttpRequest } from "./protocol-http/httpRequest";
|
|
7
7
|
export class HttpBindingProtocol extends HttpProtocol {
|
|
8
8
|
async serializeRequest(operationSchema, _input, context) {
|
|
9
9
|
const input = _input && typeof _input === "object" ? _input : {};
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { NormalizedSchema, TypeRegistry, translateTraits } from "@smithy/core/schema";
|
|
2
|
+
import { HttpRequest, HttpResponse } from "@smithy/core/transport";
|
|
2
3
|
import { SerdeContext } from "./SerdeContext";
|
|
3
|
-
import { HttpRequest } from "./protocol-http/httpRequest";
|
|
4
|
-
import { HttpResponse } from "./protocol-http/httpResponse";
|
|
5
4
|
export class HttpProtocol extends SerdeContext {
|
|
6
5
|
options;
|
|
7
6
|
compositeErrorRegistry;
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { NormalizedSchema } from "@smithy/core/schema";
|
|
2
|
+
import { HttpRequest } from "@smithy/core/transport";
|
|
2
3
|
import { HttpProtocol } from "./HttpProtocol";
|
|
3
4
|
import { collectBody } from "./collect-stream-body";
|
|
4
|
-
import { HttpRequest } from "./protocol-http/httpRequest";
|
|
5
5
|
export class RpcProtocol extends HttpProtocol {
|
|
6
6
|
async serializeRequest(operationSchema, _input, context) {
|
|
7
7
|
const serializer = this.serializer;
|
|
@@ -13,13 +13,13 @@ export * from "./serde/determineTimestampFormat";
|
|
|
13
13
|
export * from "./SerdeContext";
|
|
14
14
|
export { Field } from "./protocol-http/Field";
|
|
15
15
|
export { Fields } from "./protocol-http/Fields";
|
|
16
|
-
export { HttpRequest } from "
|
|
17
|
-
export { HttpResponse } from "
|
|
18
|
-
export { isValidHostname } from "
|
|
16
|
+
export { HttpRequest } from "@smithy/core/transport";
|
|
17
|
+
export { HttpResponse } from "@smithy/core/transport";
|
|
18
|
+
export { isValidHostname } from "@smithy/core/transport";
|
|
19
19
|
export { getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig, } from "./protocol-http/extensions/httpExtensionConfiguration";
|
|
20
20
|
export { contentLengthMiddleware, contentLengthMiddlewareOptions, getContentLengthPlugin, } from "./middleware-content-length/contentLengthMiddleware";
|
|
21
21
|
export { escapeUri } from "./util-uri-escape/escape-uri";
|
|
22
22
|
export { escapeUriPath } from "./util-uri-escape/escape-uri-path";
|
|
23
23
|
export { buildQueryString } from "./querystring-builder/buildQueryString";
|
|
24
|
-
export { parseQueryString } from "
|
|
25
|
-
export { parseUrl } from "
|
|
24
|
+
export { parseQueryString } from "@smithy/core/transport";
|
|
25
|
+
export { parseUrl } from "@smithy/core/transport";
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { getSmithyContext } from "@smithy/core/
|
|
2
|
-
import { HttpResponse } from "@smithy/core/protocols";
|
|
1
|
+
import { HttpResponse, getSmithyContext } from "@smithy/core/transport";
|
|
3
2
|
import { operation } from "../schemas/operation";
|
|
4
3
|
export const schemaDeserializationMiddleware = (config) => (next, context) => async (args) => {
|
|
5
4
|
const { response } = await next(args);
|
|
@@ -42,10 +41,10 @@ export const schemaDeserializationMiddleware = (config) => (next, context) => as
|
|
|
42
41
|
}
|
|
43
42
|
try {
|
|
44
43
|
if (HttpResponse.isInstance(response)) {
|
|
45
|
-
const { headers = {} } = response;
|
|
44
|
+
const { headers = {}, statusCode } = response;
|
|
46
45
|
const headerEntries = Object.entries(headers);
|
|
47
46
|
error.$metadata = {
|
|
48
|
-
httpStatusCode:
|
|
47
|
+
httpStatusCode: statusCode,
|
|
49
48
|
requestId: findHeader(/^x-[\w-]+-request-?id$/, headerEntries),
|
|
50
49
|
extendedRequestId: findHeader(/^x-[\w-]+-id-2$/, headerEntries),
|
|
51
50
|
cfId: findHeader(/^x-[\w-]+-cf-id$/, headerEntries),
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { getSmithyContext } from "@smithy/core/
|
|
2
|
-
import { toEndpointV1 } from "@smithy/core/endpoints";
|
|
1
|
+
import { getSmithyContext, toEndpointV1 } from "@smithy/core/transport";
|
|
3
2
|
import { operation } from "../schemas/operation";
|
|
4
3
|
export const schemaSerializationMiddleware = (config) => (next, context) => async (args) => {
|
|
5
4
|
const { operationSchema } = getSmithyContext(context);
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
export { getSmithyContext } from "./getSmithyContext";
|
|
2
|
+
export { HttpRequest } from "./httpRequest";
|
|
3
|
+
export { HttpResponse } from "./httpResponse";
|
|
4
|
+
export { isValidHostLabel } from "./isValidHostLabel";
|
|
5
|
+
export { isValidHostname } from "./isValidHostname";
|
|
6
|
+
export { normalizeProvider } from "./normalizeProvider";
|
|
7
|
+
export { parseQueryString } from "./parseQueryString";
|
|
8
|
+
export { parseUrl } from "./parseUrl";
|
|
9
|
+
export { toEndpointV1 } from "./toEndpointV1";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/core",
|
|
3
|
-
"version": "3.24.
|
|
3
|
+
"version": "3.24.5",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "concurrently 'yarn:build:types' 'yarn:build:es:cjs'",
|
|
6
6
|
"build:es:cjs": "yarn g:tsc -p tsconfig.es.json && node ../../scripts/inline core",
|
|
@@ -151,6 +151,13 @@
|
|
|
151
151
|
"node": "./dist-cjs/submodules/retry/index.js",
|
|
152
152
|
"import": "./dist-es/submodules/retry/index.js",
|
|
153
153
|
"require": "./dist-cjs/submodules/retry/index.js"
|
|
154
|
+
},
|
|
155
|
+
"./transport": {
|
|
156
|
+
"types": "./dist-types/submodules/transport/index.d.ts",
|
|
157
|
+
"module": "./dist-es/submodules/transport/index.js",
|
|
158
|
+
"node": "./dist-cjs/submodules/transport/index.js",
|
|
159
|
+
"import": "./dist-es/submodules/transport/index.js",
|
|
160
|
+
"require": "./dist-cjs/submodules/transport/index.js"
|
|
154
161
|
}
|
|
155
162
|
},
|
|
156
163
|
"author": {
|
|
@@ -178,25 +185,27 @@
|
|
|
178
185
|
"files": [
|
|
179
186
|
"./cbor.d.ts",
|
|
180
187
|
"./cbor.js",
|
|
188
|
+
"./checksum.d.ts",
|
|
189
|
+
"./checksum.js",
|
|
190
|
+
"./client.d.ts",
|
|
191
|
+
"./client.js",
|
|
192
|
+
"./config.d.ts",
|
|
193
|
+
"./config.js",
|
|
181
194
|
"./endpoints.d.ts",
|
|
182
195
|
"./endpoints.js",
|
|
183
196
|
"./event-streams.d.ts",
|
|
184
197
|
"./event-streams.js",
|
|
185
198
|
"./protocols.d.ts",
|
|
186
199
|
"./protocols.js",
|
|
200
|
+
"./retry.d.ts",
|
|
201
|
+
"./retry.js",
|
|
187
202
|
"./schema.d.ts",
|
|
188
203
|
"./schema.js",
|
|
189
204
|
"./serde.d.ts",
|
|
190
205
|
"./serde.js",
|
|
191
|
-
"
|
|
192
|
-
"./
|
|
193
|
-
"
|
|
194
|
-
"./config.d.ts",
|
|
195
|
-
"./config.js",
|
|
196
|
-
"./checksum.d.ts",
|
|
197
|
-
"./checksum.js",
|
|
198
|
-
"./retry.d.ts",
|
|
199
|
-
"./retry.js"
|
|
206
|
+
"./transport.d.ts",
|
|
207
|
+
"./transport.js",
|
|
208
|
+
"dist-*/**"
|
|
200
209
|
],
|
|
201
210
|
"homepage": "https://github.com/smithy-lang/smithy-typescript/tree/main/packages/core",
|
|
202
211
|
"repository": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/credential-provider-imds",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.5",
|
|
4
4
|
"description": "AWS credential provider that sources credentials from the EC2 instance metadata service and ECS container metadata service",
|
|
5
5
|
"main": "./dist-cjs/index.js",
|
|
6
6
|
"module": "./dist-es/index.js",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"license": "Apache-2.0",
|
|
28
28
|
"sideEffects": false,
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@smithy/core": "^3.24.
|
|
30
|
+
"@smithy/core": "^3.24.5",
|
|
31
31
|
"@smithy/types": "^4.14.2",
|
|
32
32
|
"tslib": "^2.6.2"
|
|
33
33
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/fetch-http-handler",
|
|
3
|
-
"version": "5.4.
|
|
3
|
+
"version": "5.4.5",
|
|
4
4
|
"description": "Provides a way to make requests",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:types' 'yarn:build:es:cjs'",
|
|
@@ -27,7 +27,7 @@
|
|
|
27
27
|
"module": "./dist-es/index.js",
|
|
28
28
|
"types": "./dist-types/index.d.ts",
|
|
29
29
|
"dependencies": {
|
|
30
|
-
"@smithy/core": "^3.24.
|
|
30
|
+
"@smithy/core": "^3.24.5",
|
|
31
31
|
"@smithy/types": "^4.14.2",
|
|
32
32
|
"tslib": "^2.6.2"
|
|
33
33
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/node-http-handler",
|
|
3
|
-
"version": "4.7.
|
|
3
|
+
"version": "4.7.5",
|
|
4
4
|
"description": "Provides a way to make requests",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:types' 'yarn:build:es:cjs'",
|
|
@@ -26,7 +26,7 @@
|
|
|
26
26
|
"module": "./dist-es/index.js",
|
|
27
27
|
"types": "./dist-types/index.d.ts",
|
|
28
28
|
"dependencies": {
|
|
29
|
-
"@smithy/core": "^3.24.
|
|
29
|
+
"@smithy/core": "^3.24.5",
|
|
30
30
|
"@smithy/types": "^4.14.2",
|
|
31
31
|
"tslib": "^2.6.2"
|
|
32
32
|
},
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/signature-v4",
|
|
3
|
-
"version": "5.4.
|
|
3
|
+
"version": "5.4.5",
|
|
4
4
|
"description": "A standalone implementation of the AWS Signature V4 request signing algorithm",
|
|
5
5
|
"main": "./dist-cjs/index.js",
|
|
6
6
|
"module": "./dist-es/index.js",
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
"license": "Apache-2.0",
|
|
26
26
|
"sideEffects": false,
|
|
27
27
|
"dependencies": {
|
|
28
|
-
"@smithy/core": "^3.24.
|
|
28
|
+
"@smithy/core": "^3.24.5",
|
|
29
29
|
"@smithy/types": "^4.14.2",
|
|
30
30
|
"tslib": "^2.6.2"
|
|
31
31
|
},
|
|
@@ -109,6 +109,28 @@ const parser = createParser({
|
|
|
109
109
|
> [!NOTE]
|
|
110
110
|
> Leading whitespace is not stripped from comments, eg `: comment` will give ` comment` as the comment value, not `comment` (note the leading space).
|
|
111
111
|
|
|
112
|
+
### Limiting buffered memory (`maxBufferSize`)
|
|
113
|
+
|
|
114
|
+
By default the parser buffers data indefinitely until a server completes an event. A server (or proxy) that never terminates a line, or that keeps appending `data:` lines without ever sending a blank line to dispatch the event, can therefore grow the parser's buffers without bound.
|
|
115
|
+
|
|
116
|
+
Pass a `maxBufferSize` (in characters) to `createParser` to cap this. If the combined size of the pending line buffer and the in-progress event's data buffer exceeds the limit, the parser emits a `ParseError` with `type: 'max-buffer-size-exceeded'` and becomes terminated: subsequent calls to `feed()` will throw until `reset()` is called.
|
|
117
|
+
|
|
118
|
+
```ts
|
|
119
|
+
const parser = createParser({
|
|
120
|
+
maxBufferSize: 1024 * 1024, // 1 MB
|
|
121
|
+
onEvent(event) {
|
|
122
|
+
// …
|
|
123
|
+
},
|
|
124
|
+
onError(error) {
|
|
125
|
+
if (error.type === 'max-buffer-size-exceeded') {
|
|
126
|
+
// Stream peer is misbehaving — typically you'd close the connection.
|
|
127
|
+
}
|
|
128
|
+
},
|
|
129
|
+
})
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
The same option is available on the [stream variant](#stream-usage); the stream is always errored when this limit is exceeded, regardless of the `onError` setting (since the underlying parser is unrecoverable without a `reset()`).
|
|
133
|
+
|
|
112
134
|
## Stream usage
|
|
113
135
|
|
|
114
136
|
```ts
|
|
@@ -119,6 +141,15 @@ const eventStream = response.body
|
|
|
119
141
|
.pipeThrough(new EventSourceParserStream())
|
|
120
142
|
```
|
|
121
143
|
|
|
144
|
+
The stream constructor accepts a subset of the `createParser` options (`onComment`, `onRetry`, `maxBufferSize`) plus an `onError` that can either be a function or set to `'terminate'` to error the stream on parse errors. Events are delivered through the stream itself rather than via an `onEvent` callback:
|
|
145
|
+
|
|
146
|
+
```ts
|
|
147
|
+
new EventSourceParserStream({
|
|
148
|
+
maxBufferSize: 1024 * 1024,
|
|
149
|
+
onError: 'terminate',
|
|
150
|
+
})
|
|
151
|
+
```
|
|
152
|
+
|
|
122
153
|
Note that the TransformStream is exposed under a separate export (`eventsource-parser/stream`), in order to maximize compatibility with environments that do not have the `TransformStream` constructor available.
|
|
123
154
|
|
|
124
155
|
## License
|
|
@@ -8,29 +8,40 @@ class ParseError extends Error {
|
|
|
8
8
|
const LF = 10, CR = 13, SPACE = 32;
|
|
9
9
|
function noop(_arg) {
|
|
10
10
|
}
|
|
11
|
-
function createParser(
|
|
12
|
-
if (typeof
|
|
11
|
+
function createParser(config) {
|
|
12
|
+
if (typeof config == "function")
|
|
13
13
|
throw new TypeError(
|
|
14
|
-
"`
|
|
14
|
+
"`config` must be an object, got a function instead. Did you mean `createParser({onEvent: fn})`?"
|
|
15
15
|
);
|
|
16
|
-
const { onEvent = noop, onError = noop, onRetry = noop, onComment } =
|
|
17
|
-
let isFirstChunk = !0, id, data = "", dataLines = 0, eventType;
|
|
16
|
+
const { onEvent = noop, onError = noop, onRetry = noop, onComment, maxBufferSize } = config, pendingFragments = [];
|
|
17
|
+
let pendingFragmentsLength = 0, isFirstChunk = !0, id, data = "", dataLines = 0, eventType, terminated = !1;
|
|
18
18
|
function feed(chunk) {
|
|
19
|
+
if (terminated)
|
|
20
|
+
throw new Error(
|
|
21
|
+
"Cannot feed parser: it was terminated after exceeding the configured max buffer size. Call `reset()` to resume parsing."
|
|
22
|
+
);
|
|
19
23
|
if (isFirstChunk && (isFirstChunk = !1, chunk.charCodeAt(0) === 239 && chunk.charCodeAt(1) === 187 && chunk.charCodeAt(2) === 191 && (chunk = chunk.slice(3))), pendingFragments.length === 0) {
|
|
20
24
|
const trailing2 = processLines(chunk);
|
|
21
|
-
trailing2 !== "" && pendingFragments.push(trailing2);
|
|
25
|
+
trailing2 !== "" && (pendingFragments.push(trailing2), pendingFragmentsLength = trailing2.length), checkBufferSize();
|
|
22
26
|
return;
|
|
23
27
|
}
|
|
24
28
|
if (chunk.indexOf(`
|
|
25
29
|
`) === -1 && chunk.indexOf("\r") === -1) {
|
|
26
|
-
pendingFragments.push(chunk);
|
|
30
|
+
pendingFragments.push(chunk), pendingFragmentsLength += chunk.length, checkBufferSize();
|
|
27
31
|
return;
|
|
28
32
|
}
|
|
29
33
|
pendingFragments.push(chunk);
|
|
30
34
|
const input = pendingFragments.join("");
|
|
31
|
-
pendingFragments.length = 0;
|
|
35
|
+
pendingFragments.length = 0, pendingFragmentsLength = 0;
|
|
32
36
|
const trailing = processLines(input);
|
|
33
|
-
trailing !== "" && pendingFragments.push(trailing);
|
|
37
|
+
trailing !== "" && (pendingFragments.push(trailing), pendingFragmentsLength = trailing.length), checkBufferSize();
|
|
38
|
+
}
|
|
39
|
+
function checkBufferSize() {
|
|
40
|
+
maxBufferSize !== void 0 && (pendingFragmentsLength + data.length <= maxBufferSize || (terminated = !0, pendingFragments.length = 0, pendingFragmentsLength = 0, id = void 0, data = "", dataLines = 0, eventType = void 0, onError(
|
|
41
|
+
new ParseError(`Buffered data exceeded max buffer size of ${maxBufferSize} characters`, {
|
|
42
|
+
type: "max-buffer-size-exceeded"
|
|
43
|
+
})
|
|
44
|
+
)));
|
|
34
45
|
}
|
|
35
46
|
function processLines(chunk) {
|
|
36
47
|
let searchIndex = 0;
|
|
@@ -151,7 +162,7 @@ ${value}`, dataLines++;
|
|
|
151
162
|
const incompleteLine = pendingFragments.join("");
|
|
152
163
|
parseLine(incompleteLine, 0, incompleteLine.length);
|
|
153
164
|
}
|
|
154
|
-
isFirstChunk = !0, id = void 0, data = "", dataLines = 0, eventType = void 0, pendingFragments.length = 0;
|
|
165
|
+
isFirstChunk = !0, id = void 0, data = "", dataLines = 0, eventType = void 0, pendingFragments.length = 0, pendingFragmentsLength = 0, terminated = !1;
|
|
155
166
|
}
|
|
156
167
|
return { feed, reset };
|
|
157
168
|
}
|
|
@@ -6,29 +6,40 @@ class ParseError extends Error {
|
|
|
6
6
|
const LF = 10, CR = 13, SPACE = 32;
|
|
7
7
|
function noop(_arg) {
|
|
8
8
|
}
|
|
9
|
-
function createParser(
|
|
10
|
-
if (typeof
|
|
9
|
+
function createParser(config) {
|
|
10
|
+
if (typeof config == "function")
|
|
11
11
|
throw new TypeError(
|
|
12
|
-
"`
|
|
12
|
+
"`config` must be an object, got a function instead. Did you mean `createParser({onEvent: fn})`?"
|
|
13
13
|
);
|
|
14
|
-
const { onEvent = noop, onError = noop, onRetry = noop, onComment } =
|
|
15
|
-
let isFirstChunk = !0, id, data = "", dataLines = 0, eventType;
|
|
14
|
+
const { onEvent = noop, onError = noop, onRetry = noop, onComment, maxBufferSize } = config, pendingFragments = [];
|
|
15
|
+
let pendingFragmentsLength = 0, isFirstChunk = !0, id, data = "", dataLines = 0, eventType, terminated = !1;
|
|
16
16
|
function feed(chunk) {
|
|
17
|
+
if (terminated)
|
|
18
|
+
throw new Error(
|
|
19
|
+
"Cannot feed parser: it was terminated after exceeding the configured max buffer size. Call `reset()` to resume parsing."
|
|
20
|
+
);
|
|
17
21
|
if (isFirstChunk && (isFirstChunk = !1, chunk.charCodeAt(0) === 239 && chunk.charCodeAt(1) === 187 && chunk.charCodeAt(2) === 191 && (chunk = chunk.slice(3))), pendingFragments.length === 0) {
|
|
18
22
|
const trailing2 = processLines(chunk);
|
|
19
|
-
trailing2 !== "" && pendingFragments.push(trailing2);
|
|
23
|
+
trailing2 !== "" && (pendingFragments.push(trailing2), pendingFragmentsLength = trailing2.length), checkBufferSize();
|
|
20
24
|
return;
|
|
21
25
|
}
|
|
22
26
|
if (chunk.indexOf(`
|
|
23
27
|
`) === -1 && chunk.indexOf("\r") === -1) {
|
|
24
|
-
pendingFragments.push(chunk);
|
|
28
|
+
pendingFragments.push(chunk), pendingFragmentsLength += chunk.length, checkBufferSize();
|
|
25
29
|
return;
|
|
26
30
|
}
|
|
27
31
|
pendingFragments.push(chunk);
|
|
28
32
|
const input = pendingFragments.join("");
|
|
29
|
-
pendingFragments.length = 0;
|
|
33
|
+
pendingFragments.length = 0, pendingFragmentsLength = 0;
|
|
30
34
|
const trailing = processLines(input);
|
|
31
|
-
trailing !== "" && pendingFragments.push(trailing);
|
|
35
|
+
trailing !== "" && (pendingFragments.push(trailing), pendingFragmentsLength = trailing.length), checkBufferSize();
|
|
36
|
+
}
|
|
37
|
+
function checkBufferSize() {
|
|
38
|
+
maxBufferSize !== void 0 && (pendingFragmentsLength + data.length <= maxBufferSize || (terminated = !0, pendingFragments.length = 0, pendingFragmentsLength = 0, id = void 0, data = "", dataLines = 0, eventType = void 0, onError(
|
|
39
|
+
new ParseError(`Buffered data exceeded max buffer size of ${maxBufferSize} characters`, {
|
|
40
|
+
type: "max-buffer-size-exceeded"
|
|
41
|
+
})
|
|
42
|
+
)));
|
|
32
43
|
}
|
|
33
44
|
function processLines(chunk) {
|
|
34
45
|
let searchIndex = 0;
|
|
@@ -149,7 +160,7 @@ ${value}`, dataLines++;
|
|
|
149
160
|
const incompleteLine = pendingFragments.join("");
|
|
150
161
|
parseLine(incompleteLine, 0, incompleteLine.length);
|
|
151
162
|
}
|
|
152
|
-
isFirstChunk = !0, id = void 0, data = "", dataLines = 0, eventType = void 0, pendingFragments.length = 0;
|
|
163
|
+
isFirstChunk = !0, id = void 0, data = "", dataLines = 0, eventType = void 0, pendingFragments.length = 0, pendingFragmentsLength = 0, terminated = !1;
|
|
153
164
|
}
|
|
154
165
|
return { feed, reset };
|
|
155
166
|
}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: !0 });
|
|
3
3
|
var index = require("./index.cjs");
|
|
4
4
|
class EventSourceParserStream extends TransformStream {
|
|
5
|
-
constructor({ onError, onRetry, onComment } = {}) {
|
|
5
|
+
constructor({ onError, onRetry, onComment, maxBufferSize } = {}) {
|
|
6
6
|
let parser;
|
|
7
7
|
super({
|
|
8
8
|
start(controller) {
|
|
@@ -11,10 +11,11 @@ class EventSourceParserStream extends TransformStream {
|
|
|
11
11
|
controller.enqueue(event);
|
|
12
12
|
},
|
|
13
13
|
onError(error) {
|
|
14
|
-
onError
|
|
14
|
+
typeof onError == "function" && onError(error), (onError === "terminate" || error.type === "max-buffer-size-exceeded") && controller.error(error);
|
|
15
15
|
},
|
|
16
16
|
onRetry,
|
|
17
|
-
onComment
|
|
17
|
+
onComment,
|
|
18
|
+
maxBufferSize
|
|
18
19
|
});
|
|
19
20
|
},
|
|
20
21
|
transform(chunk) {
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { createParser } from "./index.js";
|
|
2
2
|
import { ParseError } from "./index.js";
|
|
3
3
|
class EventSourceParserStream extends TransformStream {
|
|
4
|
-
constructor({ onError, onRetry, onComment } = {}) {
|
|
4
|
+
constructor({ onError, onRetry, onComment, maxBufferSize } = {}) {
|
|
5
5
|
let parser;
|
|
6
6
|
super({
|
|
7
7
|
start(controller) {
|
|
@@ -10,10 +10,11 @@ class EventSourceParserStream extends TransformStream {
|
|
|
10
10
|
controller.enqueue(event);
|
|
11
11
|
},
|
|
12
12
|
onError(error) {
|
|
13
|
-
onError
|
|
13
|
+
typeof onError == "function" && onError(error), (onError === "terminate" || error.type === "max-buffer-size-exceeded") && controller.error(error);
|
|
14
14
|
},
|
|
15
15
|
onRetry,
|
|
16
|
-
onComment
|
|
16
|
+
onComment,
|
|
17
|
+
maxBufferSize
|
|
17
18
|
});
|
|
18
19
|
},
|
|
19
20
|
transform(chunk) {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "eventsource-parser",
|
|
3
|
-
"version": "3.0
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"description": "Streaming, source-agnostic EventSource/Server-Sent Events parser",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"eventsource",
|
|
@@ -63,21 +63,21 @@
|
|
|
63
63
|
"test:node": "vitest --reporter=verbose"
|
|
64
64
|
},
|
|
65
65
|
"devDependencies": {
|
|
66
|
-
"@sanity/pkg-utils": "^10.4.
|
|
66
|
+
"@sanity/pkg-utils": "^10.4.18",
|
|
67
67
|
"@sanity/semantic-release-preset": "^6.0.0",
|
|
68
68
|
"@sanity/tsconfig": "^2.1.0",
|
|
69
69
|
"@types/node": "^20.19.0",
|
|
70
|
-
"eventsource-encoder": "^1.0.
|
|
71
|
-
"knip": "^6.
|
|
70
|
+
"eventsource-encoder": "^1.0.2",
|
|
71
|
+
"knip": "^6.7.0",
|
|
72
72
|
"mitata": "^1.0.34",
|
|
73
|
-
"oxfmt": "^0.
|
|
74
|
-
"oxlint": "^1.
|
|
73
|
+
"oxfmt": "^0.47.0",
|
|
74
|
+
"oxlint": "^1.62.0",
|
|
75
75
|
"rimraf": "^6.1.3",
|
|
76
76
|
"rollup-plugin-visualizer": "^6.0.3",
|
|
77
77
|
"semantic-release": "^25.0.3",
|
|
78
|
-
"terser": "^5.46.
|
|
78
|
+
"terser": "^5.46.2",
|
|
79
79
|
"typescript": "^5.9.3",
|
|
80
|
-
"vitest": "^4.1.
|
|
80
|
+
"vitest": "^4.1.5"
|
|
81
81
|
},
|
|
82
82
|
"browserslist": [
|
|
83
83
|
"node >= 18",
|
package/package.json
CHANGED
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getSmithyContext = void 0;
|
|
4
|
-
const types_1 = require("@smithy/types");
|
|
5
|
-
const getSmithyContext = (context) => context[types_1.SMITHY_CONTEXT_KEY] || (context[types_1.SMITHY_CONTEXT_KEY] = {});
|
|
6
|
-
exports.getSmithyContext = getSmithyContext;
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getHttpAuthSchemeEndpointRuleSetPlugin = exports.httpAuthSchemeEndpointRuleSetMiddlewareOptions = void 0;
|
|
4
|
-
const httpAuthSchemeMiddleware_1 = require("./httpAuthSchemeMiddleware");
|
|
5
|
-
exports.httpAuthSchemeEndpointRuleSetMiddlewareOptions = {
|
|
6
|
-
step: "serialize",
|
|
7
|
-
tags: ["HTTP_AUTH_SCHEME"],
|
|
8
|
-
name: "httpAuthSchemeMiddleware",
|
|
9
|
-
override: true,
|
|
10
|
-
relation: "before",
|
|
11
|
-
toMiddleware: "endpointV2Middleware",
|
|
12
|
-
};
|
|
13
|
-
const getHttpAuthSchemeEndpointRuleSetPlugin = (config, { httpAuthSchemeParametersProvider, identityProviderConfigProvider, }) => ({
|
|
14
|
-
applyToStack: (clientStack) => {
|
|
15
|
-
clientStack.addRelativeTo((0, httpAuthSchemeMiddleware_1.httpAuthSchemeMiddleware)(config, {
|
|
16
|
-
httpAuthSchemeParametersProvider,
|
|
17
|
-
identityProviderConfigProvider,
|
|
18
|
-
}), exports.httpAuthSchemeEndpointRuleSetMiddlewareOptions);
|
|
19
|
-
},
|
|
20
|
-
});
|
|
21
|
-
exports.getHttpAuthSchemeEndpointRuleSetPlugin = getHttpAuthSchemeEndpointRuleSetPlugin;
|
package/node_modules/@smithy/core/dist-cjs/middleware-http-auth-scheme/getHttpAuthSchemePlugin.js
DELETED
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.getHttpAuthSchemePlugin = exports.httpAuthSchemeMiddlewareOptions = void 0;
|
|
4
|
-
const httpAuthSchemeMiddleware_1 = require("./httpAuthSchemeMiddleware");
|
|
5
|
-
exports.httpAuthSchemeMiddlewareOptions = {
|
|
6
|
-
step: "serialize",
|
|
7
|
-
tags: ["HTTP_AUTH_SCHEME"],
|
|
8
|
-
name: "httpAuthSchemeMiddleware",
|
|
9
|
-
override: true,
|
|
10
|
-
relation: "before",
|
|
11
|
-
toMiddleware: "serializerMiddleware",
|
|
12
|
-
};
|
|
13
|
-
const getHttpAuthSchemePlugin = (config, { httpAuthSchemeParametersProvider, identityProviderConfigProvider, }) => ({
|
|
14
|
-
applyToStack: (clientStack) => {
|
|
15
|
-
clientStack.addRelativeTo((0, httpAuthSchemeMiddleware_1.httpAuthSchemeMiddleware)(config, {
|
|
16
|
-
httpAuthSchemeParametersProvider,
|
|
17
|
-
identityProviderConfigProvider,
|
|
18
|
-
}), exports.httpAuthSchemeMiddlewareOptions);
|
|
19
|
-
},
|
|
20
|
-
});
|
|
21
|
-
exports.getHttpAuthSchemePlugin = getHttpAuthSchemePlugin;
|