@jjrawlins/cdk-iam-policy-builder-helper 0.0.57 → 0.0.59
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/.jsii +3 -3
- package/cdk-iam-policy-builder-helper/go.mod +2 -2
- package/cdk-iam-policy-builder-helper/jsii/jsii.go +2 -2
- package/cdk-iam-policy-builder-helper/version +1 -1
- package/node_modules/@aws-sdk/client-iam/package.json +34 -34
- package/node_modules/@aws-sdk/client-sso/package.json +32 -32
- package/node_modules/@aws-sdk/core/dist-cjs/index.js +6 -6
- package/node_modules/@aws-sdk/core/dist-cjs/submodules/protocols/index.js +6 -6
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/cbor/AwsSmithyRpcV2CborProtocol.js +1 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsJsonRpcProtocol.js +2 -2
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/json/AwsRestJsonProtocol.js +1 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/query/AwsQueryProtocol.js +1 -1
- package/node_modules/@aws-sdk/core/dist-es/submodules/protocols/xml/AwsRestXmlProtocol.js +1 -1
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/ProtocolLib.d.ts +4 -4
- package/node_modules/@aws-sdk/core/dist-types/submodules/protocols/xml/AwsRestXmlProtocol.d.ts +1 -2
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/ProtocolLib.d.ts +7 -7
- package/node_modules/@aws-sdk/core/dist-types/ts3.4/submodules/protocols/xml/AwsRestXmlProtocol.d.ts +1 -1
- package/node_modules/@aws-sdk/core/package.json +11 -11
- package/node_modules/@aws-sdk/credential-provider-env/package.json +5 -5
- package/node_modules/@aws-sdk/credential-provider-http/package.json +10 -10
- package/node_modules/@aws-sdk/credential-provider-ini/package.json +13 -13
- package/node_modules/@aws-sdk/credential-provider-node/package.json +12 -12
- package/node_modules/@aws-sdk/credential-provider-process/package.json +6 -6
- package/node_modules/@aws-sdk/credential-provider-sso/package.json +8 -8
- package/node_modules/@aws-sdk/credential-provider-web-identity/package.json +7 -7
- package/node_modules/@aws-sdk/middleware-host-header/dist-cjs/index.js +35 -63
- package/node_modules/@aws-sdk/middleware-host-header/package.json +4 -4
- package/node_modules/@aws-sdk/middleware-logger/dist-cjs/index.js +44 -75
- package/node_modules/@aws-sdk/middleware-logger/package.json +3 -3
- package/node_modules/@aws-sdk/middleware-recursion-detection/dist-cjs/index.js +19 -48
- package/node_modules/@aws-sdk/middleware-recursion-detection/package.json +4 -4
- package/node_modules/@aws-sdk/middleware-user-agent/package.json +7 -7
- package/node_modules/@aws-sdk/nested-clients/package.json +32 -32
- package/node_modules/@aws-sdk/region-config-resolver/dist-cjs/index.js +59 -95
- package/node_modules/@aws-sdk/region-config-resolver/package.json +5 -5
- package/node_modules/@aws-sdk/token-providers/package.json +7 -7
- package/node_modules/@aws-sdk/types/dist-cjs/index.js +18 -290
- package/node_modules/@aws-sdk/types/package.json +2 -2
- package/node_modules/@aws-sdk/util-endpoints/dist-cjs/index.js +395 -469
- package/node_modules/@aws-sdk/util-endpoints/package.json +5 -5
- package/node_modules/@aws-sdk/util-user-agent-browser/package.json +3 -3
- package/node_modules/@aws-sdk/util-user-agent-node/package.json +5 -5
- package/node_modules/@aws-sdk/xml-builder/dist-cjs/index.js +106 -160
- package/node_modules/@aws-sdk/xml-builder/dist-es/xml-parser.browser.js +4 -1
- package/node_modules/@aws-sdk/xml-builder/package.json +2 -2
- package/node_modules/@smithy/abort-controller/package.json +2 -2
- package/node_modules/@smithy/config-resolver/package.json +4 -4
- package/node_modules/@smithy/core/dist-cjs/submodules/event-streams/index.js +1 -2
- package/node_modules/@smithy/core/dist-cjs/submodules/protocols/index.js +3 -3
- package/node_modules/@smithy/core/dist-cjs/submodules/schema/index.js +235 -220
- package/node_modules/@smithy/core/dist-es/submodules/event-streams/EventStreamSerde.js +1 -2
- package/node_modules/@smithy/core/dist-es/submodules/protocols/HttpProtocol.js +4 -4
- package/node_modules/@smithy/core/dist-es/submodules/schema/TypeRegistry.js +16 -9
- package/node_modules/@smithy/core/dist-es/submodules/schema/index.js +1 -0
- package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaDeserializationMiddleware.js +4 -6
- package/node_modules/@smithy/core/dist-es/submodules/schema/middleware/schemaSerializationMiddleware.js +4 -6
- package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/NormalizedSchema.js +26 -35
- package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/Schema.js +0 -2
- package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/SimpleSchema.js +6 -0
- package/node_modules/@smithy/core/dist-es/submodules/schema/schemas/operation.js +7 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/TypeRegistry.d.ts +1 -2
- package/node_modules/@smithy/core/dist-types/submodules/schema/index.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/ErrorSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/ListSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/MapSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/NormalizedSchema.d.ts +4 -21
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/OperationSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/Schema.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/SimpleSchema.d.ts +7 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/StructureSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/submodules/schema/schemas/operation.d.ts +7 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/TypeRegistry.d.ts +1 -2
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/index.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/ErrorSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/ListSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/MapSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/NormalizedSchema.d.ts +4 -21
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/OperationSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/Schema.d.ts +1 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/SimpleSchema.d.ts +7 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/StructureSchema.d.ts +2 -0
- package/node_modules/@smithy/core/dist-types/ts3.4/submodules/schema/schemas/operation.d.ts +7 -0
- package/node_modules/@smithy/core/package.json +7 -7
- package/node_modules/@smithy/credential-provider-imds/package.json +5 -5
- package/node_modules/@smithy/fetch-http-handler/package.json +5 -5
- package/node_modules/@smithy/hash-node/package.json +2 -2
- package/node_modules/@smithy/invalid-dependency/package.json +2 -2
- package/node_modules/@smithy/middleware-content-length/package.json +3 -3
- package/node_modules/@smithy/middleware-endpoint/package.json +8 -8
- package/node_modules/@smithy/middleware-retry/package.json +8 -8
- package/node_modules/@smithy/middleware-serde/package.json +3 -3
- package/node_modules/@smithy/middleware-stack/package.json +2 -2
- package/node_modules/@smithy/node-config-provider/package.json +4 -4
- package/node_modules/@smithy/node-http-handler/package.json +5 -5
- package/node_modules/@smithy/property-provider/package.json +2 -2
- package/node_modules/@smithy/protocol-http/package.json +2 -2
- package/node_modules/@smithy/querystring-builder/package.json +2 -2
- package/node_modules/@smithy/querystring-parser/package.json +2 -2
- package/node_modules/@smithy/service-error-classification/package.json +2 -2
- package/node_modules/@smithy/shared-ini-file-loader/dist-cjs/index.js +2 -1
- package/node_modules/@smithy/shared-ini-file-loader/dist-es/constants.js +1 -0
- package/node_modules/@smithy/shared-ini-file-loader/dist-es/getConfigData.js +1 -1
- package/node_modules/@smithy/shared-ini-file-loader/dist-es/loadSharedConfigFiles.js +1 -1
- package/node_modules/@smithy/shared-ini-file-loader/dist-es/parseIni.js +1 -1
- package/node_modules/@smithy/shared-ini-file-loader/dist-types/constants.d.ts +4 -0
- package/node_modules/@smithy/shared-ini-file-loader/dist-types/loadSharedConfigFiles.d.ts +1 -4
- package/node_modules/@smithy/shared-ini-file-loader/dist-types/ts3.4/constants.d.ts +4 -0
- package/node_modules/@smithy/shared-ini-file-loader/dist-types/ts3.4/loadSharedConfigFiles.d.ts +1 -4
- package/node_modules/@smithy/shared-ini-file-loader/package.json +2 -2
- package/node_modules/@smithy/signature-v4/package.json +4 -4
- package/node_modules/@smithy/smithy-client/package.json +7 -7
- package/node_modules/@smithy/types/dist-es/index.js +1 -0
- package/node_modules/@smithy/types/dist-es/schema/schema-deprecated.js +1 -0
- package/node_modules/@smithy/types/dist-types/index.d.ts +1 -0
- package/node_modules/@smithy/types/dist-types/schema/schema-deprecated.d.ts +136 -0
- package/node_modules/@smithy/types/dist-types/schema/schema.d.ts +26 -68
- package/node_modules/@smithy/types/dist-types/schema/static-schemas.d.ts +8 -8
- package/node_modules/@smithy/types/dist-types/serde.d.ts +2 -2
- package/node_modules/@smithy/types/dist-types/ts3.4/index.d.ts +1 -0
- package/node_modules/@smithy/types/dist-types/ts3.4/schema/schema-deprecated.d.ts +142 -0
- package/node_modules/@smithy/types/dist-types/ts3.4/schema/schema.d.ts +27 -72
- package/node_modules/@smithy/types/dist-types/ts3.4/schema/static-schemas.d.ts +10 -10
- package/node_modules/@smithy/types/dist-types/ts3.4/serde.d.ts +2 -2
- package/node_modules/@smithy/types/package.json +1 -1
- package/node_modules/@smithy/url-parser/package.json +3 -3
- package/node_modules/@smithy/util-defaults-mode-browser/package.json +4 -4
- package/node_modules/@smithy/util-defaults-mode-node/package.json +7 -7
- package/node_modules/@smithy/util-endpoints/dist-cjs/index.js +31 -22
- package/node_modules/@smithy/util-endpoints/dist-es/utils/callFunction.js +1 -11
- package/node_modules/@smithy/util-endpoints/dist-es/utils/evaluateExpression.js +15 -2
- package/node_modules/@smithy/util-endpoints/dist-es/utils/evaluateRules.js +17 -2
- package/node_modules/@smithy/util-endpoints/dist-es/utils/evaluateTreeRule.js +1 -13
- package/node_modules/@smithy/util-endpoints/dist-es/utils/getEndpointProperties.js +25 -2
- package/node_modules/@smithy/util-endpoints/dist-es/utils/getEndpointProperty.js +1 -21
- package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/callFunction.d.ts +1 -2
- package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/evaluateExpression.d.ts +7 -2
- package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/evaluateRules.d.ts +6 -1
- package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/evaluateTreeRule.d.ts +1 -3
- package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/getEndpointProperties.d.ts +6 -0
- package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/getEndpointProperty.d.ts +1 -3
- package/node_modules/@smithy/util-endpoints/dist-types/utils/callFunction.d.ts +1 -2
- package/node_modules/@smithy/util-endpoints/dist-types/utils/evaluateExpression.d.ts +7 -2
- package/node_modules/@smithy/util-endpoints/dist-types/utils/evaluateRules.d.ts +6 -1
- package/node_modules/@smithy/util-endpoints/dist-types/utils/evaluateTreeRule.d.ts +1 -3
- package/node_modules/@smithy/util-endpoints/dist-types/utils/getEndpointProperties.d.ts +6 -0
- package/node_modules/@smithy/util-endpoints/dist-types/utils/getEndpointProperty.d.ts +1 -3
- package/node_modules/@smithy/util-endpoints/package.json +3 -3
- package/node_modules/@smithy/util-middleware/package.json +2 -2
- package/node_modules/@smithy/util-retry/package.json +3 -3
- package/node_modules/@smithy/util-stream/dist-cjs/index.js +8 -15
- package/node_modules/@smithy/util-stream/dist-es/blob/Uint8ArrayBlobAdapter.js +10 -3
- package/node_modules/@smithy/util-stream/package.json +4 -4
- package/node_modules/@smithy/util-waiter/package.json +3 -3
- package/package.json +5 -5
- package/node_modules/@smithy/util-stream/dist-es/blob/transforms.js +0 -15
- package/node_modules/@smithy/util-stream/dist-types/blob/transforms.d.ts +0 -9
- package/node_modules/@smithy/util-stream/dist-types/ts3.4/blob/transforms.d.ts +0 -9
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-defaults-mode-browser",
|
|
3
|
-
"version": "4.3.
|
|
3
|
+
"version": "4.3.3",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
|
|
6
6
|
"build:cjs": "node ../../scripts/inline util-defaults-mode-browser",
|
|
@@ -24,9 +24,9 @@
|
|
|
24
24
|
"license": "Apache-2.0",
|
|
25
25
|
"sideEffects": false,
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@smithy/property-provider": "^4.2.
|
|
28
|
-
"@smithy/smithy-client": "^4.
|
|
29
|
-
"@smithy/types": "^4.
|
|
27
|
+
"@smithy/property-provider": "^4.2.3",
|
|
28
|
+
"@smithy/smithy-client": "^4.9.0",
|
|
29
|
+
"@smithy/types": "^4.8.0",
|
|
30
30
|
"tslib": "^2.6.2"
|
|
31
31
|
},
|
|
32
32
|
"devDependencies": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-defaults-mode-node",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.4",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
|
|
6
6
|
"build:cjs": "node ../../scripts/inline util-defaults-mode-node",
|
|
@@ -24,12 +24,12 @@
|
|
|
24
24
|
"license": "Apache-2.0",
|
|
25
25
|
"sideEffects": false,
|
|
26
26
|
"dependencies": {
|
|
27
|
-
"@smithy/config-resolver": "^4.3.
|
|
28
|
-
"@smithy/credential-provider-imds": "^4.2.
|
|
29
|
-
"@smithy/node-config-provider": "^4.3.
|
|
30
|
-
"@smithy/property-provider": "^4.2.
|
|
31
|
-
"@smithy/smithy-client": "^4.
|
|
32
|
-
"@smithy/types": "^4.
|
|
27
|
+
"@smithy/config-resolver": "^4.3.3",
|
|
28
|
+
"@smithy/credential-provider-imds": "^4.2.3",
|
|
29
|
+
"@smithy/node-config-provider": "^4.3.3",
|
|
30
|
+
"@smithy/property-provider": "^4.2.3",
|
|
31
|
+
"@smithy/smithy-client": "^4.9.0",
|
|
32
|
+
"@smithy/types": "^4.8.0",
|
|
33
33
|
"tslib": "^2.6.2"
|
|
34
34
|
},
|
|
35
35
|
"devDependencies": {
|
|
@@ -260,22 +260,25 @@ const evaluateExpression = (obj, keyName, options) => {
|
|
|
260
260
|
return evaluateTemplate(obj, options);
|
|
261
261
|
}
|
|
262
262
|
else if (obj["fn"]) {
|
|
263
|
-
return callFunction(obj, options);
|
|
263
|
+
return group$2.callFunction(obj, options);
|
|
264
264
|
}
|
|
265
265
|
else if (obj["ref"]) {
|
|
266
266
|
return getReferenceValue(obj, options);
|
|
267
267
|
}
|
|
268
268
|
throw new EndpointError(`'${keyName}': ${String(obj)} is not a string, function or reference.`);
|
|
269
269
|
};
|
|
270
|
-
|
|
271
270
|
const callFunction = ({ fn, argv }, options) => {
|
|
272
|
-
const evaluatedArgs = argv.map((arg) => ["boolean", "number"].includes(typeof arg) ? arg : evaluateExpression(arg, "arg", options));
|
|
271
|
+
const evaluatedArgs = argv.map((arg) => ["boolean", "number"].includes(typeof arg) ? arg : group$2.evaluateExpression(arg, "arg", options));
|
|
273
272
|
const fnSegments = fn.split(".");
|
|
274
273
|
if (fnSegments[0] in customEndpointFunctions && fnSegments[1] != null) {
|
|
275
274
|
return customEndpointFunctions[fnSegments[0]][fnSegments[1]](...evaluatedArgs);
|
|
276
275
|
}
|
|
277
276
|
return endpointFunctions[fn](...evaluatedArgs);
|
|
278
277
|
};
|
|
278
|
+
const group$2 = {
|
|
279
|
+
evaluateExpression,
|
|
280
|
+
callFunction,
|
|
281
|
+
};
|
|
279
282
|
|
|
280
283
|
const evaluateCondition = ({ assign, ...fnArgs }, options) => {
|
|
281
284
|
if (assign && assign in options.referenceRecord) {
|
|
@@ -321,6 +324,10 @@ const getEndpointHeaders = (headers, options) => Object.entries(headers).reduce(
|
|
|
321
324
|
}),
|
|
322
325
|
}), {});
|
|
323
326
|
|
|
327
|
+
const getEndpointProperties = (properties, options) => Object.entries(properties).reduce((acc, [propertyKey, propertyVal]) => ({
|
|
328
|
+
...acc,
|
|
329
|
+
[propertyKey]: group$1.getEndpointProperty(propertyVal, options),
|
|
330
|
+
}), {});
|
|
324
331
|
const getEndpointProperty = (property, options) => {
|
|
325
332
|
if (Array.isArray(property)) {
|
|
326
333
|
return property.map((propertyEntry) => getEndpointProperty(propertyEntry, options));
|
|
@@ -332,18 +339,17 @@ const getEndpointProperty = (property, options) => {
|
|
|
332
339
|
if (property === null) {
|
|
333
340
|
throw new EndpointError(`Unexpected endpoint property: ${property}`);
|
|
334
341
|
}
|
|
335
|
-
return getEndpointProperties(property, options);
|
|
342
|
+
return group$1.getEndpointProperties(property, options);
|
|
336
343
|
case "boolean":
|
|
337
344
|
return property;
|
|
338
345
|
default:
|
|
339
346
|
throw new EndpointError(`Unexpected endpoint property type: ${typeof property}`);
|
|
340
347
|
}
|
|
341
348
|
};
|
|
342
|
-
|
|
343
|
-
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
}), {});
|
|
349
|
+
const group$1 = {
|
|
350
|
+
getEndpointProperty,
|
|
351
|
+
getEndpointProperties,
|
|
352
|
+
};
|
|
347
353
|
|
|
348
354
|
const getEndpointUrl = (endpointUrl, options) => {
|
|
349
355
|
const expression = evaluateExpression(endpointUrl, "Endpoint URL", options);
|
|
@@ -394,18 +400,6 @@ const evaluateErrorRule = (errorRule, options) => {
|
|
|
394
400
|
}));
|
|
395
401
|
};
|
|
396
402
|
|
|
397
|
-
const evaluateTreeRule = (treeRule, options) => {
|
|
398
|
-
const { conditions, rules } = treeRule;
|
|
399
|
-
const { result, referenceRecord } = evaluateConditions(conditions, options);
|
|
400
|
-
if (!result) {
|
|
401
|
-
return;
|
|
402
|
-
}
|
|
403
|
-
return evaluateRules(rules, {
|
|
404
|
-
...options,
|
|
405
|
-
referenceRecord: { ...options.referenceRecord, ...referenceRecord },
|
|
406
|
-
});
|
|
407
|
-
};
|
|
408
|
-
|
|
409
403
|
const evaluateRules = (rules, options) => {
|
|
410
404
|
for (const rule of rules) {
|
|
411
405
|
if (rule.type === "endpoint") {
|
|
@@ -418,7 +412,7 @@ const evaluateRules = (rules, options) => {
|
|
|
418
412
|
evaluateErrorRule(rule, options);
|
|
419
413
|
}
|
|
420
414
|
else if (rule.type === "tree") {
|
|
421
|
-
const endpointOrUndefined = evaluateTreeRule(rule, options);
|
|
415
|
+
const endpointOrUndefined = group.evaluateTreeRule(rule, options);
|
|
422
416
|
if (endpointOrUndefined) {
|
|
423
417
|
return endpointOrUndefined;
|
|
424
418
|
}
|
|
@@ -429,6 +423,21 @@ const evaluateRules = (rules, options) => {
|
|
|
429
423
|
}
|
|
430
424
|
throw new EndpointError(`Rules evaluation failed`);
|
|
431
425
|
};
|
|
426
|
+
const evaluateTreeRule = (treeRule, options) => {
|
|
427
|
+
const { conditions, rules } = treeRule;
|
|
428
|
+
const { result, referenceRecord } = evaluateConditions(conditions, options);
|
|
429
|
+
if (!result) {
|
|
430
|
+
return;
|
|
431
|
+
}
|
|
432
|
+
return group.evaluateRules(rules, {
|
|
433
|
+
...options,
|
|
434
|
+
referenceRecord: { ...options.referenceRecord, ...referenceRecord },
|
|
435
|
+
});
|
|
436
|
+
};
|
|
437
|
+
const group = {
|
|
438
|
+
evaluateRules,
|
|
439
|
+
evaluateTreeRule,
|
|
440
|
+
};
|
|
432
441
|
|
|
433
442
|
const resolveEndpoint = (ruleSetObject, options) => {
|
|
434
443
|
const { endpointParams, logger } = options;
|
|
@@ -1,11 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { endpointFunctions } from "./endpointFunctions";
|
|
3
|
-
import { evaluateExpression } from "./evaluateExpression";
|
|
4
|
-
export const callFunction = ({ fn, argv }, options) => {
|
|
5
|
-
const evaluatedArgs = argv.map((arg) => ["boolean", "number"].includes(typeof arg) ? arg : evaluateExpression(arg, "arg", options));
|
|
6
|
-
const fnSegments = fn.split(".");
|
|
7
|
-
if (fnSegments[0] in customEndpointFunctions && fnSegments[1] != null) {
|
|
8
|
-
return customEndpointFunctions[fnSegments[0]][fnSegments[1]](...evaluatedArgs);
|
|
9
|
-
}
|
|
10
|
-
return endpointFunctions[fn](...evaluatedArgs);
|
|
11
|
-
};
|
|
1
|
+
export { callFunction } from "./evaluateExpression";
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { EndpointError } from "../types";
|
|
2
|
-
import {
|
|
2
|
+
import { customEndpointFunctions } from "./customEndpointFunctions";
|
|
3
|
+
import { endpointFunctions } from "./endpointFunctions";
|
|
3
4
|
import { evaluateTemplate } from "./evaluateTemplate";
|
|
4
5
|
import { getReferenceValue } from "./getReferenceValue";
|
|
5
6
|
export const evaluateExpression = (obj, keyName, options) => {
|
|
@@ -7,10 +8,22 @@ export const evaluateExpression = (obj, keyName, options) => {
|
|
|
7
8
|
return evaluateTemplate(obj, options);
|
|
8
9
|
}
|
|
9
10
|
else if (obj["fn"]) {
|
|
10
|
-
return callFunction(obj, options);
|
|
11
|
+
return group.callFunction(obj, options);
|
|
11
12
|
}
|
|
12
13
|
else if (obj["ref"]) {
|
|
13
14
|
return getReferenceValue(obj, options);
|
|
14
15
|
}
|
|
15
16
|
throw new EndpointError(`'${keyName}': ${String(obj)} is not a string, function or reference.`);
|
|
16
17
|
};
|
|
18
|
+
export const callFunction = ({ fn, argv }, options) => {
|
|
19
|
+
const evaluatedArgs = argv.map((arg) => ["boolean", "number"].includes(typeof arg) ? arg : group.evaluateExpression(arg, "arg", options));
|
|
20
|
+
const fnSegments = fn.split(".");
|
|
21
|
+
if (fnSegments[0] in customEndpointFunctions && fnSegments[1] != null) {
|
|
22
|
+
return customEndpointFunctions[fnSegments[0]][fnSegments[1]](...evaluatedArgs);
|
|
23
|
+
}
|
|
24
|
+
return endpointFunctions[fn](...evaluatedArgs);
|
|
25
|
+
};
|
|
26
|
+
export const group = {
|
|
27
|
+
evaluateExpression,
|
|
28
|
+
callFunction,
|
|
29
|
+
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { EndpointError } from "../types";
|
|
2
|
+
import { evaluateConditions } from "./evaluateConditions";
|
|
2
3
|
import { evaluateEndpointRule } from "./evaluateEndpointRule";
|
|
3
4
|
import { evaluateErrorRule } from "./evaluateErrorRule";
|
|
4
|
-
import { evaluateTreeRule } from "./evaluateTreeRule";
|
|
5
5
|
export const evaluateRules = (rules, options) => {
|
|
6
6
|
for (const rule of rules) {
|
|
7
7
|
if (rule.type === "endpoint") {
|
|
@@ -14,7 +14,7 @@ export const evaluateRules = (rules, options) => {
|
|
|
14
14
|
evaluateErrorRule(rule, options);
|
|
15
15
|
}
|
|
16
16
|
else if (rule.type === "tree") {
|
|
17
|
-
const endpointOrUndefined = evaluateTreeRule(rule, options);
|
|
17
|
+
const endpointOrUndefined = group.evaluateTreeRule(rule, options);
|
|
18
18
|
if (endpointOrUndefined) {
|
|
19
19
|
return endpointOrUndefined;
|
|
20
20
|
}
|
|
@@ -25,3 +25,18 @@ export const evaluateRules = (rules, options) => {
|
|
|
25
25
|
}
|
|
26
26
|
throw new EndpointError(`Rules evaluation failed`);
|
|
27
27
|
};
|
|
28
|
+
export const evaluateTreeRule = (treeRule, options) => {
|
|
29
|
+
const { conditions, rules } = treeRule;
|
|
30
|
+
const { result, referenceRecord } = evaluateConditions(conditions, options);
|
|
31
|
+
if (!result) {
|
|
32
|
+
return;
|
|
33
|
+
}
|
|
34
|
+
return group.evaluateRules(rules, {
|
|
35
|
+
...options,
|
|
36
|
+
referenceRecord: { ...options.referenceRecord, ...referenceRecord },
|
|
37
|
+
});
|
|
38
|
+
};
|
|
39
|
+
export const group = {
|
|
40
|
+
evaluateRules,
|
|
41
|
+
evaluateTreeRule,
|
|
42
|
+
};
|
|
@@ -1,13 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { evaluateRules } from "./evaluateRules";
|
|
3
|
-
export const evaluateTreeRule = (treeRule, options) => {
|
|
4
|
-
const { conditions, rules } = treeRule;
|
|
5
|
-
const { result, referenceRecord } = evaluateConditions(conditions, options);
|
|
6
|
-
if (!result) {
|
|
7
|
-
return;
|
|
8
|
-
}
|
|
9
|
-
return evaluateRules(rules, {
|
|
10
|
-
...options,
|
|
11
|
-
referenceRecord: { ...options.referenceRecord, ...referenceRecord },
|
|
12
|
-
});
|
|
13
|
-
};
|
|
1
|
+
export { evaluateTreeRule } from "./evaluateRules";
|
|
@@ -1,5 +1,28 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { EndpointError } from "../types";
|
|
2
|
+
import { evaluateTemplate } from "./evaluateTemplate";
|
|
2
3
|
export const getEndpointProperties = (properties, options) => Object.entries(properties).reduce((acc, [propertyKey, propertyVal]) => ({
|
|
3
4
|
...acc,
|
|
4
|
-
[propertyKey]: getEndpointProperty(propertyVal, options),
|
|
5
|
+
[propertyKey]: group.getEndpointProperty(propertyVal, options),
|
|
5
6
|
}), {});
|
|
7
|
+
export const getEndpointProperty = (property, options) => {
|
|
8
|
+
if (Array.isArray(property)) {
|
|
9
|
+
return property.map((propertyEntry) => getEndpointProperty(propertyEntry, options));
|
|
10
|
+
}
|
|
11
|
+
switch (typeof property) {
|
|
12
|
+
case "string":
|
|
13
|
+
return evaluateTemplate(property, options);
|
|
14
|
+
case "object":
|
|
15
|
+
if (property === null) {
|
|
16
|
+
throw new EndpointError(`Unexpected endpoint property: ${property}`);
|
|
17
|
+
}
|
|
18
|
+
return group.getEndpointProperties(property, options);
|
|
19
|
+
case "boolean":
|
|
20
|
+
return property;
|
|
21
|
+
default:
|
|
22
|
+
throw new EndpointError(`Unexpected endpoint property type: ${typeof property}`);
|
|
23
|
+
}
|
|
24
|
+
};
|
|
25
|
+
export const group = {
|
|
26
|
+
getEndpointProperty,
|
|
27
|
+
getEndpointProperties,
|
|
28
|
+
};
|
|
@@ -1,21 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { evaluateTemplate } from "./evaluateTemplate";
|
|
3
|
-
import { getEndpointProperties } from "./getEndpointProperties";
|
|
4
|
-
export const getEndpointProperty = (property, options) => {
|
|
5
|
-
if (Array.isArray(property)) {
|
|
6
|
-
return property.map((propertyEntry) => getEndpointProperty(propertyEntry, options));
|
|
7
|
-
}
|
|
8
|
-
switch (typeof property) {
|
|
9
|
-
case "string":
|
|
10
|
-
return evaluateTemplate(property, options);
|
|
11
|
-
case "object":
|
|
12
|
-
if (property === null) {
|
|
13
|
-
throw new EndpointError(`Unexpected endpoint property: ${property}`);
|
|
14
|
-
}
|
|
15
|
-
return getEndpointProperties(property, options);
|
|
16
|
-
case "boolean":
|
|
17
|
-
return property;
|
|
18
|
-
default:
|
|
19
|
-
throw new EndpointError(`Unexpected endpoint property type: ${typeof property}`);
|
|
20
|
-
}
|
|
21
|
-
};
|
|
1
|
+
export { getEndpointProperty } from "./getEndpointProperties";
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const callFunction: ({ fn, argv }: FunctionObject, options: EvaluateOptions) => FunctionReturn;
|
|
1
|
+
export { callFunction } from "./evaluateExpression";
|
|
@@ -1,2 +1,7 @@
|
|
|
1
|
-
import { EvaluateOptions, Expression } from "../types";
|
|
2
|
-
export declare const evaluateExpression: (obj: Expression, keyName: string, options: EvaluateOptions) =>
|
|
1
|
+
import { EvaluateOptions, Expression, FunctionObject, FunctionReturn } from "../types";
|
|
2
|
+
export declare const evaluateExpression: (obj: Expression, keyName: string, options: EvaluateOptions) => FunctionReturn;
|
|
3
|
+
export declare const callFunction: ({ fn, argv }: FunctionObject, options: EvaluateOptions) => FunctionReturn;
|
|
4
|
+
export declare const group: {
|
|
5
|
+
evaluateExpression: (obj: Expression, keyName: string, options: EvaluateOptions) => FunctionReturn;
|
|
6
|
+
callFunction: ({ fn, argv }: FunctionObject, options: EvaluateOptions) => FunctionReturn;
|
|
7
|
+
};
|
|
@@ -1,3 +1,8 @@
|
|
|
1
1
|
import { EndpointV2 } from "@smithy/types";
|
|
2
|
-
import { EvaluateOptions, RuleSetRules } from "../types";
|
|
2
|
+
import { EvaluateOptions, RuleSetRules, TreeRuleObject } from "../types";
|
|
3
3
|
export declare const evaluateRules: (rules: RuleSetRules, options: EvaluateOptions) => EndpointV2;
|
|
4
|
+
export declare const evaluateTreeRule: (treeRule: TreeRuleObject, options: EvaluateOptions) => EndpointV2 | undefined;
|
|
5
|
+
export declare const group: {
|
|
6
|
+
evaluateRules: (rules: RuleSetRules, options: EvaluateOptions) => EndpointV2;
|
|
7
|
+
evaluateTreeRule: (treeRule: TreeRuleObject, options: EvaluateOptions) => EndpointV2 | undefined;
|
|
8
|
+
};
|
|
@@ -1,3 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { EvaluateOptions, TreeRuleObject } from "../types";
|
|
3
|
-
export declare const evaluateTreeRule: (treeRule: TreeRuleObject, options: EvaluateOptions) => EndpointV2 | undefined;
|
|
1
|
+
export { evaluateTreeRule } from "./evaluateRules";
|
package/node_modules/@smithy/util-endpoints/dist-types/ts3.4/utils/getEndpointProperties.d.ts
CHANGED
|
@@ -1,2 +1,8 @@
|
|
|
1
|
+
import { EndpointObjectProperty } from "@smithy/types";
|
|
1
2
|
import { EndpointObjectProperties, EvaluateOptions } from "../types";
|
|
2
3
|
export declare const getEndpointProperties: (properties: EndpointObjectProperties, options: EvaluateOptions) => {};
|
|
4
|
+
export declare const getEndpointProperty: (property: EndpointObjectProperty, options: EvaluateOptions) => EndpointObjectProperty;
|
|
5
|
+
export declare const group: {
|
|
6
|
+
getEndpointProperty: (property: EndpointObjectProperty, options: EvaluateOptions) => EndpointObjectProperty;
|
|
7
|
+
getEndpointProperties: (properties: EndpointObjectProperties, options: EvaluateOptions) => {};
|
|
8
|
+
};
|
|
@@ -1,3 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import { EvaluateOptions } from "../types";
|
|
3
|
-
export declare const getEndpointProperty: (property: EndpointObjectProperty, options: EvaluateOptions) => EndpointObjectProperty;
|
|
1
|
+
export { getEndpointProperty } from "./getEndpointProperties";
|
|
@@ -1,2 +1 @@
|
|
|
1
|
-
|
|
2
|
-
export declare const callFunction: ({ fn, argv }: FunctionObject, options: EvaluateOptions) => FunctionReturn;
|
|
1
|
+
export { callFunction } from "./evaluateExpression";
|
|
@@ -1,2 +1,7 @@
|
|
|
1
|
-
import type { EvaluateOptions, Expression } from "../types";
|
|
2
|
-
export declare const evaluateExpression: (obj: Expression, keyName: string, options: EvaluateOptions) =>
|
|
1
|
+
import type { EvaluateOptions, Expression, FunctionObject, FunctionReturn } from "../types";
|
|
2
|
+
export declare const evaluateExpression: (obj: Expression, keyName: string, options: EvaluateOptions) => FunctionReturn;
|
|
3
|
+
export declare const callFunction: ({ fn, argv }: FunctionObject, options: EvaluateOptions) => FunctionReturn;
|
|
4
|
+
export declare const group: {
|
|
5
|
+
evaluateExpression: (obj: Expression, keyName: string, options: EvaluateOptions) => FunctionReturn;
|
|
6
|
+
callFunction: ({ fn, argv }: FunctionObject, options: EvaluateOptions) => FunctionReturn;
|
|
7
|
+
};
|
|
@@ -1,3 +1,8 @@
|
|
|
1
1
|
import type { EndpointV2 } from "@smithy/types";
|
|
2
|
-
import type { EvaluateOptions, RuleSetRules } from "../types";
|
|
2
|
+
import type { EvaluateOptions, RuleSetRules, TreeRuleObject } from "../types";
|
|
3
3
|
export declare const evaluateRules: (rules: RuleSetRules, options: EvaluateOptions) => EndpointV2;
|
|
4
|
+
export declare const evaluateTreeRule: (treeRule: TreeRuleObject, options: EvaluateOptions) => EndpointV2 | undefined;
|
|
5
|
+
export declare const group: {
|
|
6
|
+
evaluateRules: (rules: RuleSetRules, options: EvaluateOptions) => EndpointV2;
|
|
7
|
+
evaluateTreeRule: (treeRule: TreeRuleObject, options: EvaluateOptions) => EndpointV2 | undefined;
|
|
8
|
+
};
|
|
@@ -1,3 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import type { EvaluateOptions, TreeRuleObject } from "../types";
|
|
3
|
-
export declare const evaluateTreeRule: (treeRule: TreeRuleObject, options: EvaluateOptions) => EndpointV2 | undefined;
|
|
1
|
+
export { evaluateTreeRule } from "./evaluateRules";
|
|
@@ -1,2 +1,8 @@
|
|
|
1
|
+
import type { EndpointObjectProperty } from "@smithy/types";
|
|
1
2
|
import type { EndpointObjectProperties, EvaluateOptions } from "../types";
|
|
2
3
|
export declare const getEndpointProperties: (properties: EndpointObjectProperties, options: EvaluateOptions) => {};
|
|
4
|
+
export declare const getEndpointProperty: (property: EndpointObjectProperty, options: EvaluateOptions) => EndpointObjectProperty;
|
|
5
|
+
export declare const group: {
|
|
6
|
+
getEndpointProperty: (property: EndpointObjectProperty, options: EvaluateOptions) => EndpointObjectProperty;
|
|
7
|
+
getEndpointProperties: (properties: EndpointObjectProperties, options: EvaluateOptions) => {};
|
|
8
|
+
};
|
|
@@ -1,3 +1 @@
|
|
|
1
|
-
|
|
2
|
-
import type { EvaluateOptions } from "../types";
|
|
3
|
-
export declare const getEndpointProperty: (property: EndpointObjectProperty, options: EvaluateOptions) => EndpointObjectProperty;
|
|
1
|
+
export { getEndpointProperty } from "./getEndpointProperties";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-endpoints",
|
|
3
|
-
"version": "3.2.
|
|
3
|
+
"version": "3.2.3",
|
|
4
4
|
"description": "Utilities to help with endpoint resolution.",
|
|
5
5
|
"main": "./dist-cjs/index.js",
|
|
6
6
|
"module": "./dist-es/index.js",
|
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
"license": "Apache-2.0",
|
|
30
30
|
"sideEffects": false,
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@smithy/node-config-provider": "^4.3.
|
|
33
|
-
"@smithy/types": "^4.
|
|
32
|
+
"@smithy/node-config-provider": "^4.3.3",
|
|
33
|
+
"@smithy/types": "^4.8.0",
|
|
34
34
|
"tslib": "^2.6.2"
|
|
35
35
|
},
|
|
36
36
|
"devDependencies": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-middleware",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.3",
|
|
4
4
|
"description": "Shared utilities for to be used in middleware packages.",
|
|
5
5
|
"main": "./dist-cjs/index.js",
|
|
6
6
|
"module": "./dist-es/index.js",
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
"license": "Apache-2.0",
|
|
29
29
|
"sideEffects": false,
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@smithy/types": "^4.
|
|
31
|
+
"@smithy/types": "^4.8.0",
|
|
32
32
|
"tslib": "^2.6.2"
|
|
33
33
|
},
|
|
34
34
|
"devDependencies": {
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-retry",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.3",
|
|
4
4
|
"description": "Shared retry utilities to be used in middleware packages.",
|
|
5
5
|
"main": "./dist-cjs/index.js",
|
|
6
6
|
"module": "./dist-es/index.js",
|
|
@@ -31,8 +31,8 @@
|
|
|
31
31
|
"license": "Apache-2.0",
|
|
32
32
|
"sideEffects": false,
|
|
33
33
|
"dependencies": {
|
|
34
|
-
"@smithy/service-error-classification": "^4.2.
|
|
35
|
-
"@smithy/types": "^4.
|
|
34
|
+
"@smithy/service-error-classification": "^4.2.3",
|
|
35
|
+
"@smithy/types": "^4.8.0",
|
|
36
36
|
"tslib": "^2.6.2"
|
|
37
37
|
},
|
|
38
38
|
"devDependencies": {
|
|
@@ -11,23 +11,13 @@ var sdkStreamMixin = require('./sdk-stream-mixin');
|
|
|
11
11
|
var splitStream = require('./splitStream');
|
|
12
12
|
var streamTypeCheck = require('./stream-type-check');
|
|
13
13
|
|
|
14
|
-
function transformToString(payload, encoding = "utf-8") {
|
|
15
|
-
if (encoding === "base64") {
|
|
16
|
-
return utilBase64.toBase64(payload);
|
|
17
|
-
}
|
|
18
|
-
return utilUtf8.toUtf8(payload);
|
|
19
|
-
}
|
|
20
|
-
function transformFromString(str, encoding) {
|
|
21
|
-
if (encoding === "base64") {
|
|
22
|
-
return Uint8ArrayBlobAdapter.mutate(utilBase64.fromBase64(str));
|
|
23
|
-
}
|
|
24
|
-
return Uint8ArrayBlobAdapter.mutate(utilUtf8.fromUtf8(str));
|
|
25
|
-
}
|
|
26
|
-
|
|
27
14
|
class Uint8ArrayBlobAdapter extends Uint8Array {
|
|
28
15
|
static fromString(source, encoding = "utf-8") {
|
|
29
16
|
if (typeof source === "string") {
|
|
30
|
-
|
|
17
|
+
if (encoding === "base64") {
|
|
18
|
+
return Uint8ArrayBlobAdapter.mutate(utilBase64.fromBase64(source));
|
|
19
|
+
}
|
|
20
|
+
return Uint8ArrayBlobAdapter.mutate(utilUtf8.fromUtf8(source));
|
|
31
21
|
}
|
|
32
22
|
throw new Error(`Unsupported conversion from ${typeof source} to Uint8ArrayBlobAdapter.`);
|
|
33
23
|
}
|
|
@@ -36,7 +26,10 @@ class Uint8ArrayBlobAdapter extends Uint8Array {
|
|
|
36
26
|
return source;
|
|
37
27
|
}
|
|
38
28
|
transformToString(encoding = "utf-8") {
|
|
39
|
-
|
|
29
|
+
if (encoding === "base64") {
|
|
30
|
+
return utilBase64.toBase64(this);
|
|
31
|
+
}
|
|
32
|
+
return utilUtf8.toUtf8(this);
|
|
40
33
|
}
|
|
41
34
|
}
|
|
42
35
|
|
|
@@ -1,8 +1,12 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { fromBase64, toBase64 } from "@smithy/util-base64";
|
|
2
|
+
import { fromUtf8, toUtf8 } from "@smithy/util-utf8";
|
|
2
3
|
export class Uint8ArrayBlobAdapter extends Uint8Array {
|
|
3
4
|
static fromString(source, encoding = "utf-8") {
|
|
4
5
|
if (typeof source === "string") {
|
|
5
|
-
|
|
6
|
+
if (encoding === "base64") {
|
|
7
|
+
return Uint8ArrayBlobAdapter.mutate(fromBase64(source));
|
|
8
|
+
}
|
|
9
|
+
return Uint8ArrayBlobAdapter.mutate(fromUtf8(source));
|
|
6
10
|
}
|
|
7
11
|
throw new Error(`Unsupported conversion from ${typeof source} to Uint8ArrayBlobAdapter.`);
|
|
8
12
|
}
|
|
@@ -11,6 +15,9 @@ export class Uint8ArrayBlobAdapter extends Uint8Array {
|
|
|
11
15
|
return source;
|
|
12
16
|
}
|
|
13
17
|
transformToString(encoding = "utf-8") {
|
|
14
|
-
|
|
18
|
+
if (encoding === "base64") {
|
|
19
|
+
return toBase64(this);
|
|
20
|
+
}
|
|
21
|
+
return toUtf8(this);
|
|
15
22
|
}
|
|
16
23
|
}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-stream",
|
|
3
|
-
"version": "4.5.
|
|
3
|
+
"version": "4.5.3",
|
|
4
4
|
"scripts": {
|
|
5
5
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types && yarn build:types:downlevel'",
|
|
6
6
|
"build:cjs": "node ../../scripts/inline util-stream",
|
|
@@ -29,9 +29,9 @@
|
|
|
29
29
|
"license": "Apache-2.0",
|
|
30
30
|
"sideEffects": false,
|
|
31
31
|
"dependencies": {
|
|
32
|
-
"@smithy/fetch-http-handler": "^5.3.
|
|
33
|
-
"@smithy/node-http-handler": "^4.4.
|
|
34
|
-
"@smithy/types": "^4.
|
|
32
|
+
"@smithy/fetch-http-handler": "^5.3.4",
|
|
33
|
+
"@smithy/node-http-handler": "^4.4.2",
|
|
34
|
+
"@smithy/types": "^4.8.0",
|
|
35
35
|
"@smithy/util-base64": "^4.3.0",
|
|
36
36
|
"@smithy/util-buffer-from": "^4.2.0",
|
|
37
37
|
"@smithy/util-hex-encoding": "^4.2.0",
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@smithy/util-waiter",
|
|
3
|
-
"version": "4.2.
|
|
3
|
+
"version": "4.2.3",
|
|
4
4
|
"description": "Shared utilities for client waiters for the AWS SDK",
|
|
5
5
|
"dependencies": {
|
|
6
|
-
"@smithy/abort-controller": "^4.2.
|
|
7
|
-
"@smithy/types": "^4.
|
|
6
|
+
"@smithy/abort-controller": "^4.2.3",
|
|
7
|
+
"@smithy/types": "^4.8.0",
|
|
8
8
|
"tslib": "^2.6.2"
|
|
9
9
|
},
|
|
10
10
|
"scripts": {
|
package/package.json
CHANGED
|
@@ -40,7 +40,7 @@
|
|
|
40
40
|
"organization": false
|
|
41
41
|
},
|
|
42
42
|
"devDependencies": {
|
|
43
|
-
"@aws-sdk/types": "^3.
|
|
43
|
+
"@aws-sdk/types": "^3.910.0",
|
|
44
44
|
"@stylistic/eslint-plugin": "^2",
|
|
45
45
|
"@types/jest": "^29.5.14",
|
|
46
46
|
"@types/node": "^20",
|
|
@@ -55,9 +55,9 @@
|
|
|
55
55
|
"jest": "^29.7.0",
|
|
56
56
|
"jest-junit": "^16",
|
|
57
57
|
"jsii": "~5.8.0",
|
|
58
|
-
"jsii-diff": "^1.
|
|
58
|
+
"jsii-diff": "^1.116.0",
|
|
59
59
|
"jsii-docgen": "^10.5.0",
|
|
60
|
-
"jsii-pacmak": "^1.
|
|
60
|
+
"jsii-pacmak": "^1.116.0",
|
|
61
61
|
"jsii-rosetta": "~5.8.0",
|
|
62
62
|
"projen": "^0.98.0",
|
|
63
63
|
"ts-jest": "^29.4.5",
|
|
@@ -69,7 +69,7 @@
|
|
|
69
69
|
"constructs": "^10.0.5"
|
|
70
70
|
},
|
|
71
71
|
"dependencies": {
|
|
72
|
-
"@aws-sdk/client-iam": "^3.
|
|
72
|
+
"@aws-sdk/client-iam": "^3.911.0",
|
|
73
73
|
"axios": "^1.8.2",
|
|
74
74
|
"constructs": "^10.4.2",
|
|
75
75
|
"jsonc-parser": "^3.3.1"
|
|
@@ -101,7 +101,7 @@
|
|
|
101
101
|
"publishConfig": {
|
|
102
102
|
"access": "public"
|
|
103
103
|
},
|
|
104
|
-
"version": "0.0.
|
|
104
|
+
"version": "0.0.59",
|
|
105
105
|
"jest": {
|
|
106
106
|
"coverageProvider": "v8",
|
|
107
107
|
"testMatch": [
|
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
import { fromBase64, toBase64 } from "@smithy/util-base64";
|
|
2
|
-
import { fromUtf8, toUtf8 } from "@smithy/util-utf8";
|
|
3
|
-
import { Uint8ArrayBlobAdapter } from "./Uint8ArrayBlobAdapter";
|
|
4
|
-
export function transformToString(payload, encoding = "utf-8") {
|
|
5
|
-
if (encoding === "base64") {
|
|
6
|
-
return toBase64(payload);
|
|
7
|
-
}
|
|
8
|
-
return toUtf8(payload);
|
|
9
|
-
}
|
|
10
|
-
export function transformFromString(str, encoding) {
|
|
11
|
-
if (encoding === "base64") {
|
|
12
|
-
return Uint8ArrayBlobAdapter.mutate(fromBase64(str));
|
|
13
|
-
}
|
|
14
|
-
return Uint8ArrayBlobAdapter.mutate(fromUtf8(str));
|
|
15
|
-
}
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import { Uint8ArrayBlobAdapter } from "./Uint8ArrayBlobAdapter";
|
|
2
|
-
/**
|
|
3
|
-
* @internal
|
|
4
|
-
*/
|
|
5
|
-
export declare function transformToString(payload: Uint8Array, encoding?: string): string;
|
|
6
|
-
/**
|
|
7
|
-
* @internal
|
|
8
|
-
*/
|
|
9
|
-
export declare function transformFromString(str: string, encoding?: string): Uint8ArrayBlobAdapter;
|