@aws-sdk/client-resiliencehub 3.118.0 → 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.
@@ -15,9 +15,8 @@ const serializeAws_restJson1AddDraftAppVersionResourceMappingsCommand = async (i
15
15
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/add-draft-app-version-resource-mappings";
16
16
  let body;
17
17
  body = JSON.stringify({
18
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
19
- ...(input.resourceMappings !== undefined &&
20
- input.resourceMappings !== null && {
18
+ ...(input.appArn != null && { appArn: input.appArn }),
19
+ ...(input.resourceMappings != null && {
21
20
  resourceMappings: serializeAws_restJson1ResourceMappingList(input.resourceMappings, context),
22
21
  }),
23
22
  });
@@ -41,13 +40,12 @@ const serializeAws_restJson1CreateAppCommand = async (input, context) => {
41
40
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/create-app";
42
41
  let body;
43
42
  body = JSON.stringify({
44
- ...(input.assessmentSchedule !== undefined &&
45
- input.assessmentSchedule !== null && { assessmentSchedule: input.assessmentSchedule }),
43
+ ...(input.assessmentSchedule != null && { assessmentSchedule: input.assessmentSchedule }),
46
44
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
47
- ...(input.description !== undefined && input.description !== null && { description: input.description }),
48
- ...(input.name !== undefined && input.name !== null && { name: input.name }),
49
- ...(input.policyArn !== undefined && input.policyArn !== null && { policyArn: input.policyArn }),
50
- ...(input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
45
+ ...(input.description != null && { description: input.description }),
46
+ ...(input.name != null && { name: input.name }),
47
+ ...(input.policyArn != null && { policyArn: input.policyArn }),
48
+ ...(input.tags != null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
51
49
  });
52
50
  return new protocol_http_1.HttpRequest({
53
51
  protocol,
@@ -69,20 +67,18 @@ const serializeAws_restJson1CreateRecommendationTemplateCommand = async (input,
69
67
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/create-recommendation-template";
70
68
  let body;
71
69
  body = JSON.stringify({
72
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
73
- ...(input.bucketName !== undefined && input.bucketName !== null && { bucketName: input.bucketName }),
70
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
71
+ ...(input.bucketName != null && { bucketName: input.bucketName }),
74
72
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
75
- ...(input.format !== undefined && input.format !== null && { format: input.format }),
76
- ...(input.name !== undefined && input.name !== null && { name: input.name }),
77
- ...(input.recommendationIds !== undefined &&
78
- input.recommendationIds !== null && {
73
+ ...(input.format != null && { format: input.format }),
74
+ ...(input.name != null && { name: input.name }),
75
+ ...(input.recommendationIds != null && {
79
76
  recommendationIds: serializeAws_restJson1RecommendationIdList(input.recommendationIds, context),
80
77
  }),
81
- ...(input.recommendationTypes !== undefined &&
82
- input.recommendationTypes !== null && {
78
+ ...(input.recommendationTypes != null && {
83
79
  recommendationTypes: serializeAws_restJson1RenderRecommendationTypeList(input.recommendationTypes, context),
84
80
  }),
85
- ...(input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
81
+ ...(input.tags != null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
86
82
  });
87
83
  return new protocol_http_1.HttpRequest({
88
84
  protocol,
@@ -105,15 +101,12 @@ const serializeAws_restJson1CreateResiliencyPolicyCommand = async (input, contex
105
101
  let body;
106
102
  body = JSON.stringify({
107
103
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
108
- ...(input.dataLocationConstraint !== undefined &&
109
- input.dataLocationConstraint !== null && { dataLocationConstraint: input.dataLocationConstraint }),
110
- ...(input.policy !== undefined &&
111
- input.policy !== null && { policy: serializeAws_restJson1DisruptionPolicy(input.policy, context) }),
112
- ...(input.policyDescription !== undefined &&
113
- input.policyDescription !== null && { policyDescription: input.policyDescription }),
114
- ...(input.policyName !== undefined && input.policyName !== null && { policyName: input.policyName }),
115
- ...(input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
116
- ...(input.tier !== undefined && input.tier !== null && { tier: input.tier }),
104
+ ...(input.dataLocationConstraint != null && { dataLocationConstraint: input.dataLocationConstraint }),
105
+ ...(input.policy != null && { policy: serializeAws_restJson1DisruptionPolicy(input.policy, context) }),
106
+ ...(input.policyDescription != null && { policyDescription: input.policyDescription }),
107
+ ...(input.policyName != null && { policyName: input.policyName }),
108
+ ...(input.tags != null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
109
+ ...(input.tier != null && { tier: input.tier }),
117
110
  });
118
111
  return new protocol_http_1.HttpRequest({
119
112
  protocol,
@@ -135,9 +128,9 @@ const serializeAws_restJson1DeleteAppCommand = async (input, context) => {
135
128
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/delete-app";
136
129
  let body;
137
130
  body = JSON.stringify({
138
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
131
+ ...(input.appArn != null && { appArn: input.appArn }),
139
132
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
140
- ...(input.forceDelete !== undefined && input.forceDelete !== null && { forceDelete: input.forceDelete }),
133
+ ...(input.forceDelete != null && { forceDelete: input.forceDelete }),
141
134
  });
142
135
  return new protocol_http_1.HttpRequest({
143
136
  protocol,
@@ -159,7 +152,7 @@ const serializeAws_restJson1DeleteAppAssessmentCommand = async (input, context)
159
152
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/delete-app-assessment";
160
153
  let body;
161
154
  body = JSON.stringify({
162
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
155
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
163
156
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
164
157
  });
165
158
  return new protocol_http_1.HttpRequest({
@@ -183,8 +176,7 @@ const serializeAws_restJson1DeleteRecommendationTemplateCommand = async (input,
183
176
  let body;
184
177
  body = JSON.stringify({
185
178
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
186
- ...(input.recommendationTemplateArn !== undefined &&
187
- input.recommendationTemplateArn !== null && { recommendationTemplateArn: input.recommendationTemplateArn }),
179
+ ...(input.recommendationTemplateArn != null && { recommendationTemplateArn: input.recommendationTemplateArn }),
188
180
  });
189
181
  return new protocol_http_1.HttpRequest({
190
182
  protocol,
@@ -207,7 +199,7 @@ const serializeAws_restJson1DeleteResiliencyPolicyCommand = async (input, contex
207
199
  let body;
208
200
  body = JSON.stringify({
209
201
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
210
- ...(input.policyArn !== undefined && input.policyArn !== null && { policyArn: input.policyArn }),
202
+ ...(input.policyArn != null && { policyArn: input.policyArn }),
211
203
  });
212
204
  return new protocol_http_1.HttpRequest({
213
205
  protocol,
@@ -228,7 +220,7 @@ const serializeAws_restJson1DescribeAppCommand = async (input, context) => {
228
220
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/describe-app";
229
221
  let body;
230
222
  body = JSON.stringify({
231
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
223
+ ...(input.appArn != null && { appArn: input.appArn }),
232
224
  });
233
225
  return new protocol_http_1.HttpRequest({
234
226
  protocol,
@@ -249,7 +241,7 @@ const serializeAws_restJson1DescribeAppAssessmentCommand = async (input, context
249
241
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/describe-app-assessment";
250
242
  let body;
251
243
  body = JSON.stringify({
252
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
244
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
253
245
  });
254
246
  return new protocol_http_1.HttpRequest({
255
247
  protocol,
@@ -271,9 +263,9 @@ const serializeAws_restJson1DescribeAppVersionResourcesResolutionStatusCommand =
271
263
  "/describe-app-version-resources-resolution-status";
272
264
  let body;
273
265
  body = JSON.stringify({
274
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
275
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
276
- ...(input.resolutionId !== undefined && input.resolutionId !== null && { resolutionId: input.resolutionId }),
266
+ ...(input.appArn != null && { appArn: input.appArn }),
267
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
268
+ ...(input.resolutionId != null && { resolutionId: input.resolutionId }),
277
269
  });
278
270
  return new protocol_http_1.HttpRequest({
279
271
  protocol,
@@ -294,8 +286,8 @@ const serializeAws_restJson1DescribeAppVersionTemplateCommand = async (input, co
294
286
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/describe-app-version-template";
295
287
  let body;
296
288
  body = JSON.stringify({
297
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
298
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
289
+ ...(input.appArn != null && { appArn: input.appArn }),
290
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
299
291
  });
300
292
  return new protocol_http_1.HttpRequest({
301
293
  protocol,
@@ -317,7 +309,7 @@ const serializeAws_restJson1DescribeDraftAppVersionResourcesImportStatusCommand
317
309
  "/describe-draft-app-version-resources-import-status";
318
310
  let body;
319
311
  body = JSON.stringify({
320
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
312
+ ...(input.appArn != null && { appArn: input.appArn }),
321
313
  });
322
314
  return new protocol_http_1.HttpRequest({
323
315
  protocol,
@@ -338,7 +330,7 @@ const serializeAws_restJson1DescribeResiliencyPolicyCommand = async (input, cont
338
330
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/describe-resiliency-policy";
339
331
  let body;
340
332
  body = JSON.stringify({
341
- ...(input.policyArn !== undefined && input.policyArn !== null && { policyArn: input.policyArn }),
333
+ ...(input.policyArn != null && { policyArn: input.policyArn }),
342
334
  });
343
335
  return new protocol_http_1.HttpRequest({
344
336
  protocol,
@@ -359,11 +351,9 @@ const serializeAws_restJson1ImportResourcesToDraftAppVersionCommand = async (inp
359
351
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/import-resources-to-draft-app-version";
360
352
  let body;
361
353
  body = JSON.stringify({
362
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
363
- ...(input.sourceArns !== undefined &&
364
- input.sourceArns !== null && { sourceArns: serializeAws_restJson1ArnList(input.sourceArns, context) }),
365
- ...(input.terraformSources !== undefined &&
366
- input.terraformSources !== null && {
354
+ ...(input.appArn != null && { appArn: input.appArn }),
355
+ ...(input.sourceArns != null && { sourceArns: serializeAws_restJson1ArnList(input.sourceArns, context) }),
356
+ ...(input.terraformSources != null && {
367
357
  terraformSources: serializeAws_restJson1TerraformSourceList(input.terraformSources, context),
368
358
  }),
369
359
  });
@@ -386,9 +376,9 @@ const serializeAws_restJson1ListAlarmRecommendationsCommand = async (input, cont
386
376
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-alarm-recommendations";
387
377
  let body;
388
378
  body = JSON.stringify({
389
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
390
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
391
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
379
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
380
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
381
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
392
382
  });
393
383
  return new protocol_http_1.HttpRequest({
394
384
  protocol,
@@ -438,9 +428,9 @@ const serializeAws_restJson1ListAppComponentCompliancesCommand = async (input, c
438
428
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-app-component-compliances";
439
429
  let body;
440
430
  body = JSON.stringify({
441
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
442
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
443
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
431
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
432
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
433
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
444
434
  });
445
435
  return new protocol_http_1.HttpRequest({
446
436
  protocol,
@@ -461,9 +451,9 @@ const serializeAws_restJson1ListAppComponentRecommendationsCommand = async (inpu
461
451
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-app-component-recommendations";
462
452
  let body;
463
453
  body = JSON.stringify({
464
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
465
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
466
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
454
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
455
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
456
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
467
457
  });
468
458
  return new protocol_http_1.HttpRequest({
469
459
  protocol,
@@ -507,10 +497,10 @@ const serializeAws_restJson1ListAppVersionResourceMappingsCommand = async (input
507
497
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-app-version-resource-mappings";
508
498
  let body;
509
499
  body = JSON.stringify({
510
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
511
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
512
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
513
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
500
+ ...(input.appArn != null && { appArn: input.appArn }),
501
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
502
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
503
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
514
504
  });
515
505
  return new protocol_http_1.HttpRequest({
516
506
  protocol,
@@ -531,11 +521,11 @@ const serializeAws_restJson1ListAppVersionResourcesCommand = async (input, conte
531
521
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-app-version-resources";
532
522
  let body;
533
523
  body = JSON.stringify({
534
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
535
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
536
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
537
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
538
- ...(input.resolutionId !== undefined && input.resolutionId !== null && { resolutionId: input.resolutionId }),
524
+ ...(input.appArn != null && { appArn: input.appArn }),
525
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
526
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
527
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
528
+ ...(input.resolutionId != null && { resolutionId: input.resolutionId }),
539
529
  });
540
530
  return new protocol_http_1.HttpRequest({
541
531
  protocol,
@@ -556,9 +546,9 @@ const serializeAws_restJson1ListAppVersionsCommand = async (input, context) => {
556
546
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-app-versions";
557
547
  let body;
558
548
  body = JSON.stringify({
559
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
560
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
561
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
549
+ ...(input.appArn != null && { appArn: input.appArn }),
550
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
551
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
562
552
  });
563
553
  return new protocol_http_1.HttpRequest({
564
554
  protocol,
@@ -629,9 +619,9 @@ const serializeAws_restJson1ListSopRecommendationsCommand = async (input, contex
629
619
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-sop-recommendations";
630
620
  let body;
631
621
  body = JSON.stringify({
632
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
633
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
634
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
622
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
623
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
624
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
635
625
  });
636
626
  return new protocol_http_1.HttpRequest({
637
627
  protocol,
@@ -699,9 +689,9 @@ const serializeAws_restJson1ListTestRecommendationsCommand = async (input, conte
699
689
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-test-recommendations";
700
690
  let body;
701
691
  body = JSON.stringify({
702
- ...(input.assessmentArn !== undefined && input.assessmentArn !== null && { assessmentArn: input.assessmentArn }),
703
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
704
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
692
+ ...(input.assessmentArn != null && { assessmentArn: input.assessmentArn }),
693
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
694
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
705
695
  });
706
696
  return new protocol_http_1.HttpRequest({
707
697
  protocol,
@@ -722,11 +712,11 @@ const serializeAws_restJson1ListUnsupportedAppVersionResourcesCommand = async (i
722
712
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/list-unsupported-app-version-resources";
723
713
  let body;
724
714
  body = JSON.stringify({
725
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
726
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
727
- ...(input.maxResults !== undefined && input.maxResults !== null && { maxResults: input.maxResults }),
728
- ...(input.nextToken !== undefined && input.nextToken !== null && { nextToken: input.nextToken }),
729
- ...(input.resolutionId !== undefined && input.resolutionId !== null && { resolutionId: input.resolutionId }),
715
+ ...(input.appArn != null && { appArn: input.appArn }),
716
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
717
+ ...(input.maxResults != null && { maxResults: input.maxResults }),
718
+ ...(input.nextToken != null && { nextToken: input.nextToken }),
719
+ ...(input.resolutionId != null && { resolutionId: input.resolutionId }),
730
720
  });
731
721
  return new protocol_http_1.HttpRequest({
732
722
  protocol,
@@ -747,7 +737,7 @@ const serializeAws_restJson1PublishAppVersionCommand = async (input, context) =>
747
737
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/publish-app-version";
748
738
  let body;
749
739
  body = JSON.stringify({
750
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
740
+ ...(input.appArn != null && { appArn: input.appArn }),
751
741
  });
752
742
  return new protocol_http_1.HttpRequest({
753
743
  protocol,
@@ -768,9 +758,8 @@ const serializeAws_restJson1PutDraftAppVersionTemplateCommand = async (input, co
768
758
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/put-draft-app-version-template";
769
759
  let body;
770
760
  body = JSON.stringify({
771
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
772
- ...(input.appTemplateBody !== undefined &&
773
- input.appTemplateBody !== null && { appTemplateBody: input.appTemplateBody }),
761
+ ...(input.appArn != null && { appArn: input.appArn }),
762
+ ...(input.appTemplateBody != null && { appTemplateBody: input.appTemplateBody }),
774
763
  });
775
764
  return new protocol_http_1.HttpRequest({
776
765
  protocol,
@@ -792,25 +781,20 @@ const serializeAws_restJson1RemoveDraftAppVersionResourceMappingsCommand = async
792
781
  "/remove-draft-app-version-resource-mappings";
793
782
  let body;
794
783
  body = JSON.stringify({
795
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
796
- ...(input.appRegistryAppNames !== undefined &&
797
- input.appRegistryAppNames !== null && {
784
+ ...(input.appArn != null && { appArn: input.appArn }),
785
+ ...(input.appRegistryAppNames != null && {
798
786
  appRegistryAppNames: serializeAws_restJson1EntityNameList(input.appRegistryAppNames, context),
799
787
  }),
800
- ...(input.logicalStackNames !== undefined &&
801
- input.logicalStackNames !== null && {
788
+ ...(input.logicalStackNames != null && {
802
789
  logicalStackNames: serializeAws_restJson1String255List(input.logicalStackNames, context),
803
790
  }),
804
- ...(input.resourceGroupNames !== undefined &&
805
- input.resourceGroupNames !== null && {
791
+ ...(input.resourceGroupNames != null && {
806
792
  resourceGroupNames: serializeAws_restJson1EntityNameList(input.resourceGroupNames, context),
807
793
  }),
808
- ...(input.resourceNames !== undefined &&
809
- input.resourceNames !== null && {
794
+ ...(input.resourceNames != null && {
810
795
  resourceNames: serializeAws_restJson1EntityNameList(input.resourceNames, context),
811
796
  }),
812
- ...(input.terraformSourceNames !== undefined &&
813
- input.terraformSourceNames !== null && {
797
+ ...(input.terraformSourceNames != null && {
814
798
  terraformSourceNames: serializeAws_restJson1String255List(input.terraformSourceNames, context),
815
799
  }),
816
800
  });
@@ -833,8 +817,8 @@ const serializeAws_restJson1ResolveAppVersionResourcesCommand = async (input, co
833
817
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/resolve-app-version-resources";
834
818
  let body;
835
819
  body = JSON.stringify({
836
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
837
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
820
+ ...(input.appArn != null && { appArn: input.appArn }),
821
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
838
822
  });
839
823
  return new protocol_http_1.HttpRequest({
840
824
  protocol,
@@ -856,12 +840,11 @@ const serializeAws_restJson1StartAppAssessmentCommand = async (input, context) =
856
840
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/start-app-assessment";
857
841
  let body;
858
842
  body = JSON.stringify({
859
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
860
- ...(input.appVersion !== undefined && input.appVersion !== null && { appVersion: input.appVersion }),
861
- ...(input.assessmentName !== undefined &&
862
- input.assessmentName !== null && { assessmentName: input.assessmentName }),
843
+ ...(input.appArn != null && { appArn: input.appArn }),
844
+ ...(input.appVersion != null && { appVersion: input.appVersion }),
845
+ ...(input.assessmentName != null && { assessmentName: input.assessmentName }),
863
846
  clientToken: (_a = input.clientToken) !== null && _a !== void 0 ? _a : (0, uuid_1.v4)(),
864
- ...(input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
847
+ ...(input.tags != null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
865
848
  });
866
849
  return new protocol_http_1.HttpRequest({
867
850
  protocol,
@@ -892,7 +875,7 @@ const serializeAws_restJson1TagResourceCommand = async (input, context) => {
892
875
  }
893
876
  let body;
894
877
  body = JSON.stringify({
895
- ...(input.tags !== undefined && input.tags !== null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
878
+ ...(input.tags != null && { tags: serializeAws_restJson1TagMap(input.tags, context) }),
896
879
  });
897
880
  return new protocol_http_1.HttpRequest({
898
881
  protocol,
@@ -943,13 +926,11 @@ const serializeAws_restJson1UpdateAppCommand = async (input, context) => {
943
926
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/update-app";
944
927
  let body;
945
928
  body = JSON.stringify({
946
- ...(input.appArn !== undefined && input.appArn !== null && { appArn: input.appArn }),
947
- ...(input.assessmentSchedule !== undefined &&
948
- input.assessmentSchedule !== null && { assessmentSchedule: input.assessmentSchedule }),
949
- ...(input.clearResiliencyPolicyArn !== undefined &&
950
- input.clearResiliencyPolicyArn !== null && { clearResiliencyPolicyArn: input.clearResiliencyPolicyArn }),
951
- ...(input.description !== undefined && input.description !== null && { description: input.description }),
952
- ...(input.policyArn !== undefined && input.policyArn !== null && { policyArn: input.policyArn }),
929
+ ...(input.appArn != null && { appArn: input.appArn }),
930
+ ...(input.assessmentSchedule != null && { assessmentSchedule: input.assessmentSchedule }),
931
+ ...(input.clearResiliencyPolicyArn != null && { clearResiliencyPolicyArn: input.clearResiliencyPolicyArn }),
932
+ ...(input.description != null && { description: input.description }),
933
+ ...(input.policyArn != null && { policyArn: input.policyArn }),
953
934
  });
954
935
  return new protocol_http_1.HttpRequest({
955
936
  protocol,
@@ -970,15 +951,12 @@ const serializeAws_restJson1UpdateResiliencyPolicyCommand = async (input, contex
970
951
  const resolvedPath = `${(basePath === null || basePath === void 0 ? void 0 : basePath.endsWith("/")) ? basePath.slice(0, -1) : basePath || ""}` + "/update-resiliency-policy";
971
952
  let body;
972
953
  body = JSON.stringify({
973
- ...(input.dataLocationConstraint !== undefined &&
974
- input.dataLocationConstraint !== null && { dataLocationConstraint: input.dataLocationConstraint }),
975
- ...(input.policy !== undefined &&
976
- input.policy !== null && { policy: serializeAws_restJson1DisruptionPolicy(input.policy, context) }),
977
- ...(input.policyArn !== undefined && input.policyArn !== null && { policyArn: input.policyArn }),
978
- ...(input.policyDescription !== undefined &&
979
- input.policyDescription !== null && { policyDescription: input.policyDescription }),
980
- ...(input.policyName !== undefined && input.policyName !== null && { policyName: input.policyName }),
981
- ...(input.tier !== undefined && input.tier !== null && { tier: input.tier }),
954
+ ...(input.dataLocationConstraint != null && { dataLocationConstraint: input.dataLocationConstraint }),
955
+ ...(input.policy != null && { policy: serializeAws_restJson1DisruptionPolicy(input.policy, context) }),
956
+ ...(input.policyArn != null && { policyArn: input.policyArn }),
957
+ ...(input.policyDescription != null && { policyDescription: input.policyDescription }),
958
+ ...(input.policyName != null && { policyName: input.policyName }),
959
+ ...(input.tier != null && { tier: input.tier }),
982
960
  });
983
961
  return new protocol_http_1.HttpRequest({
984
962
  protocol,
@@ -1020,8 +998,7 @@ const deserializeAws_restJson1AddDraftAppVersionResourceMappingsCommandError = a
1020
998
  body: await parseBody(output.body, context),
1021
999
  };
1022
1000
  let response;
1023
- let errorCode = "UnknownError";
1024
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1001
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1025
1002
  switch (errorCode) {
1026
1003
  case "AccessDeniedException":
1027
1004
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1043,10 +1020,12 @@ const deserializeAws_restJson1AddDraftAppVersionResourceMappingsCommandError = a
1043
1020
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1044
1021
  default:
1045
1022
  const parsedBody = parsedOutput.body;
1023
+ const $metadata = deserializeMetadata(output);
1024
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1046
1025
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1047
- name: parsedBody.code || parsedBody.Code || errorCode,
1026
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1048
1027
  $fault: "client",
1049
- $metadata: deserializeMetadata(output),
1028
+ $metadata,
1050
1029
  });
1051
1030
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1052
1031
  }
@@ -1072,8 +1051,7 @@ const deserializeAws_restJson1CreateAppCommandError = async (output, context) =>
1072
1051
  body: await parseBody(output.body, context),
1073
1052
  };
1074
1053
  let response;
1075
- let errorCode = "UnknownError";
1076
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1054
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1077
1055
  switch (errorCode) {
1078
1056
  case "AccessDeniedException":
1079
1057
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1098,10 +1076,12 @@ const deserializeAws_restJson1CreateAppCommandError = async (output, context) =>
1098
1076
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1099
1077
  default:
1100
1078
  const parsedBody = parsedOutput.body;
1079
+ const $metadata = deserializeMetadata(output);
1080
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1101
1081
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1102
- name: parsedBody.code || parsedBody.Code || errorCode,
1082
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1103
1083
  $fault: "client",
1104
- $metadata: deserializeMetadata(output),
1084
+ $metadata,
1105
1085
  });
1106
1086
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1107
1087
  }
@@ -1127,8 +1107,7 @@ const deserializeAws_restJson1CreateRecommendationTemplateCommandError = async (
1127
1107
  body: await parseBody(output.body, context),
1128
1108
  };
1129
1109
  let response;
1130
- let errorCode = "UnknownError";
1131
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1110
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1132
1111
  switch (errorCode) {
1133
1112
  case "AccessDeniedException":
1134
1113
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1150,10 +1129,12 @@ const deserializeAws_restJson1CreateRecommendationTemplateCommandError = async (
1150
1129
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1151
1130
  default:
1152
1131
  const parsedBody = parsedOutput.body;
1132
+ const $metadata = deserializeMetadata(output);
1133
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1153
1134
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1154
- name: parsedBody.code || parsedBody.Code || errorCode,
1135
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1155
1136
  $fault: "client",
1156
- $metadata: deserializeMetadata(output),
1137
+ $metadata,
1157
1138
  });
1158
1139
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1159
1140
  }
@@ -1179,8 +1160,7 @@ const deserializeAws_restJson1CreateResiliencyPolicyCommandError = async (output
1179
1160
  body: await parseBody(output.body, context),
1180
1161
  };
1181
1162
  let response;
1182
- let errorCode = "UnknownError";
1183
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1163
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1184
1164
  switch (errorCode) {
1185
1165
  case "AccessDeniedException":
1186
1166
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1202,10 +1182,12 @@ const deserializeAws_restJson1CreateResiliencyPolicyCommandError = async (output
1202
1182
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1203
1183
  default:
1204
1184
  const parsedBody = parsedOutput.body;
1185
+ const $metadata = deserializeMetadata(output);
1186
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1205
1187
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1206
- name: parsedBody.code || parsedBody.Code || errorCode,
1188
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1207
1189
  $fault: "client",
1208
- $metadata: deserializeMetadata(output),
1190
+ $metadata,
1209
1191
  });
1210
1192
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1211
1193
  }
@@ -1231,8 +1213,7 @@ const deserializeAws_restJson1DeleteAppCommandError = async (output, context) =>
1231
1213
  body: await parseBody(output.body, context),
1232
1214
  };
1233
1215
  let response;
1234
- let errorCode = "UnknownError";
1235
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1216
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1236
1217
  switch (errorCode) {
1237
1218
  case "ConflictException":
1238
1219
  case "com.amazonaws.resiliencehub#ConflictException":
@@ -1251,10 +1232,12 @@ const deserializeAws_restJson1DeleteAppCommandError = async (output, context) =>
1251
1232
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1252
1233
  default:
1253
1234
  const parsedBody = parsedOutput.body;
1235
+ const $metadata = deserializeMetadata(output);
1236
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1254
1237
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1255
- name: parsedBody.code || parsedBody.Code || errorCode,
1238
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1256
1239
  $fault: "client",
1257
- $metadata: deserializeMetadata(output),
1240
+ $metadata,
1258
1241
  });
1259
1242
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1260
1243
  }
@@ -1284,8 +1267,7 @@ const deserializeAws_restJson1DeleteAppAssessmentCommandError = async (output, c
1284
1267
  body: await parseBody(output.body, context),
1285
1268
  };
1286
1269
  let response;
1287
- let errorCode = "UnknownError";
1288
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1270
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1289
1271
  switch (errorCode) {
1290
1272
  case "AccessDeniedException":
1291
1273
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1307,10 +1289,12 @@ const deserializeAws_restJson1DeleteAppAssessmentCommandError = async (output, c
1307
1289
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1308
1290
  default:
1309
1291
  const parsedBody = parsedOutput.body;
1292
+ const $metadata = deserializeMetadata(output);
1293
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1310
1294
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1311
- name: parsedBody.code || parsedBody.Code || errorCode,
1295
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1312
1296
  $fault: "client",
1313
- $metadata: deserializeMetadata(output),
1297
+ $metadata,
1314
1298
  });
1315
1299
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1316
1300
  }
@@ -1340,8 +1324,7 @@ const deserializeAws_restJson1DeleteRecommendationTemplateCommandError = async (
1340
1324
  body: await parseBody(output.body, context),
1341
1325
  };
1342
1326
  let response;
1343
- let errorCode = "UnknownError";
1344
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1327
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1345
1328
  switch (errorCode) {
1346
1329
  case "AccessDeniedException":
1347
1330
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1360,10 +1343,12 @@ const deserializeAws_restJson1DeleteRecommendationTemplateCommandError = async (
1360
1343
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1361
1344
  default:
1362
1345
  const parsedBody = parsedOutput.body;
1346
+ const $metadata = deserializeMetadata(output);
1347
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1363
1348
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1364
- name: parsedBody.code || parsedBody.Code || errorCode,
1349
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1365
1350
  $fault: "client",
1366
- $metadata: deserializeMetadata(output),
1351
+ $metadata,
1367
1352
  });
1368
1353
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1369
1354
  }
@@ -1389,8 +1374,7 @@ const deserializeAws_restJson1DeleteResiliencyPolicyCommandError = async (output
1389
1374
  body: await parseBody(output.body, context),
1390
1375
  };
1391
1376
  let response;
1392
- let errorCode = "UnknownError";
1393
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1377
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1394
1378
  switch (errorCode) {
1395
1379
  case "AccessDeniedException":
1396
1380
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1412,10 +1396,12 @@ const deserializeAws_restJson1DeleteResiliencyPolicyCommandError = async (output
1412
1396
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1413
1397
  default:
1414
1398
  const parsedBody = parsedOutput.body;
1399
+ const $metadata = deserializeMetadata(output);
1400
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1415
1401
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1416
- name: parsedBody.code || parsedBody.Code || errorCode,
1402
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1417
1403
  $fault: "client",
1418
- $metadata: deserializeMetadata(output),
1404
+ $metadata,
1419
1405
  });
1420
1406
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1421
1407
  }
@@ -1441,8 +1427,7 @@ const deserializeAws_restJson1DescribeAppCommandError = async (output, context)
1441
1427
  body: await parseBody(output.body, context),
1442
1428
  };
1443
1429
  let response;
1444
- let errorCode = "UnknownError";
1445
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1430
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1446
1431
  switch (errorCode) {
1447
1432
  case "AccessDeniedException":
1448
1433
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1461,10 +1446,12 @@ const deserializeAws_restJson1DescribeAppCommandError = async (output, context)
1461
1446
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1462
1447
  default:
1463
1448
  const parsedBody = parsedOutput.body;
1449
+ const $metadata = deserializeMetadata(output);
1450
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1464
1451
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1465
- name: parsedBody.code || parsedBody.Code || errorCode,
1452
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1466
1453
  $fault: "client",
1467
- $metadata: deserializeMetadata(output),
1454
+ $metadata,
1468
1455
  });
1469
1456
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1470
1457
  }
@@ -1490,8 +1477,7 @@ const deserializeAws_restJson1DescribeAppAssessmentCommandError = async (output,
1490
1477
  body: await parseBody(output.body, context),
1491
1478
  };
1492
1479
  let response;
1493
- let errorCode = "UnknownError";
1494
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1480
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1495
1481
  switch (errorCode) {
1496
1482
  case "AccessDeniedException":
1497
1483
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1510,10 +1496,12 @@ const deserializeAws_restJson1DescribeAppAssessmentCommandError = async (output,
1510
1496
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1511
1497
  default:
1512
1498
  const parsedBody = parsedOutput.body;
1499
+ const $metadata = deserializeMetadata(output);
1500
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1513
1501
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1514
- name: parsedBody.code || parsedBody.Code || errorCode,
1502
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1515
1503
  $fault: "client",
1516
- $metadata: deserializeMetadata(output),
1504
+ $metadata,
1517
1505
  });
1518
1506
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1519
1507
  }
@@ -1555,8 +1543,7 @@ const deserializeAws_restJson1DescribeAppVersionResourcesResolutionStatusCommand
1555
1543
  body: await parseBody(output.body, context),
1556
1544
  };
1557
1545
  let response;
1558
- let errorCode = "UnknownError";
1559
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1546
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1560
1547
  switch (errorCode) {
1561
1548
  case "AccessDeniedException":
1562
1549
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1575,10 +1562,12 @@ const deserializeAws_restJson1DescribeAppVersionResourcesResolutionStatusCommand
1575
1562
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1576
1563
  default:
1577
1564
  const parsedBody = parsedOutput.body;
1565
+ const $metadata = deserializeMetadata(output);
1566
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1578
1567
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1579
- name: parsedBody.code || parsedBody.Code || errorCode,
1568
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1580
1569
  $fault: "client",
1581
- $metadata: deserializeMetadata(output),
1570
+ $metadata,
1582
1571
  });
1583
1572
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1584
1573
  }
@@ -1612,8 +1601,7 @@ const deserializeAws_restJson1DescribeAppVersionTemplateCommandError = async (ou
1612
1601
  body: await parseBody(output.body, context),
1613
1602
  };
1614
1603
  let response;
1615
- let errorCode = "UnknownError";
1616
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1604
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1617
1605
  switch (errorCode) {
1618
1606
  case "AccessDeniedException":
1619
1607
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1632,10 +1620,12 @@ const deserializeAws_restJson1DescribeAppVersionTemplateCommandError = async (ou
1632
1620
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1633
1621
  default:
1634
1622
  const parsedBody = parsedOutput.body;
1623
+ const $metadata = deserializeMetadata(output);
1624
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1635
1625
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1636
- name: parsedBody.code || parsedBody.Code || errorCode,
1626
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1637
1627
  $fault: "client",
1638
- $metadata: deserializeMetadata(output),
1628
+ $metadata,
1639
1629
  });
1640
1630
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1641
1631
  }
@@ -1677,8 +1667,7 @@ const deserializeAws_restJson1DescribeDraftAppVersionResourcesImportStatusComman
1677
1667
  body: await parseBody(output.body, context),
1678
1668
  };
1679
1669
  let response;
1680
- let errorCode = "UnknownError";
1681
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1670
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1682
1671
  switch (errorCode) {
1683
1672
  case "AccessDeniedException":
1684
1673
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1697,10 +1686,12 @@ const deserializeAws_restJson1DescribeDraftAppVersionResourcesImportStatusComman
1697
1686
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1698
1687
  default:
1699
1688
  const parsedBody = parsedOutput.body;
1689
+ const $metadata = deserializeMetadata(output);
1690
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1700
1691
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1701
- name: parsedBody.code || parsedBody.Code || errorCode,
1692
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1702
1693
  $fault: "client",
1703
- $metadata: deserializeMetadata(output),
1694
+ $metadata,
1704
1695
  });
1705
1696
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1706
1697
  }
@@ -1726,8 +1717,7 @@ const deserializeAws_restJson1DescribeResiliencyPolicyCommandError = async (outp
1726
1717
  body: await parseBody(output.body, context),
1727
1718
  };
1728
1719
  let response;
1729
- let errorCode = "UnknownError";
1730
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1720
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1731
1721
  switch (errorCode) {
1732
1722
  case "AccessDeniedException":
1733
1723
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1746,10 +1736,12 @@ const deserializeAws_restJson1DescribeResiliencyPolicyCommandError = async (outp
1746
1736
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1747
1737
  default:
1748
1738
  const parsedBody = parsedOutput.body;
1739
+ const $metadata = deserializeMetadata(output);
1740
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1749
1741
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1750
- name: parsedBody.code || parsedBody.Code || errorCode,
1742
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1751
1743
  $fault: "client",
1752
- $metadata: deserializeMetadata(output),
1744
+ $metadata,
1753
1745
  });
1754
1746
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1755
1747
  }
@@ -1791,8 +1783,7 @@ const deserializeAws_restJson1ImportResourcesToDraftAppVersionCommandError = asy
1791
1783
  body: await parseBody(output.body, context),
1792
1784
  };
1793
1785
  let response;
1794
- let errorCode = "UnknownError";
1795
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1786
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1796
1787
  switch (errorCode) {
1797
1788
  case "AccessDeniedException":
1798
1789
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1814,10 +1805,12 @@ const deserializeAws_restJson1ImportResourcesToDraftAppVersionCommandError = asy
1814
1805
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1815
1806
  default:
1816
1807
  const parsedBody = parsedOutput.body;
1808
+ const $metadata = deserializeMetadata(output);
1809
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1817
1810
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1818
- name: parsedBody.code || parsedBody.Code || errorCode,
1811
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1819
1812
  $fault: "client",
1820
- $metadata: deserializeMetadata(output),
1813
+ $metadata,
1821
1814
  });
1822
1815
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1823
1816
  }
@@ -1847,8 +1840,7 @@ const deserializeAws_restJson1ListAlarmRecommendationsCommandError = async (outp
1847
1840
  body: await parseBody(output.body, context),
1848
1841
  };
1849
1842
  let response;
1850
- let errorCode = "UnknownError";
1851
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1843
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1852
1844
  switch (errorCode) {
1853
1845
  case "AccessDeniedException":
1854
1846
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1867,10 +1859,12 @@ const deserializeAws_restJson1ListAlarmRecommendationsCommandError = async (outp
1867
1859
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1868
1860
  default:
1869
1861
  const parsedBody = parsedOutput.body;
1862
+ const $metadata = deserializeMetadata(output);
1863
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1870
1864
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1871
- name: parsedBody.code || parsedBody.Code || errorCode,
1865
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1872
1866
  $fault: "client",
1873
- $metadata: deserializeMetadata(output),
1867
+ $metadata,
1874
1868
  });
1875
1869
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1876
1870
  }
@@ -1900,8 +1894,7 @@ const deserializeAws_restJson1ListAppAssessmentsCommandError = async (output, co
1900
1894
  body: await parseBody(output.body, context),
1901
1895
  };
1902
1896
  let response;
1903
- let errorCode = "UnknownError";
1904
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1897
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1905
1898
  switch (errorCode) {
1906
1899
  case "AccessDeniedException":
1907
1900
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1920,10 +1913,12 @@ const deserializeAws_restJson1ListAppAssessmentsCommandError = async (output, co
1920
1913
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1921
1914
  default:
1922
1915
  const parsedBody = parsedOutput.body;
1916
+ const $metadata = deserializeMetadata(output);
1917
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1923
1918
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1924
- name: parsedBody.code || parsedBody.Code || errorCode,
1919
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1925
1920
  $fault: "client",
1926
- $metadata: deserializeMetadata(output),
1921
+ $metadata,
1927
1922
  });
1928
1923
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1929
1924
  }
@@ -1953,8 +1948,7 @@ const deserializeAws_restJson1ListAppComponentCompliancesCommandError = async (o
1953
1948
  body: await parseBody(output.body, context),
1954
1949
  };
1955
1950
  let response;
1956
- let errorCode = "UnknownError";
1957
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1951
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
1958
1952
  switch (errorCode) {
1959
1953
  case "AccessDeniedException":
1960
1954
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -1973,10 +1967,12 @@ const deserializeAws_restJson1ListAppComponentCompliancesCommandError = async (o
1973
1967
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
1974
1968
  default:
1975
1969
  const parsedBody = parsedOutput.body;
1970
+ const $metadata = deserializeMetadata(output);
1971
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
1976
1972
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
1977
- name: parsedBody.code || parsedBody.Code || errorCode,
1973
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
1978
1974
  $fault: "client",
1979
- $metadata: deserializeMetadata(output),
1975
+ $metadata,
1980
1976
  });
1981
1977
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
1982
1978
  }
@@ -2006,8 +2002,7 @@ const deserializeAws_restJson1ListAppComponentRecommendationsCommandError = asyn
2006
2002
  body: await parseBody(output.body, context),
2007
2003
  };
2008
2004
  let response;
2009
- let errorCode = "UnknownError";
2010
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2005
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2011
2006
  switch (errorCode) {
2012
2007
  case "AccessDeniedException":
2013
2008
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2026,10 +2021,12 @@ const deserializeAws_restJson1ListAppComponentRecommendationsCommandError = asyn
2026
2021
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2027
2022
  default:
2028
2023
  const parsedBody = parsedOutput.body;
2024
+ const $metadata = deserializeMetadata(output);
2025
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2029
2026
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2030
- name: parsedBody.code || parsedBody.Code || errorCode,
2027
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2031
2028
  $fault: "client",
2032
- $metadata: deserializeMetadata(output),
2029
+ $metadata,
2033
2030
  });
2034
2031
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2035
2032
  }
@@ -2059,8 +2056,7 @@ const deserializeAws_restJson1ListAppsCommandError = async (output, context) =>
2059
2056
  body: await parseBody(output.body, context),
2060
2057
  };
2061
2058
  let response;
2062
- let errorCode = "UnknownError";
2063
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2059
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2064
2060
  switch (errorCode) {
2065
2061
  case "AccessDeniedException":
2066
2062
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2076,10 +2072,12 @@ const deserializeAws_restJson1ListAppsCommandError = async (output, context) =>
2076
2072
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2077
2073
  default:
2078
2074
  const parsedBody = parsedOutput.body;
2075
+ const $metadata = deserializeMetadata(output);
2076
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2079
2077
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2080
- name: parsedBody.code || parsedBody.Code || errorCode,
2078
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2081
2079
  $fault: "client",
2082
- $metadata: deserializeMetadata(output),
2080
+ $metadata,
2083
2081
  });
2084
2082
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2085
2083
  }
@@ -2109,8 +2107,7 @@ const deserializeAws_restJson1ListAppVersionResourceMappingsCommandError = async
2109
2107
  body: await parseBody(output.body, context),
2110
2108
  };
2111
2109
  let response;
2112
- let errorCode = "UnknownError";
2113
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2110
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2114
2111
  switch (errorCode) {
2115
2112
  case "AccessDeniedException":
2116
2113
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2129,10 +2126,12 @@ const deserializeAws_restJson1ListAppVersionResourceMappingsCommandError = async
2129
2126
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2130
2127
  default:
2131
2128
  const parsedBody = parsedOutput.body;
2129
+ const $metadata = deserializeMetadata(output);
2130
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2132
2131
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2133
- name: parsedBody.code || parsedBody.Code || errorCode,
2132
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2134
2133
  $fault: "client",
2135
- $metadata: deserializeMetadata(output),
2134
+ $metadata,
2136
2135
  });
2137
2136
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2138
2137
  }
@@ -2166,8 +2165,7 @@ const deserializeAws_restJson1ListAppVersionResourcesCommandError = async (outpu
2166
2165
  body: await parseBody(output.body, context),
2167
2166
  };
2168
2167
  let response;
2169
- let errorCode = "UnknownError";
2170
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2168
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2171
2169
  switch (errorCode) {
2172
2170
  case "AccessDeniedException":
2173
2171
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2189,10 +2187,12 @@ const deserializeAws_restJson1ListAppVersionResourcesCommandError = async (outpu
2189
2187
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2190
2188
  default:
2191
2189
  const parsedBody = parsedOutput.body;
2190
+ const $metadata = deserializeMetadata(output);
2191
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2192
2192
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2193
- name: parsedBody.code || parsedBody.Code || errorCode,
2193
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2194
2194
  $fault: "client",
2195
- $metadata: deserializeMetadata(output),
2195
+ $metadata,
2196
2196
  });
2197
2197
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2198
2198
  }
@@ -2222,8 +2222,7 @@ const deserializeAws_restJson1ListAppVersionsCommandError = async (output, conte
2222
2222
  body: await parseBody(output.body, context),
2223
2223
  };
2224
2224
  let response;
2225
- let errorCode = "UnknownError";
2226
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2225
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2227
2226
  switch (errorCode) {
2228
2227
  case "AccessDeniedException":
2229
2228
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2239,10 +2238,12 @@ const deserializeAws_restJson1ListAppVersionsCommandError = async (output, conte
2239
2238
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2240
2239
  default:
2241
2240
  const parsedBody = parsedOutput.body;
2241
+ const $metadata = deserializeMetadata(output);
2242
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2242
2243
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2243
- name: parsedBody.code || parsedBody.Code || errorCode,
2244
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2244
2245
  $fault: "client",
2245
- $metadata: deserializeMetadata(output),
2246
+ $metadata,
2246
2247
  });
2247
2248
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2248
2249
  }
@@ -2272,8 +2273,7 @@ const deserializeAws_restJson1ListRecommendationTemplatesCommandError = async (o
2272
2273
  body: await parseBody(output.body, context),
2273
2274
  };
2274
2275
  let response;
2275
- let errorCode = "UnknownError";
2276
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2276
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2277
2277
  switch (errorCode) {
2278
2278
  case "AccessDeniedException":
2279
2279
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2289,10 +2289,12 @@ const deserializeAws_restJson1ListRecommendationTemplatesCommandError = async (o
2289
2289
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2290
2290
  default:
2291
2291
  const parsedBody = parsedOutput.body;
2292
+ const $metadata = deserializeMetadata(output);
2293
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2292
2294
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2293
- name: parsedBody.code || parsedBody.Code || errorCode,
2295
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2294
2296
  $fault: "client",
2295
- $metadata: deserializeMetadata(output),
2297
+ $metadata,
2296
2298
  });
2297
2299
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2298
2300
  }
@@ -2322,8 +2324,7 @@ const deserializeAws_restJson1ListResiliencyPoliciesCommandError = async (output
2322
2324
  body: await parseBody(output.body, context),
2323
2325
  };
2324
2326
  let response;
2325
- let errorCode = "UnknownError";
2326
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2327
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2327
2328
  switch (errorCode) {
2328
2329
  case "AccessDeniedException":
2329
2330
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2342,10 +2343,12 @@ const deserializeAws_restJson1ListResiliencyPoliciesCommandError = async (output
2342
2343
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2343
2344
  default:
2344
2345
  const parsedBody = parsedOutput.body;
2346
+ const $metadata = deserializeMetadata(output);
2347
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2345
2348
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2346
- name: parsedBody.code || parsedBody.Code || errorCode,
2349
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2347
2350
  $fault: "client",
2348
- $metadata: deserializeMetadata(output),
2351
+ $metadata,
2349
2352
  });
2350
2353
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2351
2354
  }
@@ -2375,8 +2378,7 @@ const deserializeAws_restJson1ListSopRecommendationsCommandError = async (output
2375
2378
  body: await parseBody(output.body, context),
2376
2379
  };
2377
2380
  let response;
2378
- let errorCode = "UnknownError";
2379
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2381
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2380
2382
  switch (errorCode) {
2381
2383
  case "AccessDeniedException":
2382
2384
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2398,10 +2400,12 @@ const deserializeAws_restJson1ListSopRecommendationsCommandError = async (output
2398
2400
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2399
2401
  default:
2400
2402
  const parsedBody = parsedOutput.body;
2403
+ const $metadata = deserializeMetadata(output);
2404
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2401
2405
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2402
- name: parsedBody.code || parsedBody.Code || errorCode,
2406
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2403
2407
  $fault: "client",
2404
- $metadata: deserializeMetadata(output),
2408
+ $metadata,
2405
2409
  });
2406
2410
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2407
2411
  }
@@ -2431,8 +2435,7 @@ const deserializeAws_restJson1ListSuggestedResiliencyPoliciesCommandError = asyn
2431
2435
  body: await parseBody(output.body, context),
2432
2436
  };
2433
2437
  let response;
2434
- let errorCode = "UnknownError";
2435
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2438
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2436
2439
  switch (errorCode) {
2437
2440
  case "AccessDeniedException":
2438
2441
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2451,10 +2454,12 @@ const deserializeAws_restJson1ListSuggestedResiliencyPoliciesCommandError = asyn
2451
2454
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2452
2455
  default:
2453
2456
  const parsedBody = parsedOutput.body;
2457
+ const $metadata = deserializeMetadata(output);
2458
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2454
2459
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2455
- name: parsedBody.code || parsedBody.Code || errorCode,
2460
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2456
2461
  $fault: "client",
2457
- $metadata: deserializeMetadata(output),
2462
+ $metadata,
2458
2463
  });
2459
2464
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2460
2465
  }
@@ -2480,8 +2485,7 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
2480
2485
  body: await parseBody(output.body, context),
2481
2486
  };
2482
2487
  let response;
2483
- let errorCode = "UnknownError";
2484
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2488
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2485
2489
  switch (errorCode) {
2486
2490
  case "AccessDeniedException":
2487
2491
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2500,10 +2504,12 @@ const deserializeAws_restJson1ListTagsForResourceCommandError = async (output, c
2500
2504
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2501
2505
  default:
2502
2506
  const parsedBody = parsedOutput.body;
2507
+ const $metadata = deserializeMetadata(output);
2508
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2503
2509
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2504
- name: parsedBody.code || parsedBody.Code || errorCode,
2510
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2505
2511
  $fault: "client",
2506
- $metadata: deserializeMetadata(output),
2512
+ $metadata,
2507
2513
  });
2508
2514
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2509
2515
  }
@@ -2533,8 +2539,7 @@ const deserializeAws_restJson1ListTestRecommendationsCommandError = async (outpu
2533
2539
  body: await parseBody(output.body, context),
2534
2540
  };
2535
2541
  let response;
2536
- let errorCode = "UnknownError";
2537
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2542
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2538
2543
  switch (errorCode) {
2539
2544
  case "AccessDeniedException":
2540
2545
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2556,10 +2561,12 @@ const deserializeAws_restJson1ListTestRecommendationsCommandError = async (outpu
2556
2561
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2557
2562
  default:
2558
2563
  const parsedBody = parsedOutput.body;
2564
+ const $metadata = deserializeMetadata(output);
2565
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2559
2566
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2560
- name: parsedBody.code || parsedBody.Code || errorCode,
2567
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2561
2568
  $fault: "client",
2562
- $metadata: deserializeMetadata(output),
2569
+ $metadata,
2563
2570
  });
2564
2571
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2565
2572
  }
@@ -2593,8 +2600,7 @@ const deserializeAws_restJson1ListUnsupportedAppVersionResourcesCommandError = a
2593
2600
  body: await parseBody(output.body, context),
2594
2601
  };
2595
2602
  let response;
2596
- let errorCode = "UnknownError";
2597
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2603
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2598
2604
  switch (errorCode) {
2599
2605
  case "AccessDeniedException":
2600
2606
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2616,10 +2622,12 @@ const deserializeAws_restJson1ListUnsupportedAppVersionResourcesCommandError = a
2616
2622
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2617
2623
  default:
2618
2624
  const parsedBody = parsedOutput.body;
2625
+ const $metadata = deserializeMetadata(output);
2626
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2619
2627
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2620
- name: parsedBody.code || parsedBody.Code || errorCode,
2628
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2621
2629
  $fault: "client",
2622
- $metadata: deserializeMetadata(output),
2630
+ $metadata,
2623
2631
  });
2624
2632
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2625
2633
  }
@@ -2649,8 +2657,7 @@ const deserializeAws_restJson1PublishAppVersionCommandError = async (output, con
2649
2657
  body: await parseBody(output.body, context),
2650
2658
  };
2651
2659
  let response;
2652
- let errorCode = "UnknownError";
2653
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2660
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2654
2661
  switch (errorCode) {
2655
2662
  case "AccessDeniedException":
2656
2663
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2672,10 +2679,12 @@ const deserializeAws_restJson1PublishAppVersionCommandError = async (output, con
2672
2679
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2673
2680
  default:
2674
2681
  const parsedBody = parsedOutput.body;
2682
+ const $metadata = deserializeMetadata(output);
2683
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2675
2684
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2676
- name: parsedBody.code || parsedBody.Code || errorCode,
2685
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2677
2686
  $fault: "client",
2678
- $metadata: deserializeMetadata(output),
2687
+ $metadata,
2679
2688
  });
2680
2689
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2681
2690
  }
@@ -2705,8 +2714,7 @@ const deserializeAws_restJson1PutDraftAppVersionTemplateCommandError = async (ou
2705
2714
  body: await parseBody(output.body, context),
2706
2715
  };
2707
2716
  let response;
2708
- let errorCode = "UnknownError";
2709
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2717
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2710
2718
  switch (errorCode) {
2711
2719
  case "AccessDeniedException":
2712
2720
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2728,10 +2736,12 @@ const deserializeAws_restJson1PutDraftAppVersionTemplateCommandError = async (ou
2728
2736
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2729
2737
  default:
2730
2738
  const parsedBody = parsedOutput.body;
2739
+ const $metadata = deserializeMetadata(output);
2740
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2731
2741
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2732
- name: parsedBody.code || parsedBody.Code || errorCode,
2742
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2733
2743
  $fault: "client",
2734
- $metadata: deserializeMetadata(output),
2744
+ $metadata,
2735
2745
  });
2736
2746
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2737
2747
  }
@@ -2761,8 +2771,7 @@ const deserializeAws_restJson1RemoveDraftAppVersionResourceMappingsCommandError
2761
2771
  body: await parseBody(output.body, context),
2762
2772
  };
2763
2773
  let response;
2764
- let errorCode = "UnknownError";
2765
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2774
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2766
2775
  switch (errorCode) {
2767
2776
  case "AccessDeniedException":
2768
2777
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2784,10 +2793,12 @@ const deserializeAws_restJson1RemoveDraftAppVersionResourceMappingsCommandError
2784
2793
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2785
2794
  default:
2786
2795
  const parsedBody = parsedOutput.body;
2796
+ const $metadata = deserializeMetadata(output);
2797
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2787
2798
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2788
- name: parsedBody.code || parsedBody.Code || errorCode,
2799
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2789
2800
  $fault: "client",
2790
- $metadata: deserializeMetadata(output),
2801
+ $metadata,
2791
2802
  });
2792
2803
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2793
2804
  }
@@ -2825,8 +2836,7 @@ const deserializeAws_restJson1ResolveAppVersionResourcesCommandError = async (ou
2825
2836
  body: await parseBody(output.body, context),
2826
2837
  };
2827
2838
  let response;
2828
- let errorCode = "UnknownError";
2829
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2839
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2830
2840
  switch (errorCode) {
2831
2841
  case "AccessDeniedException":
2832
2842
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2848,10 +2858,12 @@ const deserializeAws_restJson1ResolveAppVersionResourcesCommandError = async (ou
2848
2858
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2849
2859
  default:
2850
2860
  const parsedBody = parsedOutput.body;
2861
+ const $metadata = deserializeMetadata(output);
2862
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2851
2863
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2852
- name: parsedBody.code || parsedBody.Code || errorCode,
2864
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2853
2865
  $fault: "client",
2854
- $metadata: deserializeMetadata(output),
2866
+ $metadata,
2855
2867
  });
2856
2868
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2857
2869
  }
@@ -2877,8 +2889,7 @@ const deserializeAws_restJson1StartAppAssessmentCommandError = async (output, co
2877
2889
  body: await parseBody(output.body, context),
2878
2890
  };
2879
2891
  let response;
2880
- let errorCode = "UnknownError";
2881
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2892
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2882
2893
  switch (errorCode) {
2883
2894
  case "AccessDeniedException":
2884
2895
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2903,10 +2914,12 @@ const deserializeAws_restJson1StartAppAssessmentCommandError = async (output, co
2903
2914
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2904
2915
  default:
2905
2916
  const parsedBody = parsedOutput.body;
2917
+ const $metadata = deserializeMetadata(output);
2918
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2906
2919
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2907
- name: parsedBody.code || parsedBody.Code || errorCode,
2920
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2908
2921
  $fault: "client",
2909
- $metadata: deserializeMetadata(output),
2922
+ $metadata,
2910
2923
  });
2911
2924
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2912
2925
  }
@@ -2928,8 +2941,7 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
2928
2941
  body: await parseBody(output.body, context),
2929
2942
  };
2930
2943
  let response;
2931
- let errorCode = "UnknownError";
2932
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2944
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2933
2945
  switch (errorCode) {
2934
2946
  case "AccessDeniedException":
2935
2947
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2948,10 +2960,12 @@ const deserializeAws_restJson1TagResourceCommandError = async (output, context)
2948
2960
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2949
2961
  default:
2950
2962
  const parsedBody = parsedOutput.body;
2963
+ const $metadata = deserializeMetadata(output);
2964
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2951
2965
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2952
- name: parsedBody.code || parsedBody.Code || errorCode,
2966
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2953
2967
  $fault: "client",
2954
- $metadata: deserializeMetadata(output),
2968
+ $metadata,
2955
2969
  });
2956
2970
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
2957
2971
  }
@@ -2973,8 +2987,7 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
2973
2987
  body: await parseBody(output.body, context),
2974
2988
  };
2975
2989
  let response;
2976
- let errorCode = "UnknownError";
2977
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2990
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
2978
2991
  switch (errorCode) {
2979
2992
  case "AccessDeniedException":
2980
2993
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -2993,10 +3006,12 @@ const deserializeAws_restJson1UntagResourceCommandError = async (output, context
2993
3006
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
2994
3007
  default:
2995
3008
  const parsedBody = parsedOutput.body;
3009
+ const $metadata = deserializeMetadata(output);
3010
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
2996
3011
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
2997
- name: parsedBody.code || parsedBody.Code || errorCode,
3012
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
2998
3013
  $fault: "client",
2999
- $metadata: deserializeMetadata(output),
3014
+ $metadata,
3000
3015
  });
3001
3016
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
3002
3017
  }
@@ -3022,8 +3037,7 @@ const deserializeAws_restJson1UpdateAppCommandError = async (output, context) =>
3022
3037
  body: await parseBody(output.body, context),
3023
3038
  };
3024
3039
  let response;
3025
- let errorCode = "UnknownError";
3026
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3040
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3027
3041
  switch (errorCode) {
3028
3042
  case "AccessDeniedException":
3029
3043
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -3045,10 +3059,12 @@ const deserializeAws_restJson1UpdateAppCommandError = async (output, context) =>
3045
3059
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
3046
3060
  default:
3047
3061
  const parsedBody = parsedOutput.body;
3062
+ const $metadata = deserializeMetadata(output);
3063
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
3048
3064
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
3049
- name: parsedBody.code || parsedBody.Code || errorCode,
3065
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
3050
3066
  $fault: "client",
3051
- $metadata: deserializeMetadata(output),
3067
+ $metadata,
3052
3068
  });
3053
3069
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
3054
3070
  }
@@ -3074,8 +3090,7 @@ const deserializeAws_restJson1UpdateResiliencyPolicyCommandError = async (output
3074
3090
  body: await parseBody(output.body, context),
3075
3091
  };
3076
3092
  let response;
3077
- let errorCode = "UnknownError";
3078
- errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3093
+ const errorCode = loadRestJsonErrorCode(output, parsedOutput.body);
3079
3094
  switch (errorCode) {
3080
3095
  case "AccessDeniedException":
3081
3096
  case "com.amazonaws.resiliencehub#AccessDeniedException":
@@ -3097,10 +3112,12 @@ const deserializeAws_restJson1UpdateResiliencyPolicyCommandError = async (output
3097
3112
  throw await deserializeAws_restJson1ValidationExceptionResponse(parsedOutput, context);
3098
3113
  default:
3099
3114
  const parsedBody = parsedOutput.body;
3115
+ const $metadata = deserializeMetadata(output);
3116
+ const statusCode = $metadata.httpStatusCode ? $metadata.httpStatusCode + "" : undefined;
3100
3117
  response = new ResiliencehubServiceException_1.ResiliencehubServiceException({
3101
- name: parsedBody.code || parsedBody.Code || errorCode,
3118
+ name: parsedBody.code || parsedBody.Code || errorCode || statusCode || "UnknowError",
3102
3119
  $fault: "client",
3103
- $metadata: deserializeMetadata(output),
3120
+ $metadata,
3104
3121
  });
3105
3122
  throw (0, smithy_client_1.decorateServiceException)(response, parsedBody);
3106
3123
  }
@@ -3237,16 +3254,16 @@ const serializeAws_restJson1EntityNameList = (input, context) => {
3237
3254
  };
3238
3255
  const serializeAws_restJson1FailurePolicy = (input, context) => {
3239
3256
  return {
3240
- ...(input.rpoInSecs !== undefined && input.rpoInSecs !== null && { rpoInSecs: input.rpoInSecs }),
3241
- ...(input.rtoInSecs !== undefined && input.rtoInSecs !== null && { rtoInSecs: input.rtoInSecs }),
3257
+ ...(input.rpoInSecs != null && { rpoInSecs: input.rpoInSecs }),
3258
+ ...(input.rtoInSecs != null && { rtoInSecs: input.rtoInSecs }),
3242
3259
  };
3243
3260
  };
3244
3261
  const serializeAws_restJson1PhysicalResourceId = (input, context) => {
3245
3262
  return {
3246
- ...(input.awsAccountId !== undefined && input.awsAccountId !== null && { awsAccountId: input.awsAccountId }),
3247
- ...(input.awsRegion !== undefined && input.awsRegion !== null && { awsRegion: input.awsRegion }),
3248
- ...(input.identifier !== undefined && input.identifier !== null && { identifier: input.identifier }),
3249
- ...(input.type !== undefined && input.type !== null && { type: input.type }),
3263
+ ...(input.awsAccountId != null && { awsAccountId: input.awsAccountId }),
3264
+ ...(input.awsRegion != null && { awsRegion: input.awsRegion }),
3265
+ ...(input.identifier != null && { identifier: input.identifier }),
3266
+ ...(input.type != null && { type: input.type }),
3250
3267
  };
3251
3268
  };
3252
3269
  const serializeAws_restJson1RecommendationIdList = (input, context) => {
@@ -3271,20 +3288,15 @@ const serializeAws_restJson1RenderRecommendationTypeList = (input, context) => {
3271
3288
  };
3272
3289
  const serializeAws_restJson1ResourceMapping = (input, context) => {
3273
3290
  return {
3274
- ...(input.appRegistryAppName !== undefined &&
3275
- input.appRegistryAppName !== null && { appRegistryAppName: input.appRegistryAppName }),
3276
- ...(input.logicalStackName !== undefined &&
3277
- input.logicalStackName !== null && { logicalStackName: input.logicalStackName }),
3278
- ...(input.mappingType !== undefined && input.mappingType !== null && { mappingType: input.mappingType }),
3279
- ...(input.physicalResourceId !== undefined &&
3280
- input.physicalResourceId !== null && {
3291
+ ...(input.appRegistryAppName != null && { appRegistryAppName: input.appRegistryAppName }),
3292
+ ...(input.logicalStackName != null && { logicalStackName: input.logicalStackName }),
3293
+ ...(input.mappingType != null && { mappingType: input.mappingType }),
3294
+ ...(input.physicalResourceId != null && {
3281
3295
  physicalResourceId: serializeAws_restJson1PhysicalResourceId(input.physicalResourceId, context),
3282
3296
  }),
3283
- ...(input.resourceGroupName !== undefined &&
3284
- input.resourceGroupName !== null && { resourceGroupName: input.resourceGroupName }),
3285
- ...(input.resourceName !== undefined && input.resourceName !== null && { resourceName: input.resourceName }),
3286
- ...(input.terraformSourceName !== undefined &&
3287
- input.terraformSourceName !== null && { terraformSourceName: input.terraformSourceName }),
3297
+ ...(input.resourceGroupName != null && { resourceGroupName: input.resourceGroupName }),
3298
+ ...(input.resourceName != null && { resourceName: input.resourceName }),
3299
+ ...(input.terraformSourceName != null && { terraformSourceName: input.terraformSourceName }),
3288
3300
  };
3289
3301
  };
3290
3302
  const serializeAws_restJson1ResourceMappingList = (input, context) => {
@@ -3320,8 +3332,7 @@ const serializeAws_restJson1TagMap = (input, context) => {
3320
3332
  };
3321
3333
  const serializeAws_restJson1TerraformSource = (input, context) => {
3322
3334
  return {
3323
- ...(input.s3StateFileUrl !== undefined &&
3324
- input.s3StateFileUrl !== null && { s3StateFileUrl: input.s3StateFileUrl }),
3335
+ ...(input.s3StateFileUrl != null && { s3StateFileUrl: input.s3StateFileUrl }),
3325
3336
  };
3326
3337
  };
3327
3338
  const serializeAws_restJson1TerraformSourceList = (input, context) => {
@@ -3338,9 +3349,7 @@ const deserializeAws_restJson1AlarmRecommendation = (output, context) => {
3338
3349
  return {
3339
3350
  appComponentName: (0, smithy_client_1.expectString)(output.appComponentName),
3340
3351
  description: (0, smithy_client_1.expectString)(output.description),
3341
- items: output.items !== undefined && output.items !== null
3342
- ? deserializeAws_restJson1RecommendationItemList(output.items, context)
3343
- : undefined,
3352
+ items: output.items != null ? deserializeAws_restJson1RecommendationItemList(output.items, context) : undefined,
3344
3353
  name: (0, smithy_client_1.expectString)(output.name),
3345
3354
  prerequisite: (0, smithy_client_1.expectString)(output.prerequisite),
3346
3355
  recommendationId: (0, smithy_client_1.expectString)(output.recommendationId),
@@ -3375,23 +3384,21 @@ const deserializeAws_restJson1App = (output, context) => {
3375
3384
  appArn: (0, smithy_client_1.expectString)(output.appArn),
3376
3385
  assessmentSchedule: (0, smithy_client_1.expectString)(output.assessmentSchedule),
3377
3386
  complianceStatus: (0, smithy_client_1.expectString)(output.complianceStatus),
3378
- creationTime: output.creationTime !== undefined && output.creationTime !== null
3387
+ creationTime: output.creationTime != null
3379
3388
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.creationTime)))
3380
3389
  : undefined,
3381
3390
  description: (0, smithy_client_1.expectString)(output.description),
3382
- lastAppComplianceEvaluationTime: output.lastAppComplianceEvaluationTime !== undefined && output.lastAppComplianceEvaluationTime !== null
3391
+ lastAppComplianceEvaluationTime: output.lastAppComplianceEvaluationTime != null
3383
3392
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.lastAppComplianceEvaluationTime)))
3384
3393
  : undefined,
3385
- lastResiliencyScoreEvaluationTime: output.lastResiliencyScoreEvaluationTime !== undefined && output.lastResiliencyScoreEvaluationTime !== null
3394
+ lastResiliencyScoreEvaluationTime: output.lastResiliencyScoreEvaluationTime != null
3386
3395
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.lastResiliencyScoreEvaluationTime)))
3387
3396
  : undefined,
3388
3397
  name: (0, smithy_client_1.expectString)(output.name),
3389
3398
  policyArn: (0, smithy_client_1.expectString)(output.policyArn),
3390
3399
  resiliencyScore: (0, smithy_client_1.limitedParseDouble)(output.resiliencyScore),
3391
3400
  status: (0, smithy_client_1.expectString)(output.status),
3392
- tags: output.tags !== undefined && output.tags !== null
3393
- ? deserializeAws_restJson1TagMap(output.tags, context)
3394
- : undefined,
3401
+ tags: output.tags != null ? deserializeAws_restJson1TagMap(output.tags, context) : undefined,
3395
3402
  };
3396
3403
  };
3397
3404
  const deserializeAws_restJson1AppAssessment = (output, context) => {
@@ -3401,33 +3408,21 @@ const deserializeAws_restJson1AppAssessment = (output, context) => {
3401
3408
  assessmentArn: (0, smithy_client_1.expectString)(output.assessmentArn),
3402
3409
  assessmentName: (0, smithy_client_1.expectString)(output.assessmentName),
3403
3410
  assessmentStatus: (0, smithy_client_1.expectString)(output.assessmentStatus),
3404
- compliance: output.compliance !== undefined && output.compliance !== null
3405
- ? deserializeAws_restJson1AssessmentCompliance(output.compliance, context)
3406
- : undefined,
3411
+ compliance: output.compliance != null ? deserializeAws_restJson1AssessmentCompliance(output.compliance, context) : undefined,
3407
3412
  complianceStatus: (0, smithy_client_1.expectString)(output.complianceStatus),
3408
- cost: output.cost !== undefined && output.cost !== null
3409
- ? deserializeAws_restJson1Cost(output.cost, context)
3410
- : undefined,
3411
- endTime: output.endTime !== undefined && output.endTime !== null
3412
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.endTime)))
3413
- : undefined,
3413
+ cost: output.cost != null ? deserializeAws_restJson1Cost(output.cost, context) : undefined,
3414
+ endTime: output.endTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.endTime))) : undefined,
3414
3415
  invoker: (0, smithy_client_1.expectString)(output.invoker),
3415
3416
  message: (0, smithy_client_1.expectString)(output.message),
3416
- policy: output.policy !== undefined && output.policy !== null
3417
- ? deserializeAws_restJson1ResiliencyPolicy(output.policy, context)
3418
- : undefined,
3419
- resiliencyScore: output.resiliencyScore !== undefined && output.resiliencyScore !== null
3417
+ policy: output.policy != null ? deserializeAws_restJson1ResiliencyPolicy(output.policy, context) : undefined,
3418
+ resiliencyScore: output.resiliencyScore != null
3420
3419
  ? deserializeAws_restJson1ResiliencyScore(output.resiliencyScore, context)
3421
3420
  : undefined,
3422
- resourceErrorsDetails: output.resourceErrorsDetails !== undefined && output.resourceErrorsDetails !== null
3421
+ resourceErrorsDetails: output.resourceErrorsDetails != null
3423
3422
  ? deserializeAws_restJson1ResourceErrorsDetails(output.resourceErrorsDetails, context)
3424
3423
  : undefined,
3425
- startTime: output.startTime !== undefined && output.startTime !== null
3426
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.startTime)))
3427
- : undefined,
3428
- tags: output.tags !== undefined && output.tags !== null
3429
- ? deserializeAws_restJson1TagMap(output.tags, context)
3430
- : undefined,
3424
+ startTime: output.startTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.startTime))) : undefined,
3425
+ tags: output.tags != null ? deserializeAws_restJson1TagMap(output.tags, context) : undefined,
3431
3426
  };
3432
3427
  };
3433
3428
  const deserializeAws_restJson1AppAssessmentSummary = (output, context) => {
@@ -3438,18 +3433,12 @@ const deserializeAws_restJson1AppAssessmentSummary = (output, context) => {
3438
3433
  assessmentName: (0, smithy_client_1.expectString)(output.assessmentName),
3439
3434
  assessmentStatus: (0, smithy_client_1.expectString)(output.assessmentStatus),
3440
3435
  complianceStatus: (0, smithy_client_1.expectString)(output.complianceStatus),
3441
- cost: output.cost !== undefined && output.cost !== null
3442
- ? deserializeAws_restJson1Cost(output.cost, context)
3443
- : undefined,
3444
- endTime: output.endTime !== undefined && output.endTime !== null
3445
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.endTime)))
3446
- : undefined,
3436
+ cost: output.cost != null ? deserializeAws_restJson1Cost(output.cost, context) : undefined,
3437
+ endTime: output.endTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.endTime))) : undefined,
3447
3438
  invoker: (0, smithy_client_1.expectString)(output.invoker),
3448
3439
  message: (0, smithy_client_1.expectString)(output.message),
3449
3440
  resiliencyScore: (0, smithy_client_1.limitedParseDouble)(output.resiliencyScore),
3450
- startTime: output.startTime !== undefined && output.startTime !== null
3451
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.startTime)))
3452
- : undefined,
3441
+ startTime: output.startTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.startTime))) : undefined,
3453
3442
  };
3454
3443
  };
3455
3444
  const deserializeAws_restJson1AppAssessmentSummaryList = (output, context) => {
@@ -3472,14 +3461,10 @@ const deserializeAws_restJson1AppComponent = (output, context) => {
3472
3461
  const deserializeAws_restJson1AppComponentCompliance = (output, context) => {
3473
3462
  return {
3474
3463
  appComponentName: (0, smithy_client_1.expectString)(output.appComponentName),
3475
- compliance: output.compliance !== undefined && output.compliance !== null
3476
- ? deserializeAws_restJson1AssessmentCompliance(output.compliance, context)
3477
- : undefined,
3478
- cost: output.cost !== undefined && output.cost !== null
3479
- ? deserializeAws_restJson1Cost(output.cost, context)
3480
- : undefined,
3464
+ compliance: output.compliance != null ? deserializeAws_restJson1AssessmentCompliance(output.compliance, context) : undefined,
3465
+ cost: output.cost != null ? deserializeAws_restJson1Cost(output.cost, context) : undefined,
3481
3466
  message: (0, smithy_client_1.expectString)(output.message),
3482
- resiliencyScore: output.resiliencyScore !== undefined && output.resiliencyScore !== null
3467
+ resiliencyScore: output.resiliencyScore != null
3483
3468
  ? deserializeAws_restJson1ResiliencyScore(output.resiliencyScore, context)
3484
3469
  : undefined,
3485
3470
  status: (0, smithy_client_1.expectString)(output.status),
@@ -3501,7 +3486,7 @@ const deserializeAws_restJson1AppSummary = (output, context) => {
3501
3486
  appArn: (0, smithy_client_1.expectString)(output.appArn),
3502
3487
  assessmentSchedule: (0, smithy_client_1.expectString)(output.assessmentSchedule),
3503
3488
  complianceStatus: (0, smithy_client_1.expectString)(output.complianceStatus),
3504
- creationTime: output.creationTime !== undefined && output.creationTime !== null
3489
+ creationTime: output.creationTime != null
3505
3490
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.creationTime)))
3506
3491
  : undefined,
3507
3492
  description: (0, smithy_client_1.expectString)(output.description),
@@ -3572,7 +3557,7 @@ const deserializeAws_restJson1ComponentCompliancesList = (output, context) => {
3572
3557
  const deserializeAws_restJson1ComponentRecommendation = (output, context) => {
3573
3558
  return {
3574
3559
  appComponentName: (0, smithy_client_1.expectString)(output.appComponentName),
3575
- configRecommendations: output.configRecommendations !== undefined && output.configRecommendations !== null
3560
+ configRecommendations: output.configRecommendations != null
3576
3561
  ? deserializeAws_restJson1ConfigRecommendationList(output.configRecommendations, context)
3577
3562
  : undefined,
3578
3563
  recommendationStatus: (0, smithy_client_1.expectString)(output.recommendationStatus),
@@ -3592,21 +3577,17 @@ const deserializeAws_restJson1ComponentRecommendationList = (output, context) =>
3592
3577
  const deserializeAws_restJson1ConfigRecommendation = (output, context) => {
3593
3578
  return {
3594
3579
  appComponentName: (0, smithy_client_1.expectString)(output.appComponentName),
3595
- compliance: output.compliance !== undefined && output.compliance !== null
3596
- ? deserializeAws_restJson1AssessmentCompliance(output.compliance, context)
3597
- : undefined,
3598
- cost: output.cost !== undefined && output.cost !== null
3599
- ? deserializeAws_restJson1Cost(output.cost, context)
3600
- : undefined,
3580
+ compliance: output.compliance != null ? deserializeAws_restJson1AssessmentCompliance(output.compliance, context) : undefined,
3581
+ cost: output.cost != null ? deserializeAws_restJson1Cost(output.cost, context) : undefined,
3601
3582
  description: (0, smithy_client_1.expectString)(output.description),
3602
3583
  haArchitecture: (0, smithy_client_1.expectString)(output.haArchitecture),
3603
3584
  name: (0, smithy_client_1.expectString)(output.name),
3604
3585
  optimizationType: (0, smithy_client_1.expectString)(output.optimizationType),
3605
- recommendationCompliance: output.recommendationCompliance !== undefined && output.recommendationCompliance !== null
3586
+ recommendationCompliance: output.recommendationCompliance != null
3606
3587
  ? deserializeAws_restJson1RecommendationCompliance(output.recommendationCompliance, context)
3607
3588
  : undefined,
3608
3589
  referenceId: (0, smithy_client_1.expectString)(output.referenceId),
3609
- suggestedChanges: output.suggestedChanges !== undefined && output.suggestedChanges !== null
3590
+ suggestedChanges: output.suggestedChanges != null
3610
3591
  ? deserializeAws_restJson1SuggestedChangesList(output.suggestedChanges, context)
3611
3592
  : undefined,
3612
3593
  };
@@ -3681,13 +3662,13 @@ const deserializeAws_restJson1LogicalResourceId = (output, context) => {
3681
3662
  };
3682
3663
  const deserializeAws_restJson1PhysicalResource = (output, context) => {
3683
3664
  return {
3684
- appComponents: output.appComponents !== undefined && output.appComponents !== null
3665
+ appComponents: output.appComponents != null
3685
3666
  ? deserializeAws_restJson1AppComponentList(output.appComponents, context)
3686
3667
  : undefined,
3687
- logicalResourceId: output.logicalResourceId !== undefined && output.logicalResourceId !== null
3668
+ logicalResourceId: output.logicalResourceId != null
3688
3669
  ? deserializeAws_restJson1LogicalResourceId(output.logicalResourceId, context)
3689
3670
  : undefined,
3690
- physicalResourceId: output.physicalResourceId !== undefined && output.physicalResourceId !== null
3671
+ physicalResourceId: output.physicalResourceId != null
3691
3672
  ? deserializeAws_restJson1PhysicalResourceId(output.physicalResourceId, context)
3692
3673
  : undefined,
3693
3674
  resourceName: (0, smithy_client_1.expectString)(output.resourceName),
@@ -3767,28 +3748,22 @@ const deserializeAws_restJson1RecommendationTemplate = (output, context) => {
3767
3748
  return {
3768
3749
  appArn: (0, smithy_client_1.expectString)(output.appArn),
3769
3750
  assessmentArn: (0, smithy_client_1.expectString)(output.assessmentArn),
3770
- endTime: output.endTime !== undefined && output.endTime !== null
3771
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.endTime)))
3772
- : undefined,
3751
+ endTime: output.endTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.endTime))) : undefined,
3773
3752
  format: (0, smithy_client_1.expectString)(output.format),
3774
3753
  message: (0, smithy_client_1.expectString)(output.message),
3775
3754
  name: (0, smithy_client_1.expectString)(output.name),
3776
3755
  needsReplacements: (0, smithy_client_1.expectBoolean)(output.needsReplacements),
3777
- recommendationIds: output.recommendationIds !== undefined && output.recommendationIds !== null
3756
+ recommendationIds: output.recommendationIds != null
3778
3757
  ? deserializeAws_restJson1RecommendationIdList(output.recommendationIds, context)
3779
3758
  : undefined,
3780
3759
  recommendationTemplateArn: (0, smithy_client_1.expectString)(output.recommendationTemplateArn),
3781
- recommendationTypes: output.recommendationTypes !== undefined && output.recommendationTypes !== null
3760
+ recommendationTypes: output.recommendationTypes != null
3782
3761
  ? deserializeAws_restJson1RenderRecommendationTypeList(output.recommendationTypes, context)
3783
3762
  : undefined,
3784
- startTime: output.startTime !== undefined && output.startTime !== null
3785
- ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.startTime)))
3786
- : undefined,
3763
+ startTime: output.startTime != null ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.startTime))) : undefined,
3787
3764
  status: (0, smithy_client_1.expectString)(output.status),
3788
- tags: output.tags !== undefined && output.tags !== null
3789
- ? deserializeAws_restJson1TagMap(output.tags, context)
3790
- : undefined,
3791
- templatesLocation: output.templatesLocation !== undefined && output.templatesLocation !== null
3765
+ tags: output.tags != null ? deserializeAws_restJson1TagMap(output.tags, context) : undefined,
3766
+ templatesLocation: output.templatesLocation != null
3792
3767
  ? deserializeAws_restJson1S3Location(output.templatesLocation, context)
3793
3768
  : undefined,
3794
3769
  };
@@ -3828,26 +3803,22 @@ const deserializeAws_restJson1ResiliencyPolicies = (output, context) => {
3828
3803
  };
3829
3804
  const deserializeAws_restJson1ResiliencyPolicy = (output, context) => {
3830
3805
  return {
3831
- creationTime: output.creationTime !== undefined && output.creationTime !== null
3806
+ creationTime: output.creationTime != null
3832
3807
  ? (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(output.creationTime)))
3833
3808
  : undefined,
3834
3809
  dataLocationConstraint: (0, smithy_client_1.expectString)(output.dataLocationConstraint),
3835
3810
  estimatedCostTier: (0, smithy_client_1.expectString)(output.estimatedCostTier),
3836
- policy: output.policy !== undefined && output.policy !== null
3837
- ? deserializeAws_restJson1DisruptionPolicy(output.policy, context)
3838
- : undefined,
3811
+ policy: output.policy != null ? deserializeAws_restJson1DisruptionPolicy(output.policy, context) : undefined,
3839
3812
  policyArn: (0, smithy_client_1.expectString)(output.policyArn),
3840
3813
  policyDescription: (0, smithy_client_1.expectString)(output.policyDescription),
3841
3814
  policyName: (0, smithy_client_1.expectString)(output.policyName),
3842
- tags: output.tags !== undefined && output.tags !== null
3843
- ? deserializeAws_restJson1TagMap(output.tags, context)
3844
- : undefined,
3815
+ tags: output.tags != null ? deserializeAws_restJson1TagMap(output.tags, context) : undefined,
3845
3816
  tier: (0, smithy_client_1.expectString)(output.tier),
3846
3817
  };
3847
3818
  };
3848
3819
  const deserializeAws_restJson1ResiliencyScore = (output, context) => {
3849
3820
  return {
3850
- disruptionScore: output.disruptionScore !== undefined && output.disruptionScore !== null
3821
+ disruptionScore: output.disruptionScore != null
3851
3822
  ? deserializeAws_restJson1DisruptionResiliencyScore(output.disruptionScore, context)
3852
3823
  : undefined,
3853
3824
  score: (0, smithy_client_1.limitedParseDouble)(output.score),
@@ -3874,7 +3845,7 @@ const deserializeAws_restJson1ResourceErrorList = (output, context) => {
3874
3845
  const deserializeAws_restJson1ResourceErrorsDetails = (output, context) => {
3875
3846
  return {
3876
3847
  hasMoreErrors: (0, smithy_client_1.expectBoolean)(output.hasMoreErrors),
3877
- resourceErrors: output.resourceErrors !== undefined && output.resourceErrors !== null
3848
+ resourceErrors: output.resourceErrors != null
3878
3849
  ? deserializeAws_restJson1ResourceErrorList(output.resourceErrors, context)
3879
3850
  : undefined,
3880
3851
  };
@@ -3884,7 +3855,7 @@ const deserializeAws_restJson1ResourceMapping = (output, context) => {
3884
3855
  appRegistryAppName: (0, smithy_client_1.expectString)(output.appRegistryAppName),
3885
3856
  logicalStackName: (0, smithy_client_1.expectString)(output.logicalStackName),
3886
3857
  mappingType: (0, smithy_client_1.expectString)(output.mappingType),
3887
- physicalResourceId: output.physicalResourceId !== undefined && output.physicalResourceId !== null
3858
+ physicalResourceId: output.physicalResourceId != null
3888
3859
  ? deserializeAws_restJson1PhysicalResourceId(output.physicalResourceId, context)
3889
3860
  : undefined,
3890
3861
  resourceGroupName: (0, smithy_client_1.expectString)(output.resourceGroupName),
@@ -3913,9 +3884,7 @@ const deserializeAws_restJson1SopRecommendation = (output, context) => {
3913
3884
  return {
3914
3885
  appComponentName: (0, smithy_client_1.expectString)(output.appComponentName),
3915
3886
  description: (0, smithy_client_1.expectString)(output.description),
3916
- items: output.items !== undefined && output.items !== null
3917
- ? deserializeAws_restJson1RecommendationItemList(output.items, context)
3918
- : undefined,
3887
+ items: output.items != null ? deserializeAws_restJson1RecommendationItemList(output.items, context) : undefined,
3919
3888
  name: (0, smithy_client_1.expectString)(output.name),
3920
3889
  prerequisite: (0, smithy_client_1.expectString)(output.prerequisite),
3921
3890
  recommendationId: (0, smithy_client_1.expectString)(output.recommendationId),
@@ -3975,14 +3944,12 @@ const deserializeAws_restJson1TerraformSourceList = (output, context) => {
3975
3944
  const deserializeAws_restJson1TestRecommendation = (output, context) => {
3976
3945
  return {
3977
3946
  appComponentName: (0, smithy_client_1.expectString)(output.appComponentName),
3978
- dependsOnAlarms: output.dependsOnAlarms !== undefined && output.dependsOnAlarms !== null
3947
+ dependsOnAlarms: output.dependsOnAlarms != null
3979
3948
  ? deserializeAws_restJson1AlarmReferenceIdList(output.dependsOnAlarms, context)
3980
3949
  : undefined,
3981
3950
  description: (0, smithy_client_1.expectString)(output.description),
3982
3951
  intent: (0, smithy_client_1.expectString)(output.intent),
3983
- items: output.items !== undefined && output.items !== null
3984
- ? deserializeAws_restJson1RecommendationItemList(output.items, context)
3985
- : undefined,
3952
+ items: output.items != null ? deserializeAws_restJson1RecommendationItemList(output.items, context) : undefined,
3986
3953
  name: (0, smithy_client_1.expectString)(output.name),
3987
3954
  prerequisite: (0, smithy_client_1.expectString)(output.prerequisite),
3988
3955
  recommendationId: (0, smithy_client_1.expectString)(output.recommendationId),
@@ -4004,10 +3971,10 @@ const deserializeAws_restJson1TestRecommendationList = (output, context) => {
4004
3971
  };
4005
3972
  const deserializeAws_restJson1UnsupportedResource = (output, context) => {
4006
3973
  return {
4007
- logicalResourceId: output.logicalResourceId !== undefined && output.logicalResourceId !== null
3974
+ logicalResourceId: output.logicalResourceId != null
4008
3975
  ? deserializeAws_restJson1LogicalResourceId(output.logicalResourceId, context)
4009
3976
  : undefined,
4010
- physicalResourceId: output.physicalResourceId !== undefined && output.physicalResourceId !== null
3977
+ physicalResourceId: output.physicalResourceId != null
4011
3978
  ? deserializeAws_restJson1PhysicalResourceId(output.physicalResourceId, context)
4012
3979
  : undefined,
4013
3980
  resourceType: (0, smithy_client_1.expectString)(output.resourceType),
@@ -4073,5 +4040,4 @@ const loadRestJsonErrorCode = (output, data) => {
4073
4040
  if (data["__type"] !== undefined) {
4074
4041
  return sanitizeErrorCode(data["__type"]);
4075
4042
  }
4076
- return "";
4077
4043
  };