@aws-sdk/client-synthetics 3.118.1 → 3.127.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/CHANGELOG.md +30 -0
- package/README.md +7 -7
- package/dist-cjs/Synthetics.js +120 -0
- package/dist-cjs/commands/AssociateResourceCommand.js +36 -0
- package/dist-cjs/commands/CreateGroupCommand.js +36 -0
- package/dist-cjs/commands/DeleteGroupCommand.js +36 -0
- package/dist-cjs/commands/DisassociateResourceCommand.js +36 -0
- package/dist-cjs/commands/GetGroupCommand.js +36 -0
- package/dist-cjs/commands/ListAssociatedGroupsCommand.js +36 -0
- package/dist-cjs/commands/ListGroupResourcesCommand.js +36 -0
- package/dist-cjs/commands/ListGroupsCommand.js +36 -0
- package/dist-cjs/commands/index.js +8 -0
- package/dist-cjs/models/models_0.js +236 -58
- package/dist-cjs/pagination/ListAssociatedGroupsPaginator.js +36 -0
- package/dist-cjs/pagination/ListGroupResourcesPaginator.js +36 -0
- package/dist-cjs/pagination/ListGroupsPaginator.js +36 -0
- package/dist-cjs/pagination/index.js +3 -0
- package/dist-cjs/protocols/Aws_restJson1.js +939 -274
- package/dist-es/Synthetics.js +120 -0
- package/dist-es/commands/AssociateResourceCommand.js +39 -0
- package/dist-es/commands/CreateGroupCommand.js +39 -0
- package/dist-es/commands/DeleteGroupCommand.js +39 -0
- package/dist-es/commands/DisassociateResourceCommand.js +39 -0
- package/dist-es/commands/GetGroupCommand.js +39 -0
- package/dist-es/commands/ListAssociatedGroupsCommand.js +39 -0
- package/dist-es/commands/ListGroupResourcesCommand.js +39 -0
- package/dist-es/commands/ListGroupsCommand.js +39 -0
- package/dist-es/commands/index.js +8 -0
- package/dist-es/models/models_0.js +189 -52
- package/dist-es/pagination/ListAssociatedGroupsPaginator.js +75 -0
- package/dist-es/pagination/ListGroupResourcesPaginator.js +75 -0
- package/dist-es/pagination/ListGroupsPaginator.js +75 -0
- package/dist-es/pagination/index.js +3 -0
- package/dist-es/protocols/Aws_restJson1.js +1116 -253
- package/dist-types/Synthetics.d.ts +90 -11
- package/dist-types/SyntheticsClient.d.ts +10 -2
- package/dist-types/commands/AssociateResourceCommand.d.ts +38 -0
- package/dist-types/commands/CreateCanaryCommand.d.ts +1 -1
- package/dist-types/commands/CreateGroupCommand.d.ts +47 -0
- package/dist-types/commands/DeleteCanaryCommand.d.ts +1 -1
- package/dist-types/commands/DeleteGroupCommand.d.ts +39 -0
- package/dist-types/commands/DisassociateResourceCommand.d.ts +35 -0
- package/dist-types/commands/GetGroupCommand.d.ts +36 -0
- package/dist-types/commands/ListAssociatedGroupsCommand.d.ts +36 -0
- package/dist-types/commands/ListGroupResourcesCommand.d.ts +35 -0
- package/dist-types/commands/ListGroupsCommand.d.ts +36 -0
- package/dist-types/commands/ListTagsForResourceCommand.d.ts +1 -1
- package/dist-types/commands/StopCanaryCommand.d.ts +1 -2
- package/dist-types/commands/TagResourceCommand.d.ts +6 -4
- package/dist-types/commands/UntagResourceCommand.d.ts +1 -1
- package/dist-types/commands/UpdateCanaryCommand.d.ts +1 -1
- package/dist-types/commands/index.d.ts +8 -0
- package/dist-types/models/models_0.d.ts +450 -52
- package/dist-types/pagination/ListAssociatedGroupsPaginator.d.ts +4 -0
- package/dist-types/pagination/ListGroupResourcesPaginator.d.ts +4 -0
- package/dist-types/pagination/ListGroupsPaginator.d.ts +4 -0
- package/dist-types/pagination/index.d.ts +3 -0
- package/dist-types/protocols/Aws_restJson1.d.ts +24 -0
- package/dist-types/ts3.4/Synthetics.d.ts +40 -0
- package/dist-types/ts3.4/SyntheticsClient.d.ts +10 -2
- package/dist-types/ts3.4/commands/AssociateResourceCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/CreateGroupCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/DeleteGroupCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/DisassociateResourceCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetGroupCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListAssociatedGroupsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListGroupResourcesCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListGroupsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/index.d.ts +8 -0
- package/dist-types/ts3.4/models/models_0.d.ts +243 -27
- package/dist-types/ts3.4/pagination/ListAssociatedGroupsPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/ListGroupResourcesPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/ListGroupsPaginator.d.ts +4 -0
- package/dist-types/ts3.4/pagination/index.d.ts +3 -0
- package/dist-types/ts3.4/protocols/Aws_restJson1.d.ts +24 -0
- package/package.json +26 -26
|
@@ -1,8 +1,42 @@
|
|
|
1
1
|
import { __assign, __awaiter, __generator, __read } from "tslib";
|
|
2
2
|
import { HttpRequest as __HttpRequest } from "@aws-sdk/protocol-http";
|
|
3
3
|
import { decorateServiceException as __decorateServiceException, expectBoolean as __expectBoolean, expectInt32 as __expectInt32, expectLong as __expectLong, expectNonNull as __expectNonNull, expectNumber as __expectNumber, expectObject as __expectObject, expectString as __expectString, extendedEncodeURIComponent as __extendedEncodeURIComponent, parseEpochTimestamp as __parseEpochTimestamp, } from "@aws-sdk/smithy-client";
|
|
4
|
-
import { ConflictException, InternalServerException, RequestEntityTooLargeException, ResourceNotFoundException, ValidationException, } from "../models/models_0";
|
|
4
|
+
import { BadRequestException, ConflictException, InternalFailureException, InternalServerException, NotFoundException, RequestEntityTooLargeException, ResourceNotFoundException, ServiceQuotaExceededException, TooManyRequestsException, ValidationException, } from "../models/models_0";
|
|
5
5
|
import { SyntheticsServiceException as __BaseException } from "../models/SyntheticsServiceException";
|
|
6
|
+
export var serializeAws_restJson1AssociateResourceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
7
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
8
|
+
return __generator(this, function (_c) {
|
|
9
|
+
switch (_c.label) {
|
|
10
|
+
case 0: return [4, context.endpoint()];
|
|
11
|
+
case 1:
|
|
12
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
13
|
+
headers = {
|
|
14
|
+
"content-type": "application/json",
|
|
15
|
+
};
|
|
16
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/group/{GroupIdentifier}/associate";
|
|
17
|
+
if (input.GroupIdentifier !== undefined) {
|
|
18
|
+
labelValue = input.GroupIdentifier;
|
|
19
|
+
if (labelValue.length <= 0) {
|
|
20
|
+
throw new Error("Empty value provided for input HTTP label: GroupIdentifier.");
|
|
21
|
+
}
|
|
22
|
+
resolvedPath = resolvedPath.replace("{GroupIdentifier}", __extendedEncodeURIComponent(labelValue));
|
|
23
|
+
}
|
|
24
|
+
else {
|
|
25
|
+
throw new Error("No value provided for input HTTP label: GroupIdentifier.");
|
|
26
|
+
}
|
|
27
|
+
body = JSON.stringify(__assign({}, (input.ResourceArn != null && { ResourceArn: input.ResourceArn })));
|
|
28
|
+
return [2, new __HttpRequest({
|
|
29
|
+
protocol: protocol,
|
|
30
|
+
hostname: hostname,
|
|
31
|
+
port: port,
|
|
32
|
+
method: "PATCH",
|
|
33
|
+
headers: headers,
|
|
34
|
+
path: resolvedPath,
|
|
35
|
+
body: body,
|
|
36
|
+
})];
|
|
37
|
+
}
|
|
38
|
+
});
|
|
39
|
+
}); };
|
|
6
40
|
export var serializeAws_restJson1CreateCanaryCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
7
41
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
8
42
|
return __generator(this, function (_c) {
|
|
@@ -14,23 +48,37 @@ export var serializeAws_restJson1CreateCanaryCommand = function (input, context)
|
|
|
14
48
|
"content-type": "application/json",
|
|
15
49
|
};
|
|
16
50
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/canary";
|
|
17
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.ArtifactConfig
|
|
18
|
-
input.ArtifactConfig !== null && {
|
|
51
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.ArtifactConfig != null && {
|
|
19
52
|
ArtifactConfig: serializeAws_restJson1ArtifactConfigInput(input.ArtifactConfig, context),
|
|
20
|
-
})), (input.ArtifactS3Location
|
|
21
|
-
input.ArtifactS3Location !== null && { ArtifactS3Location: input.ArtifactS3Location })), (input.Code !== undefined &&
|
|
22
|
-
input.Code !== null && { Code: serializeAws_restJson1CanaryCodeInput(input.Code, context) })), (input.ExecutionRoleArn !== undefined &&
|
|
23
|
-
input.ExecutionRoleArn !== null && { ExecutionRoleArn: input.ExecutionRoleArn })), (input.FailureRetentionPeriodInDays !== undefined &&
|
|
24
|
-
input.FailureRetentionPeriodInDays !== null && {
|
|
53
|
+
})), (input.ArtifactS3Location != null && { ArtifactS3Location: input.ArtifactS3Location })), (input.Code != null && { Code: serializeAws_restJson1CanaryCodeInput(input.Code, context) })), (input.ExecutionRoleArn != null && { ExecutionRoleArn: input.ExecutionRoleArn })), (input.FailureRetentionPeriodInDays != null && {
|
|
25
54
|
FailureRetentionPeriodInDays: input.FailureRetentionPeriodInDays,
|
|
26
|
-
})), (input.Name
|
|
27
|
-
input.RunConfig !== null && { RunConfig: serializeAws_restJson1CanaryRunConfigInput(input.RunConfig, context) })), (input.RuntimeVersion !== undefined &&
|
|
28
|
-
input.RuntimeVersion !== null && { RuntimeVersion: input.RuntimeVersion })), (input.Schedule !== undefined &&
|
|
29
|
-
input.Schedule !== null && { Schedule: serializeAws_restJson1CanaryScheduleInput(input.Schedule, context) })), (input.SuccessRetentionPeriodInDays !== undefined &&
|
|
30
|
-
input.SuccessRetentionPeriodInDays !== null && {
|
|
55
|
+
})), (input.Name != null && { Name: input.Name })), (input.RunConfig != null && { RunConfig: serializeAws_restJson1CanaryRunConfigInput(input.RunConfig, context) })), (input.RuntimeVersion != null && { RuntimeVersion: input.RuntimeVersion })), (input.Schedule != null && { Schedule: serializeAws_restJson1CanaryScheduleInput(input.Schedule, context) })), (input.SuccessRetentionPeriodInDays != null && {
|
|
31
56
|
SuccessRetentionPeriodInDays: input.SuccessRetentionPeriodInDays,
|
|
32
|
-
})), (input.Tags
|
|
33
|
-
|
|
57
|
+
})), (input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) })), (input.VpcConfig != null && { VpcConfig: serializeAws_restJson1VpcConfigInput(input.VpcConfig, context) })));
|
|
58
|
+
return [2, new __HttpRequest({
|
|
59
|
+
protocol: protocol,
|
|
60
|
+
hostname: hostname,
|
|
61
|
+
port: port,
|
|
62
|
+
method: "POST",
|
|
63
|
+
headers: headers,
|
|
64
|
+
path: resolvedPath,
|
|
65
|
+
body: body,
|
|
66
|
+
})];
|
|
67
|
+
}
|
|
68
|
+
});
|
|
69
|
+
}); };
|
|
70
|
+
export var serializeAws_restJson1CreateGroupCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
71
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
72
|
+
return __generator(this, function (_c) {
|
|
73
|
+
switch (_c.label) {
|
|
74
|
+
case 0: return [4, context.endpoint()];
|
|
75
|
+
case 1:
|
|
76
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
77
|
+
headers = {
|
|
78
|
+
"content-type": "application/json",
|
|
79
|
+
};
|
|
80
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/group";
|
|
81
|
+
body = JSON.stringify(__assign(__assign({}, (input.Name != null && { Name: input.Name })), (input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) })));
|
|
34
82
|
return [2, new __HttpRequest({
|
|
35
83
|
protocol: protocol,
|
|
36
84
|
hostname: hostname,
|
|
@@ -76,6 +124,37 @@ export var serializeAws_restJson1DeleteCanaryCommand = function (input, context)
|
|
|
76
124
|
}
|
|
77
125
|
});
|
|
78
126
|
}); };
|
|
127
|
+
export var serializeAws_restJson1DeleteGroupCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
128
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
129
|
+
return __generator(this, function (_c) {
|
|
130
|
+
switch (_c.label) {
|
|
131
|
+
case 0: return [4, context.endpoint()];
|
|
132
|
+
case 1:
|
|
133
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
134
|
+
headers = {};
|
|
135
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/group/{GroupIdentifier}";
|
|
136
|
+
if (input.GroupIdentifier !== undefined) {
|
|
137
|
+
labelValue = input.GroupIdentifier;
|
|
138
|
+
if (labelValue.length <= 0) {
|
|
139
|
+
throw new Error("Empty value provided for input HTTP label: GroupIdentifier.");
|
|
140
|
+
}
|
|
141
|
+
resolvedPath = resolvedPath.replace("{GroupIdentifier}", __extendedEncodeURIComponent(labelValue));
|
|
142
|
+
}
|
|
143
|
+
else {
|
|
144
|
+
throw new Error("No value provided for input HTTP label: GroupIdentifier.");
|
|
145
|
+
}
|
|
146
|
+
return [2, new __HttpRequest({
|
|
147
|
+
protocol: protocol,
|
|
148
|
+
hostname: hostname,
|
|
149
|
+
port: port,
|
|
150
|
+
method: "DELETE",
|
|
151
|
+
headers: headers,
|
|
152
|
+
path: resolvedPath,
|
|
153
|
+
body: body,
|
|
154
|
+
})];
|
|
155
|
+
}
|
|
156
|
+
});
|
|
157
|
+
}); };
|
|
79
158
|
export var serializeAws_restJson1DescribeCanariesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
80
159
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
81
160
|
return __generator(this, function (_c) {
|
|
@@ -87,8 +166,7 @@ export var serializeAws_restJson1DescribeCanariesCommand = function (input, cont
|
|
|
87
166
|
"content-type": "application/json",
|
|
88
167
|
};
|
|
89
168
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/canaries";
|
|
90
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.MaxResults
|
|
91
|
-
input.Names !== null && { Names: serializeAws_restJson1DescribeCanariesNameFilter(input.Names, context) })), (input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken })));
|
|
169
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.Names != null && { Names: serializeAws_restJson1DescribeCanariesNameFilter(input.Names, context) })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
92
170
|
return [2, new __HttpRequest({
|
|
93
171
|
protocol: protocol,
|
|
94
172
|
hostname: hostname,
|
|
@@ -112,8 +190,9 @@ export var serializeAws_restJson1DescribeCanariesLastRunCommand = function (inpu
|
|
|
112
190
|
"content-type": "application/json",
|
|
113
191
|
};
|
|
114
192
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/canaries/last-run";
|
|
115
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.MaxResults
|
|
116
|
-
|
|
193
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.Names != null && {
|
|
194
|
+
Names: serializeAws_restJson1DescribeCanariesLastRunNameFilter(input.Names, context),
|
|
195
|
+
})), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
117
196
|
return [2, new __HttpRequest({
|
|
118
197
|
protocol: protocol,
|
|
119
198
|
hostname: hostname,
|
|
@@ -137,7 +216,7 @@ export var serializeAws_restJson1DescribeRuntimeVersionsCommand = function (inpu
|
|
|
137
216
|
"content-type": "application/json",
|
|
138
217
|
};
|
|
139
218
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/runtime-versions";
|
|
140
|
-
body = JSON.stringify(__assign(__assign({}, (input.MaxResults
|
|
219
|
+
body = JSON.stringify(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
141
220
|
return [2, new __HttpRequest({
|
|
142
221
|
protocol: protocol,
|
|
143
222
|
hostname: hostname,
|
|
@@ -150,6 +229,40 @@ export var serializeAws_restJson1DescribeRuntimeVersionsCommand = function (inpu
|
|
|
150
229
|
}
|
|
151
230
|
});
|
|
152
231
|
}); };
|
|
232
|
+
export var serializeAws_restJson1DisassociateResourceCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
233
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
234
|
+
return __generator(this, function (_c) {
|
|
235
|
+
switch (_c.label) {
|
|
236
|
+
case 0: return [4, context.endpoint()];
|
|
237
|
+
case 1:
|
|
238
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
239
|
+
headers = {
|
|
240
|
+
"content-type": "application/json",
|
|
241
|
+
};
|
|
242
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/group/{GroupIdentifier}/disassociate";
|
|
243
|
+
if (input.GroupIdentifier !== undefined) {
|
|
244
|
+
labelValue = input.GroupIdentifier;
|
|
245
|
+
if (labelValue.length <= 0) {
|
|
246
|
+
throw new Error("Empty value provided for input HTTP label: GroupIdentifier.");
|
|
247
|
+
}
|
|
248
|
+
resolvedPath = resolvedPath.replace("{GroupIdentifier}", __extendedEncodeURIComponent(labelValue));
|
|
249
|
+
}
|
|
250
|
+
else {
|
|
251
|
+
throw new Error("No value provided for input HTTP label: GroupIdentifier.");
|
|
252
|
+
}
|
|
253
|
+
body = JSON.stringify(__assign({}, (input.ResourceArn != null && { ResourceArn: input.ResourceArn })));
|
|
254
|
+
return [2, new __HttpRequest({
|
|
255
|
+
protocol: protocol,
|
|
256
|
+
hostname: hostname,
|
|
257
|
+
port: port,
|
|
258
|
+
method: "PATCH",
|
|
259
|
+
headers: headers,
|
|
260
|
+
path: resolvedPath,
|
|
261
|
+
body: body,
|
|
262
|
+
})];
|
|
263
|
+
}
|
|
264
|
+
});
|
|
265
|
+
}); };
|
|
153
266
|
export var serializeAws_restJson1GetCanaryCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
154
267
|
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
155
268
|
return __generator(this, function (_c) {
|
|
@@ -202,7 +315,130 @@ export var serializeAws_restJson1GetCanaryRunsCommand = function (input, context
|
|
|
202
315
|
else {
|
|
203
316
|
throw new Error("No value provided for input HTTP label: Name.");
|
|
204
317
|
}
|
|
205
|
-
body = JSON.stringify(__assign(__assign({}, (input.MaxResults
|
|
318
|
+
body = JSON.stringify(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
319
|
+
return [2, new __HttpRequest({
|
|
320
|
+
protocol: protocol,
|
|
321
|
+
hostname: hostname,
|
|
322
|
+
port: port,
|
|
323
|
+
method: "POST",
|
|
324
|
+
headers: headers,
|
|
325
|
+
path: resolvedPath,
|
|
326
|
+
body: body,
|
|
327
|
+
})];
|
|
328
|
+
}
|
|
329
|
+
});
|
|
330
|
+
}); };
|
|
331
|
+
export var serializeAws_restJson1GetGroupCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
332
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
333
|
+
return __generator(this, function (_c) {
|
|
334
|
+
switch (_c.label) {
|
|
335
|
+
case 0: return [4, context.endpoint()];
|
|
336
|
+
case 1:
|
|
337
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
338
|
+
headers = {};
|
|
339
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/group/{GroupIdentifier}";
|
|
340
|
+
if (input.GroupIdentifier !== undefined) {
|
|
341
|
+
labelValue = input.GroupIdentifier;
|
|
342
|
+
if (labelValue.length <= 0) {
|
|
343
|
+
throw new Error("Empty value provided for input HTTP label: GroupIdentifier.");
|
|
344
|
+
}
|
|
345
|
+
resolvedPath = resolvedPath.replace("{GroupIdentifier}", __extendedEncodeURIComponent(labelValue));
|
|
346
|
+
}
|
|
347
|
+
else {
|
|
348
|
+
throw new Error("No value provided for input HTTP label: GroupIdentifier.");
|
|
349
|
+
}
|
|
350
|
+
return [2, new __HttpRequest({
|
|
351
|
+
protocol: protocol,
|
|
352
|
+
hostname: hostname,
|
|
353
|
+
port: port,
|
|
354
|
+
method: "GET",
|
|
355
|
+
headers: headers,
|
|
356
|
+
path: resolvedPath,
|
|
357
|
+
body: body,
|
|
358
|
+
})];
|
|
359
|
+
}
|
|
360
|
+
});
|
|
361
|
+
}); };
|
|
362
|
+
export var serializeAws_restJson1ListAssociatedGroupsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
363
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
364
|
+
return __generator(this, function (_c) {
|
|
365
|
+
switch (_c.label) {
|
|
366
|
+
case 0: return [4, context.endpoint()];
|
|
367
|
+
case 1:
|
|
368
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
369
|
+
headers = {
|
|
370
|
+
"content-type": "application/json",
|
|
371
|
+
};
|
|
372
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/resource/{ResourceArn}/groups";
|
|
373
|
+
if (input.ResourceArn !== undefined) {
|
|
374
|
+
labelValue = input.ResourceArn;
|
|
375
|
+
if (labelValue.length <= 0) {
|
|
376
|
+
throw new Error("Empty value provided for input HTTP label: ResourceArn.");
|
|
377
|
+
}
|
|
378
|
+
resolvedPath = resolvedPath.replace("{ResourceArn}", __extendedEncodeURIComponent(labelValue));
|
|
379
|
+
}
|
|
380
|
+
else {
|
|
381
|
+
throw new Error("No value provided for input HTTP label: ResourceArn.");
|
|
382
|
+
}
|
|
383
|
+
body = JSON.stringify(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
384
|
+
return [2, new __HttpRequest({
|
|
385
|
+
protocol: protocol,
|
|
386
|
+
hostname: hostname,
|
|
387
|
+
port: port,
|
|
388
|
+
method: "POST",
|
|
389
|
+
headers: headers,
|
|
390
|
+
path: resolvedPath,
|
|
391
|
+
body: body,
|
|
392
|
+
})];
|
|
393
|
+
}
|
|
394
|
+
});
|
|
395
|
+
}); };
|
|
396
|
+
export var serializeAws_restJson1ListGroupResourcesCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
397
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, labelValue, body;
|
|
398
|
+
return __generator(this, function (_c) {
|
|
399
|
+
switch (_c.label) {
|
|
400
|
+
case 0: return [4, context.endpoint()];
|
|
401
|
+
case 1:
|
|
402
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
403
|
+
headers = {
|
|
404
|
+
"content-type": "application/json",
|
|
405
|
+
};
|
|
406
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/group/{GroupIdentifier}/resources";
|
|
407
|
+
if (input.GroupIdentifier !== undefined) {
|
|
408
|
+
labelValue = input.GroupIdentifier;
|
|
409
|
+
if (labelValue.length <= 0) {
|
|
410
|
+
throw new Error("Empty value provided for input HTTP label: GroupIdentifier.");
|
|
411
|
+
}
|
|
412
|
+
resolvedPath = resolvedPath.replace("{GroupIdentifier}", __extendedEncodeURIComponent(labelValue));
|
|
413
|
+
}
|
|
414
|
+
else {
|
|
415
|
+
throw new Error("No value provided for input HTTP label: GroupIdentifier.");
|
|
416
|
+
}
|
|
417
|
+
body = JSON.stringify(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
418
|
+
return [2, new __HttpRequest({
|
|
419
|
+
protocol: protocol,
|
|
420
|
+
hostname: hostname,
|
|
421
|
+
port: port,
|
|
422
|
+
method: "POST",
|
|
423
|
+
headers: headers,
|
|
424
|
+
path: resolvedPath,
|
|
425
|
+
body: body,
|
|
426
|
+
})];
|
|
427
|
+
}
|
|
428
|
+
});
|
|
429
|
+
}); };
|
|
430
|
+
export var serializeAws_restJson1ListGroupsCommand = function (input, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
431
|
+
var _a, hostname, _b, protocol, port, basePath, headers, resolvedPath, body;
|
|
432
|
+
return __generator(this, function (_c) {
|
|
433
|
+
switch (_c.label) {
|
|
434
|
+
case 0: return [4, context.endpoint()];
|
|
435
|
+
case 1:
|
|
436
|
+
_a = _c.sent(), hostname = _a.hostname, _b = _a.protocol, protocol = _b === void 0 ? "https" : _b, port = _a.port, basePath = _a.path;
|
|
437
|
+
headers = {
|
|
438
|
+
"content-type": "application/json",
|
|
439
|
+
};
|
|
440
|
+
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/groups";
|
|
441
|
+
body = JSON.stringify(__assign(__assign({}, (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
206
442
|
return [2, new __HttpRequest({
|
|
207
443
|
protocol: protocol,
|
|
208
444
|
hostname: hostname,
|
|
@@ -329,7 +565,7 @@ export var serializeAws_restJson1TagResourceCommand = function (input, context)
|
|
|
329
565
|
else {
|
|
330
566
|
throw new Error("No value provided for input HTTP label: ResourceArn.");
|
|
331
567
|
}
|
|
332
|
-
body = JSON.stringify(__assign({}, (input.Tags
|
|
568
|
+
body = JSON.stringify(__assign({}, (input.Tags != null && { Tags: serializeAws_restJson1TagMap(input.Tags, context) })));
|
|
333
569
|
return [2, new __HttpRequest({
|
|
334
570
|
protocol: protocol,
|
|
335
571
|
hostname: hostname,
|
|
@@ -396,26 +632,15 @@ export var serializeAws_restJson1UpdateCanaryCommand = function (input, context)
|
|
|
396
632
|
else {
|
|
397
633
|
throw new Error("No value provided for input HTTP label: Name.");
|
|
398
634
|
}
|
|
399
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.ArtifactConfig
|
|
400
|
-
input.ArtifactConfig !== null && {
|
|
635
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.ArtifactConfig != null && {
|
|
401
636
|
ArtifactConfig: serializeAws_restJson1ArtifactConfigInput(input.ArtifactConfig, context),
|
|
402
|
-
})), (input.ArtifactS3Location
|
|
403
|
-
input.ArtifactS3Location !== null && { ArtifactS3Location: input.ArtifactS3Location })), (input.Code !== undefined &&
|
|
404
|
-
input.Code !== null && { Code: serializeAws_restJson1CanaryCodeInput(input.Code, context) })), (input.ExecutionRoleArn !== undefined &&
|
|
405
|
-
input.ExecutionRoleArn !== null && { ExecutionRoleArn: input.ExecutionRoleArn })), (input.FailureRetentionPeriodInDays !== undefined &&
|
|
406
|
-
input.FailureRetentionPeriodInDays !== null && {
|
|
637
|
+
})), (input.ArtifactS3Location != null && { ArtifactS3Location: input.ArtifactS3Location })), (input.Code != null && { Code: serializeAws_restJson1CanaryCodeInput(input.Code, context) })), (input.ExecutionRoleArn != null && { ExecutionRoleArn: input.ExecutionRoleArn })), (input.FailureRetentionPeriodInDays != null && {
|
|
407
638
|
FailureRetentionPeriodInDays: input.FailureRetentionPeriodInDays,
|
|
408
|
-
})), (input.RunConfig
|
|
409
|
-
input.RunConfig !== null && { RunConfig: serializeAws_restJson1CanaryRunConfigInput(input.RunConfig, context) })), (input.RuntimeVersion !== undefined &&
|
|
410
|
-
input.RuntimeVersion !== null && { RuntimeVersion: input.RuntimeVersion })), (input.Schedule !== undefined &&
|
|
411
|
-
input.Schedule !== null && { Schedule: serializeAws_restJson1CanaryScheduleInput(input.Schedule, context) })), (input.SuccessRetentionPeriodInDays !== undefined &&
|
|
412
|
-
input.SuccessRetentionPeriodInDays !== null && {
|
|
639
|
+
})), (input.RunConfig != null && { RunConfig: serializeAws_restJson1CanaryRunConfigInput(input.RunConfig, context) })), (input.RuntimeVersion != null && { RuntimeVersion: input.RuntimeVersion })), (input.Schedule != null && { Schedule: serializeAws_restJson1CanaryScheduleInput(input.Schedule, context) })), (input.SuccessRetentionPeriodInDays != null && {
|
|
413
640
|
SuccessRetentionPeriodInDays: input.SuccessRetentionPeriodInDays,
|
|
414
|
-
})), (input.VisualReference
|
|
415
|
-
input.VisualReference !== null && {
|
|
641
|
+
})), (input.VisualReference != null && {
|
|
416
642
|
VisualReference: serializeAws_restJson1VisualReferenceInput(input.VisualReference, context),
|
|
417
|
-
})), (input.VpcConfig
|
|
418
|
-
input.VpcConfig !== null && { VpcConfig: serializeAws_restJson1VpcConfigInput(input.VpcConfig, context) })));
|
|
643
|
+
})), (input.VpcConfig != null && { VpcConfig: serializeAws_restJson1VpcConfigInput(input.VpcConfig, context) })));
|
|
419
644
|
return [2, new __HttpRequest({
|
|
420
645
|
protocol: protocol,
|
|
421
646
|
hostname: hostname,
|
|
@@ -428,6 +653,73 @@ export var serializeAws_restJson1UpdateCanaryCommand = function (input, context)
|
|
|
428
653
|
}
|
|
429
654
|
});
|
|
430
655
|
}); };
|
|
656
|
+
export var deserializeAws_restJson1AssociateResourceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
657
|
+
var contents;
|
|
658
|
+
return __generator(this, function (_a) {
|
|
659
|
+
switch (_a.label) {
|
|
660
|
+
case 0:
|
|
661
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
662
|
+
return [2, deserializeAws_restJson1AssociateResourceCommandError(output, context)];
|
|
663
|
+
}
|
|
664
|
+
contents = {
|
|
665
|
+
$metadata: deserializeMetadata(output),
|
|
666
|
+
};
|
|
667
|
+
return [4, collectBody(output.body, context)];
|
|
668
|
+
case 1:
|
|
669
|
+
_a.sent();
|
|
670
|
+
return [2, Promise.resolve(contents)];
|
|
671
|
+
}
|
|
672
|
+
});
|
|
673
|
+
}); };
|
|
674
|
+
var deserializeAws_restJson1AssociateResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
675
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
676
|
+
var _c;
|
|
677
|
+
return __generator(this, function (_d) {
|
|
678
|
+
switch (_d.label) {
|
|
679
|
+
case 0:
|
|
680
|
+
_a = [__assign({}, output)];
|
|
681
|
+
_c = {};
|
|
682
|
+
return [4, parseBody(output.body, context)];
|
|
683
|
+
case 1:
|
|
684
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
685
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
686
|
+
_b = errorCode;
|
|
687
|
+
switch (_b) {
|
|
688
|
+
case "ConflictException": return [3, 2];
|
|
689
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 2];
|
|
690
|
+
case "InternalServerException": return [3, 4];
|
|
691
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 4];
|
|
692
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
693
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 6];
|
|
694
|
+
case "ServiceQuotaExceededException": return [3, 8];
|
|
695
|
+
case "com.amazonaws.synthetics#ServiceQuotaExceededException": return [3, 8];
|
|
696
|
+
case "ValidationException": return [3, 10];
|
|
697
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 10];
|
|
698
|
+
}
|
|
699
|
+
return [3, 12];
|
|
700
|
+
case 2: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
701
|
+
case 3: throw _d.sent();
|
|
702
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
703
|
+
case 5: throw _d.sent();
|
|
704
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
705
|
+
case 7: throw _d.sent();
|
|
706
|
+
case 8: return [4, deserializeAws_restJson1ServiceQuotaExceededExceptionResponse(parsedOutput, context)];
|
|
707
|
+
case 9: throw _d.sent();
|
|
708
|
+
case 10: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
709
|
+
case 11: throw _d.sent();
|
|
710
|
+
case 12:
|
|
711
|
+
parsedBody = parsedOutput.body;
|
|
712
|
+
$metadata = deserializeMetadata(output);
|
|
713
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
714
|
+
response = new __BaseException({
|
|
715
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
716
|
+
$fault: "client",
|
|
717
|
+
$metadata: $metadata,
|
|
718
|
+
});
|
|
719
|
+
throw __decorateServiceException(response, parsedBody);
|
|
720
|
+
}
|
|
721
|
+
});
|
|
722
|
+
}); };
|
|
431
723
|
export var deserializeAws_restJson1CreateCanaryCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
432
724
|
var contents, data, _a, _b;
|
|
433
725
|
return __generator(this, function (_c) {
|
|
@@ -453,7 +745,7 @@ export var deserializeAws_restJson1CreateCanaryCommand = function (output, conte
|
|
|
453
745
|
});
|
|
454
746
|
}); };
|
|
455
747
|
var deserializeAws_restJson1CreateCanaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
456
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
748
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
457
749
|
var _c;
|
|
458
750
|
return __generator(this, function (_d) {
|
|
459
751
|
switch (_d.label) {
|
|
@@ -463,7 +755,6 @@ var deserializeAws_restJson1CreateCanaryCommandError = function (output, context
|
|
|
463
755
|
return [4, parseBody(output.body, context)];
|
|
464
756
|
case 1:
|
|
465
757
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
466
|
-
errorCode = "UnknownError";
|
|
467
758
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
468
759
|
_b = errorCode;
|
|
469
760
|
switch (_b) {
|
|
@@ -483,10 +774,81 @@ var deserializeAws_restJson1CreateCanaryCommandError = function (output, context
|
|
|
483
774
|
case 7: throw _d.sent();
|
|
484
775
|
case 8:
|
|
485
776
|
parsedBody = parsedOutput.body;
|
|
777
|
+
$metadata = deserializeMetadata(output);
|
|
778
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
486
779
|
response = new __BaseException({
|
|
487
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
780
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
488
781
|
$fault: "client",
|
|
489
|
-
$metadata:
|
|
782
|
+
$metadata: $metadata,
|
|
783
|
+
});
|
|
784
|
+
throw __decorateServiceException(response, parsedBody);
|
|
785
|
+
}
|
|
786
|
+
});
|
|
787
|
+
}); };
|
|
788
|
+
export var deserializeAws_restJson1CreateGroupCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
789
|
+
var contents, data, _a, _b;
|
|
790
|
+
return __generator(this, function (_c) {
|
|
791
|
+
switch (_c.label) {
|
|
792
|
+
case 0:
|
|
793
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
794
|
+
return [2, deserializeAws_restJson1CreateGroupCommandError(output, context)];
|
|
795
|
+
}
|
|
796
|
+
contents = {
|
|
797
|
+
$metadata: deserializeMetadata(output),
|
|
798
|
+
Group: undefined,
|
|
799
|
+
};
|
|
800
|
+
_a = __expectNonNull;
|
|
801
|
+
_b = __expectObject;
|
|
802
|
+
return [4, parseBody(output.body, context)];
|
|
803
|
+
case 1:
|
|
804
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
805
|
+
if (data.Group !== undefined && data.Group !== null) {
|
|
806
|
+
contents.Group = deserializeAws_restJson1Group(data.Group, context);
|
|
807
|
+
}
|
|
808
|
+
return [2, Promise.resolve(contents)];
|
|
809
|
+
}
|
|
810
|
+
});
|
|
811
|
+
}); };
|
|
812
|
+
var deserializeAws_restJson1CreateGroupCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
813
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
814
|
+
var _c;
|
|
815
|
+
return __generator(this, function (_d) {
|
|
816
|
+
switch (_d.label) {
|
|
817
|
+
case 0:
|
|
818
|
+
_a = [__assign({}, output)];
|
|
819
|
+
_c = {};
|
|
820
|
+
return [4, parseBody(output.body, context)];
|
|
821
|
+
case 1:
|
|
822
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
823
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
824
|
+
_b = errorCode;
|
|
825
|
+
switch (_b) {
|
|
826
|
+
case "ConflictException": return [3, 2];
|
|
827
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 2];
|
|
828
|
+
case "InternalServerException": return [3, 4];
|
|
829
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 4];
|
|
830
|
+
case "ServiceQuotaExceededException": return [3, 6];
|
|
831
|
+
case "com.amazonaws.synthetics#ServiceQuotaExceededException": return [3, 6];
|
|
832
|
+
case "ValidationException": return [3, 8];
|
|
833
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 8];
|
|
834
|
+
}
|
|
835
|
+
return [3, 10];
|
|
836
|
+
case 2: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
837
|
+
case 3: throw _d.sent();
|
|
838
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
839
|
+
case 5: throw _d.sent();
|
|
840
|
+
case 6: return [4, deserializeAws_restJson1ServiceQuotaExceededExceptionResponse(parsedOutput, context)];
|
|
841
|
+
case 7: throw _d.sent();
|
|
842
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
843
|
+
case 9: throw _d.sent();
|
|
844
|
+
case 10:
|
|
845
|
+
parsedBody = parsedOutput.body;
|
|
846
|
+
$metadata = deserializeMetadata(output);
|
|
847
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
848
|
+
response = new __BaseException({
|
|
849
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
850
|
+
$fault: "client",
|
|
851
|
+
$metadata: $metadata,
|
|
490
852
|
});
|
|
491
853
|
throw __decorateServiceException(response, parsedBody);
|
|
492
854
|
}
|
|
@@ -511,7 +873,7 @@ export var deserializeAws_restJson1DeleteCanaryCommand = function (output, conte
|
|
|
511
873
|
});
|
|
512
874
|
}); };
|
|
513
875
|
var deserializeAws_restJson1DeleteCanaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
514
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
876
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
515
877
|
var _c;
|
|
516
878
|
return __generator(this, function (_d) {
|
|
517
879
|
switch (_d.label) {
|
|
@@ -521,7 +883,6 @@ var deserializeAws_restJson1DeleteCanaryCommandError = function (output, context
|
|
|
521
883
|
return [4, parseBody(output.body, context)];
|
|
522
884
|
case 1:
|
|
523
885
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
524
|
-
errorCode = "UnknownError";
|
|
525
886
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
526
887
|
_b = errorCode;
|
|
527
888
|
switch (_b) {
|
|
@@ -545,10 +906,75 @@ var deserializeAws_restJson1DeleteCanaryCommandError = function (output, context
|
|
|
545
906
|
case 9: throw _d.sent();
|
|
546
907
|
case 10:
|
|
547
908
|
parsedBody = parsedOutput.body;
|
|
909
|
+
$metadata = deserializeMetadata(output);
|
|
910
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
548
911
|
response = new __BaseException({
|
|
549
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
912
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
550
913
|
$fault: "client",
|
|
914
|
+
$metadata: $metadata,
|
|
915
|
+
});
|
|
916
|
+
throw __decorateServiceException(response, parsedBody);
|
|
917
|
+
}
|
|
918
|
+
});
|
|
919
|
+
}); };
|
|
920
|
+
export var deserializeAws_restJson1DeleteGroupCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
921
|
+
var contents;
|
|
922
|
+
return __generator(this, function (_a) {
|
|
923
|
+
switch (_a.label) {
|
|
924
|
+
case 0:
|
|
925
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
926
|
+
return [2, deserializeAws_restJson1DeleteGroupCommandError(output, context)];
|
|
927
|
+
}
|
|
928
|
+
contents = {
|
|
551
929
|
$metadata: deserializeMetadata(output),
|
|
930
|
+
};
|
|
931
|
+
return [4, collectBody(output.body, context)];
|
|
932
|
+
case 1:
|
|
933
|
+
_a.sent();
|
|
934
|
+
return [2, Promise.resolve(contents)];
|
|
935
|
+
}
|
|
936
|
+
});
|
|
937
|
+
}); };
|
|
938
|
+
var deserializeAws_restJson1DeleteGroupCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
939
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
940
|
+
var _c;
|
|
941
|
+
return __generator(this, function (_d) {
|
|
942
|
+
switch (_d.label) {
|
|
943
|
+
case 0:
|
|
944
|
+
_a = [__assign({}, output)];
|
|
945
|
+
_c = {};
|
|
946
|
+
return [4, parseBody(output.body, context)];
|
|
947
|
+
case 1:
|
|
948
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
949
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
950
|
+
_b = errorCode;
|
|
951
|
+
switch (_b) {
|
|
952
|
+
case "ConflictException": return [3, 2];
|
|
953
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 2];
|
|
954
|
+
case "InternalServerException": return [3, 4];
|
|
955
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 4];
|
|
956
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
957
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 6];
|
|
958
|
+
case "ValidationException": return [3, 8];
|
|
959
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 8];
|
|
960
|
+
}
|
|
961
|
+
return [3, 10];
|
|
962
|
+
case 2: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
963
|
+
case 3: throw _d.sent();
|
|
964
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
965
|
+
case 5: throw _d.sent();
|
|
966
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
967
|
+
case 7: throw _d.sent();
|
|
968
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
969
|
+
case 9: throw _d.sent();
|
|
970
|
+
case 10:
|
|
971
|
+
parsedBody = parsedOutput.body;
|
|
972
|
+
$metadata = deserializeMetadata(output);
|
|
973
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
974
|
+
response = new __BaseException({
|
|
975
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
976
|
+
$fault: "client",
|
|
977
|
+
$metadata: $metadata,
|
|
552
978
|
});
|
|
553
979
|
throw __decorateServiceException(response, parsedBody);
|
|
554
980
|
}
|
|
@@ -583,7 +1009,7 @@ export var deserializeAws_restJson1DescribeCanariesCommand = function (output, c
|
|
|
583
1009
|
});
|
|
584
1010
|
}); };
|
|
585
1011
|
var deserializeAws_restJson1DescribeCanariesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
586
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1012
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
587
1013
|
var _c;
|
|
588
1014
|
return __generator(this, function (_d) {
|
|
589
1015
|
switch (_d.label) {
|
|
@@ -593,7 +1019,6 @@ var deserializeAws_restJson1DescribeCanariesCommandError = function (output, con
|
|
|
593
1019
|
return [4, parseBody(output.body, context)];
|
|
594
1020
|
case 1:
|
|
595
1021
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
596
|
-
errorCode = "UnknownError";
|
|
597
1022
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
598
1023
|
_b = errorCode;
|
|
599
1024
|
switch (_b) {
|
|
@@ -609,10 +1034,12 @@ var deserializeAws_restJson1DescribeCanariesCommandError = function (output, con
|
|
|
609
1034
|
case 5: throw _d.sent();
|
|
610
1035
|
case 6:
|
|
611
1036
|
parsedBody = parsedOutput.body;
|
|
1037
|
+
$metadata = deserializeMetadata(output);
|
|
1038
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
612
1039
|
response = new __BaseException({
|
|
613
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1040
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
614
1041
|
$fault: "client",
|
|
615
|
-
$metadata:
|
|
1042
|
+
$metadata: $metadata,
|
|
616
1043
|
});
|
|
617
1044
|
throw __decorateServiceException(response, parsedBody);
|
|
618
1045
|
}
|
|
@@ -636,18 +1063,337 @@ export var deserializeAws_restJson1DescribeCanariesLastRunCommand = function (ou
|
|
|
636
1063
|
return [4, parseBody(output.body, context)];
|
|
637
1064
|
case 1:
|
|
638
1065
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
639
|
-
if (data.CanariesLastRun !== undefined && data.CanariesLastRun !== null) {
|
|
640
|
-
contents.CanariesLastRun = deserializeAws_restJson1CanariesLastRun(data.CanariesLastRun, context);
|
|
641
|
-
}
|
|
642
|
-
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
643
|
-
contents.NextToken = __expectString(data.NextToken);
|
|
1066
|
+
if (data.CanariesLastRun !== undefined && data.CanariesLastRun !== null) {
|
|
1067
|
+
contents.CanariesLastRun = deserializeAws_restJson1CanariesLastRun(data.CanariesLastRun, context);
|
|
1068
|
+
}
|
|
1069
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1070
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
1071
|
+
}
|
|
1072
|
+
return [2, Promise.resolve(contents)];
|
|
1073
|
+
}
|
|
1074
|
+
});
|
|
1075
|
+
}); };
|
|
1076
|
+
var deserializeAws_restJson1DescribeCanariesLastRunCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1077
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1078
|
+
var _c;
|
|
1079
|
+
return __generator(this, function (_d) {
|
|
1080
|
+
switch (_d.label) {
|
|
1081
|
+
case 0:
|
|
1082
|
+
_a = [__assign({}, output)];
|
|
1083
|
+
_c = {};
|
|
1084
|
+
return [4, parseBody(output.body, context)];
|
|
1085
|
+
case 1:
|
|
1086
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1087
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1088
|
+
_b = errorCode;
|
|
1089
|
+
switch (_b) {
|
|
1090
|
+
case "InternalServerException": return [3, 2];
|
|
1091
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 2];
|
|
1092
|
+
case "ValidationException": return [3, 4];
|
|
1093
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 4];
|
|
1094
|
+
}
|
|
1095
|
+
return [3, 6];
|
|
1096
|
+
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
1097
|
+
case 3: throw _d.sent();
|
|
1098
|
+
case 4: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1099
|
+
case 5: throw _d.sent();
|
|
1100
|
+
case 6:
|
|
1101
|
+
parsedBody = parsedOutput.body;
|
|
1102
|
+
$metadata = deserializeMetadata(output);
|
|
1103
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1104
|
+
response = new __BaseException({
|
|
1105
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1106
|
+
$fault: "client",
|
|
1107
|
+
$metadata: $metadata,
|
|
1108
|
+
});
|
|
1109
|
+
throw __decorateServiceException(response, parsedBody);
|
|
1110
|
+
}
|
|
1111
|
+
});
|
|
1112
|
+
}); };
|
|
1113
|
+
export var deserializeAws_restJson1DescribeRuntimeVersionsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1114
|
+
var contents, data, _a, _b;
|
|
1115
|
+
return __generator(this, function (_c) {
|
|
1116
|
+
switch (_c.label) {
|
|
1117
|
+
case 0:
|
|
1118
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1119
|
+
return [2, deserializeAws_restJson1DescribeRuntimeVersionsCommandError(output, context)];
|
|
1120
|
+
}
|
|
1121
|
+
contents = {
|
|
1122
|
+
$metadata: deserializeMetadata(output),
|
|
1123
|
+
NextToken: undefined,
|
|
1124
|
+
RuntimeVersions: undefined,
|
|
1125
|
+
};
|
|
1126
|
+
_a = __expectNonNull;
|
|
1127
|
+
_b = __expectObject;
|
|
1128
|
+
return [4, parseBody(output.body, context)];
|
|
1129
|
+
case 1:
|
|
1130
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1131
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1132
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
1133
|
+
}
|
|
1134
|
+
if (data.RuntimeVersions !== undefined && data.RuntimeVersions !== null) {
|
|
1135
|
+
contents.RuntimeVersions = deserializeAws_restJson1RuntimeVersionList(data.RuntimeVersions, context);
|
|
1136
|
+
}
|
|
1137
|
+
return [2, Promise.resolve(contents)];
|
|
1138
|
+
}
|
|
1139
|
+
});
|
|
1140
|
+
}); };
|
|
1141
|
+
var deserializeAws_restJson1DescribeRuntimeVersionsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1142
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1143
|
+
var _c;
|
|
1144
|
+
return __generator(this, function (_d) {
|
|
1145
|
+
switch (_d.label) {
|
|
1146
|
+
case 0:
|
|
1147
|
+
_a = [__assign({}, output)];
|
|
1148
|
+
_c = {};
|
|
1149
|
+
return [4, parseBody(output.body, context)];
|
|
1150
|
+
case 1:
|
|
1151
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1152
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1153
|
+
_b = errorCode;
|
|
1154
|
+
switch (_b) {
|
|
1155
|
+
case "InternalServerException": return [3, 2];
|
|
1156
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 2];
|
|
1157
|
+
case "ValidationException": return [3, 4];
|
|
1158
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 4];
|
|
1159
|
+
}
|
|
1160
|
+
return [3, 6];
|
|
1161
|
+
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
1162
|
+
case 3: throw _d.sent();
|
|
1163
|
+
case 4: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1164
|
+
case 5: throw _d.sent();
|
|
1165
|
+
case 6:
|
|
1166
|
+
parsedBody = parsedOutput.body;
|
|
1167
|
+
$metadata = deserializeMetadata(output);
|
|
1168
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1169
|
+
response = new __BaseException({
|
|
1170
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1171
|
+
$fault: "client",
|
|
1172
|
+
$metadata: $metadata,
|
|
1173
|
+
});
|
|
1174
|
+
throw __decorateServiceException(response, parsedBody);
|
|
1175
|
+
}
|
|
1176
|
+
});
|
|
1177
|
+
}); };
|
|
1178
|
+
export var deserializeAws_restJson1DisassociateResourceCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1179
|
+
var contents;
|
|
1180
|
+
return __generator(this, function (_a) {
|
|
1181
|
+
switch (_a.label) {
|
|
1182
|
+
case 0:
|
|
1183
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1184
|
+
return [2, deserializeAws_restJson1DisassociateResourceCommandError(output, context)];
|
|
1185
|
+
}
|
|
1186
|
+
contents = {
|
|
1187
|
+
$metadata: deserializeMetadata(output),
|
|
1188
|
+
};
|
|
1189
|
+
return [4, collectBody(output.body, context)];
|
|
1190
|
+
case 1:
|
|
1191
|
+
_a.sent();
|
|
1192
|
+
return [2, Promise.resolve(contents)];
|
|
1193
|
+
}
|
|
1194
|
+
});
|
|
1195
|
+
}); };
|
|
1196
|
+
var deserializeAws_restJson1DisassociateResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1197
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1198
|
+
var _c;
|
|
1199
|
+
return __generator(this, function (_d) {
|
|
1200
|
+
switch (_d.label) {
|
|
1201
|
+
case 0:
|
|
1202
|
+
_a = [__assign({}, output)];
|
|
1203
|
+
_c = {};
|
|
1204
|
+
return [4, parseBody(output.body, context)];
|
|
1205
|
+
case 1:
|
|
1206
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1207
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1208
|
+
_b = errorCode;
|
|
1209
|
+
switch (_b) {
|
|
1210
|
+
case "ConflictException": return [3, 2];
|
|
1211
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 2];
|
|
1212
|
+
case "InternalServerException": return [3, 4];
|
|
1213
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 4];
|
|
1214
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
1215
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 6];
|
|
1216
|
+
case "ValidationException": return [3, 8];
|
|
1217
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 8];
|
|
1218
|
+
}
|
|
1219
|
+
return [3, 10];
|
|
1220
|
+
case 2: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
1221
|
+
case 3: throw _d.sent();
|
|
1222
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
1223
|
+
case 5: throw _d.sent();
|
|
1224
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1225
|
+
case 7: throw _d.sent();
|
|
1226
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1227
|
+
case 9: throw _d.sent();
|
|
1228
|
+
case 10:
|
|
1229
|
+
parsedBody = parsedOutput.body;
|
|
1230
|
+
$metadata = deserializeMetadata(output);
|
|
1231
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1232
|
+
response = new __BaseException({
|
|
1233
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1234
|
+
$fault: "client",
|
|
1235
|
+
$metadata: $metadata,
|
|
1236
|
+
});
|
|
1237
|
+
throw __decorateServiceException(response, parsedBody);
|
|
1238
|
+
}
|
|
1239
|
+
});
|
|
1240
|
+
}); };
|
|
1241
|
+
export var deserializeAws_restJson1GetCanaryCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1242
|
+
var contents, data, _a, _b;
|
|
1243
|
+
return __generator(this, function (_c) {
|
|
1244
|
+
switch (_c.label) {
|
|
1245
|
+
case 0:
|
|
1246
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1247
|
+
return [2, deserializeAws_restJson1GetCanaryCommandError(output, context)];
|
|
1248
|
+
}
|
|
1249
|
+
contents = {
|
|
1250
|
+
$metadata: deserializeMetadata(output),
|
|
1251
|
+
Canary: undefined,
|
|
1252
|
+
};
|
|
1253
|
+
_a = __expectNonNull;
|
|
1254
|
+
_b = __expectObject;
|
|
1255
|
+
return [4, parseBody(output.body, context)];
|
|
1256
|
+
case 1:
|
|
1257
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1258
|
+
if (data.Canary !== undefined && data.Canary !== null) {
|
|
1259
|
+
contents.Canary = deserializeAws_restJson1Canary(data.Canary, context);
|
|
1260
|
+
}
|
|
1261
|
+
return [2, Promise.resolve(contents)];
|
|
1262
|
+
}
|
|
1263
|
+
});
|
|
1264
|
+
}); };
|
|
1265
|
+
var deserializeAws_restJson1GetCanaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1266
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1267
|
+
var _c;
|
|
1268
|
+
return __generator(this, function (_d) {
|
|
1269
|
+
switch (_d.label) {
|
|
1270
|
+
case 0:
|
|
1271
|
+
_a = [__assign({}, output)];
|
|
1272
|
+
_c = {};
|
|
1273
|
+
return [4, parseBody(output.body, context)];
|
|
1274
|
+
case 1:
|
|
1275
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1276
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1277
|
+
_b = errorCode;
|
|
1278
|
+
switch (_b) {
|
|
1279
|
+
case "InternalServerException": return [3, 2];
|
|
1280
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 2];
|
|
1281
|
+
case "ValidationException": return [3, 4];
|
|
1282
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 4];
|
|
1283
|
+
}
|
|
1284
|
+
return [3, 6];
|
|
1285
|
+
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
1286
|
+
case 3: throw _d.sent();
|
|
1287
|
+
case 4: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1288
|
+
case 5: throw _d.sent();
|
|
1289
|
+
case 6:
|
|
1290
|
+
parsedBody = parsedOutput.body;
|
|
1291
|
+
$metadata = deserializeMetadata(output);
|
|
1292
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1293
|
+
response = new __BaseException({
|
|
1294
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1295
|
+
$fault: "client",
|
|
1296
|
+
$metadata: $metadata,
|
|
1297
|
+
});
|
|
1298
|
+
throw __decorateServiceException(response, parsedBody);
|
|
1299
|
+
}
|
|
1300
|
+
});
|
|
1301
|
+
}); };
|
|
1302
|
+
export var deserializeAws_restJson1GetCanaryRunsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1303
|
+
var contents, data, _a, _b;
|
|
1304
|
+
return __generator(this, function (_c) {
|
|
1305
|
+
switch (_c.label) {
|
|
1306
|
+
case 0:
|
|
1307
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1308
|
+
return [2, deserializeAws_restJson1GetCanaryRunsCommandError(output, context)];
|
|
1309
|
+
}
|
|
1310
|
+
contents = {
|
|
1311
|
+
$metadata: deserializeMetadata(output),
|
|
1312
|
+
CanaryRuns: undefined,
|
|
1313
|
+
NextToken: undefined,
|
|
1314
|
+
};
|
|
1315
|
+
_a = __expectNonNull;
|
|
1316
|
+
_b = __expectObject;
|
|
1317
|
+
return [4, parseBody(output.body, context)];
|
|
1318
|
+
case 1:
|
|
1319
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1320
|
+
if (data.CanaryRuns !== undefined && data.CanaryRuns !== null) {
|
|
1321
|
+
contents.CanaryRuns = deserializeAws_restJson1CanaryRuns(data.CanaryRuns, context);
|
|
1322
|
+
}
|
|
1323
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1324
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
1325
|
+
}
|
|
1326
|
+
return [2, Promise.resolve(contents)];
|
|
1327
|
+
}
|
|
1328
|
+
});
|
|
1329
|
+
}); };
|
|
1330
|
+
var deserializeAws_restJson1GetCanaryRunsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1331
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1332
|
+
var _c;
|
|
1333
|
+
return __generator(this, function (_d) {
|
|
1334
|
+
switch (_d.label) {
|
|
1335
|
+
case 0:
|
|
1336
|
+
_a = [__assign({}, output)];
|
|
1337
|
+
_c = {};
|
|
1338
|
+
return [4, parseBody(output.body, context)];
|
|
1339
|
+
case 1:
|
|
1340
|
+
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1341
|
+
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1342
|
+
_b = errorCode;
|
|
1343
|
+
switch (_b) {
|
|
1344
|
+
case "InternalServerException": return [3, 2];
|
|
1345
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 2];
|
|
1346
|
+
case "ResourceNotFoundException": return [3, 4];
|
|
1347
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 4];
|
|
1348
|
+
case "ValidationException": return [3, 6];
|
|
1349
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 6];
|
|
1350
|
+
}
|
|
1351
|
+
return [3, 8];
|
|
1352
|
+
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
1353
|
+
case 3: throw _d.sent();
|
|
1354
|
+
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1355
|
+
case 5: throw _d.sent();
|
|
1356
|
+
case 6: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1357
|
+
case 7: throw _d.sent();
|
|
1358
|
+
case 8:
|
|
1359
|
+
parsedBody = parsedOutput.body;
|
|
1360
|
+
$metadata = deserializeMetadata(output);
|
|
1361
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1362
|
+
response = new __BaseException({
|
|
1363
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1364
|
+
$fault: "client",
|
|
1365
|
+
$metadata: $metadata,
|
|
1366
|
+
});
|
|
1367
|
+
throw __decorateServiceException(response, parsedBody);
|
|
1368
|
+
}
|
|
1369
|
+
});
|
|
1370
|
+
}); };
|
|
1371
|
+
export var deserializeAws_restJson1GetGroupCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1372
|
+
var contents, data, _a, _b;
|
|
1373
|
+
return __generator(this, function (_c) {
|
|
1374
|
+
switch (_c.label) {
|
|
1375
|
+
case 0:
|
|
1376
|
+
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
1377
|
+
return [2, deserializeAws_restJson1GetGroupCommandError(output, context)];
|
|
1378
|
+
}
|
|
1379
|
+
contents = {
|
|
1380
|
+
$metadata: deserializeMetadata(output),
|
|
1381
|
+
Group: undefined,
|
|
1382
|
+
};
|
|
1383
|
+
_a = __expectNonNull;
|
|
1384
|
+
_b = __expectObject;
|
|
1385
|
+
return [4, parseBody(output.body, context)];
|
|
1386
|
+
case 1:
|
|
1387
|
+
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1388
|
+
if (data.Group !== undefined && data.Group !== null) {
|
|
1389
|
+
contents.Group = deserializeAws_restJson1Group(data.Group, context);
|
|
644
1390
|
}
|
|
645
1391
|
return [2, Promise.resolve(contents)];
|
|
646
1392
|
}
|
|
647
1393
|
});
|
|
648
1394
|
}); };
|
|
649
|
-
var
|
|
650
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1395
|
+
var deserializeAws_restJson1GetGroupCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1396
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
651
1397
|
var _c;
|
|
652
1398
|
return __generator(this, function (_d) {
|
|
653
1399
|
switch (_d.label) {
|
|
@@ -657,61 +1403,70 @@ var deserializeAws_restJson1DescribeCanariesLastRunCommandError = function (outp
|
|
|
657
1403
|
return [4, parseBody(output.body, context)];
|
|
658
1404
|
case 1:
|
|
659
1405
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
660
|
-
errorCode = "UnknownError";
|
|
661
1406
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
662
1407
|
_b = errorCode;
|
|
663
1408
|
switch (_b) {
|
|
664
|
-
case "
|
|
665
|
-
case "com.amazonaws.synthetics#
|
|
666
|
-
case "
|
|
667
|
-
case "com.amazonaws.synthetics#
|
|
1409
|
+
case "ConflictException": return [3, 2];
|
|
1410
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 2];
|
|
1411
|
+
case "InternalServerException": return [3, 4];
|
|
1412
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 4];
|
|
1413
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
1414
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 6];
|
|
1415
|
+
case "ValidationException": return [3, 8];
|
|
1416
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 8];
|
|
668
1417
|
}
|
|
669
|
-
return [3,
|
|
670
|
-
case 2: return [4,
|
|
1418
|
+
return [3, 10];
|
|
1419
|
+
case 2: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
671
1420
|
case 3: throw _d.sent();
|
|
672
|
-
case 4: return [4,
|
|
1421
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
673
1422
|
case 5: throw _d.sent();
|
|
674
|
-
case 6:
|
|
1423
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1424
|
+
case 7: throw _d.sent();
|
|
1425
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1426
|
+
case 9: throw _d.sent();
|
|
1427
|
+
case 10:
|
|
675
1428
|
parsedBody = parsedOutput.body;
|
|
1429
|
+
$metadata = deserializeMetadata(output);
|
|
1430
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
676
1431
|
response = new __BaseException({
|
|
677
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1432
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
678
1433
|
$fault: "client",
|
|
679
|
-
$metadata:
|
|
1434
|
+
$metadata: $metadata,
|
|
680
1435
|
});
|
|
681
1436
|
throw __decorateServiceException(response, parsedBody);
|
|
682
1437
|
}
|
|
683
1438
|
});
|
|
684
1439
|
}); };
|
|
685
|
-
export var
|
|
1440
|
+
export var deserializeAws_restJson1ListAssociatedGroupsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
686
1441
|
var contents, data, _a, _b;
|
|
687
1442
|
return __generator(this, function (_c) {
|
|
688
1443
|
switch (_c.label) {
|
|
689
1444
|
case 0:
|
|
690
1445
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
691
|
-
return [2,
|
|
1446
|
+
return [2, deserializeAws_restJson1ListAssociatedGroupsCommandError(output, context)];
|
|
692
1447
|
}
|
|
693
1448
|
contents = {
|
|
694
1449
|
$metadata: deserializeMetadata(output),
|
|
1450
|
+
Groups: undefined,
|
|
695
1451
|
NextToken: undefined,
|
|
696
|
-
RuntimeVersions: undefined,
|
|
697
1452
|
};
|
|
698
1453
|
_a = __expectNonNull;
|
|
699
1454
|
_b = __expectObject;
|
|
700
1455
|
return [4, parseBody(output.body, context)];
|
|
701
1456
|
case 1:
|
|
702
1457
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
1458
|
+
if (data.Groups !== undefined && data.Groups !== null) {
|
|
1459
|
+
contents.Groups = deserializeAws_restJson1GroupSummaryList(data.Groups, context);
|
|
1460
|
+
}
|
|
703
1461
|
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
704
1462
|
contents.NextToken = __expectString(data.NextToken);
|
|
705
1463
|
}
|
|
706
|
-
if (data.RuntimeVersions !== undefined && data.RuntimeVersions !== null) {
|
|
707
|
-
contents.RuntimeVersions = deserializeAws_restJson1RuntimeVersionList(data.RuntimeVersions, context);
|
|
708
|
-
}
|
|
709
1464
|
return [2, Promise.resolve(contents)];
|
|
710
1465
|
}
|
|
711
1466
|
});
|
|
712
1467
|
}); };
|
|
713
|
-
var
|
|
714
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1468
|
+
var deserializeAws_restJson1ListAssociatedGroupsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1469
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
715
1470
|
var _c;
|
|
716
1471
|
return __generator(this, function (_d) {
|
|
717
1472
|
switch (_d.label) {
|
|
@@ -721,57 +1476,66 @@ var deserializeAws_restJson1DescribeRuntimeVersionsCommandError = function (outp
|
|
|
721
1476
|
return [4, parseBody(output.body, context)];
|
|
722
1477
|
case 1:
|
|
723
1478
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
724
|
-
errorCode = "UnknownError";
|
|
725
1479
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
726
1480
|
_b = errorCode;
|
|
727
1481
|
switch (_b) {
|
|
728
1482
|
case "InternalServerException": return [3, 2];
|
|
729
1483
|
case "com.amazonaws.synthetics#InternalServerException": return [3, 2];
|
|
730
|
-
case "
|
|
731
|
-
case "com.amazonaws.synthetics#
|
|
1484
|
+
case "ResourceNotFoundException": return [3, 4];
|
|
1485
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 4];
|
|
1486
|
+
case "ValidationException": return [3, 6];
|
|
1487
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 6];
|
|
732
1488
|
}
|
|
733
|
-
return [3,
|
|
1489
|
+
return [3, 8];
|
|
734
1490
|
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
735
1491
|
case 3: throw _d.sent();
|
|
736
|
-
case 4: return [4,
|
|
1492
|
+
case 4: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
737
1493
|
case 5: throw _d.sent();
|
|
738
|
-
case 6:
|
|
1494
|
+
case 6: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1495
|
+
case 7: throw _d.sent();
|
|
1496
|
+
case 8:
|
|
739
1497
|
parsedBody = parsedOutput.body;
|
|
1498
|
+
$metadata = deserializeMetadata(output);
|
|
1499
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
740
1500
|
response = new __BaseException({
|
|
741
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1501
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
742
1502
|
$fault: "client",
|
|
743
|
-
$metadata:
|
|
1503
|
+
$metadata: $metadata,
|
|
744
1504
|
});
|
|
745
1505
|
throw __decorateServiceException(response, parsedBody);
|
|
746
1506
|
}
|
|
747
1507
|
});
|
|
748
1508
|
}); };
|
|
749
|
-
export var
|
|
1509
|
+
export var deserializeAws_restJson1ListGroupResourcesCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
750
1510
|
var contents, data, _a, _b;
|
|
751
1511
|
return __generator(this, function (_c) {
|
|
752
1512
|
switch (_c.label) {
|
|
753
1513
|
case 0:
|
|
754
1514
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
755
|
-
return [2,
|
|
1515
|
+
return [2, deserializeAws_restJson1ListGroupResourcesCommandError(output, context)];
|
|
756
1516
|
}
|
|
757
1517
|
contents = {
|
|
758
1518
|
$metadata: deserializeMetadata(output),
|
|
759
|
-
|
|
1519
|
+
NextToken: undefined,
|
|
1520
|
+
Resources: undefined,
|
|
760
1521
|
};
|
|
761
1522
|
_a = __expectNonNull;
|
|
762
1523
|
_b = __expectObject;
|
|
763
1524
|
return [4, parseBody(output.body, context)];
|
|
764
1525
|
case 1:
|
|
765
1526
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
766
|
-
if (data.
|
|
767
|
-
contents.
|
|
1527
|
+
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
1528
|
+
contents.NextToken = __expectString(data.NextToken);
|
|
1529
|
+
}
|
|
1530
|
+
if (data.Resources !== undefined && data.Resources !== null) {
|
|
1531
|
+
contents.Resources = deserializeAws_restJson1StringList(data.Resources, context);
|
|
768
1532
|
}
|
|
769
1533
|
return [2, Promise.resolve(contents)];
|
|
770
1534
|
}
|
|
771
1535
|
});
|
|
772
1536
|
}); };
|
|
773
|
-
var
|
|
774
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1537
|
+
var deserializeAws_restJson1ListGroupResourcesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1538
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
775
1539
|
var _c;
|
|
776
1540
|
return __generator(this, function (_d) {
|
|
777
1541
|
switch (_d.label) {
|
|
@@ -781,42 +1545,51 @@ var deserializeAws_restJson1GetCanaryCommandError = function (output, context) {
|
|
|
781
1545
|
return [4, parseBody(output.body, context)];
|
|
782
1546
|
case 1:
|
|
783
1547
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
784
|
-
errorCode = "UnknownError";
|
|
785
1548
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
786
1549
|
_b = errorCode;
|
|
787
1550
|
switch (_b) {
|
|
788
|
-
case "
|
|
789
|
-
case "com.amazonaws.synthetics#
|
|
790
|
-
case "
|
|
791
|
-
case "com.amazonaws.synthetics#
|
|
1551
|
+
case "ConflictException": return [3, 2];
|
|
1552
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 2];
|
|
1553
|
+
case "InternalServerException": return [3, 4];
|
|
1554
|
+
case "com.amazonaws.synthetics#InternalServerException": return [3, 4];
|
|
1555
|
+
case "ResourceNotFoundException": return [3, 6];
|
|
1556
|
+
case "com.amazonaws.synthetics#ResourceNotFoundException": return [3, 6];
|
|
1557
|
+
case "ValidationException": return [3, 8];
|
|
1558
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 8];
|
|
792
1559
|
}
|
|
793
|
-
return [3,
|
|
794
|
-
case 2: return [4,
|
|
1560
|
+
return [3, 10];
|
|
1561
|
+
case 2: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
795
1562
|
case 3: throw _d.sent();
|
|
796
|
-
case 4: return [4,
|
|
1563
|
+
case 4: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
797
1564
|
case 5: throw _d.sent();
|
|
798
|
-
case 6:
|
|
1565
|
+
case 6: return [4, deserializeAws_restJson1ResourceNotFoundExceptionResponse(parsedOutput, context)];
|
|
1566
|
+
case 7: throw _d.sent();
|
|
1567
|
+
case 8: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
1568
|
+
case 9: throw _d.sent();
|
|
1569
|
+
case 10:
|
|
799
1570
|
parsedBody = parsedOutput.body;
|
|
1571
|
+
$metadata = deserializeMetadata(output);
|
|
1572
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
800
1573
|
response = new __BaseException({
|
|
801
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1574
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
802
1575
|
$fault: "client",
|
|
803
|
-
$metadata:
|
|
1576
|
+
$metadata: $metadata,
|
|
804
1577
|
});
|
|
805
1578
|
throw __decorateServiceException(response, parsedBody);
|
|
806
1579
|
}
|
|
807
1580
|
});
|
|
808
1581
|
}); };
|
|
809
|
-
export var
|
|
1582
|
+
export var deserializeAws_restJson1ListGroupsCommand = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
810
1583
|
var contents, data, _a, _b;
|
|
811
1584
|
return __generator(this, function (_c) {
|
|
812
1585
|
switch (_c.label) {
|
|
813
1586
|
case 0:
|
|
814
1587
|
if (output.statusCode !== 200 && output.statusCode >= 300) {
|
|
815
|
-
return [2,
|
|
1588
|
+
return [2, deserializeAws_restJson1ListGroupsCommandError(output, context)];
|
|
816
1589
|
}
|
|
817
1590
|
contents = {
|
|
818
1591
|
$metadata: deserializeMetadata(output),
|
|
819
|
-
|
|
1592
|
+
Groups: undefined,
|
|
820
1593
|
NextToken: undefined,
|
|
821
1594
|
};
|
|
822
1595
|
_a = __expectNonNull;
|
|
@@ -824,8 +1597,8 @@ export var deserializeAws_restJson1GetCanaryRunsCommand = function (output, cont
|
|
|
824
1597
|
return [4, parseBody(output.body, context)];
|
|
825
1598
|
case 1:
|
|
826
1599
|
data = _a.apply(void 0, [_b.apply(void 0, [_c.sent()]), "body"]);
|
|
827
|
-
if (data.
|
|
828
|
-
contents.
|
|
1600
|
+
if (data.Groups !== undefined && data.Groups !== null) {
|
|
1601
|
+
contents.Groups = deserializeAws_restJson1GroupSummaryList(data.Groups, context);
|
|
829
1602
|
}
|
|
830
1603
|
if (data.NextToken !== undefined && data.NextToken !== null) {
|
|
831
1604
|
contents.NextToken = __expectString(data.NextToken);
|
|
@@ -834,8 +1607,8 @@ export var deserializeAws_restJson1GetCanaryRunsCommand = function (output, cont
|
|
|
834
1607
|
}
|
|
835
1608
|
});
|
|
836
1609
|
}); };
|
|
837
|
-
var
|
|
838
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1610
|
+
var deserializeAws_restJson1ListGroupsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1611
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
839
1612
|
var _c;
|
|
840
1613
|
return __generator(this, function (_d) {
|
|
841
1614
|
switch (_d.label) {
|
|
@@ -845,30 +1618,27 @@ var deserializeAws_restJson1GetCanaryRunsCommandError = function (output, contex
|
|
|
845
1618
|
return [4, parseBody(output.body, context)];
|
|
846
1619
|
case 1:
|
|
847
1620
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
848
|
-
errorCode = "UnknownError";
|
|
849
1621
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
850
1622
|
_b = errorCode;
|
|
851
1623
|
switch (_b) {
|
|
852
1624
|
case "InternalServerException": return [3, 2];
|
|
853
1625
|
case "com.amazonaws.synthetics#InternalServerException": return [3, 2];
|
|
854
|
-
case "
|
|
855
|
-
case "com.amazonaws.synthetics#
|
|
856
|
-
case "ValidationException": return [3, 6];
|
|
857
|
-
case "com.amazonaws.synthetics#ValidationException": return [3, 6];
|
|
1626
|
+
case "ValidationException": return [3, 4];
|
|
1627
|
+
case "com.amazonaws.synthetics#ValidationException": return [3, 4];
|
|
858
1628
|
}
|
|
859
|
-
return [3,
|
|
1629
|
+
return [3, 6];
|
|
860
1630
|
case 2: return [4, deserializeAws_restJson1InternalServerExceptionResponse(parsedOutput, context)];
|
|
861
1631
|
case 3: throw _d.sent();
|
|
862
|
-
case 4: return [4,
|
|
1632
|
+
case 4: return [4, deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context)];
|
|
863
1633
|
case 5: throw _d.sent();
|
|
864
|
-
case 6:
|
|
865
|
-
case 7: throw _d.sent();
|
|
866
|
-
case 8:
|
|
1634
|
+
case 6:
|
|
867
1635
|
parsedBody = parsedOutput.body;
|
|
1636
|
+
$metadata = deserializeMetadata(output);
|
|
1637
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
868
1638
|
response = new __BaseException({
|
|
869
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1639
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
870
1640
|
$fault: "client",
|
|
871
|
-
$metadata:
|
|
1641
|
+
$metadata: $metadata,
|
|
872
1642
|
});
|
|
873
1643
|
throw __decorateServiceException(response, parsedBody);
|
|
874
1644
|
}
|
|
@@ -899,7 +1669,7 @@ export var deserializeAws_restJson1ListTagsForResourceCommand = function (output
|
|
|
899
1669
|
});
|
|
900
1670
|
}); };
|
|
901
1671
|
var deserializeAws_restJson1ListTagsForResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
902
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1672
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
903
1673
|
var _c;
|
|
904
1674
|
return __generator(this, function (_d) {
|
|
905
1675
|
switch (_d.label) {
|
|
@@ -909,30 +1679,39 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
|
|
|
909
1679
|
return [4, parseBody(output.body, context)];
|
|
910
1680
|
case 1:
|
|
911
1681
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
912
|
-
errorCode = "UnknownError";
|
|
913
1682
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
914
1683
|
_b = errorCode;
|
|
915
1684
|
switch (_b) {
|
|
916
|
-
case "
|
|
917
|
-
case "com.amazonaws.synthetics#
|
|
918
|
-
case "
|
|
919
|
-
case "com.amazonaws.synthetics#
|
|
920
|
-
case "
|
|
921
|
-
case "com.amazonaws.synthetics#
|
|
1685
|
+
case "BadRequestException": return [3, 2];
|
|
1686
|
+
case "com.amazonaws.synthetics#BadRequestException": return [3, 2];
|
|
1687
|
+
case "ConflictException": return [3, 4];
|
|
1688
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 4];
|
|
1689
|
+
case "InternalFailureException": return [3, 6];
|
|
1690
|
+
case "com.amazonaws.synthetics#InternalFailureException": return [3, 6];
|
|
1691
|
+
case "NotFoundException": return [3, 8];
|
|
1692
|
+
case "com.amazonaws.synthetics#NotFoundException": return [3, 8];
|
|
1693
|
+
case "TooManyRequestsException": return [3, 10];
|
|
1694
|
+
case "com.amazonaws.synthetics#TooManyRequestsException": return [3, 10];
|
|
922
1695
|
}
|
|
923
|
-
return [3,
|
|
924
|
-
case 2: return [4,
|
|
1696
|
+
return [3, 12];
|
|
1697
|
+
case 2: return [4, deserializeAws_restJson1BadRequestExceptionResponse(parsedOutput, context)];
|
|
925
1698
|
case 3: throw _d.sent();
|
|
926
|
-
case 4: return [4,
|
|
1699
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
927
1700
|
case 5: throw _d.sent();
|
|
928
|
-
case 6: return [4,
|
|
1701
|
+
case 6: return [4, deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)];
|
|
929
1702
|
case 7: throw _d.sent();
|
|
930
|
-
case 8:
|
|
1703
|
+
case 8: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
1704
|
+
case 9: throw _d.sent();
|
|
1705
|
+
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
1706
|
+
case 11: throw _d.sent();
|
|
1707
|
+
case 12:
|
|
931
1708
|
parsedBody = parsedOutput.body;
|
|
1709
|
+
$metadata = deserializeMetadata(output);
|
|
1710
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
932
1711
|
response = new __BaseException({
|
|
933
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1712
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
934
1713
|
$fault: "client",
|
|
935
|
-
$metadata:
|
|
1714
|
+
$metadata: $metadata,
|
|
936
1715
|
});
|
|
937
1716
|
throw __decorateServiceException(response, parsedBody);
|
|
938
1717
|
}
|
|
@@ -957,7 +1736,7 @@ export var deserializeAws_restJson1StartCanaryCommand = function (output, contex
|
|
|
957
1736
|
});
|
|
958
1737
|
}); };
|
|
959
1738
|
var deserializeAws_restJson1StartCanaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
960
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1739
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
961
1740
|
var _c;
|
|
962
1741
|
return __generator(this, function (_d) {
|
|
963
1742
|
switch (_d.label) {
|
|
@@ -967,7 +1746,6 @@ var deserializeAws_restJson1StartCanaryCommandError = function (output, context)
|
|
|
967
1746
|
return [4, parseBody(output.body, context)];
|
|
968
1747
|
case 1:
|
|
969
1748
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
970
|
-
errorCode = "UnknownError";
|
|
971
1749
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
972
1750
|
_b = errorCode;
|
|
973
1751
|
switch (_b) {
|
|
@@ -991,10 +1769,12 @@ var deserializeAws_restJson1StartCanaryCommandError = function (output, context)
|
|
|
991
1769
|
case 9: throw _d.sent();
|
|
992
1770
|
case 10:
|
|
993
1771
|
parsedBody = parsedOutput.body;
|
|
1772
|
+
$metadata = deserializeMetadata(output);
|
|
1773
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
994
1774
|
response = new __BaseException({
|
|
995
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1775
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
996
1776
|
$fault: "client",
|
|
997
|
-
$metadata:
|
|
1777
|
+
$metadata: $metadata,
|
|
998
1778
|
});
|
|
999
1779
|
throw __decorateServiceException(response, parsedBody);
|
|
1000
1780
|
}
|
|
@@ -1019,7 +1799,7 @@ export var deserializeAws_restJson1StopCanaryCommand = function (output, context
|
|
|
1019
1799
|
});
|
|
1020
1800
|
}); };
|
|
1021
1801
|
var deserializeAws_restJson1StopCanaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1022
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1802
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1023
1803
|
var _c;
|
|
1024
1804
|
return __generator(this, function (_d) {
|
|
1025
1805
|
switch (_d.label) {
|
|
@@ -1029,7 +1809,6 @@ var deserializeAws_restJson1StopCanaryCommandError = function (output, context)
|
|
|
1029
1809
|
return [4, parseBody(output.body, context)];
|
|
1030
1810
|
case 1:
|
|
1031
1811
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1032
|
-
errorCode = "UnknownError";
|
|
1033
1812
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1034
1813
|
_b = errorCode;
|
|
1035
1814
|
switch (_b) {
|
|
@@ -1053,10 +1832,12 @@ var deserializeAws_restJson1StopCanaryCommandError = function (output, context)
|
|
|
1053
1832
|
case 9: throw _d.sent();
|
|
1054
1833
|
case 10:
|
|
1055
1834
|
parsedBody = parsedOutput.body;
|
|
1835
|
+
$metadata = deserializeMetadata(output);
|
|
1836
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1056
1837
|
response = new __BaseException({
|
|
1057
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1838
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1058
1839
|
$fault: "client",
|
|
1059
|
-
$metadata:
|
|
1840
|
+
$metadata: $metadata,
|
|
1060
1841
|
});
|
|
1061
1842
|
throw __decorateServiceException(response, parsedBody);
|
|
1062
1843
|
}
|
|
@@ -1081,7 +1862,7 @@ export var deserializeAws_restJson1TagResourceCommand = function (output, contex
|
|
|
1081
1862
|
});
|
|
1082
1863
|
}); };
|
|
1083
1864
|
var deserializeAws_restJson1TagResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1084
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1865
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1085
1866
|
var _c;
|
|
1086
1867
|
return __generator(this, function (_d) {
|
|
1087
1868
|
switch (_d.label) {
|
|
@@ -1091,30 +1872,39 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
|
|
|
1091
1872
|
return [4, parseBody(output.body, context)];
|
|
1092
1873
|
case 1:
|
|
1093
1874
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1094
|
-
errorCode = "UnknownError";
|
|
1095
1875
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1096
1876
|
_b = errorCode;
|
|
1097
1877
|
switch (_b) {
|
|
1098
|
-
case "
|
|
1099
|
-
case "com.amazonaws.synthetics#
|
|
1100
|
-
case "
|
|
1101
|
-
case "com.amazonaws.synthetics#
|
|
1102
|
-
case "
|
|
1103
|
-
case "com.amazonaws.synthetics#
|
|
1878
|
+
case "BadRequestException": return [3, 2];
|
|
1879
|
+
case "com.amazonaws.synthetics#BadRequestException": return [3, 2];
|
|
1880
|
+
case "ConflictException": return [3, 4];
|
|
1881
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 4];
|
|
1882
|
+
case "InternalFailureException": return [3, 6];
|
|
1883
|
+
case "com.amazonaws.synthetics#InternalFailureException": return [3, 6];
|
|
1884
|
+
case "NotFoundException": return [3, 8];
|
|
1885
|
+
case "com.amazonaws.synthetics#NotFoundException": return [3, 8];
|
|
1886
|
+
case "TooManyRequestsException": return [3, 10];
|
|
1887
|
+
case "com.amazonaws.synthetics#TooManyRequestsException": return [3, 10];
|
|
1104
1888
|
}
|
|
1105
|
-
return [3,
|
|
1106
|
-
case 2: return [4,
|
|
1889
|
+
return [3, 12];
|
|
1890
|
+
case 2: return [4, deserializeAws_restJson1BadRequestExceptionResponse(parsedOutput, context)];
|
|
1107
1891
|
case 3: throw _d.sent();
|
|
1108
|
-
case 4: return [4,
|
|
1892
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
1109
1893
|
case 5: throw _d.sent();
|
|
1110
|
-
case 6: return [4,
|
|
1894
|
+
case 6: return [4, deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)];
|
|
1111
1895
|
case 7: throw _d.sent();
|
|
1112
|
-
case 8:
|
|
1896
|
+
case 8: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
1897
|
+
case 9: throw _d.sent();
|
|
1898
|
+
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
1899
|
+
case 11: throw _d.sent();
|
|
1900
|
+
case 12:
|
|
1113
1901
|
parsedBody = parsedOutput.body;
|
|
1902
|
+
$metadata = deserializeMetadata(output);
|
|
1903
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1114
1904
|
response = new __BaseException({
|
|
1115
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1905
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1116
1906
|
$fault: "client",
|
|
1117
|
-
$metadata:
|
|
1907
|
+
$metadata: $metadata,
|
|
1118
1908
|
});
|
|
1119
1909
|
throw __decorateServiceException(response, parsedBody);
|
|
1120
1910
|
}
|
|
@@ -1139,7 +1929,7 @@ export var deserializeAws_restJson1UntagResourceCommand = function (output, cont
|
|
|
1139
1929
|
});
|
|
1140
1930
|
}); };
|
|
1141
1931
|
var deserializeAws_restJson1UntagResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1142
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1932
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1143
1933
|
var _c;
|
|
1144
1934
|
return __generator(this, function (_d) {
|
|
1145
1935
|
switch (_d.label) {
|
|
@@ -1149,30 +1939,39 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
|
|
|
1149
1939
|
return [4, parseBody(output.body, context)];
|
|
1150
1940
|
case 1:
|
|
1151
1941
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1152
|
-
errorCode = "UnknownError";
|
|
1153
1942
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1154
1943
|
_b = errorCode;
|
|
1155
1944
|
switch (_b) {
|
|
1156
|
-
case "
|
|
1157
|
-
case "com.amazonaws.synthetics#
|
|
1158
|
-
case "
|
|
1159
|
-
case "com.amazonaws.synthetics#
|
|
1160
|
-
case "
|
|
1161
|
-
case "com.amazonaws.synthetics#
|
|
1945
|
+
case "BadRequestException": return [3, 2];
|
|
1946
|
+
case "com.amazonaws.synthetics#BadRequestException": return [3, 2];
|
|
1947
|
+
case "ConflictException": return [3, 4];
|
|
1948
|
+
case "com.amazonaws.synthetics#ConflictException": return [3, 4];
|
|
1949
|
+
case "InternalFailureException": return [3, 6];
|
|
1950
|
+
case "com.amazonaws.synthetics#InternalFailureException": return [3, 6];
|
|
1951
|
+
case "NotFoundException": return [3, 8];
|
|
1952
|
+
case "com.amazonaws.synthetics#NotFoundException": return [3, 8];
|
|
1953
|
+
case "TooManyRequestsException": return [3, 10];
|
|
1954
|
+
case "com.amazonaws.synthetics#TooManyRequestsException": return [3, 10];
|
|
1162
1955
|
}
|
|
1163
|
-
return [3,
|
|
1164
|
-
case 2: return [4,
|
|
1956
|
+
return [3, 12];
|
|
1957
|
+
case 2: return [4, deserializeAws_restJson1BadRequestExceptionResponse(parsedOutput, context)];
|
|
1165
1958
|
case 3: throw _d.sent();
|
|
1166
|
-
case 4: return [4,
|
|
1959
|
+
case 4: return [4, deserializeAws_restJson1ConflictExceptionResponse(parsedOutput, context)];
|
|
1167
1960
|
case 5: throw _d.sent();
|
|
1168
|
-
case 6: return [4,
|
|
1961
|
+
case 6: return [4, deserializeAws_restJson1InternalFailureExceptionResponse(parsedOutput, context)];
|
|
1169
1962
|
case 7: throw _d.sent();
|
|
1170
|
-
case 8:
|
|
1963
|
+
case 8: return [4, deserializeAws_restJson1NotFoundExceptionResponse(parsedOutput, context)];
|
|
1964
|
+
case 9: throw _d.sent();
|
|
1965
|
+
case 10: return [4, deserializeAws_restJson1TooManyRequestsExceptionResponse(parsedOutput, context)];
|
|
1966
|
+
case 11: throw _d.sent();
|
|
1967
|
+
case 12:
|
|
1171
1968
|
parsedBody = parsedOutput.body;
|
|
1969
|
+
$metadata = deserializeMetadata(output);
|
|
1970
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1172
1971
|
response = new __BaseException({
|
|
1173
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1972
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1174
1973
|
$fault: "client",
|
|
1175
|
-
$metadata:
|
|
1974
|
+
$metadata: $metadata,
|
|
1176
1975
|
});
|
|
1177
1976
|
throw __decorateServiceException(response, parsedBody);
|
|
1178
1977
|
}
|
|
@@ -1197,7 +1996,7 @@ export var deserializeAws_restJson1UpdateCanaryCommand = function (output, conte
|
|
|
1197
1996
|
});
|
|
1198
1997
|
}); };
|
|
1199
1998
|
var deserializeAws_restJson1UpdateCanaryCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1200
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1999
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1201
2000
|
var _c;
|
|
1202
2001
|
return __generator(this, function (_d) {
|
|
1203
2002
|
switch (_d.label) {
|
|
@@ -1207,7 +2006,6 @@ var deserializeAws_restJson1UpdateCanaryCommandError = function (output, context
|
|
|
1207
2006
|
return [4, parseBody(output.body, context)];
|
|
1208
2007
|
case 1:
|
|
1209
2008
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1210
|
-
errorCode = "UnknownError";
|
|
1211
2009
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1212
2010
|
_b = errorCode;
|
|
1213
2011
|
switch (_b) {
|
|
@@ -1235,15 +2033,29 @@ var deserializeAws_restJson1UpdateCanaryCommandError = function (output, context
|
|
|
1235
2033
|
case 11: throw _d.sent();
|
|
1236
2034
|
case 12:
|
|
1237
2035
|
parsedBody = parsedOutput.body;
|
|
2036
|
+
$metadata = deserializeMetadata(output);
|
|
2037
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1238
2038
|
response = new __BaseException({
|
|
1239
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
2039
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1240
2040
|
$fault: "client",
|
|
1241
|
-
$metadata:
|
|
2041
|
+
$metadata: $metadata,
|
|
1242
2042
|
});
|
|
1243
2043
|
throw __decorateServiceException(response, parsedBody);
|
|
1244
2044
|
}
|
|
1245
2045
|
});
|
|
1246
2046
|
}); };
|
|
2047
|
+
var deserializeAws_restJson1BadRequestExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2048
|
+
var contents, data, exception;
|
|
2049
|
+
return __generator(this, function (_a) {
|
|
2050
|
+
contents = {};
|
|
2051
|
+
data = parsedOutput.body;
|
|
2052
|
+
if (data.Message !== undefined && data.Message !== null) {
|
|
2053
|
+
contents.Message = __expectString(data.Message);
|
|
2054
|
+
}
|
|
2055
|
+
exception = new BadRequestException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2056
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2057
|
+
});
|
|
2058
|
+
}); };
|
|
1247
2059
|
var deserializeAws_restJson1ConflictExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1248
2060
|
var contents, data, exception;
|
|
1249
2061
|
return __generator(this, function (_a) {
|
|
@@ -1256,6 +2068,18 @@ var deserializeAws_restJson1ConflictExceptionResponse = function (parsedOutput,
|
|
|
1256
2068
|
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
1257
2069
|
});
|
|
1258
2070
|
}); };
|
|
2071
|
+
var deserializeAws_restJson1InternalFailureExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2072
|
+
var contents, data, exception;
|
|
2073
|
+
return __generator(this, function (_a) {
|
|
2074
|
+
contents = {};
|
|
2075
|
+
data = parsedOutput.body;
|
|
2076
|
+
if (data.Message !== undefined && data.Message !== null) {
|
|
2077
|
+
contents.Message = __expectString(data.Message);
|
|
2078
|
+
}
|
|
2079
|
+
exception = new InternalFailureException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2080
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2081
|
+
});
|
|
2082
|
+
}); };
|
|
1259
2083
|
var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1260
2084
|
var contents, data, exception;
|
|
1261
2085
|
return __generator(this, function (_a) {
|
|
@@ -1268,6 +2092,18 @@ var deserializeAws_restJson1InternalServerExceptionResponse = function (parsedOu
|
|
|
1268
2092
|
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
1269
2093
|
});
|
|
1270
2094
|
}); };
|
|
2095
|
+
var deserializeAws_restJson1NotFoundExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2096
|
+
var contents, data, exception;
|
|
2097
|
+
return __generator(this, function (_a) {
|
|
2098
|
+
contents = {};
|
|
2099
|
+
data = parsedOutput.body;
|
|
2100
|
+
if (data.Message !== undefined && data.Message !== null) {
|
|
2101
|
+
contents.Message = __expectString(data.Message);
|
|
2102
|
+
}
|
|
2103
|
+
exception = new NotFoundException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2104
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2105
|
+
});
|
|
2106
|
+
}); };
|
|
1271
2107
|
var deserializeAws_restJson1RequestEntityTooLargeExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1272
2108
|
var contents, data, exception;
|
|
1273
2109
|
return __generator(this, function (_a) {
|
|
@@ -1292,6 +2128,30 @@ var deserializeAws_restJson1ResourceNotFoundExceptionResponse = function (parsed
|
|
|
1292
2128
|
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
1293
2129
|
});
|
|
1294
2130
|
}); };
|
|
2131
|
+
var deserializeAws_restJson1ServiceQuotaExceededExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2132
|
+
var contents, data, exception;
|
|
2133
|
+
return __generator(this, function (_a) {
|
|
2134
|
+
contents = {};
|
|
2135
|
+
data = parsedOutput.body;
|
|
2136
|
+
if (data.Message !== undefined && data.Message !== null) {
|
|
2137
|
+
contents.Message = __expectString(data.Message);
|
|
2138
|
+
}
|
|
2139
|
+
exception = new ServiceQuotaExceededException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2140
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2141
|
+
});
|
|
2142
|
+
}); };
|
|
2143
|
+
var deserializeAws_restJson1TooManyRequestsExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
2144
|
+
var contents, data, exception;
|
|
2145
|
+
return __generator(this, function (_a) {
|
|
2146
|
+
contents = {};
|
|
2147
|
+
data = parsedOutput.body;
|
|
2148
|
+
if (data.Message !== undefined && data.Message !== null) {
|
|
2149
|
+
contents.Message = __expectString(data.Message);
|
|
2150
|
+
}
|
|
2151
|
+
exception = new TooManyRequestsException(__assign({ $metadata: deserializeMetadata(parsedOutput) }, contents));
|
|
2152
|
+
return [2, __decorateServiceException(exception, parsedOutput.body)];
|
|
2153
|
+
});
|
|
2154
|
+
}); };
|
|
1295
2155
|
var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1296
2156
|
var contents, data, exception;
|
|
1297
2157
|
return __generator(this, function (_a) {
|
|
@@ -1305,17 +2165,14 @@ var deserializeAws_restJson1ValidationExceptionResponse = function (parsedOutput
|
|
|
1305
2165
|
});
|
|
1306
2166
|
}); };
|
|
1307
2167
|
var serializeAws_restJson1ArtifactConfigInput = function (input, context) {
|
|
1308
|
-
return __assign({}, (input.S3Encryption
|
|
1309
|
-
input.S3Encryption !== null && {
|
|
2168
|
+
return __assign({}, (input.S3Encryption != null && {
|
|
1310
2169
|
S3Encryption: serializeAws_restJson1S3EncryptionConfig(input.S3Encryption, context),
|
|
1311
2170
|
}));
|
|
1312
2171
|
};
|
|
1313
2172
|
var serializeAws_restJson1BaseScreenshot = function (input, context) {
|
|
1314
|
-
return __assign(__assign({}, (input.IgnoreCoordinates
|
|
1315
|
-
input.IgnoreCoordinates !== null && {
|
|
2173
|
+
return __assign(__assign({}, (input.IgnoreCoordinates != null && {
|
|
1316
2174
|
IgnoreCoordinates: serializeAws_restJson1BaseScreenshotIgnoreCoordinates(input.IgnoreCoordinates, context),
|
|
1317
|
-
})), (input.ScreenshotName
|
|
1318
|
-
input.ScreenshotName !== null && { ScreenshotName: input.ScreenshotName }));
|
|
2175
|
+
})), (input.ScreenshotName != null && { ScreenshotName: input.ScreenshotName }));
|
|
1319
2176
|
};
|
|
1320
2177
|
var serializeAws_restJson1BaseScreenshotIgnoreCoordinates = function (input, context) {
|
|
1321
2178
|
return input
|
|
@@ -1338,18 +2195,15 @@ var serializeAws_restJson1BaseScreenshots = function (input, context) {
|
|
|
1338
2195
|
});
|
|
1339
2196
|
};
|
|
1340
2197
|
var serializeAws_restJson1CanaryCodeInput = function (input, context) {
|
|
1341
|
-
return __assign(__assign(__assign(__assign(__assign({}, (input.Handler
|
|
2198
|
+
return __assign(__assign(__assign(__assign(__assign({}, (input.Handler != null && { Handler: input.Handler })), (input.S3Bucket != null && { S3Bucket: input.S3Bucket })), (input.S3Key != null && { S3Key: input.S3Key })), (input.S3Version != null && { S3Version: input.S3Version })), (input.ZipFile != null && { ZipFile: context.base64Encoder(input.ZipFile) }));
|
|
1342
2199
|
};
|
|
1343
2200
|
var serializeAws_restJson1CanaryRunConfigInput = function (input, context) {
|
|
1344
|
-
return __assign(__assign(__assign(__assign({}, (input.ActiveTracing
|
|
1345
|
-
input.EnvironmentVariables !== null && {
|
|
2201
|
+
return __assign(__assign(__assign(__assign({}, (input.ActiveTracing != null && { ActiveTracing: input.ActiveTracing })), (input.EnvironmentVariables != null && {
|
|
1346
2202
|
EnvironmentVariables: serializeAws_restJson1EnvironmentVariablesMap(input.EnvironmentVariables, context),
|
|
1347
|
-
})), (input.MemoryInMB
|
|
1348
|
-
input.TimeoutInSeconds !== null && { TimeoutInSeconds: input.TimeoutInSeconds }));
|
|
2203
|
+
})), (input.MemoryInMB != null && { MemoryInMB: input.MemoryInMB })), (input.TimeoutInSeconds != null && { TimeoutInSeconds: input.TimeoutInSeconds }));
|
|
1349
2204
|
};
|
|
1350
2205
|
var serializeAws_restJson1CanaryScheduleInput = function (input, context) {
|
|
1351
|
-
return __assign(__assign({}, (input.DurationInSeconds
|
|
1352
|
-
input.DurationInSeconds !== null && { DurationInSeconds: input.DurationInSeconds })), (input.Expression !== undefined && input.Expression !== null && { Expression: input.Expression }));
|
|
2206
|
+
return __assign(__assign({}, (input.DurationInSeconds != null && { DurationInSeconds: input.DurationInSeconds })), (input.Expression != null && { Expression: input.Expression }));
|
|
1353
2207
|
};
|
|
1354
2208
|
var serializeAws_restJson1DescribeCanariesLastRunNameFilter = function (input, context) {
|
|
1355
2209
|
return input
|
|
@@ -1382,8 +2236,7 @@ var serializeAws_restJson1EnvironmentVariablesMap = function (input, context) {
|
|
|
1382
2236
|
}, {});
|
|
1383
2237
|
};
|
|
1384
2238
|
var serializeAws_restJson1S3EncryptionConfig = function (input, context) {
|
|
1385
|
-
return __assign(__assign({}, (input.EncryptionMode
|
|
1386
|
-
input.EncryptionMode !== null && { EncryptionMode: input.EncryptionMode })), (input.KmsKeyArn !== undefined && input.KmsKeyArn !== null && { KmsKeyArn: input.KmsKeyArn }));
|
|
2239
|
+
return __assign(__assign({}, (input.EncryptionMode != null && { EncryptionMode: input.EncryptionMode })), (input.KmsKeyArn != null && { KmsKeyArn: input.KmsKeyArn }));
|
|
1387
2240
|
};
|
|
1388
2241
|
var serializeAws_restJson1SecurityGroupIds = function (input, context) {
|
|
1389
2242
|
return input
|
|
@@ -1416,29 +2269,25 @@ var serializeAws_restJson1TagMap = function (input, context) {
|
|
|
1416
2269
|
}, {});
|
|
1417
2270
|
};
|
|
1418
2271
|
var serializeAws_restJson1VisualReferenceInput = function (input, context) {
|
|
1419
|
-
return __assign(__assign({}, (input.BaseCanaryRunId
|
|
1420
|
-
input.BaseCanaryRunId !== null && { BaseCanaryRunId: input.BaseCanaryRunId })), (input.BaseScreenshots !== undefined &&
|
|
1421
|
-
input.BaseScreenshots !== null && {
|
|
2272
|
+
return __assign(__assign({}, (input.BaseCanaryRunId != null && { BaseCanaryRunId: input.BaseCanaryRunId })), (input.BaseScreenshots != null && {
|
|
1422
2273
|
BaseScreenshots: serializeAws_restJson1BaseScreenshots(input.BaseScreenshots, context),
|
|
1423
2274
|
}));
|
|
1424
2275
|
};
|
|
1425
2276
|
var serializeAws_restJson1VpcConfigInput = function (input, context) {
|
|
1426
|
-
return __assign(__assign({}, (input.SecurityGroupIds
|
|
1427
|
-
input.SecurityGroupIds !== null && {
|
|
2277
|
+
return __assign(__assign({}, (input.SecurityGroupIds != null && {
|
|
1428
2278
|
SecurityGroupIds: serializeAws_restJson1SecurityGroupIds(input.SecurityGroupIds, context),
|
|
1429
|
-
})), (input.SubnetIds
|
|
1430
|
-
input.SubnetIds !== null && { SubnetIds: serializeAws_restJson1SubnetIds(input.SubnetIds, context) }));
|
|
2279
|
+
})), (input.SubnetIds != null && { SubnetIds: serializeAws_restJson1SubnetIds(input.SubnetIds, context) }));
|
|
1431
2280
|
};
|
|
1432
2281
|
var deserializeAws_restJson1ArtifactConfigOutput = function (output, context) {
|
|
1433
2282
|
return {
|
|
1434
|
-
S3Encryption: output.S3Encryption
|
|
2283
|
+
S3Encryption: output.S3Encryption != null
|
|
1435
2284
|
? deserializeAws_restJson1S3EncryptionConfig(output.S3Encryption, context)
|
|
1436
2285
|
: undefined,
|
|
1437
2286
|
};
|
|
1438
2287
|
};
|
|
1439
2288
|
var deserializeAws_restJson1BaseScreenshot = function (output, context) {
|
|
1440
2289
|
return {
|
|
1441
|
-
IgnoreCoordinates: output.IgnoreCoordinates
|
|
2290
|
+
IgnoreCoordinates: output.IgnoreCoordinates != null
|
|
1442
2291
|
? deserializeAws_restJson1BaseScreenshotIgnoreCoordinates(output.IgnoreCoordinates, context)
|
|
1443
2292
|
: undefined,
|
|
1444
2293
|
ScreenshotName: __expectString(output.ScreenshotName),
|
|
@@ -1490,41 +2339,27 @@ var deserializeAws_restJson1CanariesLastRun = function (output, context) {
|
|
|
1490
2339
|
};
|
|
1491
2340
|
var deserializeAws_restJson1Canary = function (output, context) {
|
|
1492
2341
|
return {
|
|
1493
|
-
ArtifactConfig: output.ArtifactConfig
|
|
2342
|
+
ArtifactConfig: output.ArtifactConfig != null
|
|
1494
2343
|
? deserializeAws_restJson1ArtifactConfigOutput(output.ArtifactConfig, context)
|
|
1495
2344
|
: undefined,
|
|
1496
2345
|
ArtifactS3Location: __expectString(output.ArtifactS3Location),
|
|
1497
|
-
Code: output.Code
|
|
1498
|
-
? deserializeAws_restJson1CanaryCodeOutput(output.Code, context)
|
|
1499
|
-
: undefined,
|
|
2346
|
+
Code: output.Code != null ? deserializeAws_restJson1CanaryCodeOutput(output.Code, context) : undefined,
|
|
1500
2347
|
EngineArn: __expectString(output.EngineArn),
|
|
1501
2348
|
ExecutionRoleArn: __expectString(output.ExecutionRoleArn),
|
|
1502
2349
|
FailureRetentionPeriodInDays: __expectInt32(output.FailureRetentionPeriodInDays),
|
|
1503
2350
|
Id: __expectString(output.Id),
|
|
1504
2351
|
Name: __expectString(output.Name),
|
|
1505
|
-
RunConfig: output.RunConfig
|
|
1506
|
-
? deserializeAws_restJson1CanaryRunConfigOutput(output.RunConfig, context)
|
|
1507
|
-
: undefined,
|
|
2352
|
+
RunConfig: output.RunConfig != null ? deserializeAws_restJson1CanaryRunConfigOutput(output.RunConfig, context) : undefined,
|
|
1508
2353
|
RuntimeVersion: __expectString(output.RuntimeVersion),
|
|
1509
|
-
Schedule: output.Schedule
|
|
1510
|
-
|
|
1511
|
-
: undefined,
|
|
1512
|
-
Status: output.Status !== undefined && output.Status !== null
|
|
1513
|
-
? deserializeAws_restJson1CanaryStatus(output.Status, context)
|
|
1514
|
-
: undefined,
|
|
2354
|
+
Schedule: output.Schedule != null ? deserializeAws_restJson1CanaryScheduleOutput(output.Schedule, context) : undefined,
|
|
2355
|
+
Status: output.Status != null ? deserializeAws_restJson1CanaryStatus(output.Status, context) : undefined,
|
|
1515
2356
|
SuccessRetentionPeriodInDays: __expectInt32(output.SuccessRetentionPeriodInDays),
|
|
1516
|
-
Tags: output.Tags
|
|
1517
|
-
|
|
1518
|
-
|
|
1519
|
-
Timeline: output.Timeline !== undefined && output.Timeline !== null
|
|
1520
|
-
? deserializeAws_restJson1CanaryTimeline(output.Timeline, context)
|
|
1521
|
-
: undefined,
|
|
1522
|
-
VisualReference: output.VisualReference !== undefined && output.VisualReference !== null
|
|
2357
|
+
Tags: output.Tags != null ? deserializeAws_restJson1TagMap(output.Tags, context) : undefined,
|
|
2358
|
+
Timeline: output.Timeline != null ? deserializeAws_restJson1CanaryTimeline(output.Timeline, context) : undefined,
|
|
2359
|
+
VisualReference: output.VisualReference != null
|
|
1523
2360
|
? deserializeAws_restJson1VisualReferenceOutput(output.VisualReference, context)
|
|
1524
2361
|
: undefined,
|
|
1525
|
-
VpcConfig: output.VpcConfig
|
|
1526
|
-
? deserializeAws_restJson1VpcConfigOutput(output.VpcConfig, context)
|
|
1527
|
-
: undefined,
|
|
2362
|
+
VpcConfig: output.VpcConfig != null ? deserializeAws_restJson1VpcConfigOutput(output.VpcConfig, context) : undefined,
|
|
1528
2363
|
};
|
|
1529
2364
|
};
|
|
1530
2365
|
var deserializeAws_restJson1CanaryCodeOutput = function (output, context) {
|
|
@@ -1536,9 +2371,7 @@ var deserializeAws_restJson1CanaryCodeOutput = function (output, context) {
|
|
|
1536
2371
|
var deserializeAws_restJson1CanaryLastRun = function (output, context) {
|
|
1537
2372
|
return {
|
|
1538
2373
|
CanaryName: __expectString(output.CanaryName),
|
|
1539
|
-
LastRun: output.LastRun
|
|
1540
|
-
? deserializeAws_restJson1CanaryRun(output.LastRun, context)
|
|
1541
|
-
: undefined,
|
|
2374
|
+
LastRun: output.LastRun != null ? deserializeAws_restJson1CanaryRun(output.LastRun, context) : undefined,
|
|
1542
2375
|
};
|
|
1543
2376
|
};
|
|
1544
2377
|
var deserializeAws_restJson1CanaryRun = function (output, context) {
|
|
@@ -1546,12 +2379,8 @@ var deserializeAws_restJson1CanaryRun = function (output, context) {
|
|
|
1546
2379
|
ArtifactS3Location: __expectString(output.ArtifactS3Location),
|
|
1547
2380
|
Id: __expectString(output.Id),
|
|
1548
2381
|
Name: __expectString(output.Name),
|
|
1549
|
-
Status: output.Status
|
|
1550
|
-
|
|
1551
|
-
: undefined,
|
|
1552
|
-
Timeline: output.Timeline !== undefined && output.Timeline !== null
|
|
1553
|
-
? deserializeAws_restJson1CanaryRunTimeline(output.Timeline, context)
|
|
1554
|
-
: undefined,
|
|
2382
|
+
Status: output.Status != null ? deserializeAws_restJson1CanaryRunStatus(output.Status, context) : undefined,
|
|
2383
|
+
Timeline: output.Timeline != null ? deserializeAws_restJson1CanaryRunTimeline(output.Timeline, context) : undefined,
|
|
1555
2384
|
};
|
|
1556
2385
|
};
|
|
1557
2386
|
var deserializeAws_restJson1CanaryRunConfigOutput = function (output, context) {
|
|
@@ -1581,12 +2410,8 @@ var deserializeAws_restJson1CanaryRunStatus = function (output, context) {
|
|
|
1581
2410
|
};
|
|
1582
2411
|
var deserializeAws_restJson1CanaryRunTimeline = function (output, context) {
|
|
1583
2412
|
return {
|
|
1584
|
-
Completed: output.Completed
|
|
1585
|
-
|
|
1586
|
-
: undefined,
|
|
1587
|
-
Started: output.Started !== undefined && output.Started !== null
|
|
1588
|
-
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Started)))
|
|
1589
|
-
: undefined,
|
|
2413
|
+
Completed: output.Completed != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Completed))) : undefined,
|
|
2414
|
+
Started: output.Started != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Started))) : undefined,
|
|
1590
2415
|
};
|
|
1591
2416
|
};
|
|
1592
2417
|
var deserializeAws_restJson1CanaryScheduleOutput = function (output, context) {
|
|
@@ -1604,27 +2429,57 @@ var deserializeAws_restJson1CanaryStatus = function (output, context) {
|
|
|
1604
2429
|
};
|
|
1605
2430
|
var deserializeAws_restJson1CanaryTimeline = function (output, context) {
|
|
1606
2431
|
return {
|
|
1607
|
-
Created: output.Created
|
|
1608
|
-
|
|
1609
|
-
: undefined,
|
|
1610
|
-
LastModified: output.LastModified !== undefined && output.LastModified !== null
|
|
2432
|
+
Created: output.Created != null ? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.Created))) : undefined,
|
|
2433
|
+
LastModified: output.LastModified != null
|
|
1611
2434
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastModified)))
|
|
1612
2435
|
: undefined,
|
|
1613
|
-
LastStarted: output.LastStarted
|
|
2436
|
+
LastStarted: output.LastStarted != null
|
|
1614
2437
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastStarted)))
|
|
1615
2438
|
: undefined,
|
|
1616
|
-
LastStopped: output.LastStopped
|
|
2439
|
+
LastStopped: output.LastStopped != null
|
|
1617
2440
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastStopped)))
|
|
1618
2441
|
: undefined,
|
|
1619
2442
|
};
|
|
1620
2443
|
};
|
|
2444
|
+
var deserializeAws_restJson1Group = function (output, context) {
|
|
2445
|
+
return {
|
|
2446
|
+
Arn: __expectString(output.Arn),
|
|
2447
|
+
CreatedTime: output.CreatedTime != null
|
|
2448
|
+
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.CreatedTime)))
|
|
2449
|
+
: undefined,
|
|
2450
|
+
Id: __expectString(output.Id),
|
|
2451
|
+
LastModifiedTime: output.LastModifiedTime != null
|
|
2452
|
+
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.LastModifiedTime)))
|
|
2453
|
+
: undefined,
|
|
2454
|
+
Name: __expectString(output.Name),
|
|
2455
|
+
Tags: output.Tags != null ? deserializeAws_restJson1TagMap(output.Tags, context) : undefined,
|
|
2456
|
+
};
|
|
2457
|
+
};
|
|
2458
|
+
var deserializeAws_restJson1GroupSummary = function (output, context) {
|
|
2459
|
+
return {
|
|
2460
|
+
Arn: __expectString(output.Arn),
|
|
2461
|
+
Id: __expectString(output.Id),
|
|
2462
|
+
Name: __expectString(output.Name),
|
|
2463
|
+
};
|
|
2464
|
+
};
|
|
2465
|
+
var deserializeAws_restJson1GroupSummaryList = function (output, context) {
|
|
2466
|
+
var retVal = (output || [])
|
|
2467
|
+
.filter(function (e) { return e != null; })
|
|
2468
|
+
.map(function (entry) {
|
|
2469
|
+
if (entry === null) {
|
|
2470
|
+
return null;
|
|
2471
|
+
}
|
|
2472
|
+
return deserializeAws_restJson1GroupSummary(entry, context);
|
|
2473
|
+
});
|
|
2474
|
+
return retVal;
|
|
2475
|
+
};
|
|
1621
2476
|
var deserializeAws_restJson1RuntimeVersion = function (output, context) {
|
|
1622
2477
|
return {
|
|
1623
|
-
DeprecationDate: output.DeprecationDate
|
|
2478
|
+
DeprecationDate: output.DeprecationDate != null
|
|
1624
2479
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.DeprecationDate)))
|
|
1625
2480
|
: undefined,
|
|
1626
2481
|
Description: __expectString(output.Description),
|
|
1627
|
-
ReleaseDate: output.ReleaseDate
|
|
2482
|
+
ReleaseDate: output.ReleaseDate != null
|
|
1628
2483
|
? __expectNonNull(__parseEpochTimestamp(__expectNumber(output.ReleaseDate)))
|
|
1629
2484
|
: undefined,
|
|
1630
2485
|
VersionName: __expectString(output.VersionName),
|
|
@@ -1658,6 +2513,17 @@ var deserializeAws_restJson1SecurityGroupIds = function (output, context) {
|
|
|
1658
2513
|
});
|
|
1659
2514
|
return retVal;
|
|
1660
2515
|
};
|
|
2516
|
+
var deserializeAws_restJson1StringList = function (output, context) {
|
|
2517
|
+
var retVal = (output || [])
|
|
2518
|
+
.filter(function (e) { return e != null; })
|
|
2519
|
+
.map(function (entry) {
|
|
2520
|
+
if (entry === null) {
|
|
2521
|
+
return null;
|
|
2522
|
+
}
|
|
2523
|
+
return __expectString(entry);
|
|
2524
|
+
});
|
|
2525
|
+
return retVal;
|
|
2526
|
+
};
|
|
1661
2527
|
var deserializeAws_restJson1SubnetIds = function (output, context) {
|
|
1662
2528
|
var retVal = (output || [])
|
|
1663
2529
|
.filter(function (e) { return e != null; })
|
|
@@ -1682,19 +2548,17 @@ var deserializeAws_restJson1TagMap = function (output, context) {
|
|
|
1682
2548
|
var deserializeAws_restJson1VisualReferenceOutput = function (output, context) {
|
|
1683
2549
|
return {
|
|
1684
2550
|
BaseCanaryRunId: __expectString(output.BaseCanaryRunId),
|
|
1685
|
-
BaseScreenshots: output.BaseScreenshots
|
|
2551
|
+
BaseScreenshots: output.BaseScreenshots != null
|
|
1686
2552
|
? deserializeAws_restJson1BaseScreenshots(output.BaseScreenshots, context)
|
|
1687
2553
|
: undefined,
|
|
1688
2554
|
};
|
|
1689
2555
|
};
|
|
1690
2556
|
var deserializeAws_restJson1VpcConfigOutput = function (output, context) {
|
|
1691
2557
|
return {
|
|
1692
|
-
SecurityGroupIds: output.SecurityGroupIds
|
|
2558
|
+
SecurityGroupIds: output.SecurityGroupIds != null
|
|
1693
2559
|
? deserializeAws_restJson1SecurityGroupIds(output.SecurityGroupIds, context)
|
|
1694
2560
|
: undefined,
|
|
1695
|
-
SubnetIds: output.SubnetIds
|
|
1696
|
-
? deserializeAws_restJson1SubnetIds(output.SubnetIds, context)
|
|
1697
|
-
: undefined,
|
|
2561
|
+
SubnetIds: output.SubnetIds != null ? deserializeAws_restJson1SubnetIds(output.SubnetIds, context) : undefined,
|
|
1698
2562
|
VpcId: __expectString(output.VpcId),
|
|
1699
2563
|
};
|
|
1700
2564
|
};
|
|
@@ -1754,5 +2618,4 @@ var loadRestJsonErrorCode = function (output, data) {
|
|
|
1754
2618
|
if (data["__type"] !== undefined) {
|
|
1755
2619
|
return sanitizeErrorCode(data["__type"]);
|
|
1756
2620
|
}
|
|
1757
|
-
return "";
|
|
1758
2621
|
};
|