@aws-sdk/client-codestar-notifications 3.118.1 → 3.128.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 +27 -0
- package/dist-cjs/protocols/Aws_restJson1.js +113 -108
- package/dist-es/protocols/Aws_restJson1.js +87 -82
- package/package.json +26 -26
package/CHANGELOG.md
CHANGED
|
@@ -3,6 +3,33 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
# [3.128.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.127.0...v3.128.0) (2022-07-12)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @aws-sdk/client-codestar-notifications
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
|
|
13
|
+
|
|
14
|
+
# [3.127.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.126.0...v3.127.0) (2022-07-11)
|
|
15
|
+
|
|
16
|
+
**Note:** Version bump only for package @aws-sdk/client-codestar-notifications
|
|
17
|
+
|
|
18
|
+
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
|
|
22
|
+
# [3.121.0](https://github.com/aws/aws-sdk-js-v3/compare/v3.120.0...v3.121.0) (2022-06-30)
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
### Features
|
|
26
|
+
|
|
27
|
+
* **clients:** fallback to status code for unmodeled errors ([#3752](https://github.com/aws/aws-sdk-js-v3/issues/3752)) ([49bcc4f](https://github.com/aws/aws-sdk-js-v3/commit/49bcc4f153e890e798a8e82fd5fc397b2dcc449f))
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
6
33
|
## [3.118.1](https://github.com/aws/aws-sdk-js-v3/compare/v3.118.0...v3.118.1) (2022-06-27)
|
|
7
34
|
|
|
8
35
|
**Note:** Version bump only for package @aws-sdk/client-codestar-notifications
|
|
@@ -16,15 +16,15 @@ const serializeAws_restJson1CreateNotificationRuleCommand = async (input, contex
|
|
|
16
16
|
let body;
|
|
17
17
|
body = JSON.stringify({
|
|
18
18
|
ClientRequestToken: (_a = input.ClientRequestToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
|
|
19
|
-
...(input.DetailType
|
|
20
|
-
...(input.EventTypeIds
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
...(input.
|
|
24
|
-
...(input.
|
|
25
|
-
...(input.
|
|
26
|
-
...(input.
|
|
27
|
-
|
|
19
|
+
...(input.DetailType != null && { DetailType: input.DetailType }),
|
|
20
|
+
...(input.EventTypeIds != null && {
|
|
21
|
+
EventTypeIds: serializeAws_restJson1EventTypeIds(input.EventTypeIds, context),
|
|
22
|
+
}),
|
|
23
|
+
...(input.Name != null && { Name: input.Name }),
|
|
24
|
+
...(input.Resource != null && { Resource: input.Resource }),
|
|
25
|
+
...(input.Status != null && { Status: input.Status }),
|
|
26
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
27
|
+
...(input.Targets != null && { Targets: serializeAws_restJson1Targets(input.Targets, context) }),
|
|
28
28
|
});
|
|
29
29
|
return new protocol_http_1.HttpRequest({
|
|
30
30
|
protocol,
|
|
@@ -45,7 +45,7 @@ const serializeAws_restJson1DeleteNotificationRuleCommand = async (input, contex
|
|
|
45
45
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/deleteNotificationRule";
|
|
46
46
|
let body;
|
|
47
47
|
body = JSON.stringify({
|
|
48
|
-
...(input.Arn
|
|
48
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
49
49
|
});
|
|
50
50
|
return new protocol_http_1.HttpRequest({
|
|
51
51
|
protocol,
|
|
@@ -66,9 +66,8 @@ const serializeAws_restJson1DeleteTargetCommand = async (input, context) => {
|
|
|
66
66
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/deleteTarget";
|
|
67
67
|
let body;
|
|
68
68
|
body = JSON.stringify({
|
|
69
|
-
...(input.ForceUnsubscribeAll
|
|
70
|
-
|
|
71
|
-
...(input.TargetAddress !== undefined && input.TargetAddress !== null && { TargetAddress: input.TargetAddress }),
|
|
69
|
+
...(input.ForceUnsubscribeAll != null && { ForceUnsubscribeAll: input.ForceUnsubscribeAll }),
|
|
70
|
+
...(input.TargetAddress != null && { TargetAddress: input.TargetAddress }),
|
|
72
71
|
});
|
|
73
72
|
return new protocol_http_1.HttpRequest({
|
|
74
73
|
protocol,
|
|
@@ -89,7 +88,7 @@ const serializeAws_restJson1DescribeNotificationRuleCommand = async (input, cont
|
|
|
89
88
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/describeNotificationRule";
|
|
90
89
|
let body;
|
|
91
90
|
body = JSON.stringify({
|
|
92
|
-
...(input.Arn
|
|
91
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
93
92
|
});
|
|
94
93
|
return new protocol_http_1.HttpRequest({
|
|
95
94
|
protocol,
|
|
@@ -110,10 +109,9 @@ const serializeAws_restJson1ListEventTypesCommand = async (input, context) => {
|
|
|
110
109
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/listEventTypes";
|
|
111
110
|
let body;
|
|
112
111
|
body = JSON.stringify({
|
|
113
|
-
...(input.Filters
|
|
114
|
-
|
|
115
|
-
...(input.
|
|
116
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
112
|
+
...(input.Filters != null && { Filters: serializeAws_restJson1ListEventTypesFilters(input.Filters, context) }),
|
|
113
|
+
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
114
|
+
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
117
115
|
});
|
|
118
116
|
return new protocol_http_1.HttpRequest({
|
|
119
117
|
protocol,
|
|
@@ -134,12 +132,11 @@ const serializeAws_restJson1ListNotificationRulesCommand = async (input, context
|
|
|
134
132
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/listNotificationRules";
|
|
135
133
|
let body;
|
|
136
134
|
body = JSON.stringify({
|
|
137
|
-
...(input.Filters
|
|
138
|
-
input.Filters !== null && {
|
|
135
|
+
...(input.Filters != null && {
|
|
139
136
|
Filters: serializeAws_restJson1ListNotificationRulesFilters(input.Filters, context),
|
|
140
137
|
}),
|
|
141
|
-
...(input.MaxResults
|
|
142
|
-
...(input.NextToken
|
|
138
|
+
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
139
|
+
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
143
140
|
});
|
|
144
141
|
return new protocol_http_1.HttpRequest({
|
|
145
142
|
protocol,
|
|
@@ -160,7 +157,7 @@ const serializeAws_restJson1ListTagsForResourceCommand = async (input, context)
|
|
|
160
157
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/listTagsForResource";
|
|
161
158
|
let body;
|
|
162
159
|
body = JSON.stringify({
|
|
163
|
-
...(input.Arn
|
|
160
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
164
161
|
});
|
|
165
162
|
return new protocol_http_1.HttpRequest({
|
|
166
163
|
protocol,
|
|
@@ -181,10 +178,9 @@ const serializeAws_restJson1ListTargetsCommand = async (input, context) => {
|
|
|
181
178
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/listTargets";
|
|
182
179
|
let body;
|
|
183
180
|
body = JSON.stringify({
|
|
184
|
-
...(input.Filters
|
|
185
|
-
|
|
186
|
-
...(input.
|
|
187
|
-
...(input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken }),
|
|
181
|
+
...(input.Filters != null && { Filters: serializeAws_restJson1ListTargetsFilters(input.Filters, context) }),
|
|
182
|
+
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
183
|
+
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
188
184
|
});
|
|
189
185
|
return new protocol_http_1.HttpRequest({
|
|
190
186
|
protocol,
|
|
@@ -205,11 +201,9 @@ const serializeAws_restJson1SubscribeCommand = async (input, context) => {
|
|
|
205
201
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/subscribe";
|
|
206
202
|
let body;
|
|
207
203
|
body = JSON.stringify({
|
|
208
|
-
...(input.Arn
|
|
209
|
-
...(input.ClientRequestToken
|
|
210
|
-
|
|
211
|
-
...(input.Target !== undefined &&
|
|
212
|
-
input.Target !== null && { Target: serializeAws_restJson1Target(input.Target, context) }),
|
|
204
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
205
|
+
...(input.ClientRequestToken != null && { ClientRequestToken: input.ClientRequestToken }),
|
|
206
|
+
...(input.Target != null && { Target: serializeAws_restJson1Target(input.Target, context) }),
|
|
213
207
|
});
|
|
214
208
|
return new protocol_http_1.HttpRequest({
|
|
215
209
|
protocol,
|
|
@@ -230,8 +224,8 @@ const serializeAws_restJson1TagResourceCommand = async (input, context) => {
|
|
|
230
224
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/tagResource";
|
|
231
225
|
let body;
|
|
232
226
|
body = JSON.stringify({
|
|
233
|
-
...(input.Arn
|
|
234
|
-
...(input.Tags
|
|
227
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
228
|
+
...(input.Tags != null && { Tags: serializeAws_restJson1Tags(input.Tags, context) }),
|
|
235
229
|
});
|
|
236
230
|
return new protocol_http_1.HttpRequest({
|
|
237
231
|
protocol,
|
|
@@ -252,8 +246,8 @@ const serializeAws_restJson1UnsubscribeCommand = async (input, context) => {
|
|
|
252
246
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/unsubscribe";
|
|
253
247
|
let body;
|
|
254
248
|
body = JSON.stringify({
|
|
255
|
-
...(input.Arn
|
|
256
|
-
...(input.TargetAddress
|
|
249
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
250
|
+
...(input.TargetAddress != null && { TargetAddress: input.TargetAddress }),
|
|
257
251
|
});
|
|
258
252
|
return new protocol_http_1.HttpRequest({
|
|
259
253
|
protocol,
|
|
@@ -274,9 +268,8 @@ const serializeAws_restJson1UntagResourceCommand = async (input, context) => {
|
|
|
274
268
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/untagResource";
|
|
275
269
|
let body;
|
|
276
270
|
body = JSON.stringify({
|
|
277
|
-
...(input.Arn
|
|
278
|
-
...(input.TagKeys
|
|
279
|
-
input.TagKeys !== null && { TagKeys: serializeAws_restJson1TagKeys(input.TagKeys, context) }),
|
|
271
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
272
|
+
...(input.TagKeys != null && { TagKeys: serializeAws_restJson1TagKeys(input.TagKeys, context) }),
|
|
280
273
|
});
|
|
281
274
|
return new protocol_http_1.HttpRequest({
|
|
282
275
|
protocol,
|
|
@@ -297,14 +290,14 @@ const serializeAws_restJson1UpdateNotificationRuleCommand = async (input, contex
|
|
|
297
290
|
const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/updateNotificationRule";
|
|
298
291
|
let body;
|
|
299
292
|
body = JSON.stringify({
|
|
300
|
-
...(input.Arn
|
|
301
|
-
...(input.DetailType
|
|
302
|
-
...(input.EventTypeIds
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
...(input.
|
|
306
|
-
...(input.
|
|
307
|
-
|
|
293
|
+
...(input.Arn != null && { Arn: input.Arn }),
|
|
294
|
+
...(input.DetailType != null && { DetailType: input.DetailType }),
|
|
295
|
+
...(input.EventTypeIds != null && {
|
|
296
|
+
EventTypeIds: serializeAws_restJson1EventTypeIds(input.EventTypeIds, context),
|
|
297
|
+
}),
|
|
298
|
+
...(input.Name != null && { Name: input.Name }),
|
|
299
|
+
...(input.Status != null && { Status: input.Status }),
|
|
300
|
+
...(input.Targets != null && { Targets: serializeAws_restJson1Targets(input.Targets, context) }),
|
|
308
301
|
});
|
|
309
302
|
return new protocol_http_1.HttpRequest({
|
|
310
303
|
protocol,
|
|
@@ -338,8 +331,7 @@ const deserializeAws_restJson1CreateNotificationRuleCommandError = async (output
|
|
|
338
331
|
body: await parseBody(output.body, context),
|
|
339
332
|
};
|
|
340
333
|
let response;
|
|
341
|
-
|
|
342
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
334
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
343
335
|
switch (errorCode) {
|
|
344
336
|
case "AccessDeniedException":
|
|
345
337
|
case "com.amazonaws.codestarnotifications#AccessDeniedException":
|
|
@@ -361,10 +353,12 @@ const deserializeAws_restJson1CreateNotificationRuleCommandError = async (output
|
|
|
361
353
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
362
354
|
default:
|
|
363
355
|
const parsedBody = parsedOutput.body;
|
|
356
|
+
const $metadata = deserializeMetadata(output);
|
|
357
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
364
358
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
365
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
359
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
366
360
|
$fault: "client",
|
|
367
|
-
$metadata
|
|
361
|
+
$metadata,
|
|
368
362
|
});
|
|
369
363
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
370
364
|
}
|
|
@@ -390,8 +384,7 @@ const deserializeAws_restJson1DeleteNotificationRuleCommandError = async (output
|
|
|
390
384
|
body: await parseBody(output.body, context),
|
|
391
385
|
};
|
|
392
386
|
let response;
|
|
393
|
-
|
|
394
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
387
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
395
388
|
switch (errorCode) {
|
|
396
389
|
case "ConcurrentModificationException":
|
|
397
390
|
case "com.amazonaws.codestarnotifications#ConcurrentModificationException":
|
|
@@ -404,10 +397,12 @@ const deserializeAws_restJson1DeleteNotificationRuleCommandError = async (output
|
|
|
404
397
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
405
398
|
default:
|
|
406
399
|
const parsedBody = parsedOutput.body;
|
|
400
|
+
const $metadata = deserializeMetadata(output);
|
|
401
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
407
402
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
408
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
403
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
409
404
|
$fault: "client",
|
|
410
|
-
$metadata
|
|
405
|
+
$metadata,
|
|
411
406
|
});
|
|
412
407
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
413
408
|
}
|
|
@@ -429,18 +424,19 @@ const deserializeAws_restJson1DeleteTargetCommandError = async (output, context)
|
|
|
429
424
|
body: await parseBody(output.body, context),
|
|
430
425
|
};
|
|
431
426
|
let response;
|
|
432
|
-
|
|
433
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
427
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
434
428
|
switch (errorCode) {
|
|
435
429
|
case "ValidationException":
|
|
436
430
|
case "com.amazonaws.codestarnotifications#ValidationException":
|
|
437
431
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
438
432
|
default:
|
|
439
433
|
const parsedBody = parsedOutput.body;
|
|
434
|
+
const $metadata = deserializeMetadata(output);
|
|
435
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
440
436
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
441
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
437
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
442
438
|
$fault: "client",
|
|
443
|
-
$metadata
|
|
439
|
+
$metadata,
|
|
444
440
|
});
|
|
445
441
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
446
442
|
}
|
|
@@ -506,8 +502,7 @@ const deserializeAws_restJson1DescribeNotificationRuleCommandError = async (outp
|
|
|
506
502
|
body: await parseBody(output.body, context),
|
|
507
503
|
};
|
|
508
504
|
let response;
|
|
509
|
-
|
|
510
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
505
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
511
506
|
switch (errorCode) {
|
|
512
507
|
case "ResourceNotFoundException":
|
|
513
508
|
case "com.amazonaws.codestarnotifications#ResourceNotFoundException":
|
|
@@ -517,10 +512,12 @@ const deserializeAws_restJson1DescribeNotificationRuleCommandError = async (outp
|
|
|
517
512
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
518
513
|
default:
|
|
519
514
|
const parsedBody = parsedOutput.body;
|
|
515
|
+
const $metadata = deserializeMetadata(output);
|
|
516
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
520
517
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
521
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
518
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
522
519
|
$fault: "client",
|
|
523
|
-
$metadata
|
|
520
|
+
$metadata,
|
|
524
521
|
});
|
|
525
522
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
526
523
|
}
|
|
@@ -550,8 +547,7 @@ const deserializeAws_restJson1ListEventTypesCommandError = async (output, contex
|
|
|
550
547
|
body: await parseBody(output.body, context),
|
|
551
548
|
};
|
|
552
549
|
let response;
|
|
553
|
-
|
|
554
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
550
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
555
551
|
switch (errorCode) {
|
|
556
552
|
case "InvalidNextTokenException":
|
|
557
553
|
case "com.amazonaws.codestarnotifications#InvalidNextTokenException":
|
|
@@ -561,10 +557,12 @@ const deserializeAws_restJson1ListEventTypesCommandError = async (output, contex
|
|
|
561
557
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
562
558
|
default:
|
|
563
559
|
const parsedBody = parsedOutput.body;
|
|
560
|
+
const $metadata = deserializeMetadata(output);
|
|
561
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
564
562
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
565
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
563
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
566
564
|
$fault: "client",
|
|
567
|
-
$metadata
|
|
565
|
+
$metadata,
|
|
568
566
|
});
|
|
569
567
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
570
568
|
}
|
|
@@ -594,8 +592,7 @@ const deserializeAws_restJson1ListNotificationRulesCommandError = async (output,
|
|
|
594
592
|
body: await parseBody(output.body, context),
|
|
595
593
|
};
|
|
596
594
|
let response;
|
|
597
|
-
|
|
598
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
595
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
599
596
|
switch (errorCode) {
|
|
600
597
|
case "InvalidNextTokenException":
|
|
601
598
|
case "com.amazonaws.codestarnotifications#InvalidNextTokenException":
|
|
@@ -605,10 +602,12 @@ const deserializeAws_restJson1ListNotificationRulesCommandError = async (output,
|
|
|
605
602
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
606
603
|
default:
|
|
607
604
|
const parsedBody = parsedOutput.body;
|
|
605
|
+
const $metadata = deserializeMetadata(output);
|
|
606
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
608
607
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
609
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
608
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
610
609
|
$fault: "client",
|
|
611
|
-
$metadata
|
|
610
|
+
$metadata,
|
|
612
611
|
});
|
|
613
612
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
614
613
|
}
|
|
@@ -634,8 +633,7 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
|
|
|
634
633
|
body: await parseBody(output.body, context),
|
|
635
634
|
};
|
|
636
635
|
let response;
|
|
637
|
-
|
|
638
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
636
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
639
637
|
switch (errorCode) {
|
|
640
638
|
case "ResourceNotFoundException":
|
|
641
639
|
case "com.amazonaws.codestarnotifications#ResourceNotFoundException":
|
|
@@ -645,10 +643,12 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
|
|
|
645
643
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
646
644
|
default:
|
|
647
645
|
const parsedBody = parsedOutput.body;
|
|
646
|
+
const $metadata = deserializeMetadata(output);
|
|
647
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
648
648
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
649
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
649
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
650
650
|
$fault: "client",
|
|
651
|
-
$metadata
|
|
651
|
+
$metadata,
|
|
652
652
|
});
|
|
653
653
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
654
654
|
}
|
|
@@ -678,8 +678,7 @@ const deserializeAws_restJson1ListTargetsCommandError = async (output, context)
|
|
|
678
678
|
body: await parseBody(output.body, context),
|
|
679
679
|
};
|
|
680
680
|
let response;
|
|
681
|
-
|
|
682
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
681
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
683
682
|
switch (errorCode) {
|
|
684
683
|
case "InvalidNextTokenException":
|
|
685
684
|
case "com.amazonaws.codestarnotifications#InvalidNextTokenException":
|
|
@@ -689,10 +688,12 @@ const deserializeAws_restJson1ListTargetsCommandError = async (output, context)
|
|
|
689
688
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
690
689
|
default:
|
|
691
690
|
const parsedBody = parsedOutput.body;
|
|
691
|
+
const $metadata = deserializeMetadata(output);
|
|
692
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
692
693
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
693
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
694
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
694
695
|
$fault: "client",
|
|
695
|
-
$metadata
|
|
696
|
+
$metadata,
|
|
696
697
|
});
|
|
697
698
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
698
699
|
}
|
|
@@ -718,8 +719,7 @@ const deserializeAws_restJson1SubscribeCommandError = async (output, context) =>
|
|
|
718
719
|
body: await parseBody(output.body, context),
|
|
719
720
|
};
|
|
720
721
|
let response;
|
|
721
|
-
|
|
722
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
722
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
723
723
|
switch (errorCode) {
|
|
724
724
|
case "ResourceNotFoundException":
|
|
725
725
|
case "com.amazonaws.codestarnotifications#ResourceNotFoundException":
|
|
@@ -729,10 +729,12 @@ const deserializeAws_restJson1SubscribeCommandError = async (output, context) =>
|
|
|
729
729
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
730
730
|
default:
|
|
731
731
|
const parsedBody = parsedOutput.body;
|
|
732
|
+
const $metadata = deserializeMetadata(output);
|
|
733
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
732
734
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
733
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
735
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
734
736
|
$fault: "client",
|
|
735
|
-
$metadata
|
|
737
|
+
$metadata,
|
|
736
738
|
});
|
|
737
739
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
738
740
|
}
|
|
@@ -758,8 +760,7 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
|
|
|
758
760
|
body: await parseBody(output.body, context),
|
|
759
761
|
};
|
|
760
762
|
let response;
|
|
761
|
-
|
|
762
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
763
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
763
764
|
switch (errorCode) {
|
|
764
765
|
case "ConcurrentModificationException":
|
|
765
766
|
case "com.amazonaws.codestarnotifications#ConcurrentModificationException":
|
|
@@ -772,10 +773,12 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
|
|
|
772
773
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
773
774
|
default:
|
|
774
775
|
const parsedBody = parsedOutput.body;
|
|
776
|
+
const $metadata = deserializeMetadata(output);
|
|
777
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
775
778
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
776
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
779
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
777
780
|
$fault: "client",
|
|
778
|
-
$metadata
|
|
781
|
+
$metadata,
|
|
779
782
|
});
|
|
780
783
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
781
784
|
}
|
|
@@ -801,18 +804,19 @@ const deserializeAws_restJson1UnsubscribeCommandError = async (output, context)
|
|
|
801
804
|
body: await parseBody(output.body, context),
|
|
802
805
|
};
|
|
803
806
|
let response;
|
|
804
|
-
|
|
805
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
807
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
806
808
|
switch (errorCode) {
|
|
807
809
|
case "ValidationException":
|
|
808
810
|
case "com.amazonaws.codestarnotifications#ValidationException":
|
|
809
811
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
810
812
|
default:
|
|
811
813
|
const parsedBody = parsedOutput.body;
|
|
814
|
+
const $metadata = deserializeMetadata(output);
|
|
815
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
812
816
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
813
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
817
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
814
818
|
$fault: "client",
|
|
815
|
-
$metadata
|
|
819
|
+
$metadata,
|
|
816
820
|
});
|
|
817
821
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
818
822
|
}
|
|
@@ -834,8 +838,7 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
|
|
|
834
838
|
body: await parseBody(output.body, context),
|
|
835
839
|
};
|
|
836
840
|
let response;
|
|
837
|
-
|
|
838
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
841
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
839
842
|
switch (errorCode) {
|
|
840
843
|
case "ConcurrentModificationException":
|
|
841
844
|
case "com.amazonaws.codestarnotifications#ConcurrentModificationException":
|
|
@@ -848,10 +851,12 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
|
|
|
848
851
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
849
852
|
default:
|
|
850
853
|
const parsedBody = parsedOutput.body;
|
|
854
|
+
const $metadata = deserializeMetadata(output);
|
|
855
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
851
856
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
852
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
857
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
853
858
|
$fault: "client",
|
|
854
|
-
$metadata
|
|
859
|
+
$metadata,
|
|
855
860
|
});
|
|
856
861
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
857
862
|
}
|
|
@@ -873,8 +878,7 @@ const deserializeAws_restJson1UpdateNotificationRuleCommandError = async (output
|
|
|
873
878
|
body: await parseBody(output.body, context),
|
|
874
879
|
};
|
|
875
880
|
let response;
|
|
876
|
-
|
|
877
|
-
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
881
|
+
const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
878
882
|
switch (errorCode) {
|
|
879
883
|
case "ResourceNotFoundException":
|
|
880
884
|
case "com.amazonaws.codestarnotifications#ResourceNotFoundException":
|
|
@@ -884,10 +888,12 @@ const deserializeAws_restJson1UpdateNotificationRuleCommandError = async (output
|
|
|
884
888
|
throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
|
|
885
889
|
default:
|
|
886
890
|
const parsedBody = parsedOutput.body;
|
|
891
|
+
const $metadata = deserializeMetadata(output);
|
|
892
|
+
const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
887
893
|
response = new CodestarNotificationsServiceException_1.CodestarNotificationsServiceException({
|
|
888
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
894
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
889
895
|
$fault: "client",
|
|
890
|
-
$metadata
|
|
896
|
+
$metadata,
|
|
891
897
|
});
|
|
892
898
|
throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
|
|
893
899
|
}
|
|
@@ -1000,8 +1006,8 @@ const serializeAws_restJson1EventTypeIds = (input, context) => {
|
|
|
1000
1006
|
};
|
|
1001
1007
|
const serializeAws_restJson1ListEventTypesFilter = (input, context) => {
|
|
1002
1008
|
return {
|
|
1003
|
-
...(input.Name
|
|
1004
|
-
...(input.Value
|
|
1009
|
+
...(input.Name != null && { Name: input.Name }),
|
|
1010
|
+
...(input.Value != null && { Value: input.Value }),
|
|
1005
1011
|
};
|
|
1006
1012
|
};
|
|
1007
1013
|
const serializeAws_restJson1ListEventTypesFilters = (input, context) => {
|
|
@@ -1016,8 +1022,8 @@ const serializeAws_restJson1ListEventTypesFilters = (input, context) => {
|
|
|
1016
1022
|
};
|
|
1017
1023
|
const serializeAws_restJson1ListNotificationRulesFilter = (input, context) => {
|
|
1018
1024
|
return {
|
|
1019
|
-
...(input.Name
|
|
1020
|
-
...(input.Value
|
|
1025
|
+
...(input.Name != null && { Name: input.Name }),
|
|
1026
|
+
...(input.Value != null && { Value: input.Value }),
|
|
1021
1027
|
};
|
|
1022
1028
|
};
|
|
1023
1029
|
const serializeAws_restJson1ListNotificationRulesFilters = (input, context) => {
|
|
@@ -1032,8 +1038,8 @@ const serializeAws_restJson1ListNotificationRulesFilters = (input, context) => {
|
|
|
1032
1038
|
};
|
|
1033
1039
|
const serializeAws_restJson1ListTargetsFilter = (input, context) => {
|
|
1034
1040
|
return {
|
|
1035
|
-
...(input.Name
|
|
1036
|
-
...(input.Value
|
|
1041
|
+
...(input.Name != null && { Name: input.Name }),
|
|
1042
|
+
...(input.Value != null && { Value: input.Value }),
|
|
1037
1043
|
};
|
|
1038
1044
|
};
|
|
1039
1045
|
const serializeAws_restJson1ListTargetsFilters = (input, context) => {
|
|
@@ -1069,8 +1075,8 @@ const serializeAws_restJson1Tags = (input, context) => {
|
|
|
1069
1075
|
};
|
|
1070
1076
|
const serializeAws_restJson1Target = (input, context) => {
|
|
1071
1077
|
return {
|
|
1072
|
-
...(input.TargetAddress
|
|
1073
|
-
...(input.TargetType
|
|
1078
|
+
...(input.TargetAddress != null && { TargetAddress: input.TargetAddress }),
|
|
1079
|
+
...(input.TargetType != null && { TargetType: input.TargetType }),
|
|
1074
1080
|
};
|
|
1075
1081
|
};
|
|
1076
1082
|
const serializeAws_restJson1Targets = (input, context) => {
|
|
@@ -1197,5 +1203,4 @@ const loadRestJsonErrorCode = (output, data) => {
|
|
|
1197
1203
|
if (data["__type"] !== undefined) {
|
|
1198
1204
|
return sanitizeErrorCode(data["__type"]);
|
|
1199
1205
|
}
|
|
1200
|
-
return "";
|
|
1201
1206
|
};
|
|
@@ -16,9 +16,9 @@ export var serializeAws_restJson1CreateNotificationRuleCommand = function (input
|
|
|
16
16
|
"content-type": "application/json",
|
|
17
17
|
};
|
|
18
18
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/createNotificationRule";
|
|
19
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign({ ClientRequestToken: (_c = input.ClientRequestToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.DetailType
|
|
20
|
-
|
|
21
|
-
|
|
19
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign(__assign({ ClientRequestToken: (_c = input.ClientRequestToken) !== null && _c !== void 0 ? _c : generateIdempotencyToken() }, (input.DetailType != null && { DetailType: input.DetailType })), (input.EventTypeIds != null && {
|
|
20
|
+
EventTypeIds: serializeAws_restJson1EventTypeIds(input.EventTypeIds, context),
|
|
21
|
+
})), (input.Name != null && { Name: input.Name })), (input.Resource != null && { Resource: input.Resource })), (input.Status != null && { Status: input.Status })), (input.Tags != null && { Tags: serializeAws_restJson1Tags(input.Tags, context) })), (input.Targets != null && { Targets: serializeAws_restJson1Targets(input.Targets, context) })));
|
|
22
22
|
return [2, new __HttpRequest({
|
|
23
23
|
protocol: protocol,
|
|
24
24
|
hostname: hostname,
|
|
@@ -42,7 +42,7 @@ export var serializeAws_restJson1DeleteNotificationRuleCommand = function (input
|
|
|
42
42
|
"content-type": "application/json",
|
|
43
43
|
};
|
|
44
44
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/deleteNotificationRule";
|
|
45
|
-
body = JSON.stringify(__assign({}, (input.Arn
|
|
45
|
+
body = JSON.stringify(__assign({}, (input.Arn != null && { Arn: input.Arn })));
|
|
46
46
|
return [2, new __HttpRequest({
|
|
47
47
|
protocol: protocol,
|
|
48
48
|
hostname: hostname,
|
|
@@ -66,8 +66,7 @@ export var serializeAws_restJson1DeleteTargetCommand = function (input, context)
|
|
|
66
66
|
"content-type": "application/json",
|
|
67
67
|
};
|
|
68
68
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/deleteTarget";
|
|
69
|
-
body = JSON.stringify(__assign(__assign({}, (input.ForceUnsubscribeAll
|
|
70
|
-
input.ForceUnsubscribeAll !== null && { ForceUnsubscribeAll: input.ForceUnsubscribeAll })), (input.TargetAddress !== undefined && input.TargetAddress !== null && { TargetAddress: input.TargetAddress })));
|
|
69
|
+
body = JSON.stringify(__assign(__assign({}, (input.ForceUnsubscribeAll != null && { ForceUnsubscribeAll: input.ForceUnsubscribeAll })), (input.TargetAddress != null && { TargetAddress: input.TargetAddress })));
|
|
71
70
|
return [2, new __HttpRequest({
|
|
72
71
|
protocol: protocol,
|
|
73
72
|
hostname: hostname,
|
|
@@ -91,7 +90,7 @@ export var serializeAws_restJson1DescribeNotificationRuleCommand = function (inp
|
|
|
91
90
|
"content-type": "application/json",
|
|
92
91
|
};
|
|
93
92
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/describeNotificationRule";
|
|
94
|
-
body = JSON.stringify(__assign({}, (input.Arn
|
|
93
|
+
body = JSON.stringify(__assign({}, (input.Arn != null && { Arn: input.Arn })));
|
|
95
94
|
return [2, new __HttpRequest({
|
|
96
95
|
protocol: protocol,
|
|
97
96
|
hostname: hostname,
|
|
@@ -115,8 +114,7 @@ export var serializeAws_restJson1ListEventTypesCommand = function (input, contex
|
|
|
115
114
|
"content-type": "application/json",
|
|
116
115
|
};
|
|
117
116
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/listEventTypes";
|
|
118
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.Filters
|
|
119
|
-
input.Filters !== null && { Filters: serializeAws_restJson1ListEventTypesFilters(input.Filters, context) })), (input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults })), (input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken })));
|
|
117
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.Filters != null && { Filters: serializeAws_restJson1ListEventTypesFilters(input.Filters, context) })), (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
120
118
|
return [2, new __HttpRequest({
|
|
121
119
|
protocol: protocol,
|
|
122
120
|
hostname: hostname,
|
|
@@ -140,10 +138,9 @@ export var serializeAws_restJson1ListNotificationRulesCommand = function (input,
|
|
|
140
138
|
"content-type": "application/json",
|
|
141
139
|
};
|
|
142
140
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/listNotificationRules";
|
|
143
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.Filters
|
|
144
|
-
input.Filters !== null && {
|
|
141
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.Filters != null && {
|
|
145
142
|
Filters: serializeAws_restJson1ListNotificationRulesFilters(input.Filters, context),
|
|
146
|
-
})), (input.MaxResults
|
|
143
|
+
})), (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
147
144
|
return [2, new __HttpRequest({
|
|
148
145
|
protocol: protocol,
|
|
149
146
|
hostname: hostname,
|
|
@@ -167,7 +164,7 @@ export var serializeAws_restJson1ListTagsForResourceCommand = function (input, c
|
|
|
167
164
|
"content-type": "application/json",
|
|
168
165
|
};
|
|
169
166
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/listTagsForResource";
|
|
170
|
-
body = JSON.stringify(__assign({}, (input.Arn
|
|
167
|
+
body = JSON.stringify(__assign({}, (input.Arn != null && { Arn: input.Arn })));
|
|
171
168
|
return [2, new __HttpRequest({
|
|
172
169
|
protocol: protocol,
|
|
173
170
|
hostname: hostname,
|
|
@@ -191,8 +188,7 @@ export var serializeAws_restJson1ListTargetsCommand = function (input, context)
|
|
|
191
188
|
"content-type": "application/json",
|
|
192
189
|
};
|
|
193
190
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/listTargets";
|
|
194
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.Filters
|
|
195
|
-
input.Filters !== null && { Filters: serializeAws_restJson1ListTargetsFilters(input.Filters, context) })), (input.MaxResults !== undefined && input.MaxResults !== null && { MaxResults: input.MaxResults })), (input.NextToken !== undefined && input.NextToken !== null && { NextToken: input.NextToken })));
|
|
191
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.Filters != null && { Filters: serializeAws_restJson1ListTargetsFilters(input.Filters, context) })), (input.MaxResults != null && { MaxResults: input.MaxResults })), (input.NextToken != null && { NextToken: input.NextToken })));
|
|
196
192
|
return [2, new __HttpRequest({
|
|
197
193
|
protocol: protocol,
|
|
198
194
|
hostname: hostname,
|
|
@@ -216,9 +212,7 @@ export var serializeAws_restJson1SubscribeCommand = function (input, context) {
|
|
|
216
212
|
"content-type": "application/json",
|
|
217
213
|
};
|
|
218
214
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/subscribe";
|
|
219
|
-
body = JSON.stringify(__assign(__assign(__assign({}, (input.Arn
|
|
220
|
-
input.ClientRequestToken !== null && { ClientRequestToken: input.ClientRequestToken })), (input.Target !== undefined &&
|
|
221
|
-
input.Target !== null && { Target: serializeAws_restJson1Target(input.Target, context) })));
|
|
215
|
+
body = JSON.stringify(__assign(__assign(__assign({}, (input.Arn != null && { Arn: input.Arn })), (input.ClientRequestToken != null && { ClientRequestToken: input.ClientRequestToken })), (input.Target != null && { Target: serializeAws_restJson1Target(input.Target, context) })));
|
|
222
216
|
return [2, new __HttpRequest({
|
|
223
217
|
protocol: protocol,
|
|
224
218
|
hostname: hostname,
|
|
@@ -242,7 +236,7 @@ export var serializeAws_restJson1TagResourceCommand = function (input, context)
|
|
|
242
236
|
"content-type": "application/json",
|
|
243
237
|
};
|
|
244
238
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/tagResource";
|
|
245
|
-
body = JSON.stringify(__assign(__assign({}, (input.Arn
|
|
239
|
+
body = JSON.stringify(__assign(__assign({}, (input.Arn != null && { Arn: input.Arn })), (input.Tags != null && { Tags: serializeAws_restJson1Tags(input.Tags, context) })));
|
|
246
240
|
return [2, new __HttpRequest({
|
|
247
241
|
protocol: protocol,
|
|
248
242
|
hostname: hostname,
|
|
@@ -266,7 +260,7 @@ export var serializeAws_restJson1UnsubscribeCommand = function (input, context)
|
|
|
266
260
|
"content-type": "application/json",
|
|
267
261
|
};
|
|
268
262
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/unsubscribe";
|
|
269
|
-
body = JSON.stringify(__assign(__assign({}, (input.Arn
|
|
263
|
+
body = JSON.stringify(__assign(__assign({}, (input.Arn != null && { Arn: input.Arn })), (input.TargetAddress != null && { TargetAddress: input.TargetAddress })));
|
|
270
264
|
return [2, new __HttpRequest({
|
|
271
265
|
protocol: protocol,
|
|
272
266
|
hostname: hostname,
|
|
@@ -290,8 +284,7 @@ export var serializeAws_restJson1UntagResourceCommand = function (input, context
|
|
|
290
284
|
"content-type": "application/json",
|
|
291
285
|
};
|
|
292
286
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/untagResource";
|
|
293
|
-
body = JSON.stringify(__assign(__assign({}, (input.Arn
|
|
294
|
-
input.TagKeys !== null && { TagKeys: serializeAws_restJson1TagKeys(input.TagKeys, context) })));
|
|
287
|
+
body = JSON.stringify(__assign(__assign({}, (input.Arn != null && { Arn: input.Arn })), (input.TagKeys != null && { TagKeys: serializeAws_restJson1TagKeys(input.TagKeys, context) })));
|
|
295
288
|
return [2, new __HttpRequest({
|
|
296
289
|
protocol: protocol,
|
|
297
290
|
hostname: hostname,
|
|
@@ -315,9 +308,9 @@ export var serializeAws_restJson1UpdateNotificationRuleCommand = function (input
|
|
|
315
308
|
"content-type": "application/json",
|
|
316
309
|
};
|
|
317
310
|
resolvedPath = "".concat((basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || "") + "/updateNotificationRule";
|
|
318
|
-
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.Arn
|
|
319
|
-
|
|
320
|
-
|
|
311
|
+
body = JSON.stringify(__assign(__assign(__assign(__assign(__assign(__assign({}, (input.Arn != null && { Arn: input.Arn })), (input.DetailType != null && { DetailType: input.DetailType })), (input.EventTypeIds != null && {
|
|
312
|
+
EventTypeIds: serializeAws_restJson1EventTypeIds(input.EventTypeIds, context),
|
|
313
|
+
})), (input.Name != null && { Name: input.Name })), (input.Status != null && { Status: input.Status })), (input.Targets != null && { Targets: serializeAws_restJson1Targets(input.Targets, context) })));
|
|
321
314
|
return [2, new __HttpRequest({
|
|
322
315
|
protocol: protocol,
|
|
323
316
|
hostname: hostname,
|
|
@@ -355,7 +348,7 @@ export var deserializeAws_restJson1CreateNotificationRuleCommand = function (out
|
|
|
355
348
|
});
|
|
356
349
|
}); };
|
|
357
350
|
var deserializeAws_restJson1CreateNotificationRuleCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
358
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
351
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
359
352
|
var _c;
|
|
360
353
|
return __generator(this, function (_d) {
|
|
361
354
|
switch (_d.label) {
|
|
@@ -365,7 +358,6 @@ var deserializeAws_restJson1CreateNotificationRuleCommandError = function (outpu
|
|
|
365
358
|
return [4, parseBody(output.body, context)];
|
|
366
359
|
case 1:
|
|
367
360
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
368
|
-
errorCode = "UnknownError";
|
|
369
361
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
370
362
|
_b = errorCode;
|
|
371
363
|
switch (_b) {
|
|
@@ -397,10 +389,12 @@ var deserializeAws_restJson1CreateNotificationRuleCommandError = function (outpu
|
|
|
397
389
|
case 13: throw _d.sent();
|
|
398
390
|
case 14:
|
|
399
391
|
parsedBody = parsedOutput.body;
|
|
392
|
+
$metadata = deserializeMetadata(output);
|
|
393
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
400
394
|
response = new __BaseException({
|
|
401
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
395
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
402
396
|
$fault: "client",
|
|
403
|
-
$metadata:
|
|
397
|
+
$metadata: $metadata,
|
|
404
398
|
});
|
|
405
399
|
throw __decorateServiceException(response, parsedBody);
|
|
406
400
|
}
|
|
@@ -431,7 +425,7 @@ export var deserializeAws_restJson1DeleteNotificationRuleCommand = function (out
|
|
|
431
425
|
});
|
|
432
426
|
}); };
|
|
433
427
|
var deserializeAws_restJson1DeleteNotificationRuleCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
434
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
428
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
435
429
|
var _c;
|
|
436
430
|
return __generator(this, function (_d) {
|
|
437
431
|
switch (_d.label) {
|
|
@@ -441,7 +435,6 @@ var deserializeAws_restJson1DeleteNotificationRuleCommandError = function (outpu
|
|
|
441
435
|
return [4, parseBody(output.body, context)];
|
|
442
436
|
case 1:
|
|
443
437
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
444
|
-
errorCode = "UnknownError";
|
|
445
438
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
446
439
|
_b = errorCode;
|
|
447
440
|
switch (_b) {
|
|
@@ -461,10 +454,12 @@ var deserializeAws_restJson1DeleteNotificationRuleCommandError = function (outpu
|
|
|
461
454
|
case 7: throw _d.sent();
|
|
462
455
|
case 8:
|
|
463
456
|
parsedBody = parsedOutput.body;
|
|
457
|
+
$metadata = deserializeMetadata(output);
|
|
458
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
464
459
|
response = new __BaseException({
|
|
465
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
460
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
466
461
|
$fault: "client",
|
|
467
|
-
$metadata:
|
|
462
|
+
$metadata: $metadata,
|
|
468
463
|
});
|
|
469
464
|
throw __decorateServiceException(response, parsedBody);
|
|
470
465
|
}
|
|
@@ -489,7 +484,7 @@ export var deserializeAws_restJson1DeleteTargetCommand = function (output, conte
|
|
|
489
484
|
});
|
|
490
485
|
}); };
|
|
491
486
|
var deserializeAws_restJson1DeleteTargetCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
492
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
487
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
493
488
|
var _c;
|
|
494
489
|
return __generator(this, function (_d) {
|
|
495
490
|
switch (_d.label) {
|
|
@@ -499,7 +494,6 @@ var deserializeAws_restJson1DeleteTargetCommandError = function (output, context
|
|
|
499
494
|
return [4, parseBody(output.body, context)];
|
|
500
495
|
case 1:
|
|
501
496
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
502
|
-
errorCode = "UnknownError";
|
|
503
497
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
504
498
|
_b = errorCode;
|
|
505
499
|
switch (_b) {
|
|
@@ -511,10 +505,12 @@ var deserializeAws_restJson1DeleteTargetCommandError = function (output, context
|
|
|
511
505
|
case 3: throw _d.sent();
|
|
512
506
|
case 4:
|
|
513
507
|
parsedBody = parsedOutput.body;
|
|
508
|
+
$metadata = deserializeMetadata(output);
|
|
509
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
514
510
|
response = new __BaseException({
|
|
515
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
511
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
516
512
|
$fault: "client",
|
|
517
|
-
$metadata:
|
|
513
|
+
$metadata: $metadata,
|
|
518
514
|
});
|
|
519
515
|
throw __decorateServiceException(response, parsedBody);
|
|
520
516
|
}
|
|
@@ -585,7 +581,7 @@ export var deserializeAws_restJson1DescribeNotificationRuleCommand = function (o
|
|
|
585
581
|
});
|
|
586
582
|
}); };
|
|
587
583
|
var deserializeAws_restJson1DescribeNotificationRuleCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
588
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
584
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
589
585
|
var _c;
|
|
590
586
|
return __generator(this, function (_d) {
|
|
591
587
|
switch (_d.label) {
|
|
@@ -595,7 +591,6 @@ var deserializeAws_restJson1DescribeNotificationRuleCommandError = function (out
|
|
|
595
591
|
return [4, parseBody(output.body, context)];
|
|
596
592
|
case 1:
|
|
597
593
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
598
|
-
errorCode = "UnknownError";
|
|
599
594
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
600
595
|
_b = errorCode;
|
|
601
596
|
switch (_b) {
|
|
@@ -611,10 +606,12 @@ var deserializeAws_restJson1DescribeNotificationRuleCommandError = function (out
|
|
|
611
606
|
case 5: throw _d.sent();
|
|
612
607
|
case 6:
|
|
613
608
|
parsedBody = parsedOutput.body;
|
|
609
|
+
$metadata = deserializeMetadata(output);
|
|
610
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
614
611
|
response = new __BaseException({
|
|
615
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
612
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
616
613
|
$fault: "client",
|
|
617
|
-
$metadata:
|
|
614
|
+
$metadata: $metadata,
|
|
618
615
|
});
|
|
619
616
|
throw __decorateServiceException(response, parsedBody);
|
|
620
617
|
}
|
|
@@ -649,7 +646,7 @@ export var deserializeAws_restJson1ListEventTypesCommand = function (output, con
|
|
|
649
646
|
});
|
|
650
647
|
}); };
|
|
651
648
|
var deserializeAws_restJson1ListEventTypesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
652
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
649
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
653
650
|
var _c;
|
|
654
651
|
return __generator(this, function (_d) {
|
|
655
652
|
switch (_d.label) {
|
|
@@ -659,7 +656,6 @@ var deserializeAws_restJson1ListEventTypesCommandError = function (output, conte
|
|
|
659
656
|
return [4, parseBody(output.body, context)];
|
|
660
657
|
case 1:
|
|
661
658
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
662
|
-
errorCode = "UnknownError";
|
|
663
659
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
664
660
|
_b = errorCode;
|
|
665
661
|
switch (_b) {
|
|
@@ -675,10 +671,12 @@ var deserializeAws_restJson1ListEventTypesCommandError = function (output, conte
|
|
|
675
671
|
case 5: throw _d.sent();
|
|
676
672
|
case 6:
|
|
677
673
|
parsedBody = parsedOutput.body;
|
|
674
|
+
$metadata = deserializeMetadata(output);
|
|
675
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
678
676
|
response = new __BaseException({
|
|
679
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
677
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
680
678
|
$fault: "client",
|
|
681
|
-
$metadata:
|
|
679
|
+
$metadata: $metadata,
|
|
682
680
|
});
|
|
683
681
|
throw __decorateServiceException(response, parsedBody);
|
|
684
682
|
}
|
|
@@ -713,7 +711,7 @@ export var deserializeAws_restJson1ListNotificationRulesCommand = function (outp
|
|
|
713
711
|
});
|
|
714
712
|
}); };
|
|
715
713
|
var deserializeAws_restJson1ListNotificationRulesCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
716
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
714
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
717
715
|
var _c;
|
|
718
716
|
return __generator(this, function (_d) {
|
|
719
717
|
switch (_d.label) {
|
|
@@ -723,7 +721,6 @@ var deserializeAws_restJson1ListNotificationRulesCommandError = function (output
|
|
|
723
721
|
return [4, parseBody(output.body, context)];
|
|
724
722
|
case 1:
|
|
725
723
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
726
|
-
errorCode = "UnknownError";
|
|
727
724
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
728
725
|
_b = errorCode;
|
|
729
726
|
switch (_b) {
|
|
@@ -739,10 +736,12 @@ var deserializeAws_restJson1ListNotificationRulesCommandError = function (output
|
|
|
739
736
|
case 5: throw _d.sent();
|
|
740
737
|
case 6:
|
|
741
738
|
parsedBody = parsedOutput.body;
|
|
739
|
+
$metadata = deserializeMetadata(output);
|
|
740
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
742
741
|
response = new __BaseException({
|
|
743
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
742
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
744
743
|
$fault: "client",
|
|
745
|
-
$metadata:
|
|
744
|
+
$metadata: $metadata,
|
|
746
745
|
});
|
|
747
746
|
throw __decorateServiceException(response, parsedBody);
|
|
748
747
|
}
|
|
@@ -773,7 +772,7 @@ export var deserializeAws_restJson1ListTagsForResourceCommand = function (output
|
|
|
773
772
|
});
|
|
774
773
|
}); };
|
|
775
774
|
var deserializeAws_restJson1ListTagsForResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
776
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
775
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
777
776
|
var _c;
|
|
778
777
|
return __generator(this, function (_d) {
|
|
779
778
|
switch (_d.label) {
|
|
@@ -783,7 +782,6 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
|
|
|
783
782
|
return [4, parseBody(output.body, context)];
|
|
784
783
|
case 1:
|
|
785
784
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
786
|
-
errorCode = "UnknownError";
|
|
787
785
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
788
786
|
_b = errorCode;
|
|
789
787
|
switch (_b) {
|
|
@@ -799,10 +797,12 @@ var deserializeAws_restJson1ListTagsForResourceCommandError = function (output,
|
|
|
799
797
|
case 5: throw _d.sent();
|
|
800
798
|
case 6:
|
|
801
799
|
parsedBody = parsedOutput.body;
|
|
800
|
+
$metadata = deserializeMetadata(output);
|
|
801
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
802
802
|
response = new __BaseException({
|
|
803
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
803
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
804
804
|
$fault: "client",
|
|
805
|
-
$metadata:
|
|
805
|
+
$metadata: $metadata,
|
|
806
806
|
});
|
|
807
807
|
throw __decorateServiceException(response, parsedBody);
|
|
808
808
|
}
|
|
@@ -837,7 +837,7 @@ export var deserializeAws_restJson1ListTargetsCommand = function (output, contex
|
|
|
837
837
|
});
|
|
838
838
|
}); };
|
|
839
839
|
var deserializeAws_restJson1ListTargetsCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
840
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
840
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
841
841
|
var _c;
|
|
842
842
|
return __generator(this, function (_d) {
|
|
843
843
|
switch (_d.label) {
|
|
@@ -847,7 +847,6 @@ var deserializeAws_restJson1ListTargetsCommandError = function (output, context)
|
|
|
847
847
|
return [4, parseBody(output.body, context)];
|
|
848
848
|
case 1:
|
|
849
849
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
850
|
-
errorCode = "UnknownError";
|
|
851
850
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
852
851
|
_b = errorCode;
|
|
853
852
|
switch (_b) {
|
|
@@ -863,10 +862,12 @@ var deserializeAws_restJson1ListTargetsCommandError = function (output, context)
|
|
|
863
862
|
case 5: throw _d.sent();
|
|
864
863
|
case 6:
|
|
865
864
|
parsedBody = parsedOutput.body;
|
|
865
|
+
$metadata = deserializeMetadata(output);
|
|
866
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
866
867
|
response = new __BaseException({
|
|
867
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
868
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
868
869
|
$fault: "client",
|
|
869
|
-
$metadata:
|
|
870
|
+
$metadata: $metadata,
|
|
870
871
|
});
|
|
871
872
|
throw __decorateServiceException(response, parsedBody);
|
|
872
873
|
}
|
|
@@ -897,7 +898,7 @@ export var deserializeAws_restJson1SubscribeCommand = function (output, context)
|
|
|
897
898
|
});
|
|
898
899
|
}); };
|
|
899
900
|
var deserializeAws_restJson1SubscribeCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
900
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
901
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
901
902
|
var _c;
|
|
902
903
|
return __generator(this, function (_d) {
|
|
903
904
|
switch (_d.label) {
|
|
@@ -907,7 +908,6 @@ var deserializeAws_restJson1SubscribeCommandError = function (output, context) {
|
|
|
907
908
|
return [4, parseBody(output.body, context)];
|
|
908
909
|
case 1:
|
|
909
910
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
910
|
-
errorCode = "UnknownError";
|
|
911
911
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
912
912
|
_b = errorCode;
|
|
913
913
|
switch (_b) {
|
|
@@ -923,10 +923,12 @@ var deserializeAws_restJson1SubscribeCommandError = function (output, context) {
|
|
|
923
923
|
case 5: throw _d.sent();
|
|
924
924
|
case 6:
|
|
925
925
|
parsedBody = parsedOutput.body;
|
|
926
|
+
$metadata = deserializeMetadata(output);
|
|
927
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
926
928
|
response = new __BaseException({
|
|
927
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
929
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
928
930
|
$fault: "client",
|
|
929
|
-
$metadata:
|
|
931
|
+
$metadata: $metadata,
|
|
930
932
|
});
|
|
931
933
|
throw __decorateServiceException(response, parsedBody);
|
|
932
934
|
}
|
|
@@ -957,7 +959,7 @@ export var deserializeAws_restJson1TagResourceCommand = function (output, contex
|
|
|
957
959
|
});
|
|
958
960
|
}); };
|
|
959
961
|
var deserializeAws_restJson1TagResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
960
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
962
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
961
963
|
var _c;
|
|
962
964
|
return __generator(this, function (_d) {
|
|
963
965
|
switch (_d.label) {
|
|
@@ -967,7 +969,6 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
|
|
|
967
969
|
return [4, parseBody(output.body, context)];
|
|
968
970
|
case 1:
|
|
969
971
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
970
|
-
errorCode = "UnknownError";
|
|
971
972
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
972
973
|
_b = errorCode;
|
|
973
974
|
switch (_b) {
|
|
@@ -987,10 +988,12 @@ var deserializeAws_restJson1TagResourceCommandError = function (output, context)
|
|
|
987
988
|
case 7: throw _d.sent();
|
|
988
989
|
case 8:
|
|
989
990
|
parsedBody = parsedOutput.body;
|
|
991
|
+
$metadata = deserializeMetadata(output);
|
|
992
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
990
993
|
response = new __BaseException({
|
|
991
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
994
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
992
995
|
$fault: "client",
|
|
993
|
-
$metadata:
|
|
996
|
+
$metadata: $metadata,
|
|
994
997
|
});
|
|
995
998
|
throw __decorateServiceException(response, parsedBody);
|
|
996
999
|
}
|
|
@@ -1021,7 +1024,7 @@ export var deserializeAws_restJson1UnsubscribeCommand = function (output, contex
|
|
|
1021
1024
|
});
|
|
1022
1025
|
}); };
|
|
1023
1026
|
var deserializeAws_restJson1UnsubscribeCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1024
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1027
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1025
1028
|
var _c;
|
|
1026
1029
|
return __generator(this, function (_d) {
|
|
1027
1030
|
switch (_d.label) {
|
|
@@ -1031,7 +1034,6 @@ var deserializeAws_restJson1UnsubscribeCommandError = function (output, context)
|
|
|
1031
1034
|
return [4, parseBody(output.body, context)];
|
|
1032
1035
|
case 1:
|
|
1033
1036
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1034
|
-
errorCode = "UnknownError";
|
|
1035
1037
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1036
1038
|
_b = errorCode;
|
|
1037
1039
|
switch (_b) {
|
|
@@ -1043,10 +1045,12 @@ var deserializeAws_restJson1UnsubscribeCommandError = function (output, context)
|
|
|
1043
1045
|
case 3: throw _d.sent();
|
|
1044
1046
|
case 4:
|
|
1045
1047
|
parsedBody = parsedOutput.body;
|
|
1048
|
+
$metadata = deserializeMetadata(output);
|
|
1049
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1046
1050
|
response = new __BaseException({
|
|
1047
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1051
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1048
1052
|
$fault: "client",
|
|
1049
|
-
$metadata:
|
|
1053
|
+
$metadata: $metadata,
|
|
1050
1054
|
});
|
|
1051
1055
|
throw __decorateServiceException(response, parsedBody);
|
|
1052
1056
|
}
|
|
@@ -1071,7 +1075,7 @@ export var deserializeAws_restJson1UntagResourceCommand = function (output, cont
|
|
|
1071
1075
|
});
|
|
1072
1076
|
}); };
|
|
1073
1077
|
var deserializeAws_restJson1UntagResourceCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1074
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1078
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1075
1079
|
var _c;
|
|
1076
1080
|
return __generator(this, function (_d) {
|
|
1077
1081
|
switch (_d.label) {
|
|
@@ -1081,7 +1085,6 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
|
|
|
1081
1085
|
return [4, parseBody(output.body, context)];
|
|
1082
1086
|
case 1:
|
|
1083
1087
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1084
|
-
errorCode = "UnknownError";
|
|
1085
1088
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1086
1089
|
_b = errorCode;
|
|
1087
1090
|
switch (_b) {
|
|
@@ -1101,10 +1104,12 @@ var deserializeAws_restJson1UntagResourceCommandError = function (output, contex
|
|
|
1101
1104
|
case 7: throw _d.sent();
|
|
1102
1105
|
case 8:
|
|
1103
1106
|
parsedBody = parsedOutput.body;
|
|
1107
|
+
$metadata = deserializeMetadata(output);
|
|
1108
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1104
1109
|
response = new __BaseException({
|
|
1105
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1110
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1106
1111
|
$fault: "client",
|
|
1107
|
-
$metadata:
|
|
1112
|
+
$metadata: $metadata,
|
|
1108
1113
|
});
|
|
1109
1114
|
throw __decorateServiceException(response, parsedBody);
|
|
1110
1115
|
}
|
|
@@ -1129,7 +1134,7 @@ export var deserializeAws_restJson1UpdateNotificationRuleCommand = function (out
|
|
|
1129
1134
|
});
|
|
1130
1135
|
}); };
|
|
1131
1136
|
var deserializeAws_restJson1UpdateNotificationRuleCommandError = function (output, context) { return __awaiter(void 0, void 0, void 0, function () {
|
|
1132
|
-
var parsedOutput, _a, response, errorCode, _b, parsedBody;
|
|
1137
|
+
var parsedOutput, _a, response, errorCode, _b, parsedBody, $metadata, statusCode;
|
|
1133
1138
|
var _c;
|
|
1134
1139
|
return __generator(this, function (_d) {
|
|
1135
1140
|
switch (_d.label) {
|
|
@@ -1139,7 +1144,6 @@ var deserializeAws_restJson1UpdateNotificationRuleCommandError = function (outpu
|
|
|
1139
1144
|
return [4, parseBody(output.body, context)];
|
|
1140
1145
|
case 1:
|
|
1141
1146
|
parsedOutput = __assign.apply(void 0, _a.concat([(_c.body = _d.sent(), _c)]));
|
|
1142
|
-
errorCode = "UnknownError";
|
|
1143
1147
|
errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
|
|
1144
1148
|
_b = errorCode;
|
|
1145
1149
|
switch (_b) {
|
|
@@ -1155,10 +1159,12 @@ var deserializeAws_restJson1UpdateNotificationRuleCommandError = function (outpu
|
|
|
1155
1159
|
case 5: throw _d.sent();
|
|
1156
1160
|
case 6:
|
|
1157
1161
|
parsedBody = parsedOutput.body;
|
|
1162
|
+
$metadata = deserializeMetadata(output);
|
|
1163
|
+
statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
|
|
1158
1164
|
response = new __BaseException({
|
|
1159
|
-
name: parsedBody.code || parsedBody.Code || errorCode,
|
|
1165
|
+
name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
|
|
1160
1166
|
$fault: "client",
|
|
1161
|
-
$metadata:
|
|
1167
|
+
$metadata: $metadata,
|
|
1162
1168
|
});
|
|
1163
1169
|
throw __decorateServiceException(response, parsedBody);
|
|
1164
1170
|
}
|
|
@@ -1271,7 +1277,7 @@ var serializeAws_restJson1EventTypeIds = function (input, context) {
|
|
|
1271
1277
|
});
|
|
1272
1278
|
};
|
|
1273
1279
|
var serializeAws_restJson1ListEventTypesFilter = function (input, context) {
|
|
1274
|
-
return __assign(__assign({}, (input.Name
|
|
1280
|
+
return __assign(__assign({}, (input.Name != null && { Name: input.Name })), (input.Value != null && { Value: input.Value }));
|
|
1275
1281
|
};
|
|
1276
1282
|
var serializeAws_restJson1ListEventTypesFilters = function (input, context) {
|
|
1277
1283
|
return input
|
|
@@ -1284,7 +1290,7 @@ var serializeAws_restJson1ListEventTypesFilters = function (input, context) {
|
|
|
1284
1290
|
});
|
|
1285
1291
|
};
|
|
1286
1292
|
var serializeAws_restJson1ListNotificationRulesFilter = function (input, context) {
|
|
1287
|
-
return __assign(__assign({}, (input.Name
|
|
1293
|
+
return __assign(__assign({}, (input.Name != null && { Name: input.Name })), (input.Value != null && { Value: input.Value }));
|
|
1288
1294
|
};
|
|
1289
1295
|
var serializeAws_restJson1ListNotificationRulesFilters = function (input, context) {
|
|
1290
1296
|
return input
|
|
@@ -1297,7 +1303,7 @@ var serializeAws_restJson1ListNotificationRulesFilters = function (input, contex
|
|
|
1297
1303
|
});
|
|
1298
1304
|
};
|
|
1299
1305
|
var serializeAws_restJson1ListTargetsFilter = function (input, context) {
|
|
1300
|
-
return __assign(__assign({}, (input.Name
|
|
1306
|
+
return __assign(__assign({}, (input.Name != null && { Name: input.Name })), (input.Value != null && { Value: input.Value }));
|
|
1301
1307
|
};
|
|
1302
1308
|
var serializeAws_restJson1ListTargetsFilters = function (input, context) {
|
|
1303
1309
|
return input
|
|
@@ -1330,7 +1336,7 @@ var serializeAws_restJson1Tags = function (input, context) {
|
|
|
1330
1336
|
}, {});
|
|
1331
1337
|
};
|
|
1332
1338
|
var serializeAws_restJson1Target = function (input, context) {
|
|
1333
|
-
return __assign(__assign({}, (input.TargetAddress
|
|
1339
|
+
return __assign(__assign({}, (input.TargetAddress != null && { TargetAddress: input.TargetAddress })), (input.TargetType != null && { TargetType: input.TargetType }));
|
|
1334
1340
|
};
|
|
1335
1341
|
var serializeAws_restJson1Targets = function (input, context) {
|
|
1336
1342
|
return input
|
|
@@ -1462,5 +1468,4 @@ var loadRestJsonErrorCode = function (output, data) {
|
|
|
1462
1468
|
if (data["__type"] !== undefined) {
|
|
1463
1469
|
return sanitizeErrorCode(data["__type"]);
|
|
1464
1470
|
}
|
|
1465
|
-
return "";
|
|
1466
1471
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@aws-sdk/client-codestar-notifications",
|
|
3
3
|
"description": "AWS SDK for JavaScript Codestar Notifications Client for Node.js, Browser and React Native",
|
|
4
|
-
"version": "3.
|
|
4
|
+
"version": "3.128.0",
|
|
5
5
|
"scripts": {
|
|
6
6
|
"build": "concurrently 'yarn:build:cjs' 'yarn:build:es' 'yarn:build:types'",
|
|
7
7
|
"build:cjs": "tsc -p tsconfig.cjs.json",
|
|
@@ -18,35 +18,35 @@
|
|
|
18
18
|
"dependencies": {
|
|
19
19
|
"@aws-crypto/sha256-browser": "2.0.0",
|
|
20
20
|
"@aws-crypto/sha256-js": "2.0.0",
|
|
21
|
-
"@aws-sdk/client-sts": "3.
|
|
22
|
-
"@aws-sdk/config-resolver": "3.
|
|
23
|
-
"@aws-sdk/credential-provider-node": "3.
|
|
24
|
-
"@aws-sdk/fetch-http-handler": "3.
|
|
25
|
-
"@aws-sdk/hash-node": "3.
|
|
26
|
-
"@aws-sdk/invalid-dependency": "3.
|
|
27
|
-
"@aws-sdk/middleware-content-length": "3.
|
|
28
|
-
"@aws-sdk/middleware-host-header": "3.
|
|
29
|
-
"@aws-sdk/middleware-logger": "3.
|
|
30
|
-
"@aws-sdk/middleware-recursion-detection": "3.
|
|
31
|
-
"@aws-sdk/middleware-retry": "3.
|
|
32
|
-
"@aws-sdk/middleware-serde": "3.
|
|
33
|
-
"@aws-sdk/middleware-signing": "3.
|
|
34
|
-
"@aws-sdk/middleware-stack": "3.
|
|
35
|
-
"@aws-sdk/middleware-user-agent": "3.
|
|
36
|
-
"@aws-sdk/node-config-provider": "3.
|
|
37
|
-
"@aws-sdk/node-http-handler": "3.
|
|
38
|
-
"@aws-sdk/protocol-http": "3.
|
|
39
|
-
"@aws-sdk/smithy-client": "3.
|
|
40
|
-
"@aws-sdk/types": "3.
|
|
41
|
-
"@aws-sdk/url-parser": "3.
|
|
21
|
+
"@aws-sdk/client-sts": "3.128.0",
|
|
22
|
+
"@aws-sdk/config-resolver": "3.128.0",
|
|
23
|
+
"@aws-sdk/credential-provider-node": "3.128.0",
|
|
24
|
+
"@aws-sdk/fetch-http-handler": "3.127.0",
|
|
25
|
+
"@aws-sdk/hash-node": "3.127.0",
|
|
26
|
+
"@aws-sdk/invalid-dependency": "3.127.0",
|
|
27
|
+
"@aws-sdk/middleware-content-length": "3.127.0",
|
|
28
|
+
"@aws-sdk/middleware-host-header": "3.127.0",
|
|
29
|
+
"@aws-sdk/middleware-logger": "3.127.0",
|
|
30
|
+
"@aws-sdk/middleware-recursion-detection": "3.127.0",
|
|
31
|
+
"@aws-sdk/middleware-retry": "3.127.0",
|
|
32
|
+
"@aws-sdk/middleware-serde": "3.127.0",
|
|
33
|
+
"@aws-sdk/middleware-signing": "3.128.0",
|
|
34
|
+
"@aws-sdk/middleware-stack": "3.127.0",
|
|
35
|
+
"@aws-sdk/middleware-user-agent": "3.127.0",
|
|
36
|
+
"@aws-sdk/node-config-provider": "3.127.0",
|
|
37
|
+
"@aws-sdk/node-http-handler": "3.127.0",
|
|
38
|
+
"@aws-sdk/protocol-http": "3.127.0",
|
|
39
|
+
"@aws-sdk/smithy-client": "3.127.0",
|
|
40
|
+
"@aws-sdk/types": "3.127.0",
|
|
41
|
+
"@aws-sdk/url-parser": "3.127.0",
|
|
42
42
|
"@aws-sdk/util-base64-browser": "3.109.0",
|
|
43
43
|
"@aws-sdk/util-base64-node": "3.55.0",
|
|
44
44
|
"@aws-sdk/util-body-length-browser": "3.55.0",
|
|
45
45
|
"@aws-sdk/util-body-length-node": "3.55.0",
|
|
46
|
-
"@aws-sdk/util-defaults-mode-browser": "3.
|
|
47
|
-
"@aws-sdk/util-defaults-mode-node": "3.
|
|
48
|
-
"@aws-sdk/util-user-agent-browser": "3.
|
|
49
|
-
"@aws-sdk/util-user-agent-node": "3.
|
|
46
|
+
"@aws-sdk/util-defaults-mode-browser": "3.127.0",
|
|
47
|
+
"@aws-sdk/util-defaults-mode-node": "3.128.0",
|
|
48
|
+
"@aws-sdk/util-user-agent-browser": "3.127.0",
|
|
49
|
+
"@aws-sdk/util-user-agent-node": "3.127.0",
|
|
50
50
|
"@aws-sdk/util-utf8-browser": "3.109.0",
|
|
51
51
|
"@aws-sdk/util-utf8-node": "3.109.0",
|
|
52
52
|
"tslib": "^2.3.1",
|