@aws-sdk/client-cloudhsm-v2 3.312.0 → 3.316.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-cjs/CloudHSMV2.js +19 -210
- package/dist-cjs/protocols/Aws_json1_1.js +121 -427
- package/dist-es/CloudHSMV2.js +19 -210
- package/dist-es/protocols/Aws_json1_1.js +122 -428
- package/dist-types/CloudHSMV2.d.ts +23 -62
- package/dist-types/ts3.4/CloudHSMV2.d.ts +4 -1
- package/package.json +6 -6
|
@@ -8,105 +8,105 @@ const models_0_1 = require("../models/models_0");
|
|
|
8
8
|
const se_CopyBackupToRegionCommand = async (input, context) => {
|
|
9
9
|
const headers = sharedHeaders("CopyBackupToRegion");
|
|
10
10
|
let body;
|
|
11
|
-
body = JSON.stringify(
|
|
11
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
12
12
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
13
13
|
};
|
|
14
14
|
exports.se_CopyBackupToRegionCommand = se_CopyBackupToRegionCommand;
|
|
15
15
|
const se_CreateClusterCommand = async (input, context) => {
|
|
16
16
|
const headers = sharedHeaders("CreateCluster");
|
|
17
17
|
let body;
|
|
18
|
-
body = JSON.stringify(
|
|
18
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
19
19
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
20
20
|
};
|
|
21
21
|
exports.se_CreateClusterCommand = se_CreateClusterCommand;
|
|
22
22
|
const se_CreateHsmCommand = async (input, context) => {
|
|
23
23
|
const headers = sharedHeaders("CreateHsm");
|
|
24
24
|
let body;
|
|
25
|
-
body = JSON.stringify(
|
|
25
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
26
26
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
27
27
|
};
|
|
28
28
|
exports.se_CreateHsmCommand = se_CreateHsmCommand;
|
|
29
29
|
const se_DeleteBackupCommand = async (input, context) => {
|
|
30
30
|
const headers = sharedHeaders("DeleteBackup");
|
|
31
31
|
let body;
|
|
32
|
-
body = JSON.stringify(
|
|
32
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
33
33
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
34
34
|
};
|
|
35
35
|
exports.se_DeleteBackupCommand = se_DeleteBackupCommand;
|
|
36
36
|
const se_DeleteClusterCommand = async (input, context) => {
|
|
37
37
|
const headers = sharedHeaders("DeleteCluster");
|
|
38
38
|
let body;
|
|
39
|
-
body = JSON.stringify(
|
|
39
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
40
40
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
41
41
|
};
|
|
42
42
|
exports.se_DeleteClusterCommand = se_DeleteClusterCommand;
|
|
43
43
|
const se_DeleteHsmCommand = async (input, context) => {
|
|
44
44
|
const headers = sharedHeaders("DeleteHsm");
|
|
45
45
|
let body;
|
|
46
|
-
body = JSON.stringify(
|
|
46
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
47
47
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
48
48
|
};
|
|
49
49
|
exports.se_DeleteHsmCommand = se_DeleteHsmCommand;
|
|
50
50
|
const se_DescribeBackupsCommand = async (input, context) => {
|
|
51
51
|
const headers = sharedHeaders("DescribeBackups");
|
|
52
52
|
let body;
|
|
53
|
-
body = JSON.stringify(
|
|
53
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
54
54
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
55
55
|
};
|
|
56
56
|
exports.se_DescribeBackupsCommand = se_DescribeBackupsCommand;
|
|
57
57
|
const se_DescribeClustersCommand = async (input, context) => {
|
|
58
58
|
const headers = sharedHeaders("DescribeClusters");
|
|
59
59
|
let body;
|
|
60
|
-
body = JSON.stringify(
|
|
60
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
61
61
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
62
62
|
};
|
|
63
63
|
exports.se_DescribeClustersCommand = se_DescribeClustersCommand;
|
|
64
64
|
const se_InitializeClusterCommand = async (input, context) => {
|
|
65
65
|
const headers = sharedHeaders("InitializeCluster");
|
|
66
66
|
let body;
|
|
67
|
-
body = JSON.stringify(
|
|
67
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
68
68
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
69
69
|
};
|
|
70
70
|
exports.se_InitializeClusterCommand = se_InitializeClusterCommand;
|
|
71
71
|
const se_ListTagsCommand = async (input, context) => {
|
|
72
72
|
const headers = sharedHeaders("ListTags");
|
|
73
73
|
let body;
|
|
74
|
-
body = JSON.stringify(
|
|
74
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
75
75
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
76
76
|
};
|
|
77
77
|
exports.se_ListTagsCommand = se_ListTagsCommand;
|
|
78
78
|
const se_ModifyBackupAttributesCommand = async (input, context) => {
|
|
79
79
|
const headers = sharedHeaders("ModifyBackupAttributes");
|
|
80
80
|
let body;
|
|
81
|
-
body = JSON.stringify(
|
|
81
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
82
82
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
83
83
|
};
|
|
84
84
|
exports.se_ModifyBackupAttributesCommand = se_ModifyBackupAttributesCommand;
|
|
85
85
|
const se_ModifyClusterCommand = async (input, context) => {
|
|
86
86
|
const headers = sharedHeaders("ModifyCluster");
|
|
87
87
|
let body;
|
|
88
|
-
body = JSON.stringify(
|
|
88
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
89
89
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
90
90
|
};
|
|
91
91
|
exports.se_ModifyClusterCommand = se_ModifyClusterCommand;
|
|
92
92
|
const se_RestoreBackupCommand = async (input, context) => {
|
|
93
93
|
const headers = sharedHeaders("RestoreBackup");
|
|
94
94
|
let body;
|
|
95
|
-
body = JSON.stringify(
|
|
95
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
96
96
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
97
97
|
};
|
|
98
98
|
exports.se_RestoreBackupCommand = se_RestoreBackupCommand;
|
|
99
99
|
const se_TagResourceCommand = async (input, context) => {
|
|
100
100
|
const headers = sharedHeaders("TagResource");
|
|
101
101
|
let body;
|
|
102
|
-
body = JSON.stringify(
|
|
102
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
103
103
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
104
104
|
};
|
|
105
105
|
exports.se_TagResourceCommand = se_TagResourceCommand;
|
|
106
106
|
const se_UntagResourceCommand = async (input, context) => {
|
|
107
107
|
const headers = sharedHeaders("UntagResource");
|
|
108
108
|
let body;
|
|
109
|
-
body = JSON.stringify(
|
|
109
|
+
body = JSON.stringify((0, smithy_client_1._json)(input));
|
|
110
110
|
return buildHttpRpcRequest(context, headers, "/", undefined, body);
|
|
111
111
|
};
|
|
112
112
|
exports.se_UntagResourceCommand = se_UntagResourceCommand;
|
|
@@ -121,7 +121,7 @@ const de_CopyBackupToRegionCommand = async (output, context) => {
|
|
|
121
121
|
$metadata: deserializeMetadata(output),
|
|
122
122
|
...contents,
|
|
123
123
|
};
|
|
124
|
-
return
|
|
124
|
+
return response;
|
|
125
125
|
};
|
|
126
126
|
exports.de_CopyBackupToRegionCommand = de_CopyBackupToRegionCommand;
|
|
127
127
|
const de_CopyBackupToRegionCommandError = async (output, context) => {
|
|
@@ -151,10 +151,9 @@ const de_CopyBackupToRegionCommandError = async (output, context) => {
|
|
|
151
151
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
152
152
|
default:
|
|
153
153
|
const parsedBody = parsedOutput.body;
|
|
154
|
-
|
|
154
|
+
return throwDefaultError({
|
|
155
155
|
output,
|
|
156
156
|
parsedBody,
|
|
157
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
158
157
|
errorCode,
|
|
159
158
|
});
|
|
160
159
|
}
|
|
@@ -170,7 +169,7 @@ const de_CreateClusterCommand = async (output, context) => {
|
|
|
170
169
|
$metadata: deserializeMetadata(output),
|
|
171
170
|
...contents,
|
|
172
171
|
};
|
|
173
|
-
return
|
|
172
|
+
return response;
|
|
174
173
|
};
|
|
175
174
|
exports.de_CreateClusterCommand = de_CreateClusterCommand;
|
|
176
175
|
const de_CreateClusterCommandError = async (output, context) => {
|
|
@@ -200,10 +199,9 @@ const de_CreateClusterCommandError = async (output, context) => {
|
|
|
200
199
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
201
200
|
default:
|
|
202
201
|
const parsedBody = parsedOutput.body;
|
|
203
|
-
|
|
202
|
+
return throwDefaultError({
|
|
204
203
|
output,
|
|
205
204
|
parsedBody,
|
|
206
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
207
205
|
errorCode,
|
|
208
206
|
});
|
|
209
207
|
}
|
|
@@ -214,12 +212,12 @@ const de_CreateHsmCommand = async (output, context) => {
|
|
|
214
212
|
}
|
|
215
213
|
const data = await parseBody(output.body, context);
|
|
216
214
|
let contents = {};
|
|
217
|
-
contents =
|
|
215
|
+
contents = (0, smithy_client_1._json)(data);
|
|
218
216
|
const response = {
|
|
219
217
|
$metadata: deserializeMetadata(output),
|
|
220
218
|
...contents,
|
|
221
219
|
};
|
|
222
|
-
return
|
|
220
|
+
return response;
|
|
223
221
|
};
|
|
224
222
|
exports.de_CreateHsmCommand = de_CreateHsmCommand;
|
|
225
223
|
const de_CreateHsmCommandError = async (output, context) => {
|
|
@@ -246,10 +244,9 @@ const de_CreateHsmCommandError = async (output, context) => {
|
|
|
246
244
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
247
245
|
default:
|
|
248
246
|
const parsedBody = parsedOutput.body;
|
|
249
|
-
|
|
247
|
+
return throwDefaultError({
|
|
250
248
|
output,
|
|
251
249
|
parsedBody,
|
|
252
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
253
250
|
errorCode,
|
|
254
251
|
});
|
|
255
252
|
}
|
|
@@ -265,7 +262,7 @@ const de_DeleteBackupCommand = async (output, context) => {
|
|
|
265
262
|
$metadata: deserializeMetadata(output),
|
|
266
263
|
...contents,
|
|
267
264
|
};
|
|
268
|
-
return
|
|
265
|
+
return response;
|
|
269
266
|
};
|
|
270
267
|
exports.de_DeleteBackupCommand = de_DeleteBackupCommand;
|
|
271
268
|
const de_DeleteBackupCommandError = async (output, context) => {
|
|
@@ -292,10 +289,9 @@ const de_DeleteBackupCommandError = async (output, context) => {
|
|
|
292
289
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
293
290
|
default:
|
|
294
291
|
const parsedBody = parsedOutput.body;
|
|
295
|
-
|
|
292
|
+
return throwDefaultError({
|
|
296
293
|
output,
|
|
297
294
|
parsedBody,
|
|
298
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
299
295
|
errorCode,
|
|
300
296
|
});
|
|
301
297
|
}
|
|
@@ -311,7 +307,7 @@ const de_DeleteClusterCommand = async (output, context) => {
|
|
|
311
307
|
$metadata: deserializeMetadata(output),
|
|
312
308
|
...contents,
|
|
313
309
|
};
|
|
314
|
-
return
|
|
310
|
+
return response;
|
|
315
311
|
};
|
|
316
312
|
exports.de_DeleteClusterCommand = de_DeleteClusterCommand;
|
|
317
313
|
const de_DeleteClusterCommandError = async (output, context) => {
|
|
@@ -341,10 +337,9 @@ const de_DeleteClusterCommandError = async (output, context) => {
|
|
|
341
337
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
342
338
|
default:
|
|
343
339
|
const parsedBody = parsedOutput.body;
|
|
344
|
-
|
|
340
|
+
return throwDefaultError({
|
|
345
341
|
output,
|
|
346
342
|
parsedBody,
|
|
347
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
348
343
|
errorCode,
|
|
349
344
|
});
|
|
350
345
|
}
|
|
@@ -355,12 +350,12 @@ const de_DeleteHsmCommand = async (output, context) => {
|
|
|
355
350
|
}
|
|
356
351
|
const data = await parseBody(output.body, context);
|
|
357
352
|
let contents = {};
|
|
358
|
-
contents =
|
|
353
|
+
contents = (0, smithy_client_1._json)(data);
|
|
359
354
|
const response = {
|
|
360
355
|
$metadata: deserializeMetadata(output),
|
|
361
356
|
...contents,
|
|
362
357
|
};
|
|
363
|
-
return
|
|
358
|
+
return response;
|
|
364
359
|
};
|
|
365
360
|
exports.de_DeleteHsmCommand = de_DeleteHsmCommand;
|
|
366
361
|
const de_DeleteHsmCommandError = async (output, context) => {
|
|
@@ -387,10 +382,9 @@ const de_DeleteHsmCommandError = async (output, context) => {
|
|
|
387
382
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
388
383
|
default:
|
|
389
384
|
const parsedBody = parsedOutput.body;
|
|
390
|
-
|
|
385
|
+
return throwDefaultError({
|
|
391
386
|
output,
|
|
392
387
|
parsedBody,
|
|
393
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
394
388
|
errorCode,
|
|
395
389
|
});
|
|
396
390
|
}
|
|
@@ -406,7 +400,7 @@ const de_DescribeBackupsCommand = async (output, context) => {
|
|
|
406
400
|
$metadata: deserializeMetadata(output),
|
|
407
401
|
...contents,
|
|
408
402
|
};
|
|
409
|
-
return
|
|
403
|
+
return response;
|
|
410
404
|
};
|
|
411
405
|
exports.de_DescribeBackupsCommand = de_DescribeBackupsCommand;
|
|
412
406
|
const de_DescribeBackupsCommandError = async (output, context) => {
|
|
@@ -436,10 +430,9 @@ const de_DescribeBackupsCommandError = async (output, context) => {
|
|
|
436
430
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
437
431
|
default:
|
|
438
432
|
const parsedBody = parsedOutput.body;
|
|
439
|
-
|
|
433
|
+
return throwDefaultError({
|
|
440
434
|
output,
|
|
441
435
|
parsedBody,
|
|
442
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
443
436
|
errorCode,
|
|
444
437
|
});
|
|
445
438
|
}
|
|
@@ -455,7 +448,7 @@ const de_DescribeClustersCommand = async (output, context) => {
|
|
|
455
448
|
$metadata: deserializeMetadata(output),
|
|
456
449
|
...contents,
|
|
457
450
|
};
|
|
458
|
-
return
|
|
451
|
+
return response;
|
|
459
452
|
};
|
|
460
453
|
exports.de_DescribeClustersCommand = de_DescribeClustersCommand;
|
|
461
454
|
const de_DescribeClustersCommandError = async (output, context) => {
|
|
@@ -482,10 +475,9 @@ const de_DescribeClustersCommandError = async (output, context) => {
|
|
|
482
475
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
483
476
|
default:
|
|
484
477
|
const parsedBody = parsedOutput.body;
|
|
485
|
-
|
|
478
|
+
return throwDefaultError({
|
|
486
479
|
output,
|
|
487
480
|
parsedBody,
|
|
488
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
489
481
|
errorCode,
|
|
490
482
|
});
|
|
491
483
|
}
|
|
@@ -496,12 +488,12 @@ const de_InitializeClusterCommand = async (output, context) => {
|
|
|
496
488
|
}
|
|
497
489
|
const data = await parseBody(output.body, context);
|
|
498
490
|
let contents = {};
|
|
499
|
-
contents =
|
|
491
|
+
contents = (0, smithy_client_1._json)(data);
|
|
500
492
|
const response = {
|
|
501
493
|
$metadata: deserializeMetadata(output),
|
|
502
494
|
...contents,
|
|
503
495
|
};
|
|
504
|
-
return
|
|
496
|
+
return response;
|
|
505
497
|
};
|
|
506
498
|
exports.de_InitializeClusterCommand = de_InitializeClusterCommand;
|
|
507
499
|
const de_InitializeClusterCommandError = async (output, context) => {
|
|
@@ -528,10 +520,9 @@ const de_InitializeClusterCommandError = async (output, context) => {
|
|
|
528
520
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
529
521
|
default:
|
|
530
522
|
const parsedBody = parsedOutput.body;
|
|
531
|
-
|
|
523
|
+
return throwDefaultError({
|
|
532
524
|
output,
|
|
533
525
|
parsedBody,
|
|
534
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
535
526
|
errorCode,
|
|
536
527
|
});
|
|
537
528
|
}
|
|
@@ -542,12 +533,12 @@ const de_ListTagsCommand = async (output, context) => {
|
|
|
542
533
|
}
|
|
543
534
|
const data = await parseBody(output.body, context);
|
|
544
535
|
let contents = {};
|
|
545
|
-
contents =
|
|
536
|
+
contents = (0, smithy_client_1._json)(data);
|
|
546
537
|
const response = {
|
|
547
538
|
$metadata: deserializeMetadata(output),
|
|
548
539
|
...contents,
|
|
549
540
|
};
|
|
550
|
-
return
|
|
541
|
+
return response;
|
|
551
542
|
};
|
|
552
543
|
exports.de_ListTagsCommand = de_ListTagsCommand;
|
|
553
544
|
const de_ListTagsCommandError = async (output, context) => {
|
|
@@ -577,10 +568,9 @@ const de_ListTagsCommandError = async (output, context) => {
|
|
|
577
568
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
578
569
|
default:
|
|
579
570
|
const parsedBody = parsedOutput.body;
|
|
580
|
-
|
|
571
|
+
return throwDefaultError({
|
|
581
572
|
output,
|
|
582
573
|
parsedBody,
|
|
583
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
584
574
|
errorCode,
|
|
585
575
|
});
|
|
586
576
|
}
|
|
@@ -596,7 +586,7 @@ const de_ModifyBackupAttributesCommand = async (output, context) => {
|
|
|
596
586
|
$metadata: deserializeMetadata(output),
|
|
597
587
|
...contents,
|
|
598
588
|
};
|
|
599
|
-
return
|
|
589
|
+
return response;
|
|
600
590
|
};
|
|
601
591
|
exports.de_ModifyBackupAttributesCommand = de_ModifyBackupAttributesCommand;
|
|
602
592
|
const de_ModifyBackupAttributesCommandError = async (output, context) => {
|
|
@@ -623,10 +613,9 @@ const de_ModifyBackupAttributesCommandError = async (output, context) => {
|
|
|
623
613
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
624
614
|
default:
|
|
625
615
|
const parsedBody = parsedOutput.body;
|
|
626
|
-
|
|
616
|
+
return throwDefaultError({
|
|
627
617
|
output,
|
|
628
618
|
parsedBody,
|
|
629
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
630
619
|
errorCode,
|
|
631
620
|
});
|
|
632
621
|
}
|
|
@@ -642,7 +631,7 @@ const de_ModifyClusterCommand = async (output, context) => {
|
|
|
642
631
|
$metadata: deserializeMetadata(output),
|
|
643
632
|
...contents,
|
|
644
633
|
};
|
|
645
|
-
return
|
|
634
|
+
return response;
|
|
646
635
|
};
|
|
647
636
|
exports.de_ModifyClusterCommand = de_ModifyClusterCommand;
|
|
648
637
|
const de_ModifyClusterCommandError = async (output, context) => {
|
|
@@ -669,10 +658,9 @@ const de_ModifyClusterCommandError = async (output, context) => {
|
|
|
669
658
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
670
659
|
default:
|
|
671
660
|
const parsedBody = parsedOutput.body;
|
|
672
|
-
|
|
661
|
+
return throwDefaultError({
|
|
673
662
|
output,
|
|
674
663
|
parsedBody,
|
|
675
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
676
664
|
errorCode,
|
|
677
665
|
});
|
|
678
666
|
}
|
|
@@ -688,7 +676,7 @@ const de_RestoreBackupCommand = async (output, context) => {
|
|
|
688
676
|
$metadata: deserializeMetadata(output),
|
|
689
677
|
...contents,
|
|
690
678
|
};
|
|
691
|
-
return
|
|
679
|
+
return response;
|
|
692
680
|
};
|
|
693
681
|
exports.de_RestoreBackupCommand = de_RestoreBackupCommand;
|
|
694
682
|
const de_RestoreBackupCommandError = async (output, context) => {
|
|
@@ -715,10 +703,9 @@ const de_RestoreBackupCommandError = async (output, context) => {
|
|
|
715
703
|
throw await de_CloudHsmServiceExceptionRes(parsedOutput, context);
|
|
716
704
|
default:
|
|
717
705
|
const parsedBody = parsedOutput.body;
|
|
718
|
-
|
|
706
|
+
return throwDefaultError({
|
|
719
707
|
output,
|
|
720
708
|
parsedBody,
|
|
721
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
722
709
|
errorCode,
|
|
723
710
|
});
|
|
724
711
|
}
|
|
@@ -729,12 +716,12 @@ const de_TagResourceCommand = async (output, context) => {
|
|
|
729
716
|
}
|
|
730
717
|
const data = await parseBody(output.body, context);
|
|
731
718
|
let contents = {};
|
|
732
|
-
contents =
|
|
719
|
+
contents = (0, smithy_client_1._json)(data);
|
|
733
720
|
const response = {
|
|
734
721
|
$metadata: deserializeMetadata(output),
|
|
735
722
|
...contents,
|
|
736
723
|
};
|
|
737
|
-
return
|
|
724
|
+
return response;
|
|
738
725
|
};
|
|
739
726
|
exports.de_TagResourceCommand = de_TagResourceCommand;
|
|
740
727
|
const de_TagResourceCommandError = async (output, context) => {
|
|
@@ -764,10 +751,9 @@ const de_TagResourceCommandError = async (output, context) => {
|
|
|
764
751
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
765
752
|
default:
|
|
766
753
|
const parsedBody = parsedOutput.body;
|
|
767
|
-
|
|
754
|
+
return throwDefaultError({
|
|
768
755
|
output,
|
|
769
756
|
parsedBody,
|
|
770
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
771
757
|
errorCode,
|
|
772
758
|
});
|
|
773
759
|
}
|
|
@@ -778,12 +764,12 @@ const de_UntagResourceCommand = async (output, context) => {
|
|
|
778
764
|
}
|
|
779
765
|
const data = await parseBody(output.body, context);
|
|
780
766
|
let contents = {};
|
|
781
|
-
contents =
|
|
767
|
+
contents = (0, smithy_client_1._json)(data);
|
|
782
768
|
const response = {
|
|
783
769
|
$metadata: deserializeMetadata(output),
|
|
784
770
|
...contents,
|
|
785
771
|
};
|
|
786
|
-
return
|
|
772
|
+
return response;
|
|
787
773
|
};
|
|
788
774
|
exports.de_UntagResourceCommand = de_UntagResourceCommand;
|
|
789
775
|
const de_UntagResourceCommandError = async (output, context) => {
|
|
@@ -813,17 +799,16 @@ const de_UntagResourceCommandError = async (output, context) => {
|
|
|
813
799
|
throw await de_CloudHsmTagExceptionRes(parsedOutput, context);
|
|
814
800
|
default:
|
|
815
801
|
const parsedBody = parsedOutput.body;
|
|
816
|
-
|
|
802
|
+
return throwDefaultError({
|
|
817
803
|
output,
|
|
818
804
|
parsedBody,
|
|
819
|
-
exceptionCtor: CloudHSMV2ServiceException_1.CloudHSMV2ServiceException,
|
|
820
805
|
errorCode,
|
|
821
806
|
});
|
|
822
807
|
}
|
|
823
808
|
};
|
|
824
809
|
const de_CloudHsmAccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
825
810
|
const body = parsedOutput.body;
|
|
826
|
-
const deserialized =
|
|
811
|
+
const deserialized = (0, smithy_client_1._json)(body);
|
|
827
812
|
const exception = new models_0_1.CloudHsmAccessDeniedException({
|
|
828
813
|
$metadata: deserializeMetadata(parsedOutput),
|
|
829
814
|
...deserialized,
|
|
@@ -832,7 +817,7 @@ const de_CloudHsmAccessDeniedExceptionRes = async (parsedOutput, context) => {
|
|
|
832
817
|
};
|
|
833
818
|
const de_CloudHsmInternalFailureExceptionRes = async (parsedOutput, context) => {
|
|
834
819
|
const body = parsedOutput.body;
|
|
835
|
-
const deserialized =
|
|
820
|
+
const deserialized = (0, smithy_client_1._json)(body);
|
|
836
821
|
const exception = new models_0_1.CloudHsmInternalFailureException({
|
|
837
822
|
$metadata: deserializeMetadata(parsedOutput),
|
|
838
823
|
...deserialized,
|
|
@@ -841,7 +826,7 @@ const de_CloudHsmInternalFailureExceptionRes = async (parsedOutput, context) =>
|
|
|
841
826
|
};
|
|
842
827
|
const de_CloudHsmInvalidRequestExceptionRes = async (parsedOutput, context) => {
|
|
843
828
|
const body = parsedOutput.body;
|
|
844
|
-
const deserialized =
|
|
829
|
+
const deserialized = (0, smithy_client_1._json)(body);
|
|
845
830
|
const exception = new models_0_1.CloudHsmInvalidRequestException({
|
|
846
831
|
$metadata: deserializeMetadata(parsedOutput),
|
|
847
832
|
...deserialized,
|
|
@@ -850,7 +835,7 @@ const de_CloudHsmInvalidRequestExceptionRes = async (parsedOutput, context) => {
|
|
|
850
835
|
};
|
|
851
836
|
const de_CloudHsmResourceNotFoundExceptionRes = async (parsedOutput, context) => {
|
|
852
837
|
const body = parsedOutput.body;
|
|
853
|
-
const deserialized =
|
|
838
|
+
const deserialized = (0, smithy_client_1._json)(body);
|
|
854
839
|
const exception = new models_0_1.CloudHsmResourceNotFoundException({
|
|
855
840
|
$metadata: deserializeMetadata(parsedOutput),
|
|
856
841
|
...deserialized,
|
|
@@ -859,7 +844,7 @@ const de_CloudHsmResourceNotFoundExceptionRes = async (parsedOutput, context) =>
|
|
|
859
844
|
};
|
|
860
845
|
const de_CloudHsmServiceExceptionRes = async (parsedOutput, context) => {
|
|
861
846
|
const body = parsedOutput.body;
|
|
862
|
-
const deserialized =
|
|
847
|
+
const deserialized = (0, smithy_client_1._json)(body);
|
|
863
848
|
const exception = new models_0_1.CloudHsmServiceException({
|
|
864
849
|
$metadata: deserializeMetadata(parsedOutput),
|
|
865
850
|
...deserialized,
|
|
@@ -868,409 +853,117 @@ const de_CloudHsmServiceExceptionRes = async (parsedOutput, context) => {
|
|
|
868
853
|
};
|
|
869
854
|
const de_CloudHsmTagExceptionRes = async (parsedOutput, context) => {
|
|
870
855
|
const body = parsedOutput.body;
|
|
871
|
-
const deserialized =
|
|
856
|
+
const deserialized = (0, smithy_client_1._json)(body);
|
|
872
857
|
const exception = new models_0_1.CloudHsmTagException({
|
|
873
858
|
$metadata: deserializeMetadata(parsedOutput),
|
|
874
859
|
...deserialized,
|
|
875
860
|
});
|
|
876
861
|
return (0, smithy_client_1.decorateServiceException)(exception, body);
|
|
877
862
|
};
|
|
878
|
-
const se_BackupRetentionPolicy = (input, context) => {
|
|
879
|
-
return {
|
|
880
|
-
...(input.Type != null && { Type: input.Type }),
|
|
881
|
-
...(input.Value != null && { Value: input.Value }),
|
|
882
|
-
};
|
|
883
|
-
};
|
|
884
|
-
const se_CopyBackupToRegionRequest = (input, context) => {
|
|
885
|
-
return {
|
|
886
|
-
...(input.BackupId != null && { BackupId: input.BackupId }),
|
|
887
|
-
...(input.DestinationRegion != null && { DestinationRegion: input.DestinationRegion }),
|
|
888
|
-
...(input.TagList != null && { TagList: se_TagList(input.TagList, context) }),
|
|
889
|
-
};
|
|
890
|
-
};
|
|
891
|
-
const se_CreateClusterRequest = (input, context) => {
|
|
892
|
-
return {
|
|
893
|
-
...(input.BackupRetentionPolicy != null && {
|
|
894
|
-
BackupRetentionPolicy: se_BackupRetentionPolicy(input.BackupRetentionPolicy, context),
|
|
895
|
-
}),
|
|
896
|
-
...(input.HsmType != null && { HsmType: input.HsmType }),
|
|
897
|
-
...(input.SourceBackupId != null && { SourceBackupId: input.SourceBackupId }),
|
|
898
|
-
...(input.SubnetIds != null && { SubnetIds: se_SubnetIds(input.SubnetIds, context) }),
|
|
899
|
-
...(input.TagList != null && { TagList: se_TagList(input.TagList, context) }),
|
|
900
|
-
};
|
|
901
|
-
};
|
|
902
|
-
const se_CreateHsmRequest = (input, context) => {
|
|
903
|
-
return {
|
|
904
|
-
...(input.AvailabilityZone != null && { AvailabilityZone: input.AvailabilityZone }),
|
|
905
|
-
...(input.ClusterId != null && { ClusterId: input.ClusterId }),
|
|
906
|
-
...(input.IpAddress != null && { IpAddress: input.IpAddress }),
|
|
907
|
-
};
|
|
908
|
-
};
|
|
909
|
-
const se_DeleteBackupRequest = (input, context) => {
|
|
910
|
-
return {
|
|
911
|
-
...(input.BackupId != null && { BackupId: input.BackupId }),
|
|
912
|
-
};
|
|
913
|
-
};
|
|
914
|
-
const se_DeleteClusterRequest = (input, context) => {
|
|
915
|
-
return {
|
|
916
|
-
...(input.ClusterId != null && { ClusterId: input.ClusterId }),
|
|
917
|
-
};
|
|
918
|
-
};
|
|
919
|
-
const se_DeleteHsmRequest = (input, context) => {
|
|
920
|
-
return {
|
|
921
|
-
...(input.ClusterId != null && { ClusterId: input.ClusterId }),
|
|
922
|
-
...(input.EniId != null && { EniId: input.EniId }),
|
|
923
|
-
...(input.EniIp != null && { EniIp: input.EniIp }),
|
|
924
|
-
...(input.HsmId != null && { HsmId: input.HsmId }),
|
|
925
|
-
};
|
|
926
|
-
};
|
|
927
|
-
const se_DescribeBackupsRequest = (input, context) => {
|
|
928
|
-
return {
|
|
929
|
-
...(input.Filters != null && { Filters: se_Filters(input.Filters, context) }),
|
|
930
|
-
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
931
|
-
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
932
|
-
...(input.SortAscending != null && { SortAscending: input.SortAscending }),
|
|
933
|
-
};
|
|
934
|
-
};
|
|
935
|
-
const se_DescribeClustersRequest = (input, context) => {
|
|
936
|
-
return {
|
|
937
|
-
...(input.Filters != null && { Filters: se_Filters(input.Filters, context) }),
|
|
938
|
-
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
939
|
-
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
940
|
-
};
|
|
941
|
-
};
|
|
942
|
-
const se_Filters = (input, context) => {
|
|
943
|
-
return Object.entries(input).reduce((acc, [key, value]) => {
|
|
944
|
-
if (value === null) {
|
|
945
|
-
return acc;
|
|
946
|
-
}
|
|
947
|
-
acc[key] = se_Strings(value, context);
|
|
948
|
-
return acc;
|
|
949
|
-
}, {});
|
|
950
|
-
};
|
|
951
|
-
const se_InitializeClusterRequest = (input, context) => {
|
|
952
|
-
return {
|
|
953
|
-
...(input.ClusterId != null && { ClusterId: input.ClusterId }),
|
|
954
|
-
...(input.SignedCert != null && { SignedCert: input.SignedCert }),
|
|
955
|
-
...(input.TrustAnchor != null && { TrustAnchor: input.TrustAnchor }),
|
|
956
|
-
};
|
|
957
|
-
};
|
|
958
|
-
const se_ListTagsRequest = (input, context) => {
|
|
959
|
-
return {
|
|
960
|
-
...(input.MaxResults != null && { MaxResults: input.MaxResults }),
|
|
961
|
-
...(input.NextToken != null && { NextToken: input.NextToken }),
|
|
962
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
963
|
-
};
|
|
964
|
-
};
|
|
965
|
-
const se_ModifyBackupAttributesRequest = (input, context) => {
|
|
966
|
-
return {
|
|
967
|
-
...(input.BackupId != null && { BackupId: input.BackupId }),
|
|
968
|
-
...(input.NeverExpires != null && { NeverExpires: input.NeverExpires }),
|
|
969
|
-
};
|
|
970
|
-
};
|
|
971
|
-
const se_ModifyClusterRequest = (input, context) => {
|
|
972
|
-
return {
|
|
973
|
-
...(input.BackupRetentionPolicy != null && {
|
|
974
|
-
BackupRetentionPolicy: se_BackupRetentionPolicy(input.BackupRetentionPolicy, context),
|
|
975
|
-
}),
|
|
976
|
-
...(input.ClusterId != null && { ClusterId: input.ClusterId }),
|
|
977
|
-
};
|
|
978
|
-
};
|
|
979
|
-
const se_RestoreBackupRequest = (input, context) => {
|
|
980
|
-
return {
|
|
981
|
-
...(input.BackupId != null && { BackupId: input.BackupId }),
|
|
982
|
-
};
|
|
983
|
-
};
|
|
984
|
-
const se_Strings = (input, context) => {
|
|
985
|
-
return input
|
|
986
|
-
.filter((e) => e != null)
|
|
987
|
-
.map((entry) => {
|
|
988
|
-
return entry;
|
|
989
|
-
});
|
|
990
|
-
};
|
|
991
|
-
const se_SubnetIds = (input, context) => {
|
|
992
|
-
return input
|
|
993
|
-
.filter((e) => e != null)
|
|
994
|
-
.map((entry) => {
|
|
995
|
-
return entry;
|
|
996
|
-
});
|
|
997
|
-
};
|
|
998
|
-
const se_Tag = (input, context) => {
|
|
999
|
-
return {
|
|
1000
|
-
...(input.Key != null && { Key: input.Key }),
|
|
1001
|
-
...(input.Value != null && { Value: input.Value }),
|
|
1002
|
-
};
|
|
1003
|
-
};
|
|
1004
|
-
const se_TagKeyList = (input, context) => {
|
|
1005
|
-
return input
|
|
1006
|
-
.filter((e) => e != null)
|
|
1007
|
-
.map((entry) => {
|
|
1008
|
-
return entry;
|
|
1009
|
-
});
|
|
1010
|
-
};
|
|
1011
|
-
const se_TagList = (input, context) => {
|
|
1012
|
-
return input
|
|
1013
|
-
.filter((e) => e != null)
|
|
1014
|
-
.map((entry) => {
|
|
1015
|
-
return se_Tag(entry, context);
|
|
1016
|
-
});
|
|
1017
|
-
};
|
|
1018
|
-
const se_TagResourceRequest = (input, context) => {
|
|
1019
|
-
return {
|
|
1020
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
1021
|
-
...(input.TagList != null && { TagList: se_TagList(input.TagList, context) }),
|
|
1022
|
-
};
|
|
1023
|
-
};
|
|
1024
|
-
const se_UntagResourceRequest = (input, context) => {
|
|
1025
|
-
return {
|
|
1026
|
-
...(input.ResourceId != null && { ResourceId: input.ResourceId }),
|
|
1027
|
-
...(input.TagKeyList != null && { TagKeyList: se_TagKeyList(input.TagKeyList, context) }),
|
|
1028
|
-
};
|
|
1029
|
-
};
|
|
1030
863
|
const de_Backup = (output, context) => {
|
|
1031
|
-
return {
|
|
1032
|
-
BackupId:
|
|
1033
|
-
BackupState:
|
|
1034
|
-
ClusterId:
|
|
1035
|
-
CopyTimestamp:
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
NeverExpires: (0, smithy_client_1.expectBoolean)(output.NeverExpires),
|
|
1045
|
-
SourceBackup: (0, smithy_client_1.expectString)(output.SourceBackup),
|
|
1046
|
-
SourceCluster: (0, smithy_client_1.expectString)(output.SourceCluster),
|
|
1047
|
-
SourceRegion: (0, smithy_client_1.expectString)(output.SourceRegion),
|
|
1048
|
-
TagList: output.TagList != null ? de_TagList(output.TagList, context) : undefined,
|
|
1049
|
-
};
|
|
1050
|
-
};
|
|
1051
|
-
const de_BackupRetentionPolicy = (output, context) => {
|
|
1052
|
-
return {
|
|
1053
|
-
Type: (0, smithy_client_1.expectString)(output.Type),
|
|
1054
|
-
Value: (0, smithy_client_1.expectString)(output.Value),
|
|
1055
|
-
};
|
|
864
|
+
return (0, smithy_client_1.take)(output, {
|
|
865
|
+
BackupId: smithy_client_1.expectString,
|
|
866
|
+
BackupState: smithy_client_1.expectString,
|
|
867
|
+
ClusterId: smithy_client_1.expectString,
|
|
868
|
+
CopyTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
869
|
+
CreateTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
870
|
+
DeleteTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
871
|
+
NeverExpires: smithy_client_1.expectBoolean,
|
|
872
|
+
SourceBackup: smithy_client_1.expectString,
|
|
873
|
+
SourceCluster: smithy_client_1.expectString,
|
|
874
|
+
SourceRegion: smithy_client_1.expectString,
|
|
875
|
+
TagList: smithy_client_1._json,
|
|
876
|
+
});
|
|
1056
877
|
};
|
|
1057
878
|
const de_Backups = (output, context) => {
|
|
1058
879
|
const retVal = (output || [])
|
|
1059
880
|
.filter((e) => e != null)
|
|
1060
881
|
.map((entry) => {
|
|
1061
|
-
if (entry === null) {
|
|
1062
|
-
return null;
|
|
1063
|
-
}
|
|
1064
882
|
return de_Backup(entry, context);
|
|
1065
883
|
});
|
|
1066
884
|
return retVal;
|
|
1067
885
|
};
|
|
1068
|
-
const de_Certificates = (output, context) => {
|
|
1069
|
-
return {
|
|
1070
|
-
AwsHardwareCertificate: (0, smithy_client_1.expectString)(output.AwsHardwareCertificate),
|
|
1071
|
-
ClusterCertificate: (0, smithy_client_1.expectString)(output.ClusterCertificate),
|
|
1072
|
-
ClusterCsr: (0, smithy_client_1.expectString)(output.ClusterCsr),
|
|
1073
|
-
HsmCertificate: (0, smithy_client_1.expectString)(output.HsmCertificate),
|
|
1074
|
-
ManufacturerHardwareCertificate: (0, smithy_client_1.expectString)(output.ManufacturerHardwareCertificate),
|
|
1075
|
-
};
|
|
1076
|
-
};
|
|
1077
|
-
const de_CloudHsmAccessDeniedException = (output, context) => {
|
|
1078
|
-
return {
|
|
1079
|
-
Message: (0, smithy_client_1.expectString)(output.Message),
|
|
1080
|
-
};
|
|
1081
|
-
};
|
|
1082
|
-
const de_CloudHsmInternalFailureException = (output, context) => {
|
|
1083
|
-
return {
|
|
1084
|
-
Message: (0, smithy_client_1.expectString)(output.Message),
|
|
1085
|
-
};
|
|
1086
|
-
};
|
|
1087
|
-
const de_CloudHsmInvalidRequestException = (output, context) => {
|
|
1088
|
-
return {
|
|
1089
|
-
Message: (0, smithy_client_1.expectString)(output.Message),
|
|
1090
|
-
};
|
|
1091
|
-
};
|
|
1092
|
-
const de_CloudHsmResourceNotFoundException = (output, context) => {
|
|
1093
|
-
return {
|
|
1094
|
-
Message: (0, smithy_client_1.expectString)(output.Message),
|
|
1095
|
-
};
|
|
1096
|
-
};
|
|
1097
|
-
const de_CloudHsmServiceException = (output, context) => {
|
|
1098
|
-
return {
|
|
1099
|
-
Message: (0, smithy_client_1.expectString)(output.Message),
|
|
1100
|
-
};
|
|
1101
|
-
};
|
|
1102
|
-
const de_CloudHsmTagException = (output, context) => {
|
|
1103
|
-
return {
|
|
1104
|
-
Message: (0, smithy_client_1.expectString)(output.Message),
|
|
1105
|
-
};
|
|
1106
|
-
};
|
|
1107
886
|
const de_Cluster = (output, context) => {
|
|
1108
|
-
return {
|
|
1109
|
-
BackupPolicy:
|
|
1110
|
-
BackupRetentionPolicy:
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
SubnetMapping: output.SubnetMapping != null ? de_ExternalSubnetMapping(output.SubnetMapping, context) : undefined,
|
|
1126
|
-
TagList: output.TagList != null ? de_TagList(output.TagList, context) : undefined,
|
|
1127
|
-
VpcId: (0, smithy_client_1.expectString)(output.VpcId),
|
|
1128
|
-
};
|
|
887
|
+
return (0, smithy_client_1.take)(output, {
|
|
888
|
+
BackupPolicy: smithy_client_1.expectString,
|
|
889
|
+
BackupRetentionPolicy: smithy_client_1._json,
|
|
890
|
+
Certificates: smithy_client_1._json,
|
|
891
|
+
ClusterId: smithy_client_1.expectString,
|
|
892
|
+
CreateTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
893
|
+
HsmType: smithy_client_1.expectString,
|
|
894
|
+
Hsms: smithy_client_1._json,
|
|
895
|
+
PreCoPassword: smithy_client_1.expectString,
|
|
896
|
+
SecurityGroup: smithy_client_1.expectString,
|
|
897
|
+
SourceBackupId: smithy_client_1.expectString,
|
|
898
|
+
State: smithy_client_1.expectString,
|
|
899
|
+
StateMessage: smithy_client_1.expectString,
|
|
900
|
+
SubnetMapping: smithy_client_1._json,
|
|
901
|
+
TagList: smithy_client_1._json,
|
|
902
|
+
VpcId: smithy_client_1.expectString,
|
|
903
|
+
});
|
|
1129
904
|
};
|
|
1130
905
|
const de_Clusters = (output, context) => {
|
|
1131
906
|
const retVal = (output || [])
|
|
1132
907
|
.filter((e) => e != null)
|
|
1133
908
|
.map((entry) => {
|
|
1134
|
-
if (entry === null) {
|
|
1135
|
-
return null;
|
|
1136
|
-
}
|
|
1137
909
|
return de_Cluster(entry, context);
|
|
1138
910
|
});
|
|
1139
911
|
return retVal;
|
|
1140
912
|
};
|
|
1141
913
|
const de_CopyBackupToRegionResponse = (output, context) => {
|
|
1142
|
-
return {
|
|
1143
|
-
DestinationBackup:
|
|
1144
|
-
};
|
|
914
|
+
return (0, smithy_client_1.take)(output, {
|
|
915
|
+
DestinationBackup: (_) => de_DestinationBackup(_, context),
|
|
916
|
+
});
|
|
1145
917
|
};
|
|
1146
918
|
const de_CreateClusterResponse = (output, context) => {
|
|
1147
|
-
return {
|
|
1148
|
-
Cluster:
|
|
1149
|
-
};
|
|
1150
|
-
};
|
|
1151
|
-
const de_CreateHsmResponse = (output, context) => {
|
|
1152
|
-
return {
|
|
1153
|
-
Hsm: output.Hsm != null ? de_Hsm(output.Hsm, context) : undefined,
|
|
1154
|
-
};
|
|
919
|
+
return (0, smithy_client_1.take)(output, {
|
|
920
|
+
Cluster: (_) => de_Cluster(_, context),
|
|
921
|
+
});
|
|
1155
922
|
};
|
|
1156
923
|
const de_DeleteBackupResponse = (output, context) => {
|
|
1157
|
-
return {
|
|
1158
|
-
Backup:
|
|
1159
|
-
};
|
|
924
|
+
return (0, smithy_client_1.take)(output, {
|
|
925
|
+
Backup: (_) => de_Backup(_, context),
|
|
926
|
+
});
|
|
1160
927
|
};
|
|
1161
928
|
const de_DeleteClusterResponse = (output, context) => {
|
|
1162
|
-
return {
|
|
1163
|
-
Cluster:
|
|
1164
|
-
};
|
|
1165
|
-
};
|
|
1166
|
-
const de_DeleteHsmResponse = (output, context) => {
|
|
1167
|
-
return {
|
|
1168
|
-
HsmId: (0, smithy_client_1.expectString)(output.HsmId),
|
|
1169
|
-
};
|
|
929
|
+
return (0, smithy_client_1.take)(output, {
|
|
930
|
+
Cluster: (_) => de_Cluster(_, context),
|
|
931
|
+
});
|
|
1170
932
|
};
|
|
1171
933
|
const de_DescribeBackupsResponse = (output, context) => {
|
|
1172
|
-
return {
|
|
1173
|
-
Backups:
|
|
1174
|
-
NextToken:
|
|
1175
|
-
};
|
|
934
|
+
return (0, smithy_client_1.take)(output, {
|
|
935
|
+
Backups: (_) => de_Backups(_, context),
|
|
936
|
+
NextToken: smithy_client_1.expectString,
|
|
937
|
+
});
|
|
1176
938
|
};
|
|
1177
939
|
const de_DescribeClustersResponse = (output, context) => {
|
|
1178
|
-
return {
|
|
1179
|
-
Clusters:
|
|
1180
|
-
NextToken:
|
|
1181
|
-
};
|
|
940
|
+
return (0, smithy_client_1.take)(output, {
|
|
941
|
+
Clusters: (_) => de_Clusters(_, context),
|
|
942
|
+
NextToken: smithy_client_1.expectString,
|
|
943
|
+
});
|
|
1182
944
|
};
|
|
1183
945
|
const de_DestinationBackup = (output, context) => {
|
|
1184
|
-
return {
|
|
1185
|
-
CreateTimestamp:
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
SourceCluster: (0, smithy_client_1.expectString)(output.SourceCluster),
|
|
1190
|
-
SourceRegion: (0, smithy_client_1.expectString)(output.SourceRegion),
|
|
1191
|
-
};
|
|
1192
|
-
};
|
|
1193
|
-
const de_ExternalSubnetMapping = (output, context) => {
|
|
1194
|
-
return Object.entries(output).reduce((acc, [key, value]) => {
|
|
1195
|
-
if (value === null) {
|
|
1196
|
-
return acc;
|
|
1197
|
-
}
|
|
1198
|
-
acc[key] = (0, smithy_client_1.expectString)(value);
|
|
1199
|
-
return acc;
|
|
1200
|
-
}, {});
|
|
1201
|
-
};
|
|
1202
|
-
const de_Hsm = (output, context) => {
|
|
1203
|
-
return {
|
|
1204
|
-
AvailabilityZone: (0, smithy_client_1.expectString)(output.AvailabilityZone),
|
|
1205
|
-
ClusterId: (0, smithy_client_1.expectString)(output.ClusterId),
|
|
1206
|
-
EniId: (0, smithy_client_1.expectString)(output.EniId),
|
|
1207
|
-
EniIp: (0, smithy_client_1.expectString)(output.EniIp),
|
|
1208
|
-
HsmId: (0, smithy_client_1.expectString)(output.HsmId),
|
|
1209
|
-
State: (0, smithy_client_1.expectString)(output.State),
|
|
1210
|
-
StateMessage: (0, smithy_client_1.expectString)(output.StateMessage),
|
|
1211
|
-
SubnetId: (0, smithy_client_1.expectString)(output.SubnetId),
|
|
1212
|
-
};
|
|
1213
|
-
};
|
|
1214
|
-
const de_Hsms = (output, context) => {
|
|
1215
|
-
const retVal = (output || [])
|
|
1216
|
-
.filter((e) => e != null)
|
|
1217
|
-
.map((entry) => {
|
|
1218
|
-
if (entry === null) {
|
|
1219
|
-
return null;
|
|
1220
|
-
}
|
|
1221
|
-
return de_Hsm(entry, context);
|
|
946
|
+
return (0, smithy_client_1.take)(output, {
|
|
947
|
+
CreateTimestamp: (_) => (0, smithy_client_1.expectNonNull)((0, smithy_client_1.parseEpochTimestamp)((0, smithy_client_1.expectNumber)(_))),
|
|
948
|
+
SourceBackup: smithy_client_1.expectString,
|
|
949
|
+
SourceCluster: smithy_client_1.expectString,
|
|
950
|
+
SourceRegion: smithy_client_1.expectString,
|
|
1222
951
|
});
|
|
1223
|
-
return retVal;
|
|
1224
|
-
};
|
|
1225
|
-
const de_InitializeClusterResponse = (output, context) => {
|
|
1226
|
-
return {
|
|
1227
|
-
State: (0, smithy_client_1.expectString)(output.State),
|
|
1228
|
-
StateMessage: (0, smithy_client_1.expectString)(output.StateMessage),
|
|
1229
|
-
};
|
|
1230
|
-
};
|
|
1231
|
-
const de_ListTagsResponse = (output, context) => {
|
|
1232
|
-
return {
|
|
1233
|
-
NextToken: (0, smithy_client_1.expectString)(output.NextToken),
|
|
1234
|
-
TagList: output.TagList != null ? de_TagList(output.TagList, context) : undefined,
|
|
1235
|
-
};
|
|
1236
952
|
};
|
|
1237
953
|
const de_ModifyBackupAttributesResponse = (output, context) => {
|
|
1238
|
-
return {
|
|
1239
|
-
Backup:
|
|
1240
|
-
};
|
|
954
|
+
return (0, smithy_client_1.take)(output, {
|
|
955
|
+
Backup: (_) => de_Backup(_, context),
|
|
956
|
+
});
|
|
1241
957
|
};
|
|
1242
958
|
const de_ModifyClusterResponse = (output, context) => {
|
|
1243
|
-
return {
|
|
1244
|
-
Cluster:
|
|
1245
|
-
};
|
|
959
|
+
return (0, smithy_client_1.take)(output, {
|
|
960
|
+
Cluster: (_) => de_Cluster(_, context),
|
|
961
|
+
});
|
|
1246
962
|
};
|
|
1247
963
|
const de_RestoreBackupResponse = (output, context) => {
|
|
1248
|
-
return {
|
|
1249
|
-
Backup:
|
|
1250
|
-
};
|
|
1251
|
-
};
|
|
1252
|
-
const de_Tag = (output, context) => {
|
|
1253
|
-
return {
|
|
1254
|
-
Key: (0, smithy_client_1.expectString)(output.Key),
|
|
1255
|
-
Value: (0, smithy_client_1.expectString)(output.Value),
|
|
1256
|
-
};
|
|
1257
|
-
};
|
|
1258
|
-
const de_TagList = (output, context) => {
|
|
1259
|
-
const retVal = (output || [])
|
|
1260
|
-
.filter((e) => e != null)
|
|
1261
|
-
.map((entry) => {
|
|
1262
|
-
if (entry === null) {
|
|
1263
|
-
return null;
|
|
1264
|
-
}
|
|
1265
|
-
return de_Tag(entry, context);
|
|
964
|
+
return (0, smithy_client_1.take)(output, {
|
|
965
|
+
Backup: (_) => de_Backup(_, context),
|
|
1266
966
|
});
|
|
1267
|
-
return retVal;
|
|
1268
|
-
};
|
|
1269
|
-
const de_TagResourceResponse = (output, context) => {
|
|
1270
|
-
return {};
|
|
1271
|
-
};
|
|
1272
|
-
const de_UntagResourceResponse = (output, context) => {
|
|
1273
|
-
return {};
|
|
1274
967
|
};
|
|
1275
968
|
const deserializeMetadata = (output) => ({
|
|
1276
969
|
httpStatusCode: output.statusCode,
|
|
@@ -1285,6 +978,7 @@ const collectBody = (streamBody = new Uint8Array(), context) => {
|
|
|
1285
978
|
return context.streamCollector(streamBody) || Promise.resolve(new Uint8Array());
|
|
1286
979
|
};
|
|
1287
980
|
const collectBodyString = (streamBody, context) => collectBody(streamBody, context).then((body) => context.utf8Encoder(body));
|
|
981
|
+
const throwDefaultError = (0, smithy_client_1.withBaseException)(CloudHSMV2ServiceException_1.CloudHSMV2ServiceException);
|
|
1288
982
|
const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
|
|
1289
983
|
const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
|
|
1290
984
|
const contents = {
|