@aws-sdk/client-cloudhsm-v2 3.927.0 → 3.929.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.
Files changed (39) hide show
  1. package/dist-cjs/index.js +508 -733
  2. package/dist-cjs/runtimeConfig.shared.js +7 -0
  3. package/dist-es/CloudHSMV2Client.js +2 -0
  4. package/dist-es/commands/CopyBackupToRegionCommand.js +3 -9
  5. package/dist-es/commands/CreateClusterCommand.js +3 -9
  6. package/dist-es/commands/CreateHsmCommand.js +3 -9
  7. package/dist-es/commands/DeleteBackupCommand.js +3 -9
  8. package/dist-es/commands/DeleteClusterCommand.js +3 -9
  9. package/dist-es/commands/DeleteHsmCommand.js +3 -9
  10. package/dist-es/commands/DeleteResourcePolicyCommand.js +3 -9
  11. package/dist-es/commands/DescribeBackupsCommand.js +3 -9
  12. package/dist-es/commands/DescribeClustersCommand.js +3 -9
  13. package/dist-es/commands/GetResourcePolicyCommand.js +3 -9
  14. package/dist-es/commands/InitializeClusterCommand.js +3 -9
  15. package/dist-es/commands/ListTagsCommand.js +3 -9
  16. package/dist-es/commands/ModifyBackupAttributesCommand.js +3 -9
  17. package/dist-es/commands/ModifyClusterCommand.js +3 -9
  18. package/dist-es/commands/PutResourcePolicyCommand.js +3 -9
  19. package/dist-es/commands/RestoreBackupCommand.js +3 -9
  20. package/dist-es/commands/TagResourceCommand.js +3 -9
  21. package/dist-es/commands/UntagResourceCommand.js +3 -9
  22. package/dist-es/runtimeConfig.shared.js +7 -0
  23. package/dist-es/schemas/schemas_0.js +455 -0
  24. package/dist-types/CloudHSMV2Client.d.ts +10 -1
  25. package/dist-types/runtimeConfig.browser.d.ts +1 -0
  26. package/dist-types/runtimeConfig.d.ts +1 -0
  27. package/dist-types/runtimeConfig.native.d.ts +1 -0
  28. package/dist-types/runtimeConfig.shared.d.ts +1 -0
  29. package/dist-types/schemas/schemas_0.d.ts +80 -0
  30. package/dist-types/ts3.4/CloudHSMV2Client.d.ts +4 -0
  31. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +4 -0
  32. package/dist-types/ts3.4/runtimeConfig.d.ts +4 -0
  33. package/dist-types/ts3.4/runtimeConfig.native.d.ts +4 -0
  34. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +4 -0
  35. package/dist-types/ts3.4/schemas/schemas_0.d.ts +86 -0
  36. package/package.json +5 -5
  37. package/dist-es/protocols/Aws_json1_1.js +0 -590
  38. package/dist-types/protocols/Aws_json1_1.d.ts +0 -164
  39. package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +0 -221
