@aws-sdk/client-inspector-scan 3.474.0 → 3.477.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.
|
@@ -1,30 +1,23 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.de_ScanSbomCommand = exports.se_ScanSbomCommand = void 0;
|
|
4
|
-
const
|
|
4
|
+
const core_1 = require("@smithy/core");
|
|
5
5
|
const smithy_client_1 = require("@smithy/smithy-client");
|
|
6
6
|
const InspectorScanServiceException_1 = require("../models/InspectorScanServiceException");
|
|
7
7
|
const models_0_1 = require("../models/models_0");
|
|
8
8
|
const se_ScanSbomCommand = async (input, context) => {
|
|
9
|
-
const
|
|
9
|
+
const b = (0, core_1.requestBuilder)(input, context);
|
|
10
10
|
const headers = {
|
|
11
11
|
"content-type": "application/json",
|
|
12
12
|
};
|
|
13
|
-
|
|
13
|
+
b.bp("/scan/sbom");
|
|
14
14
|
let body;
|
|
15
15
|
body = JSON.stringify((0, smithy_client_1.take)(input, {
|
|
16
16
|
outputFormat: [],
|
|
17
17
|
sbom: (_) => se_Sbom(_, context),
|
|
18
18
|
}));
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
hostname,
|
|
22
|
-
port,
|
|
23
|
-
method: "POST",
|
|
24
|
-
headers,
|
|
25
|
-
path: resolvedPath,
|
|
26
|
-
body,
|
|
27
|
-
});
|
|
19
|
+
b.m("POST").h(headers).b(body);
|
|
20
|
+
return b.build();
|
|
28
21
|
};
|
|
29
22
|
exports.se_ScanSbomCommand = se_ScanSbomCommand;
|
|
30
23
|
const de_ScanSbomCommand = async (output, context) => {
|
|
@@ -86,10 +79,7 @@ const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
|
86
79
|
};
|
|
87
80
|
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
88
81
|
const contents = (0, smithy_client_1.map)({
|
|
89
|
-
|
|
90
|
-
() => void 0 !== parsedOutput.headers["retry-after"],
|
|
91
|
-
() => (0, smithy_client_1.strictParseInt32)(parsedOutput.headers["retry-after"]),
|
|
92
|
-
],
|
|
82
|
+
[_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => (0, smithy_client_1.strictParseInt32)(parsedOutput.headers[_ra])],
|
|
93
83
|
});
|
|
94
84
|
const data = parsedOutput.body;
|
|
95
85
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -105,10 +95,7 @@ const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
|
105
95
|
};
|
|
106
96
|
const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
|
|
107
97
|
const contents = (0, smithy_client_1.map)({
|
|
108
|
-
|
|
109
|
-
() => void 0 !== parsedOutput.headers["retry-after"],
|
|
110
|
-
() => (0, smithy_client_1.strictParseInt32)(parsedOutput.headers["retry-after"]),
|
|
111
|
-
],
|
|
98
|
+
[_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => (0, smithy_client_1.strictParseInt32)(parsedOutput.headers[_ra])],
|
|
112
99
|
});
|
|
113
100
|
const data = parsedOutput.body;
|
|
114
101
|
const doc = (0, smithy_client_1.take)(data, {
|
|
@@ -154,6 +141,8 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
|
154
141
|
value !== "" &&
|
|
155
142
|
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
156
143
|
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
144
|
+
const _rAS = "retryAfterSeconds";
|
|
145
|
+
const _ra = "retry-after";
|
|
157
146
|
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
158
147
|
if (encoded.length) {
|
|
159
148
|
return JSON.parse(encoded);
|
|
@@ -1,27 +1,20 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { requestBuilder as rb } from "@smithy/core";
|
|
2
2
|
import { _json, collectBody, decorateServiceException as __decorateServiceException, expectNonNull as __expectNonNull, expectObject as __expectObject, expectString as __expectString, map, strictParseInt32 as __strictParseInt32, take, withBaseException, } from "@smithy/smithy-client";
|
|
3
3
|
import { InspectorScanServiceException as __BaseException } from "../models/InspectorScanServiceException";
|
|
4
4
|
import { AccessDeniedException, InternalServerException, ThrottlingException, ValidationException, } from "../models/models_0";
|
|
5
5
|
export const se_ScanSbomCommand = async (input, context) => {
|
|
6
|
-
const
|
|
6
|
+
const b = rb(input, context);
|
|
7
7
|
const headers = {
|
|
8
8
|
"content-type": "application/json",
|
|
9
9
|
};
|
|
10
|
-
|
|
10
|
+
b.bp("/scan/sbom");
|
|
11
11
|
let body;
|
|
12
12
|
body = JSON.stringify(take(input, {
|
|
13
13
|
outputFormat: [],
|
|
14
14
|
sbom: (_) => se_Sbom(_, context),
|
|
15
15
|
}));
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
hostname,
|
|
19
|
-
port,
|
|
20
|
-
method: "POST",
|
|
21
|
-
headers,
|
|
22
|
-
path: resolvedPath,
|
|
23
|
-
body,
|
|
24
|
-
});
|
|
16
|
+
b.m("POST").h(headers).b(body);
|
|
17
|
+
return b.build();
|
|
25
18
|
};
|
|
26
19
|
export const de_ScanSbomCommand = async (output, context) => {
|
|
27
20
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
@@ -81,10 +74,7 @@ const de_AccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
|
81
74
|
};
|
|
82
75
|
const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
83
76
|
const contents = map({
|
|
84
|
-
|
|
85
|
-
() => void 0 !== parsedOutput.headers["retry-after"],
|
|
86
|
-
() => __strictParseInt32(parsedOutput.headers["retry-after"]),
|
|
87
|
-
],
|
|
77
|
+
[_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])],
|
|
88
78
|
});
|
|
89
79
|
const data = parsedOutput.body;
|
|
90
80
|
const doc = take(data, {
|
|
@@ -100,10 +90,7 @@ const de_InternalServerExceptionRes = async (parsedOutput, context) => {
|
|
|
100
90
|
};
|
|
101
91
|
const de_ThrottlingExceptionRes = async (parsedOutput, context) => {
|
|
102
92
|
const contents = map({
|
|
103
|
-
|
|
104
|
-
() => void 0 !== parsedOutput.headers["retry-after"],
|
|
105
|
-
() => __strictParseInt32(parsedOutput.headers["retry-after"]),
|
|
106
|
-
],
|
|
93
|
+
[_rAS]: [() => void 0 !== parsedOutput.headers[_ra], () => __strictParseInt32(parsedOutput.headers[_ra])],
|
|
107
94
|
});
|
|
108
95
|
const data = parsedOutput.body;
|
|
109
96
|
const doc = take(data, {
|
|
@@ -149,6 +136,8 @@ const isSerializableHeaderValue = (value) => value !== undefined &&
|
|
|
149
136
|
value !== "" &&
|
|
150
137
|
(!Object.getOwnPropertyNames(value).includes("length") || value.length != 0) &&
|
|
151
138
|
(!Object.getOwnPropertyNames(value).includes("size") || value.size != 0);
|
|
139
|
+
const _rAS = "retryAfterSeconds";
|
|
140
|
+
const _ra = "retry-after";
|
|
152
141
|
const parseBody = (streamBody, context) => collectBodyString(streamBody, context).then((encoded) => {
|
|
153
142
|
if (encoded.length) {
|
|
154
143
|
return JSON.parse(encoded);
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-inspector-scan",
|
|
3
3
|
"description": "AWS SDK for JavaScript Inspector Scan Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.477.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
@@ -20,9 +20,9 @@
|
|
|
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.477.0",
|
|
24
|
+
"@aws-sdk/core": "3.477.0",
|
|
25
|
+
"@aws-sdk/credential-provider-node": "3.477.0",
|
|
26
26
|
"@aws-sdk/middleware-host-header": "3.468.0",
|
|
27
27
|
"@aws-sdk/middleware-logger": "3.468.0",
|
|
28
28
|
"@aws-sdk/middleware-recursion-detection": "3.468.0",
|
|
@@ -34,6 +34,7 @@
|
|
|
34
34
|
"@aws-sdk/util-user-agent-browser": "3.468.0",
|
|
35
35
|
"@aws-sdk/util-user-agent-node": "3.470.0",
|
|
36
36
|
"@smithy/config-resolver": "^2.0.21",
|
|
37
|
+
"@smithy/core": "^1.2.0",
|
|
37
38
|
"@smithy/fetch-http-handler": "^2.3.1",
|
|
38
39
|
"@smithy/hash-node": "^2.0.17",
|
|
39
40
|
"@smithy/invalid-dependency": "^2.0.15",
|