@aws-sdk/client-marketplace-entitlement-service 3.523.0 → 3.529.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/index.js +4 -44
- package/dist-es/protocols/Aws_json1_1.js +1 -40
- package/package.json +17 -17
- package/dist-cjs/MarketplaceEntitlementService.js +0 -1
- package/dist-cjs/MarketplaceEntitlementServiceClient.js +0 -1
- package/dist-cjs/auth/httpAuthExtensionConfiguration.js +0 -1
- package/dist-cjs/commands/GetEntitlementsCommand.js +0 -1
- package/dist-cjs/commands/index.js +0 -1
- package/dist-cjs/endpoint/EndpointParameters.js +0 -1
- package/dist-cjs/extensionConfiguration.js +0 -1
- package/dist-cjs/models/MarketplaceEntitlementServiceServiceException.js +0 -1
- package/dist-cjs/models/index.js +0 -1
- package/dist-cjs/models/models_0.js +0 -1
- package/dist-cjs/pagination/GetEntitlementsPaginator.js +0 -1
- package/dist-cjs/pagination/Interfaces.js +0 -1
- package/dist-cjs/pagination/index.js +0 -1
- package/dist-cjs/protocols/Aws_json1_1.js +0 -1
- package/dist-cjs/runtimeExtensions.js +0 -1
package/dist-cjs/index.js
CHANGED
|
@@ -189,6 +189,7 @@ var import_middleware_serde = require("@smithy/middleware-serde");
|
|
|
189
189
|
var import_types = require("@smithy/types");
|
|
190
190
|
|
|
191
191
|
// src/protocols/Aws_json1_1.ts
|
|
192
|
+
var import_core2 = require("@aws-sdk/core");
|
|
192
193
|
|
|
193
194
|
|
|
194
195
|
|
|
@@ -274,7 +275,7 @@ var de_GetEntitlementsCommand = /* @__PURE__ */ __name(async (output, context) =
|
|
|
274
275
|
if (output.statusCode >= 300) {
|
|
275
276
|
return de_CommandError(output, context);
|
|
276
277
|
}
|
|
277
|
-
const data = await
|
|
278
|
+
const data = await (0, import_core2.parseJsonBody)(output.body, context);
|
|
278
279
|
let contents = {};
|
|
279
280
|
contents = de_GetEntitlementsResult(data, context);
|
|
280
281
|
const response = {
|
|
@@ -286,9 +287,9 @@ var de_GetEntitlementsCommand = /* @__PURE__ */ __name(async (output, context) =
|
|
|
286
287
|
var de_CommandError = /* @__PURE__ */ __name(async (output, context) => {
|
|
287
288
|
const parsedOutput = {
|
|
288
289
|
...output,
|
|
289
|
-
body: await
|
|
290
|
+
body: await (0, import_core2.parseJsonErrorBody)(output.body, context)
|
|
290
291
|
};
|
|
291
|
-
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
292
|
+
const errorCode = (0, import_core2.loadRestJsonErrorCode)(output, parsedOutput.body);
|
|
292
293
|
switch (errorCode) {
|
|
293
294
|
case "InternalServiceErrorException":
|
|
294
295
|
case "com.amazonaws.marketplaceentitlementservice#InternalServiceErrorException":
|
|
@@ -370,7 +371,6 @@ var deserializeMetadata = /* @__PURE__ */ __name((output) => ({
|
|
|
370
371
|
extendedRequestId: output.headers["x-amz-id-2"],
|
|
371
372
|
cfId: output.headers["x-amz-cf-id"]
|
|
372
373
|
}), "deserializeMetadata");
|
|
373
|
-
var collectBodyString = /* @__PURE__ */ __name((streamBody, context) => (0, import_smithy_client.collectBody)(streamBody, context).then((body) => context.utf8Encoder(body)), "collectBodyString");
|
|
374
374
|
var throwDefaultError = (0, import_smithy_client.withBaseException)(MarketplaceEntitlementServiceServiceException);
|
|
375
375
|
var buildHttpRpcRequest = /* @__PURE__ */ __name(async (context, headers, path, resolvedHostname, body) => {
|
|
376
376
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
@@ -397,46 +397,6 @@ function sharedHeaders(operation) {
|
|
|
397
397
|
};
|
|
398
398
|
}
|
|
399
399
|
__name(sharedHeaders, "sharedHeaders");
|
|
400
|
-
var parseBody = /* @__PURE__ */ __name((streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
401
|
-
if (encoded.length) {
|
|
402
|
-
return JSON.parse(encoded);
|
|
403
|
-
}
|
|
404
|
-
return {};
|
|
405
|
-
}), "parseBody");
|
|
406
|
-
var parseErrorBody = /* @__PURE__ */ __name(async (errorBody, context) => {
|
|
407
|
-
const value = await parseBody(errorBody, context);
|
|
408
|
-
value.message = value.message ?? value.Message;
|
|
409
|
-
return value;
|
|
410
|
-
}, "parseErrorBody");
|
|
411
|
-
var loadRestJsonErrorCode = /* @__PURE__ */ __name((output, data) => {
|
|
412
|
-
const findKey = /* @__PURE__ */ __name((object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase()), "findKey");
|
|
413
|
-
const sanitizeErrorCode = /* @__PURE__ */ __name((rawValue) => {
|
|
414
|
-
let cleanValue = rawValue;
|
|
415
|
-
if (typeof cleanValue === "number") {
|
|
416
|
-
cleanValue = cleanValue.toString();
|
|
417
|
-
}
|
|
418
|
-
if (cleanValue.indexOf(",") >= 0) {
|
|
419
|
-
cleanValue = cleanValue.split(",")[0];
|
|
420
|
-
}
|
|
421
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
422
|
-
cleanValue = cleanValue.split(":")[0];
|
|
423
|
-
}
|
|
424
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
425
|
-
cleanValue = cleanValue.split("#")[1];
|
|
426
|
-
}
|
|
427
|
-
return cleanValue;
|
|
428
|
-
}, "sanitizeErrorCode");
|
|
429
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
430
|
-
if (headerKey !== void 0) {
|
|
431
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
432
|
-
}
|
|
433
|
-
if (data.code !== void 0) {
|
|
434
|
-
return sanitizeErrorCode(data.code);
|
|
435
|
-
}
|
|
436
|
-
if (data["__type"] !== void 0) {
|
|
437
|
-
return sanitizeErrorCode(data["__type"]);
|
|
438
|
-
}
|
|
439
|
-
}, "loadRestJsonErrorCode");
|
|
440
400
|
|
|
441
401
|
// src/commands/GetEntitlementsCommand.ts
|
|
442
402
|
var _GetEntitlementsCommand = class _GetEntitlementsCommand extends import_smithy_client.Command.classBuilder().ep({
|
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { loadRestJsonErrorCode, parseJsonBody as parseBody, parseJsonErrorBody as parseErrorBody } from "@aws-sdk/core";
|
|
1
2
|
import { HttpRequest as __HttpRequest } from "@smithy/protocol-http";
|
|
2
3
|
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectString as __expectString, limitedParseDouble as __limitedParseDouble, parseEpochTimestamp as __parseEpochTimestamp, take, withBaseException, } from "@smithy/smithy-client";
|
|
3
4
|
import { MarketplaceEntitlementServiceServiceException as __BaseException } from "../models/MarketplaceEntitlementServiceServiceException";
|
|
@@ -136,43 +137,3 @@ function sharedHeaders(operation) {
|
|
|
136
137
|
"x-amz-target": `AWSMPEntitlementService.${operation}`,
|
|
137
138
|
};
|
|
138
139
|
}
|
|
139
|
-
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
140
|
-
if (encoded.length) {
|
|
141
|
-
return JSON.parse(encoded);
|
|
142
|
-
}
|
|
143
|
-
return {};
|
|
144
|
-
});
|
|
145
|
-
const parseErrorBody = async (errorBody, context) => {
|
|
146
|
-
const value = await parseBody(errorBody, context);
|
|
147
|
-
value.message = value.message ?? value.Message;
|
|
148
|
-
return value;
|
|
149
|
-
};
|
|
150
|
-
const loadRestJsonErrorCode = (output, data) => {
|
|
151
|
-
const findKey = (object, key) => Object.keys(object).find((k) => k.toLowerCase() === key.toLowerCase());
|
|
152
|
-
const sanitizeErrorCode = (rawValue) => {
|
|
153
|
-
let cleanValue = rawValue;
|
|
154
|
-
if (typeof cleanValue === "number") {
|
|
155
|
-
cleanValue = cleanValue.toString();
|
|
156
|
-
}
|
|
157
|
-
if (cleanValue.indexOf(",") >= 0) {
|
|
158
|
-
cleanValue = cleanValue.split(",")[0];
|
|
159
|
-
}
|
|
160
|
-
if (cleanValue.indexOf(":") >= 0) {
|
|
161
|
-
cleanValue = cleanValue.split(":")[0];
|
|
162
|
-
}
|
|
163
|
-
if (cleanValue.indexOf("#") >= 0) {
|
|
164
|
-
cleanValue = cleanValue.split("#")[1];
|
|
165
|
-
}
|
|
166
|
-
return cleanValue;
|
|
167
|
-
};
|
|
168
|
-
const headerKey = findKey(output.headers, "x-amzn-errortype");
|
|
169
|
-
if (headerKey !== undefined) {
|
|
170
|
-
return sanitizeErrorCode(output.headers[headerKey]);
|
|
171
|
-
}
|
|
172
|
-
if (data.code !== undefined) {
|
|
173
|
-
return sanitizeErrorCode(data.code);
|
|
174
|
-
}
|
|
175
|
-
if (data["__type"] !== undefined) {
|
|
176
|
-
return sanitizeErrorCode(data["__type"]);
|
|
177
|
-
}
|
|
178
|
-
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-marketplace-entitlement-service",
|
|
3
3
|
"description": "AWS SDK for JavaScript Marketplace Entitlement Service Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.529.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "node ../../scripts/compilation/inline client-marketplace-entitlement-service",
|
|
@@ -20,40 +20,40 @@
|
|
|
20
20
|
"dependencies": {
|
|
21
21
|
"@aws-crypto/sha256-browser": "3.0.0",
|
|
22
22
|
"@aws-crypto/sha256-js": "3.0.0",
|
|
23
|
-
"@aws-sdk/client-sts": "3.
|
|
24
|
-
"@aws-sdk/core": "3.
|
|
25
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
23
|
+
"@aws-sdk/client-sts": "3.529.0",
|
|
24
|
+
"@aws-sdk/core": "3.529.0",
|
|
25
|
+
"@aws-sdk/credential-provider-node": "3.529.0",
|
|
26
26
|
"@aws-sdk/middleware-host-header": "3.523.0",
|
|
27
27
|
"@aws-sdk/middleware-logger": "3.523.0",
|
|
28
28
|
"@aws-sdk/middleware-recursion-detection": "3.523.0",
|
|
29
|
-
"@aws-sdk/middleware-user-agent": "3.
|
|
30
|
-
"@aws-sdk/region-config-resolver": "3.
|
|
29
|
+
"@aws-sdk/middleware-user-agent": "3.525.0",
|
|
30
|
+
"@aws-sdk/region-config-resolver": "3.525.0",
|
|
31
31
|
"@aws-sdk/types": "3.523.0",
|
|
32
|
-
"@aws-sdk/util-endpoints": "3.
|
|
32
|
+
"@aws-sdk/util-endpoints": "3.525.0",
|
|
33
33
|
"@aws-sdk/util-user-agent-browser": "3.523.0",
|
|
34
|
-
"@aws-sdk/util-user-agent-node": "3.
|
|
35
|
-
"@smithy/config-resolver": "^2.1.
|
|
36
|
-
"@smithy/core": "^1.3.
|
|
34
|
+
"@aws-sdk/util-user-agent-node": "3.525.0",
|
|
35
|
+
"@smithy/config-resolver": "^2.1.4",
|
|
36
|
+
"@smithy/core": "^1.3.5",
|
|
37
37
|
"@smithy/fetch-http-handler": "^2.4.3",
|
|
38
38
|
"@smithy/hash-node": "^2.1.3",
|
|
39
39
|
"@smithy/invalid-dependency": "^2.1.3",
|
|
40
40
|
"@smithy/middleware-content-length": "^2.1.3",
|
|
41
|
-
"@smithy/middleware-endpoint": "^2.4.
|
|
42
|
-
"@smithy/middleware-retry": "^2.1.
|
|
41
|
+
"@smithy/middleware-endpoint": "^2.4.4",
|
|
42
|
+
"@smithy/middleware-retry": "^2.1.4",
|
|
43
43
|
"@smithy/middleware-serde": "^2.1.3",
|
|
44
44
|
"@smithy/middleware-stack": "^2.1.3",
|
|
45
|
-
"@smithy/node-config-provider": "^2.2.
|
|
45
|
+
"@smithy/node-config-provider": "^2.2.4",
|
|
46
46
|
"@smithy/node-http-handler": "^2.4.1",
|
|
47
47
|
"@smithy/protocol-http": "^3.2.1",
|
|
48
|
-
"@smithy/smithy-client": "^2.4.
|
|
48
|
+
"@smithy/smithy-client": "^2.4.2",
|
|
49
49
|
"@smithy/types": "^2.10.1",
|
|
50
50
|
"@smithy/url-parser": "^2.1.3",
|
|
51
51
|
"@smithy/util-base64": "^2.1.1",
|
|
52
52
|
"@smithy/util-body-length-browser": "^2.1.1",
|
|
53
53
|
"@smithy/util-body-length-node": "^2.2.1",
|
|
54
|
-
"@smithy/util-defaults-mode-browser": "^2.1.
|
|
55
|
-
"@smithy/util-defaults-mode-node": "^2.2.
|
|
56
|
-
"@smithy/util-endpoints": "^1.1.
|
|
54
|
+
"@smithy/util-defaults-mode-browser": "^2.1.4",
|
|
55
|
+
"@smithy/util-defaults-mode-node": "^2.2.3",
|
|
56
|
+
"@smithy/util-endpoints": "^1.1.4",
|
|
57
57
|
"@smithy/util-middleware": "^2.1.3",
|
|
58
58
|
"@smithy/util-retry": "^2.1.3",
|
|
59
59
|
"@smithy/util-utf8": "^2.1.1",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("./index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("./index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("./index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
package/dist-cjs/models/index.js
DELETED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("../index.js");
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
module.exports = require("./index.js");
|