package/dist-cjs/index.js CHANGED
@@ -6,6 +6,7 @@ var middlewareRecursionDetection = require('@aws-sdk/middleware-recursion-detect
6
6
  var middlewareUserAgent = require('@aws-sdk/middleware-user-agent');
7
7
  var configResolver = require('@smithy/config-resolver');
8
8
  var core = require('@smithy/core');
9
+ var schema = require('@smithy/core/schema');
9
10
  var middlewareContentLength = require('@smithy/middleware-content-length');
10
11
  var middlewareEndpoint = require('@smithy/middleware-endpoint');
11
12
  var middlewareRetry = require('@smithy/middleware-retry');
@@ -14,8 +15,6 @@ var httpAuthSchemeProvider = require('./auth/httpAuthSchemeProvider');
14
15
  var runtimeConfig = require('./runtimeConfig');
15
16
  var regionConfigResolver = require('@aws-sdk/region-config-resolver');
16
17
  var protocolHttp = require('@smithy/protocol-http');
17
- var middlewareSerde = require('@smithy/middleware-serde');
18
- var core$1 = require('@aws-sdk/core');
19
18
 
20
19
  const resolveClientEndpointParameters = (options) => {
21
20
  return Object.assign(options, {
@@ -91,6 +90,7 @@ class CloudHSMV2Client extends smithyClient.Client {
91
90
  const _config_7 = httpAuthSchemeProvider.resolveHttpAuthSchemeConfig(_config_6);
92
91
  const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
93
92
  this.config = _config_8;
93
+ this.middlewareStack.use(schema.getSchemaSerdePlugin(this.config));
94
94
  this.middlewareStack.use(middlewareUserAgent.getUserAgentPlugin(this.config));
95
95
  this.middlewareStack.use(middlewareRetry.getRetryPlugin(this.config));
96
96
  this.middlewareStack.use(middlewareContentLength.getContentLengthPlugin(this.config));
@@ -110,12 +110,12 @@ class CloudHSMV2Client extends smithyClient.Client {
110
110
  }
111
111
  }
112
112
 
113
- class CloudHSMV2ServiceException extends smithyClient.ServiceException {
113
+ let CloudHSMV2ServiceException$1 = class CloudHSMV2ServiceException extends smithyClient.ServiceException {
114
114
  constructor(options) {
115
115
  super(options);
116
116
  Object.setPrototypeOf(this, CloudHSMV2ServiceException.prototype);
117
117
  }
118
- }
118
+ };
119
119
 
120
120
  const BackupState = {
121
121
  CREATE_IN_PROGRESS: "CREATE_IN_PROGRESS",
@@ -133,7 +133,7 @@ const BackupPolicy = {
133
133
  const BackupRetentionType = {
134
134
  DAYS: "DAYS",
135
135
  };
136
- class CloudHsmAccessDeniedException extends CloudHSMV2ServiceException {
136
+ let CloudHsmAccessDeniedException$1 = class CloudHsmAccessDeniedException extends CloudHSMV2ServiceException$1 {
137
137
  name = "CloudHsmAccessDeniedException";
138
138
  $fault = "client";
139
139
  Message;
@@ -146,8 +146,8 @@ class CloudHsmAccessDeniedException extends CloudHSMV2ServiceException {
146
146
  Object.setPrototypeOf(this, CloudHsmAccessDeniedException.prototype);
147
147
  this.Message = opts.Message;
148
148
  }
149
- }
150
- class CloudHsmInternalFailureException extends CloudHSMV2ServiceException {
149
+ };
150
+ let CloudHsmInternalFailureException$1 = class CloudHsmInternalFailureException extends CloudHSMV2ServiceException$1 {
151
151
  name = "CloudHsmInternalFailureException";
152
152
  $fault = "server";
153
153
  Message;
@@ -160,8 +160,8 @@ class CloudHsmInternalFailureException extends CloudHSMV2ServiceException {
160
160
  Object.setPrototypeOf(this, CloudHsmInternalFailureException.prototype);
161
161
  this.Message = opts.Message;
162
162
  }
163
- }
164
- class CloudHsmInvalidRequestException extends CloudHSMV2ServiceException {
163
+ };
164
+ let CloudHsmInvalidRequestException$1 = class CloudHsmInvalidRequestException extends CloudHSMV2ServiceException$1 {
165
165
  name = "CloudHsmInvalidRequestException";
166
166
  $fault = "client";
167
167
  Message;
@@ -174,8 +174,8 @@ class CloudHsmInvalidRequestException extends CloudHSMV2ServiceException {
174
174
  Object.setPrototypeOf(this, CloudHsmInvalidRequestException.prototype);
175
175
  this.Message = opts.Message;
176
176
  }
177
- }
178
- class CloudHsmResourceNotFoundException extends CloudHSMV2ServiceException {
177
+ };
178
+ let CloudHsmResourceNotFoundException$1 = class CloudHsmResourceNotFoundException extends CloudHSMV2ServiceException$1 {
179
179
  name = "CloudHsmResourceNotFoundException";
180
180
  $fault = "client";
181
181
  Message;
@@ -188,8 +188,8 @@ class CloudHsmResourceNotFoundException extends CloudHSMV2ServiceException {
188
188
  Object.setPrototypeOf(this, CloudHsmResourceNotFoundException.prototype);
189
189
  this.Message = opts.Message;
190
190
  }
191
- }
192
- class CloudHsmServiceException extends CloudHSMV2ServiceException {
191
+ };
192
+ let CloudHsmServiceException$1 = class CloudHsmServiceException extends CloudHSMV2ServiceException$1 {
193
193
  name = "CloudHsmServiceException";
194
194
  $fault = "client";
195
195
  Message;
@@ -202,8 +202,8 @@ class CloudHsmServiceException extends CloudHSMV2ServiceException {
202
202
  Object.setPrototypeOf(this, CloudHsmServiceException.prototype);
203
203
  this.Message = opts.Message;
204
204
  }
205
- }
206
- class CloudHsmTagException extends CloudHSMV2ServiceException {
205
+ };
206
+ let CloudHsmTagException$1 = class CloudHsmTagException extends CloudHSMV2ServiceException$1 {
207
207
  name = "CloudHsmTagException";
208
208
  $fault = "client";
209
209
  Message;
@@ -216,7 +216,7 @@ class CloudHsmTagException extends CloudHSMV2ServiceException {
216
216
  Object.setPrototypeOf(this, CloudHsmTagException.prototype);
217
217
  this.Message = opts.Message;
218
218
  }
219
- }
219
+ };
220
220
  const NetworkType = {
221
221
  DUALSTACK: "DUALSTACK",
222
222
  IPV4: "IPV4",
@@ -241,7 +241,7 @@ const ClusterState = {
241
241
  UNINITIALIZED: "UNINITIALIZED",
242
242
  UPDATE_IN_PROGRESS: "UPDATE_IN_PROGRESS",
243
243
  };
244
- class CloudHsmResourceLimitExceededException extends CloudHSMV2ServiceException {
244
+ let CloudHsmResourceLimitExceededException$1 = class CloudHsmResourceLimitExceededException extends CloudHSMV2ServiceException$1 {
245
245
  name = "CloudHsmResourceLimitExceededException";
246
246
  $fault = "client";
247
247
  Message;
@@ -254,604 +254,464 @@ class CloudHsmResourceLimitExceededException extends CloudHSMV2ServiceException
254
254
  Object.setPrototypeOf(this, CloudHsmResourceLimitExceededException.prototype);
255
255
  this.Message = opts.Message;
256
256
  }
257
- }
258
-
259
- const se_CopyBackupToRegionCommand = async (input, context) => {
260
- const headers = sharedHeaders("CopyBackupToRegion");
261
- let body;
262
- body = JSON.stringify(smithyClient._json(input));
263
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
264
- };
265
- const se_CreateClusterCommand = async (input, context) => {
266
- const headers = sharedHeaders("CreateCluster");
267
- let body;
268
- body = JSON.stringify(smithyClient._json(input));
269
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
270
- };
271
- const se_CreateHsmCommand = async (input, context) => {
272
- const headers = sharedHeaders("CreateHsm");
273
- let body;
274
- body = JSON.stringify(smithyClient._json(input));
275
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
276
- };
277
- const se_DeleteBackupCommand = async (input, context) => {
278
- const headers = sharedHeaders("DeleteBackup");
279
- let body;
280
- body = JSON.stringify(smithyClient._json(input));
281
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
282
- };
283
- const se_DeleteClusterCommand = async (input, context) => {
284
- const headers = sharedHeaders("DeleteCluster");
285
- let body;
286
- body = JSON.stringify(smithyClient._json(input));
287
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
288
- };
289
- const se_DeleteHsmCommand = async (input, context) => {
290
- const headers = sharedHeaders("DeleteHsm");
291
- let body;
292
- body = JSON.stringify(smithyClient._json(input));
293
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
294
- };
295
- const se_DeleteResourcePolicyCommand = async (input, context) => {
296
- const headers = sharedHeaders("DeleteResourcePolicy");
297
- let body;
298
- body = JSON.stringify(smithyClient._json(input));
299
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
300
- };
301
- const se_DescribeBackupsCommand = async (input, context) => {
302
- const headers = sharedHeaders("DescribeBackups");
303
- let body;
304
- body = JSON.stringify(smithyClient._json(input));
305
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
306
- };
307
- const se_DescribeClustersCommand = async (input, context) => {
308
- const headers = sharedHeaders("DescribeClusters");
309
- let body;
310
- body = JSON.stringify(smithyClient._json(input));
311
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
312
- };
313
- const se_GetResourcePolicyCommand = async (input, context) => {
314
- const headers = sharedHeaders("GetResourcePolicy");
315
- let body;
316
- body = JSON.stringify(smithyClient._json(input));
317
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
318
- };
319
- const se_InitializeClusterCommand = async (input, context) => {
320
- const headers = sharedHeaders("InitializeCluster");
321
- let body;
322
- body = JSON.stringify(smithyClient._json(input));
323
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
324
- };
325
- const se_ListTagsCommand = async (input, context) => {
326
- const headers = sharedHeaders("ListTags");
327
- let body;
328
- body = JSON.stringify(smithyClient._json(input));
329
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
330
- };
331
- const se_ModifyBackupAttributesCommand = async (input, context) => {
332
- const headers = sharedHeaders("ModifyBackupAttributes");
333
- let body;
334
- body = JSON.stringify(smithyClient._json(input));
335
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
336
- };
337
- const se_ModifyClusterCommand = async (input, context) => {
338
- const headers = sharedHeaders("ModifyCluster");
339
- let body;
340
- body = JSON.stringify(smithyClient._json(input));
341
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
342
- };
343
- const se_PutResourcePolicyCommand = async (input, context) => {
344
- const headers = sharedHeaders("PutResourcePolicy");
345
- let body;
346
- body = JSON.stringify(smithyClient._json(input));
347
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
348
- };
349
- const se_RestoreBackupCommand = async (input, context) => {
350
- const headers = sharedHeaders("RestoreBackup");
351
- let body;
352
- body = JSON.stringify(smithyClient._json(input));
353
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
354
- };
355
- const se_TagResourceCommand = async (input, context) => {
356
- const headers = sharedHeaders("TagResource");
357
- let body;
358
- body = JSON.stringify(smithyClient._json(input));
359
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
360
- };
361
- const se_UntagResourceCommand = async (input, context) => {
362
- const headers = sharedHeaders("UntagResource");
363
- let body;
364
- body = JSON.stringify(smithyClient._json(input));
365
- return buildHttpRpcRequest(context, headers, "/", undefined, body);
366
- };
367
- const de_CopyBackupToRegionCommand = async (output, context) => {
368
- if (output.statusCode >= 300) {
369
- return de_CommandError(output, context);
370
- }
371
- const data = await core$1.parseJsonBody(output.body, context);
372
- let contents = {};
373
- contents = de_CopyBackupToRegionResponse(data);
374
- const response = {
375
- $metadata: deserializeMetadata(output),
376
- ...contents,
377
- };
378
- return response;
379
- };
380
- const de_CreateClusterCommand = async (output, context) => {
381
- if (output.statusCode >= 300) {
382
- return de_CommandError(output, context);
383
- }
384
- const data = await core$1.parseJsonBody(output.body, context);
385
- let contents = {};
386
- contents = de_CreateClusterResponse(data);
387
- const response = {
388
- $metadata: deserializeMetadata(output),
389
- ...contents,
390
- };
391
- return response;
392
- };
393
- const de_CreateHsmCommand = async (output, context) => {
394
- if (output.statusCode >= 300) {
395
- return de_CommandError(output, context);
396
- }
397
- const data = await core$1.parseJsonBody(output.body, context);
398
- let contents = {};
399
- contents = smithyClient._json(data);
400
- const response = {
401
- $metadata: deserializeMetadata(output),
402
- ...contents,
403
- };
404
- return response;
405
- };
406
- const de_DeleteBackupCommand = async (output, context) => {
407
- if (output.statusCode >= 300) {
408
- return de_CommandError(output, context);
409
- }
410
- const data = await core$1.parseJsonBody(output.body, context);
411
- let contents = {};
412
- contents = de_DeleteBackupResponse(data);
413
- const response = {
414
- $metadata: deserializeMetadata(output),
415
- ...contents,
416
- };
417
- return response;
418
- };
419
- const de_DeleteClusterCommand = async (output, context) => {
420
- if (output.statusCode >= 300) {
421
- return de_CommandError(output, context);
422
- }
423
- const data = await core$1.parseJsonBody(output.body, context);
424
- let contents = {};
425
- contents = de_DeleteClusterResponse(data);
426
- const response = {
427
- $metadata: deserializeMetadata(output),
428
- ...contents,
429
- };
430
- return response;
431
- };
432
- const de_DeleteHsmCommand = async (output, context) => {
433
- if (output.statusCode >= 300) {
434
- return de_CommandError(output, context);
435
- }
436
- const data = await core$1.parseJsonBody(output.body, context);
437
- let contents = {};
438
- contents = smithyClient._json(data);
439
- const response = {
440
- $metadata: deserializeMetadata(output),
441
- ...contents,
442
- };
443
- return response;
444
- };
445
- const de_DeleteResourcePolicyCommand = async (output, context) => {
446
- if (output.statusCode >= 300) {
447
- return de_CommandError(output, context);
448
- }
449
- const data = await core$1.parseJsonBody(output.body, context);
450
- let contents = {};
451
- contents = smithyClient._json(data);
452
- const response = {
453
- $metadata: deserializeMetadata(output),
454
- ...contents,
455
- };
456
- return response;
457
- };
458
- const de_DescribeBackupsCommand = async (output, context) => {
459
- if (output.statusCode >= 300) {
460
- return de_CommandError(output, context);
461
- }
462
- const data = await core$1.parseJsonBody(output.body, context);
463
- let contents = {};
464
- contents = de_DescribeBackupsResponse(data);
465
- const response = {
466
- $metadata: deserializeMetadata(output),
467
- ...contents,
468
- };
469
- return response;
470
- };
471
- const de_DescribeClustersCommand = async (output, context) => {
472
- if (output.statusCode >= 300) {
473
- return de_CommandError(output, context);
474
- }
475
- const data = await core$1.parseJsonBody(output.body, context);
476
- let contents = {};
477
- contents = de_DescribeClustersResponse(data);
478
- const response = {
479
- $metadata: deserializeMetadata(output),
480
- ...contents,
481
- };
482
- return response;
483
- };
484
- const de_GetResourcePolicyCommand = async (output, context) => {
485
- if (output.statusCode >= 300) {
486
- return de_CommandError(output, context);
487
- }
488
- const data = await core$1.parseJsonBody(output.body, context);
489
- let contents = {};
490
- contents = smithyClient._json(data);
491
- const response = {
492
- $metadata: deserializeMetadata(output),
493
- ...contents,
494
- };
495
- return response;
496
- };
497
- const de_InitializeClusterCommand = async (output, context) => {
498
- if (output.statusCode >= 300) {
499
- return de_CommandError(output, context);
500
- }
501
- const data = await core$1.parseJsonBody(output.body, context);
502
- let contents = {};
503
- contents = smithyClient._json(data);
504
- const response = {
505
- $metadata: deserializeMetadata(output),
506
- ...contents,
507
- };
508
- return response;
509
- };
510
- const de_ListTagsCommand = async (output, context) => {
511
- if (output.statusCode >= 300) {
512
- return de_CommandError(output, context);
513
- }
514
- const data = await core$1.parseJsonBody(output.body, context);
515
- let contents = {};
516
- contents = smithyClient._json(data);
517
- const response = {
518
- $metadata: deserializeMetadata(output),
519
- ...contents,
520
- };
521
- return response;
522
- };
523
- const de_ModifyBackupAttributesCommand = async (output, context) => {
524
- if (output.statusCode >= 300) {
525
- return de_CommandError(output, context);
526
- }
527
- const data = await core$1.parseJsonBody(output.body, context);
528
- let contents = {};
529
- contents = de_ModifyBackupAttributesResponse(data);
530
- const response = {
531
- $metadata: deserializeMetadata(output),
532
- ...contents,
533
- };
534
- return response;
535
- };
536
- const de_ModifyClusterCommand = async (output, context) => {
537
- if (output.statusCode >= 300) {
538
- return de_CommandError(output, context);
539
- }
540
- const data = await core$1.parseJsonBody(output.body, context);
541
- let contents = {};
542
- contents = de_ModifyClusterResponse(data);
543
- const response = {
544
- $metadata: deserializeMetadata(output),
545
- ...contents,
546
- };
547
- return response;
548
- };
549
- const de_PutResourcePolicyCommand = async (output, context) => {
550
- if (output.statusCode >= 300) {
551
- return de_CommandError(output, context);
552
- }
553
- const data = await core$1.parseJsonBody(output.body, context);
554
- let contents = {};
555
- contents = smithyClient._json(data);
556
- const response = {
557
- $metadata: deserializeMetadata(output),
558
- ...contents,
559
- };
560
- return response;
561
- };
562
- const de_RestoreBackupCommand = async (output, context) => {
563
- if (output.statusCode >= 300) {
564
- return de_CommandError(output, context);
565
- }
566
- const data = await core$1.parseJsonBody(output.body, context);
567
- let contents = {};
568
- contents = de_RestoreBackupResponse(data);
569
- const response = {
570
- $metadata: deserializeMetadata(output),
571
- ...contents,
572
- };
573
- return response;
574
- };
575
- const de_TagResourceCommand = async (output, context) => {
576
- if (output.statusCode >= 300) {
577
- return de_CommandError(output, context);
578
- }
579
- const data = await core$1.parseJsonBody(output.body, context);
580
- let contents = {};
581
- contents = smithyClient._json(data);
582
- const response = {
583
- $metadata: deserializeMetadata(output),
584
- ...contents,
585
- };
586
- return response;
587
- };
588
- const de_UntagResourceCommand = async (output, context) => {
589
- if (output.statusCode >= 300) {
590
- return de_CommandError(output, context);
591
- }
592
- const data = await core$1.parseJsonBody(output.body, context);
593
- let contents = {};
594
- contents = smithyClient._json(data);
595
- const response = {
596
- $metadata: deserializeMetadata(output),
597
- ...contents,
598
- };
599
- return response;
600
- };
601
- const de_CommandError = async (output, context) => {
602
- const parsedOutput = {
603
- ...output,
604
- body: await core$1.parseJsonErrorBody(output.body, context),
605
- };
606
- const errorCode = core$1.loadRestJsonErrorCode(output, parsedOutput.body);
607
- switch (errorCode) {
608
- case "CloudHsmAccessDeniedException":
609
- case "com.amazonaws.cloudhsmv2#CloudHsmAccessDeniedException":
610
- throw await de_CloudHsmAccessDeniedExceptionRes(parsedOutput);
611
- case "CloudHsmInternalFailureException":
612
- case "com.amazonaws.cloudhsmv2#CloudHsmInternalFailureException":
613
- throw await de_CloudHsmInternalFailureExceptionRes(parsedOutput);
614
- case "CloudHsmInvalidRequestException":
615
- case "com.amazonaws.cloudhsmv2#CloudHsmInvalidRequestException":
616
- throw await de_CloudHsmInvalidRequestExceptionRes(parsedOutput);
617
- case "CloudHsmResourceNotFoundException":
618
- case "com.amazonaws.cloudhsmv2#CloudHsmResourceNotFoundException":
619
- throw await de_CloudHsmResourceNotFoundExceptionRes(parsedOutput);
620
- case "CloudHsmServiceException":
621
- case "com.amazonaws.cloudhsmv2#CloudHsmServiceException":
622
- throw await de_CloudHsmServiceExceptionRes(parsedOutput);
623
- case "CloudHsmTagException":
624
- case "com.amazonaws.cloudhsmv2#CloudHsmTagException":
625
- throw await de_CloudHsmTagExceptionRes(parsedOutput);
626
- case "CloudHsmResourceLimitExceededException":
627
- case "com.amazonaws.cloudhsmv2#CloudHsmResourceLimitExceededException":
628
- throw await de_CloudHsmResourceLimitExceededExceptionRes(parsedOutput);
629
- default:
630
- const parsedBody = parsedOutput.body;
631
- return throwDefaultError({
632
- output,
633
- parsedBody,
634
- errorCode,
635
- });
636
- }
637
- };
638
- const de_CloudHsmAccessDeniedExceptionRes = async (parsedOutput, context) => {
639
- const body = parsedOutput.body;
640
- const deserialized = smithyClient._json(body);
641
- const exception = new CloudHsmAccessDeniedException({
642
- $metadata: deserializeMetadata(parsedOutput),
643
- ...deserialized,
644
- });
645
- return smithyClient.decorateServiceException(exception, body);
646
- };
647
- const de_CloudHsmInternalFailureExceptionRes = async (parsedOutput, context) => {
648
- const body = parsedOutput.body;
649
- const deserialized = smithyClient._json(body);
650
- const exception = new CloudHsmInternalFailureException({
651
- $metadata: deserializeMetadata(parsedOutput),
652
- ...deserialized,
653
- });
654
- return smithyClient.decorateServiceException(exception, body);
655
- };
656
- const de_CloudHsmInvalidRequestExceptionRes = async (parsedOutput, context) => {
657
- const body = parsedOutput.body;
658
- const deserialized = smithyClient._json(body);
659
- const exception = new CloudHsmInvalidRequestException({
660
- $metadata: deserializeMetadata(parsedOutput),
661
- ...deserialized,
662
- });
663
- return smithyClient.decorateServiceException(exception, body);
664
- };
665
- const de_CloudHsmResourceLimitExceededExceptionRes = async (parsedOutput, context) => {
666
- const body = parsedOutput.body;
667
- const deserialized = smithyClient._json(body);
668
- const exception = new CloudHsmResourceLimitExceededException({
669
- $metadata: deserializeMetadata(parsedOutput),
670
- ...deserialized,
671
- });
672
- return smithyClient.decorateServiceException(exception, body);
673
- };
674
- const de_CloudHsmResourceNotFoundExceptionRes = async (parsedOutput, context) => {
675
- const body = parsedOutput.body;
676
- const deserialized = smithyClient._json(body);
677
- const exception = new CloudHsmResourceNotFoundException({
678
- $metadata: deserializeMetadata(parsedOutput),
679
- ...deserialized,
680
- });
681
- return smithyClient.decorateServiceException(exception, body);
682
- };
683
- const de_CloudHsmServiceExceptionRes = async (parsedOutput, context) => {
684
- const body = parsedOutput.body;
685
- const deserialized = smithyClient._json(body);
686
- const exception = new CloudHsmServiceException({
687
- $metadata: deserializeMetadata(parsedOutput),
688
- ...deserialized,
689
- });
690
- return smithyClient.decorateServiceException(exception, body);
691
- };
692
- const de_CloudHsmTagExceptionRes = async (parsedOutput, context) => {
693
- const body = parsedOutput.body;
694
- const deserialized = smithyClient._json(body);
695
- const exception = new CloudHsmTagException({
696
- $metadata: deserializeMetadata(parsedOutput),
697
- ...deserialized,
698
- });
699
- return smithyClient.decorateServiceException(exception, body);
700
- };
701
- const de_Backup = (output, context) => {
702
- return smithyClient.take(output, {
703
- BackupArn: smithyClient.expectString,
704
- BackupId: smithyClient.expectString,
705
- BackupState: smithyClient.expectString,
706
- ClusterId: smithyClient.expectString,
707
- CopyTimestamp: (_) => smithyClient.expectNonNull(smithyClient.parseEpochTimestamp(smithyClient.expectNumber(_))),
708
- CreateTimestamp: (_) => smithyClient.expectNonNull(smithyClient.parseEpochTimestamp(smithyClient.expectNumber(_))),
709
- DeleteTimestamp: (_) => smithyClient.expectNonNull(smithyClient.parseEpochTimestamp(smithyClient.expectNumber(_))),
710
- HsmType: smithyClient.expectString,
711
- Mode: smithyClient.expectString,
712
- NeverExpires: smithyClient.expectBoolean,
713
- SourceBackup: smithyClient.expectString,
714
- SourceCluster: smithyClient.expectString,
715
- SourceRegion: smithyClient.expectString,
716
- TagList: smithyClient._json,
717
- });
718
- };
719
- const de_Backups = (output, context) => {
720
- const retVal = (output || [])
721
- .filter((e) => e != null)
722
- .map((entry) => {
723
- return de_Backup(entry);
724
- });
725
- return retVal;
726
- };
727
- const de_Cluster = (output, context) => {
728
- return smithyClient.take(output, {
729
- BackupPolicy: smithyClient.expectString,
730
- BackupRetentionPolicy: smithyClient._json,
731
- Certificates: smithyClient._json,
732
- ClusterId: smithyClient.expectString,
733
- CreateTimestamp: (_) => smithyClient.expectNonNull(smithyClient.parseEpochTimestamp(smithyClient.expectNumber(_))),
734
- HsmType: smithyClient.expectString,
735
- HsmTypeRollbackExpiration: (_) => smithyClient.expectNonNull(smithyClient.parseEpochTimestamp(smithyClient.expectNumber(_))),
736
- Hsms: smithyClient._json,
737
- Mode: smithyClient.expectString,
738
- NetworkType: smithyClient.expectString,
739
- PreCoPassword: smithyClient.expectString,
740
- SecurityGroup: smithyClient.expectString,
741
- SourceBackupId: smithyClient.expectString,
742
- State: smithyClient.expectString,
743
- StateMessage: smithyClient.expectString,
744
- SubnetMapping: smithyClient._json,
745
- TagList: smithyClient._json,
746
- VpcId: smithyClient.expectString,
747
- });
748
- };
749
- const de_Clusters = (output, context) => {
750
- const retVal = (output || [])
751
- .filter((e) => e != null)
752
- .map((entry) => {
753
- return de_Cluster(entry);
754
- });
755
- return retVal;
756
- };
757
- const de_CopyBackupToRegionResponse = (output, context) => {
758
- return smithyClient.take(output, {
759
- DestinationBackup: (_) => de_DestinationBackup(_),
760
- });
761
- };
762
- const de_CreateClusterResponse = (output, context) => {
763
- return smithyClient.take(output, {
764
- Cluster: (_) => de_Cluster(_),
765
- });
766
- };
767
- const de_DeleteBackupResponse = (output, context) => {
768
- return smithyClient.take(output, {
769
- Backup: (_) => de_Backup(_),
770
- });
771
- };
772
- const de_DeleteClusterResponse = (output, context) => {
773
- return smithyClient.take(output, {
774
- Cluster: (_) => de_Cluster(_),
775
- });
776
- };
777
- const de_DescribeBackupsResponse = (output, context) => {
778
- return smithyClient.take(output, {
779
- Backups: (_) => de_Backups(_),
780
- NextToken: smithyClient.expectString,
781
- });
782
- };
783
- const de_DescribeClustersResponse = (output, context) => {
784
- return smithyClient.take(output, {
785
- Clusters: (_) => de_Clusters(_),
786
- NextToken: smithyClient.expectString,
787
- });
788
- };
789
- const de_DestinationBackup = (output, context) => {
790
- return smithyClient.take(output, {
791
- CreateTimestamp: (_) => smithyClient.expectNonNull(smithyClient.parseEpochTimestamp(smithyClient.expectNumber(_))),
792
- SourceBackup: smithyClient.expectString,
793
- SourceCluster: smithyClient.expectString,
794
- SourceRegion: smithyClient.expectString,
795
- });
796
- };
797
- const de_ModifyBackupAttributesResponse = (output, context) => {
798
- return smithyClient.take(output, {
799
- Backup: (_) => de_Backup(_),
800
- });
801
- };
802
- const de_ModifyClusterResponse = (output, context) => {
803
- return smithyClient.take(output, {
804
- Cluster: (_) => de_Cluster(_),
805
- });
806
- };
807
- const de_RestoreBackupResponse = (output, context) => {
808
- return smithyClient.take(output, {
809
- Backup: (_) => de_Backup(_),
810
- });
811
- };
812
- const deserializeMetadata = (output) => ({
813
- httpStatusCode: output.statusCode,
814
- requestId: output.headers["x-amzn-requestid"] ?? output.headers["x-amzn-request-id"] ?? output.headers["x-amz-request-id"],
815
- extendedRequestId: output.headers["x-amz-id-2"],
816
- cfId: output.headers["x-amz-cf-id"],
817
- });
818
- const throwDefaultError = smithyClient.withBaseException(CloudHSMV2ServiceException);
819
- const buildHttpRpcRequest = async (context, headers, path, resolvedHostname, body) => {
820
- const { hostname, protocol = "https", port, path: basePath } = await context.endpoint();
821
- const contents = {
822
- protocol,
823
- hostname,
824
- port,
825
- method: "POST",
826
- path: basePath.endsWith("/") ? basePath.slice(0, -1) + path : basePath + path,
827
- headers,
828
- };
829
- if (body !== undefined) {
830
- contents.body = body;
831
- }
832
- return new protocolHttp.HttpRequest(contents);
833
257
  };
834
- function sharedHeaders(operation) {
835
- return {
836
- "content-type": "application/x-amz-json-1.1",
837
- "x-amz-target": `BaldrApiService.${operation}`,
838
- };
839
- }
258
+
259
+ const _AHC = "AwsHardwareCertificate";
260
+ const _AZ = "AvailabilityZone";
261
+ const _B = "Backup";
262
+ const _BA = "BackupArn";
263
+ const _BI = "BackupId";
264
+ const _BP = "BackupPolicy";
265
+ const _BRP = "BackupRetentionPolicy";
266
+ const _BS = "BackupState";
267
+ const _Ba = "Backups";
268
+ const _C = "Certificates";
269
+ const _CBTR = "CopyBackupToRegion";
270
+ const _CBTRR = "CopyBackupToRegionRequest";
271
+ const _CBTRRo = "CopyBackupToRegionResponse";
272
+ const _CC = "ClusterCsr";
273
+ const _CCR = "CreateClusterRequest";
274
+ const _CCRr = "CreateClusterResponse";
275
+ const _CCl = "ClusterCertificate";
276
+ const _CCr = "CreateCluster";
277
+ const _CH = "CreateHsm";
278
+ const _CHADE = "CloudHsmAccessDeniedException";
279
+ const _CHIFE = "CloudHsmInternalFailureException";
280
+ const _CHIRE = "CloudHsmInvalidRequestException";
281
+ const _CHR = "CreateHsmRequest";
282
+ const _CHRLEE = "CloudHsmResourceLimitExceededException";
283
+ const _CHRNFE = "CloudHsmResourceNotFoundException";
284
+ const _CHRr = "CreateHsmResponse";
285
+ const _CHSE = "CloudHsmServiceException";
286
+ const _CHTE = "CloudHsmTagException";
287
+ const _CI = "ClusterId";
288
+ const _CT = "CreateTimestamp";
289
+ const _CTo = "CopyTimestamp";
290
+ const _Cl = "Cluster";
291
+ const _Clu = "Clusters";
292
+ const _DB = "DestinationBackup";
293
+ const _DBR = "DeleteBackupRequest";
294
+ const _DBRe = "DeleteBackupResponse";
295
+ const _DBRes = "DescribeBackupsRequest";
296
+ const _DBResc = "DescribeBackupsResponse";
297
+ const _DBe = "DeleteBackup";
298
+ const _DBes = "DescribeBackups";
299
+ const _DC = "DeleteCluster";
300
+ const _DCR = "DeleteClusterRequest";
301
+ const _DCRe = "DeleteClusterResponse";
302
+ const _DCRes = "DescribeClustersRequest";
303
+ const _DCResc = "DescribeClustersResponse";
304
+ const _DCe = "DescribeClusters";
305
+ const _DH = "DeleteHsm";
306
+ const _DHR = "DeleteHsmRequest";
307
+ const _DHRe = "DeleteHsmResponse";
308
+ const _DR = "DestinationRegion";
309
+ const _DRP = "DeleteResourcePolicy";
310
+ const _DRPR = "DeleteResourcePolicyRequest";
311
+ const _DRPRe = "DeleteResourcePolicyResponse";
312
+ const _DT = "DeleteTimestamp";
313
+ const _EI = "EniId";
314
+ const _EIV = "EniIpV6";
315
+ const _EIn = "EniIp";
316
+ const _F = "Filters";
317
+ const _GRP = "GetResourcePolicy";
318
+ const _GRPR = "GetResourcePolicyRequest";
319
+ const _GRPRe = "GetResourcePolicyResponse";
320
+ const _H = "Hsms";
321
+ const _HC = "HsmCertificate";
322
+ const _HI = "HsmId";
323
+ const _HT = "HsmType";
324
+ const _HTRE = "HsmTypeRollbackExpiration";
325
+ const _Hs = "Hsm";
326
+ const _IA = "IpAddress";
327
+ const _IC = "InitializeCluster";
328
+ const _ICR = "InitializeClusterRequest";
329
+ const _ICRn = "InitializeClusterResponse";
330
+ const _K = "Key";
331
+ const _LT = "ListTags";
332
+ const _LTR = "ListTagsRequest";
333
+ const _LTRi = "ListTagsResponse";
334
+ const _M = "Mode";
335
+ const _MBA = "ModifyBackupAttributes";
336
+ const _MBAR = "ModifyBackupAttributesRequest";
337
+ const _MBARo = "ModifyBackupAttributesResponse";
338
+ const _MC = "ModifyCluster";
339
+ const _MCR = "ModifyClusterRequest";
340
+ const _MCRo = "ModifyClusterResponse";
341
+ const _MHC = "ManufacturerHardwareCertificate";
342
+ const _MR = "MaxResults";
343
+ const _Me = "Message";
344
+ const _NE = "NeverExpires";
345
+ const _NT = "NetworkType";
346
+ const _NTe = "NextToken";
347
+ const _P = "Policy";
348
+ const _PCP = "PreCoPassword";
349
+ const _PRP = "PutResourcePolicy";
350
+ const _PRPR = "PutResourcePolicyRequest";
351
+ const _PRPRu = "PutResourcePolicyResponse";
352
+ const _RA = "ResourceArn";
353
+ const _RB = "RestoreBackup";
354
+ const _RBR = "RestoreBackupRequest";
355
+ const _RBRe = "RestoreBackupResponse";
356
+ const _RI = "ResourceId";
357
+ const _S = "State";
358
+ const _SA = "SortAscending";
359
+ const _SB = "SourceBackup";
360
+ const _SBI = "SourceBackupId";
361
+ const _SC = "SourceCluster";
362
+ const _SCi = "SignedCert";
363
+ const _SG = "SecurityGroup";
364
+ const _SI = "SubnetIds";
365
+ const _SIu = "SubnetId";
366
+ const _SM = "StateMessage";
367
+ const _SMu = "SubnetMapping";
368
+ const _SR = "SourceRegion";
369
+ const _Sh = "Shared";
370
+ const _T = "Type";
371
+ const _TA = "TrustAnchor";
372
+ const _TKL = "TagKeyList";
373
+ const _TL = "TagList";
374
+ const _TR = "TagResource";
375
+ const _TRR = "TagResourceRequest";
376
+ const _TRRa = "TagResourceResponse";
377
+ const _Ta = "Tag";
378
+ const _UR = "UntagResource";
379
+ const _URR = "UntagResourceRequest";
380
+ const _URRn = "UntagResourceResponse";
381
+ const _V = "Value";
382
+ const _VI = "VpcId";
383
+ const _c = "client";
384
+ const _e = "error";
385
+ const _s = "server";
386
+ const _sm = "smithy.ts.sdk.synthetic.com.amazonaws.cloudhsmv2";
387
+ const n0 = "com.amazonaws.cloudhsmv2";
388
+ var Backup = [
389
+ 3,
390
+ n0,
391
+ _B,
392
+ 0,
393
+ [_BI, _BA, _BS, _CI, _CT, _CTo, _NE, _SR, _SB, _SC, _DT, _TL, _HT, _M],
394
+ [0, 0, 0, 0, 4, 4, 2, 0, 0, 0, 4, () => TagList, 0, 0],
395
+ ];
396
+ var BackupRetentionPolicy = [3, n0, _BRP, 0, [_T, _V], [0, 0]];
397
+ var Certificates = [3, n0, _C, 0, [_CC, _HC, _AHC, _MHC, _CCl], [0, 0, 0, 0, 0]];
398
+ var CloudHsmAccessDeniedException = [
399
+ -3,
400
+ n0,
401
+ _CHADE,
402
+ {
403
+ [_e]: _c,
404
+ },
405
+ [_Me],
406
+ [0],
407
+ ];
408
+ schema.TypeRegistry.for(n0).registerError(CloudHsmAccessDeniedException, CloudHsmAccessDeniedException$1);
409
+ var CloudHsmInternalFailureException = [
410
+ -3,
411
+ n0,
412
+ _CHIFE,
413
+ {
414
+ [_e]: _s,
415
+ },
416
+ [_Me],
417
+ [0],
418
+ ];
419
+ schema.TypeRegistry.for(n0).registerError(CloudHsmInternalFailureException, CloudHsmInternalFailureException$1);
420
+ var CloudHsmInvalidRequestException = [
421
+ -3,
422
+ n0,
423
+ _CHIRE,
424
+ {
425
+ [_e]: _c,
426
+ },
427
+ [_Me],
428
+ [0],
429
+ ];
430
+ schema.TypeRegistry.for(n0).registerError(CloudHsmInvalidRequestException, CloudHsmInvalidRequestException$1);
431
+ var CloudHsmResourceLimitExceededException = [
432
+ -3,
433
+ n0,
434
+ _CHRLEE,
435
+ {
436
+ [_e]: _c,
437
+ },
438
+ [_Me],
439
+ [0],
440
+ ];
441
+ schema.TypeRegistry.for(n0).registerError(CloudHsmResourceLimitExceededException, CloudHsmResourceLimitExceededException$1);
442
+ var CloudHsmResourceNotFoundException = [
443
+ -3,
444
+ n0,
445
+ _CHRNFE,
446
+ {
447
+ [_e]: _c,
448
+ },
449
+ [_Me],
450
+ [0],
451
+ ];
452
+ schema.TypeRegistry.for(n0).registerError(CloudHsmResourceNotFoundException, CloudHsmResourceNotFoundException$1);
453
+ var CloudHsmServiceException = [
454
+ -3,
455
+ n0,
456
+ _CHSE,
457
+ {
458
+ [_e]: _c,
459
+ },
460
+ [_Me],
461
+ [0],
462
+ ];
463
+ schema.TypeRegistry.for(n0).registerError(CloudHsmServiceException, CloudHsmServiceException$1);
464
+ var CloudHsmTagException = [
465
+ -3,
466
+ n0,
467
+ _CHTE,
468
+ {
469
+ [_e]: _c,
470
+ },
471
+ [_Me],
472
+ [0],
473
+ ];
474
+ schema.TypeRegistry.for(n0).registerError(CloudHsmTagException, CloudHsmTagException$1);
475
+ var Cluster = [
476
+ 3,
477
+ n0,
478
+ _Cl,
479
+ 0,
480
+ [_BP, _BRP, _CI, _CT, _H, _HT, _HTRE, _PCP, _SG, _SBI, _S, _SM, _SMu, _VI, _NT, _C, _TL, _M],
481
+ [
482
+ 0,
483
+ () => BackupRetentionPolicy,
484
+ 0,
485
+ 4,
486
+ () => Hsms,
487
+ 0,
488
+ 4,
489
+ 0,
490
+ 0,
491
+ 0,
492
+ 0,
493
+ 0,
494
+ 128 | 0,
495
+ 0,
496
+ 0,
497
+ () => Certificates,
498
+ () => TagList,
499
+ 0,
500
+ ],
501
+ ];
502
+ var CopyBackupToRegionRequest = [
503
+ 3,
504
+ n0,
505
+ _CBTRR,
506
+ 0,
507
+ [_DR, _BI, _TL],
508
+ [0, 0, () => TagList],
509
+ ];
510
+ var CopyBackupToRegionResponse = [3, n0, _CBTRRo, 0, [_DB], [() => DestinationBackup]];
511
+ var CreateClusterRequest = [
512
+ 3,
513
+ n0,
514
+ _CCR,
515
+ 0,
516
+ [_BRP, _HT, _SBI, _SI, _NT, _TL, _M],
517
+ [() => BackupRetentionPolicy, 0, 0, 64 | 0, 0, () => TagList, 0],
518
+ ];
519
+ var CreateClusterResponse = [3, n0, _CCRr, 0, [_Cl], [() => Cluster]];
520
+ var CreateHsmRequest = [3, n0, _CHR, 0, [_CI, _AZ, _IA], [0, 0, 0]];
521
+ var CreateHsmResponse = [3, n0, _CHRr, 0, [_Hs], [() => Hsm]];
522
+ var DeleteBackupRequest = [3, n0, _DBR, 0, [_BI], [0]];
523
+ var DeleteBackupResponse = [3, n0, _DBRe, 0, [_B], [() => Backup]];
524
+ var DeleteClusterRequest = [3, n0, _DCR, 0, [_CI], [0]];
525
+ var DeleteClusterResponse = [3, n0, _DCRe, 0, [_Cl], [() => Cluster]];
526
+ var DeleteHsmRequest = [3, n0, _DHR, 0, [_CI, _HI, _EI, _EIn], [0, 0, 0, 0]];
527
+ var DeleteHsmResponse = [3, n0, _DHRe, 0, [_HI], [0]];
528
+ var DeleteResourcePolicyRequest = [3, n0, _DRPR, 0, [_RA], [0]];
529
+ var DeleteResourcePolicyResponse = [3, n0, _DRPRe, 0, [_RA, _P], [0, 0]];
530
+ var DescribeBackupsRequest = [
531
+ 3,
532
+ n0,
533
+ _DBRes,
534
+ 0,
535
+ [_NTe, _MR, _F, _Sh, _SA],
536
+ [0, 1, [2, n0, _F, 0, 0, 64 | 0], 2, 2],
537
+ ];
538
+ var DescribeBackupsResponse = [3, n0, _DBResc, 0, [_Ba, _NTe], [() => Backups, 0]];
539
+ var DescribeClustersRequest = [
540
+ 3,
541
+ n0,
542
+ _DCRes,
543
+ 0,
544
+ [_F, _NTe, _MR],
545
+ [[2, n0, _F, 0, 0, 64 | 0], 0, 1],
546
+ ];
547
+ var DescribeClustersResponse = [3, n0, _DCResc, 0, [_Clu, _NTe], [() => Clusters, 0]];
548
+ var DestinationBackup = [3, n0, _DB, 0, [_CT, _SR, _SB, _SC], [4, 0, 0, 0]];
549
+ var GetResourcePolicyRequest = [3, n0, _GRPR, 0, [_RA], [0]];
550
+ var GetResourcePolicyResponse = [3, n0, _GRPRe, 0, [_P], [0]];
551
+ var Hsm = [
552
+ 3,
553
+ n0,
554
+ _Hs,
555
+ 0,
556
+ [_AZ, _CI, _SIu, _EI, _EIn, _EIV, _HI, _HT, _S, _SM],
557
+ [0, 0, 0, 0, 0, 0, 0, 0, 0, 0],
558
+ ];
559
+ var InitializeClusterRequest = [3, n0, _ICR, 0, [_CI, _SCi, _TA], [0, 0, 0]];
560
+ var InitializeClusterResponse = [3, n0, _ICRn, 0, [_S, _SM], [0, 0]];
561
+ var ListTagsRequest = [3, n0, _LTR, 0, [_RI, _NTe, _MR], [0, 0, 1]];
562
+ var ListTagsResponse = [3, n0, _LTRi, 0, [_TL, _NTe], [() => TagList, 0]];
563
+ var ModifyBackupAttributesRequest = [3, n0, _MBAR, 0, [_BI, _NE], [0, 2]];
564
+ var ModifyBackupAttributesResponse = [3, n0, _MBARo, 0, [_B], [() => Backup]];
565
+ var ModifyClusterRequest = [
566
+ 3,
567
+ n0,
568
+ _MCR,
569
+ 0,
570
+ [_HT, _BRP, _CI],
571
+ [0, () => BackupRetentionPolicy, 0],
572
+ ];
573
+ var ModifyClusterResponse = [3, n0, _MCRo, 0, [_Cl], [() => Cluster]];
574
+ var PutResourcePolicyRequest = [3, n0, _PRPR, 0, [_RA, _P], [0, 0]];
575
+ var PutResourcePolicyResponse = [3, n0, _PRPRu, 0, [_RA, _P], [0, 0]];
576
+ var RestoreBackupRequest = [3, n0, _RBR, 0, [_BI], [0]];
577
+ var RestoreBackupResponse = [3, n0, _RBRe, 0, [_B], [() => Backup]];
578
+ var Tag = [3, n0, _Ta, 0, [_K, _V], [0, 0]];
579
+ var TagResourceRequest = [3, n0, _TRR, 0, [_RI, _TL], [0, () => TagList]];
580
+ var TagResourceResponse = [3, n0, _TRRa, 0, [], []];
581
+ var UntagResourceRequest = [3, n0, _URR, 0, [_RI, _TKL], [0, 64 | 0]];
582
+ var UntagResourceResponse = [3, n0, _URRn, 0, [], []];
583
+ var CloudHSMV2ServiceException = [-3, _sm, "CloudHSMV2ServiceException", 0, [], []];
584
+ schema.TypeRegistry.for(_sm).registerError(CloudHSMV2ServiceException, CloudHSMV2ServiceException$1);
585
+ var Backups = [1, n0, _Ba, 0, () => Backup];
586
+ var Clusters = [1, n0, _Clu, 0, () => Cluster];
587
+ var Hsms = [1, n0, _H, 0, () => Hsm];
588
+ var TagList = [1, n0, _TL, 0, () => Tag];
589
+ var CopyBackupToRegion = [
590
+ 9,
591
+ n0,
592
+ _CBTR,
593
+ 0,
594
+ () => CopyBackupToRegionRequest,
595
+ () => CopyBackupToRegionResponse,
596
+ ];
597
+ var CreateCluster = [
598
+ 9,
599
+ n0,
600
+ _CCr,
601
+ 0,
602
+ () => CreateClusterRequest,
603
+ () => CreateClusterResponse,
604
+ ];
605
+ var CreateHsm = [9, n0, _CH, 0, () => CreateHsmRequest, () => CreateHsmResponse];
606
+ var DeleteBackup = [
607
+ 9,
608
+ n0,
609
+ _DBe,
610
+ 0,
611
+ () => DeleteBackupRequest,
612
+ () => DeleteBackupResponse,
613
+ ];
614
+ var DeleteCluster = [
615
+ 9,
616
+ n0,
617
+ _DC,
618
+ 0,
619
+ () => DeleteClusterRequest,
620
+ () => DeleteClusterResponse,
621
+ ];
622
+ var DeleteHsm = [9, n0, _DH, 0, () => DeleteHsmRequest, () => DeleteHsmResponse];
623
+ var DeleteResourcePolicy = [
624
+ 9,
625
+ n0,
626
+ _DRP,
627
+ 0,
628
+ () => DeleteResourcePolicyRequest,
629
+ () => DeleteResourcePolicyResponse,
630
+ ];
631
+ var DescribeBackups = [
632
+ 9,
633
+ n0,
634
+ _DBes,
635
+ 0,
636
+ () => DescribeBackupsRequest,
637
+ () => DescribeBackupsResponse,
638
+ ];
639
+ var DescribeClusters = [
640
+ 9,
641
+ n0,
642
+ _DCe,
643
+ 0,
644
+ () => DescribeClustersRequest,
645
+ () => DescribeClustersResponse,
646
+ ];
647
+ var GetResourcePolicy = [
648
+ 9,
649
+ n0,
650
+ _GRP,
651
+ 0,
652
+ () => GetResourcePolicyRequest,
653
+ () => GetResourcePolicyResponse,
654
+ ];
655
+ var InitializeCluster = [
656
+ 9,
657
+ n0,
658
+ _IC,
659
+ 0,
660
+ () => InitializeClusterRequest,
661
+ () => InitializeClusterResponse,
662
+ ];
663
+ var ListTags = [9, n0, _LT, 0, () => ListTagsRequest, () => ListTagsResponse];
664
+ var ModifyBackupAttributes = [
665
+ 9,
666
+ n0,
667
+ _MBA,
668
+ 0,
669
+ () => ModifyBackupAttributesRequest,
670
+ () => ModifyBackupAttributesResponse,
671
+ ];
672
+ var ModifyCluster = [
673
+ 9,
674
+ n0,
675
+ _MC,
676
+ 0,
677
+ () => ModifyClusterRequest,
678
+ () => ModifyClusterResponse,
679
+ ];
680
+ var PutResourcePolicy = [
681
+ 9,
682
+ n0,
683
+ _PRP,
684
+ 0,
685
+ () => PutResourcePolicyRequest,
686
+ () => PutResourcePolicyResponse,
687
+ ];
688
+ var RestoreBackup = [
689
+ 9,
690
+ n0,
691
+ _RB,
692
+ 0,
693
+ () => RestoreBackupRequest,
694
+ () => RestoreBackupResponse,
695
+ ];
696
+ var TagResource = [9, n0, _TR, 0, () => TagResourceRequest, () => TagResourceResponse];
697
+ var UntagResource = [
698
+ 9,
699
+ n0,
700
+ _UR,
701
+ 0,
702
+ () => UntagResourceRequest,
703
+ () => UntagResourceResponse,
704
+ ];
840
705
 
841
706
  class CopyBackupToRegionCommand extends smithyClient.Command
842
707
  .classBuilder()
843
708
  .ep(commonParams)
844
709
  .m(function (Command, cs, config, o) {
845
- return [
846
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
847
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
848
- ];
710
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
849
711
  })
850
712
  .s("BaldrApiService", "CopyBackupToRegion", {})
851
713
  .n("CloudHSMV2Client", "CopyBackupToRegionCommand")
852
- .f(void 0, void 0)
853
- .ser(se_CopyBackupToRegionCommand)
854
- .de(de_CopyBackupToRegionCommand)
714
+ .sc(CopyBackupToRegion)
855
715
  .build() {
856
716
  }
857
717
 
@@ -859,16 +719,11 @@ class CreateClusterCommand extends smithyClient.Command
859
719
  .classBuilder()
860
720
  .ep(commonParams)
861
721
  .m(function (Command, cs, config, o) {
862
- return [
863
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
864
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
865
- ];
722
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
866
723
  })
867
724
  .s("BaldrApiService", "CreateCluster", {})
868
725
  .n("CloudHSMV2Client", "CreateClusterCommand")
869
- .f(void 0, void 0)
870
- .ser(se_CreateClusterCommand)
871
- .de(de_CreateClusterCommand)
726
+ .sc(CreateCluster)
872
727
  .build() {
873
728
  }
874
729
 
@@ -876,16 +731,11 @@ class CreateHsmCommand extends smithyClient.Command
876
731
  .classBuilder()
877
732
  .ep(commonParams)
878
733
  .m(function (Command, cs, config, o) {
879
- return [
880
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
881
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
882
- ];
734
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
883
735
  })
884
736
  .s("BaldrApiService", "CreateHsm", {})
885
737
  .n("CloudHSMV2Client", "CreateHsmCommand")
886
- .f(void 0, void 0)
887
- .ser(se_CreateHsmCommand)
888
- .de(de_CreateHsmCommand)
738
+ .sc(CreateHsm)
889
739
  .build() {
890
740
  }
891
741
 
@@ -893,16 +743,11 @@ class DeleteBackupCommand extends smithyClient.Command
893
743
  .classBuilder()
894
744
  .ep(commonParams)
895
745
  .m(function (Command, cs, config, o) {
896
- return [
897
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
898
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
899
- ];
746
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
900
747
  })
901
748
  .s("BaldrApiService", "DeleteBackup", {})
902
749
  .n("CloudHSMV2Client", "DeleteBackupCommand")
903
- .f(void 0, void 0)
904
- .ser(se_DeleteBackupCommand)
905
- .de(de_DeleteBackupCommand)
750
+ .sc(DeleteBackup)
906
751
  .build() {
907
752
  }
908
753
 
@@ -910,16 +755,11 @@ class DeleteClusterCommand extends smithyClient.Command
910
755
  .classBuilder()
911
756
  .ep(commonParams)
912
757
  .m(function (Command, cs, config, o) {
913
- return [
914
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
915
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
916
- ];
758
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
917
759
  })
918
760
  .s("BaldrApiService", "DeleteCluster", {})
919
761
  .n("CloudHSMV2Client", "DeleteClusterCommand")
920
- .f(void 0, void 0)
921
- .ser(se_DeleteClusterCommand)
922
- .de(de_DeleteClusterCommand)
762
+ .sc(DeleteCluster)
923
763
  .build() {
924
764
  }
925
765
 
@@ -927,16 +767,11 @@ class DeleteHsmCommand extends smithyClient.Command
927
767
  .classBuilder()
928
768
  .ep(commonParams)
929
769
  .m(function (Command, cs, config, o) {
930
- return [
931
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
932
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
933
- ];
770
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
934
771
  })
935
772
  .s("BaldrApiService", "DeleteHsm", {})
936
773
  .n("CloudHSMV2Client", "DeleteHsmCommand")
937
- .f(void 0, void 0)
938
- .ser(se_DeleteHsmCommand)
939
- .de(de_DeleteHsmCommand)
774
+ .sc(DeleteHsm)
940
775
  .build() {
941
776
  }
942
777
 
@@ -944,16 +779,11 @@ class DeleteResourcePolicyCommand extends smithyClient.Command
944
779
  .classBuilder()
945
780
  .ep(commonParams)
946
781
  .m(function (Command, cs, config, o) {
947
- return [
948
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
949
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
950
- ];
782
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
951
783
  })
952
784
  .s("BaldrApiService", "DeleteResourcePolicy", {})
953
785
  .n("CloudHSMV2Client", "DeleteResourcePolicyCommand")
954
- .f(void 0, void 0)
955
- .ser(se_DeleteResourcePolicyCommand)
956
- .de(de_DeleteResourcePolicyCommand)
786
+ .sc(DeleteResourcePolicy)
957
787
  .build() {
958
788
  }
959
789
 
@@ -961,16 +791,11 @@ class DescribeBackupsCommand extends smithyClient.Command
961
791
  .classBuilder()
962
792
  .ep(commonParams)
963
793
  .m(function (Command, cs, config, o) {
964
- return [
965
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
966
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
967
- ];
794
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
968
795
  })
969
796
  .s("BaldrApiService", "DescribeBackups", {})
970
797
  .n("CloudHSMV2Client", "DescribeBackupsCommand")
971
- .f(void 0, void 0)
972
- .ser(se_DescribeBackupsCommand)
973
- .de(de_DescribeBackupsCommand)
798
+ .sc(DescribeBackups)
974
799
  .build() {
975
800
  }
976
801
 
@@ -978,16 +803,11 @@ class DescribeClustersCommand extends smithyClient.Command
978
803
  .classBuilder()
979
804
  .ep(commonParams)
980
805
  .m(function (Command, cs, config, o) {
981
- return [
982
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
983
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
984
- ];
806
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
985
807
  })
986
808
  .s("BaldrApiService", "DescribeClusters", {})
987
809
  .n("CloudHSMV2Client", "DescribeClustersCommand")
988
- .f(void 0, void 0)
989
- .ser(se_DescribeClustersCommand)
990
- .de(de_DescribeClustersCommand)
810
+ .sc(DescribeClusters)
991
811
  .build() {
992
812
  }
993
813
 
@@ -995,16 +815,11 @@ class GetResourcePolicyCommand extends smithyClient.Command
995
815
  .classBuilder()
996
816
  .ep(commonParams)
997
817
  .m(function (Command, cs, config, o) {
998
- return [
999
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1000
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1001
- ];
818
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1002
819
  })
1003
820
  .s("BaldrApiService", "GetResourcePolicy", {})
1004
821
  .n("CloudHSMV2Client", "GetResourcePolicyCommand")
1005
- .f(void 0, void 0)
1006
- .ser(se_GetResourcePolicyCommand)
1007
- .de(de_GetResourcePolicyCommand)
822
+ .sc(GetResourcePolicy)
1008
823
  .build() {
1009
824
  }
1010
825
 
@@ -1012,16 +827,11 @@ class InitializeClusterCommand extends smithyClient.Command
1012
827
  .classBuilder()
1013
828
  .ep(commonParams)
1014
829
  .m(function (Command, cs, config, o) {
1015
- return [
1016
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1017
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1018
- ];
830
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1019
831
  })
1020
832
  .s("BaldrApiService", "InitializeCluster", {})
1021
833
  .n("CloudHSMV2Client", "InitializeClusterCommand")
1022
- .f(void 0, void 0)
1023
- .ser(se_InitializeClusterCommand)
1024
- .de(de_InitializeClusterCommand)
834
+ .sc(InitializeCluster)
1025
835
  .build() {
1026
836
  }
1027
837
 
@@ -1029,16 +839,11 @@ class ListTagsCommand extends smithyClient.Command
1029
839
  .classBuilder()
1030
840
  .ep(commonParams)
1031
841
  .m(function (Command, cs, config, o) {
1032
- return [
1033
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1034
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1035
- ];
842
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1036
843
  })
1037
844
  .s("BaldrApiService", "ListTags", {})
1038
845
  .n("CloudHSMV2Client", "ListTagsCommand")
1039
- .f(void 0, void 0)
1040
- .ser(se_ListTagsCommand)
1041
- .de(de_ListTagsCommand)
846
+ .sc(ListTags)
1042
847
  .build() {
1043
848
  }
1044
849
 
@@ -1046,16 +851,11 @@ class ModifyBackupAttributesCommand extends smithyClient.Command
1046
851
  .classBuilder()
1047
852
  .ep(commonParams)
1048
853
  .m(function (Command, cs, config, o) {
1049
- return [
1050
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1051
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1052
- ];
854
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1053
855
  })
1054
856
  .s("BaldrApiService", "ModifyBackupAttributes", {})
1055
857
  .n("CloudHSMV2Client", "ModifyBackupAttributesCommand")
1056
- .f(void 0, void 0)
1057
- .ser(se_ModifyBackupAttributesCommand)
1058
- .de(de_ModifyBackupAttributesCommand)
858
+ .sc(ModifyBackupAttributes)
1059
859
  .build() {
1060
860
  }
1061
861
 
@@ -1063,16 +863,11 @@ class ModifyClusterCommand extends smithyClient.Command
1063
863
  .classBuilder()
1064
864
  .ep(commonParams)
1065
865
  .m(function (Command, cs, config, o) {
1066
- return [
1067
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1068
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1069
- ];
866
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1070
867
  })
1071
868
  .s("BaldrApiService", "ModifyCluster", {})
1072
869
  .n("CloudHSMV2Client", "ModifyClusterCommand")
1073
- .f(void 0, void 0)
1074
- .ser(se_ModifyClusterCommand)
1075
- .de(de_ModifyClusterCommand)
870
+ .sc(ModifyCluster)
1076
871
  .build() {
1077
872
  }
1078
873
 
@@ -1080,16 +875,11 @@ class PutResourcePolicyCommand extends smithyClient.Command
1080
875
  .classBuilder()
1081
876
  .ep(commonParams)
1082
877
  .m(function (Command, cs, config, o) {
1083
- return [
1084
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1085
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1086
- ];
878
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1087
879
  })
1088
880
  .s("BaldrApiService", "PutResourcePolicy", {})
1089
881
  .n("CloudHSMV2Client", "PutResourcePolicyCommand")
1090
- .f(void 0, void 0)
1091
- .ser(se_PutResourcePolicyCommand)
1092
- .de(de_PutResourcePolicyCommand)
882
+ .sc(PutResourcePolicy)
1093
883
  .build() {
1094
884
  }
1095
885
 
@@ -1097,16 +887,11 @@ class RestoreBackupCommand extends smithyClient.Command
1097
887
  .classBuilder()
1098
888
  .ep(commonParams)
1099
889
  .m(function (Command, cs, config, o) {
1100
- return [
1101
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1102
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1103
- ];
890
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1104
891
  })
1105
892
  .s("BaldrApiService", "RestoreBackup", {})
1106
893
  .n("CloudHSMV2Client", "RestoreBackupCommand")
1107
- .f(void 0, void 0)
1108
- .ser(se_RestoreBackupCommand)
1109
- .de(de_RestoreBackupCommand)
894
+ .sc(RestoreBackup)
1110
895
  .build() {
1111
896
  }
1112
897
 
@@ -1114,16 +899,11 @@ class TagResourceCommand extends smithyClient.Command
1114
899
  .classBuilder()
1115
900
  .ep(commonParams)
1116
901
  .m(function (Command, cs, config, o) {
1117
- return [
1118
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1119
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1120
- ];
902
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1121
903
  })
1122
904
  .s("BaldrApiService", "TagResource", {})
1123
905
  .n("CloudHSMV2Client", "TagResourceCommand")
1124
- .f(void 0, void 0)
1125
- .ser(se_TagResourceCommand)
1126
- .de(de_TagResourceCommand)
906
+ .sc(TagResource)
1127
907
  .build() {
1128
908
  }
1129
909
 
@@ -1131,16 +911,11 @@ class UntagResourceCommand extends smithyClient.Command
1131
911
  .classBuilder()
1132
912
  .ep(commonParams)
1133
913
  .m(function (Command, cs, config, o) {
1134
- return [
1135
- middlewareSerde.getSerdePlugin(config, this.serialize, this.deserialize),
1136
- middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
1137
- ];
914
+ return [middlewareEndpoint.getEndpointPlugin(config, Command.getEndpointParameterInstructions())];
1138
915
  })
1139
916
  .s("BaldrApiService", "UntagResource", {})
1140
917
  .n("CloudHSMV2Client", "UntagResourceCommand")
1141
- .f(void 0, void 0)
1142
- .ser(se_UntagResourceCommand)
1143
- .de(de_UntagResourceCommand)
918
+ .sc(UntagResource)
1144
919
  .build() {
1145
920
  }
1146
921
 
@@ -1187,14 +962,14 @@ exports.BackupRetentionType = BackupRetentionType;
1187
962
  exports.BackupState = BackupState;
1188
963
  exports.CloudHSMV2 = CloudHSMV2;
1189
964
  exports.CloudHSMV2Client = CloudHSMV2Client;
1190
- exports.CloudHSMV2ServiceException = CloudHSMV2ServiceException;
1191
- exports.CloudHsmAccessDeniedException = CloudHsmAccessDeniedException;
1192
- exports.CloudHsmInternalFailureException = CloudHsmInternalFailureException;
1193
- exports.CloudHsmInvalidRequestException = CloudHsmInvalidRequestException;
1194
- exports.CloudHsmResourceLimitExceededException = CloudHsmResourceLimitExceededException;
1195
- exports.CloudHsmResourceNotFoundException = CloudHsmResourceNotFoundException;
1196
- exports.CloudHsmServiceException = CloudHsmServiceException;
1197
- exports.CloudHsmTagException = CloudHsmTagException;
965
+ exports.CloudHSMV2ServiceException = CloudHSMV2ServiceException$1;
966
+ exports.CloudHsmAccessDeniedException = CloudHsmAccessDeniedException$1;
967
+ exports.CloudHsmInternalFailureException = CloudHsmInternalFailureException$1;
968
+ exports.CloudHsmInvalidRequestException = CloudHsmInvalidRequestException$1;
969
+ exports.CloudHsmResourceLimitExceededException = CloudHsmResourceLimitExceededException$1;
970
+ exports.CloudHsmResourceNotFoundException = CloudHsmResourceNotFoundException$1;
971
+ exports.CloudHsmServiceException = CloudHsmServiceException$1;
972
+ exports.CloudHsmTagException = CloudHsmTagException$1;
1198
973
  exports.ClusterMode = ClusterMode;
1199
974
  exports.ClusterState = ClusterState;
1200
975
  exports.CopyBackupToRegionCommand = CopyBackupToRegionCommand;