@aws-sdk/client-cloudhsm-v2 3.600.0 → 3.607.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 (41) hide show
  1. package/README.md +25 -1
  2. package/dist-cjs/index.js +115 -0
  3. package/dist-es/CloudHSMV2.js +6 -0
  4. package/dist-es/commands/DeleteResourcePolicyCommand.js +24 -0
  5. package/dist-es/commands/GetResourcePolicyCommand.js +24 -0
  6. package/dist-es/commands/PutResourcePolicyCommand.js +24 -0
  7. package/dist-es/commands/index.js +3 -0
  8. package/dist-es/protocols/Aws_json1_1.js +58 -0
  9. package/dist-types/CloudHSMV2.d.ts +25 -1
  10. package/dist-types/CloudHSMV2Client.d.ts +6 -3
  11. package/dist-types/commands/CopyBackupToRegionCommand.d.ts +4 -2
  12. package/dist-types/commands/CreateClusterCommand.d.ts +5 -2
  13. package/dist-types/commands/CreateHsmCommand.d.ts +4 -2
  14. package/dist-types/commands/DeleteBackupCommand.d.ts +5 -2
  15. package/dist-types/commands/DeleteClusterCommand.d.ts +4 -2
  16. package/dist-types/commands/DeleteHsmCommand.d.ts +3 -1
  17. package/dist-types/commands/DeleteResourcePolicyCommand.d.ts +83 -0
  18. package/dist-types/commands/DescribeBackupsCommand.d.ts +6 -2
  19. package/dist-types/commands/DescribeClustersCommand.d.ts +4 -2
  20. package/dist-types/commands/GetResourcePolicyCommand.d.ts +80 -0
  21. package/dist-types/commands/InitializeClusterCommand.d.ts +4 -2
  22. package/dist-types/commands/ListTagsCommand.d.ts +4 -2
  23. package/dist-types/commands/ModifyBackupAttributesCommand.d.ts +5 -2
  24. package/dist-types/commands/ModifyClusterCommand.d.ts +4 -2
  25. package/dist-types/commands/PutResourcePolicyCommand.d.ts +99 -0
  26. package/dist-types/commands/RestoreBackupCommand.d.ts +6 -3
  27. package/dist-types/commands/TagResourceCommand.d.ts +4 -2
  28. package/dist-types/commands/UntagResourceCommand.d.ts +4 -2
  29. package/dist-types/commands/index.d.ts +3 -0
  30. package/dist-types/index.d.ts +1 -1
  31. package/dist-types/models/models_0.d.ts +104 -10
  32. package/dist-types/protocols/Aws_json1_1.d.ts +27 -0
  33. package/dist-types/ts3.4/CloudHSMV2.d.ts +54 -0
  34. package/dist-types/ts3.4/CloudHSMV2Client.d.ts +18 -0
  35. package/dist-types/ts3.4/commands/DeleteResourcePolicyCommand.d.ts +40 -0
  36. package/dist-types/ts3.4/commands/GetResourcePolicyCommand.d.ts +40 -0
  37. package/dist-types/ts3.4/commands/PutResourcePolicyCommand.d.ts +40 -0
  38. package/dist-types/ts3.4/commands/index.d.ts +3 -0
  39. package/dist-types/ts3.4/models/models_0.d.ts +23 -0
  40. package/dist-types/ts3.4/protocols/Aws_json1_1.d.ts +36 -0
  41. package/package.json +3 -3
package/README.md CHANGED
@@ -6,7 +6,7 @@
6
6
 
7
7
  AWS SDK for JavaScript CloudHSMV2 Client for Node.js, Browser and React Native.
8
8
 
9
- <p>For more information about AWS CloudHSM, see <a href="http://aws.amazon.com/cloudhsm/">AWS CloudHSM</a> and the <a href="https://docs.aws.amazon.com/cloudhsm/latest/userguide/">AWS
9
+ <p>For more information about CloudHSM, see <a href="http://aws.amazon.com/cloudhsm/">CloudHSM</a> and the <a href="https://docs.aws.amazon.com/cloudhsm/latest/userguide/">
10
10
  CloudHSM User Guide</a>.</p>
11
11
 
12
12
  ## Installing
@@ -251,6 +251,14 @@ DeleteHsm
251
251
 
252
252
  [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudhsm-v2/command/DeleteHsmCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/DeleteHsmCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/DeleteHsmCommandOutput/)
253
253
 
254
+ </details>
255
+ <details>
256
+ <summary>
257
+ DeleteResourcePolicy
258
+ </summary>
259
+
260
+ [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudhsm-v2/command/DeleteResourcePolicyCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/DeleteResourcePolicyCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/DeleteResourcePolicyCommandOutput/)
261
+
254
262
  </details>
255
263
  <details>
256
264
  <summary>
@@ -267,6 +275,14 @@ DescribeClusters
267
275
 
268
276
  [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudhsm-v2/command/DescribeClustersCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/DescribeClustersCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/DescribeClustersCommandOutput/)
269
277
 
278
+ </details>
279
+ <details>
280
+ <summary>
281
+ GetResourcePolicy
282
+ </summary>
283
+
284
+ [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudhsm-v2/command/GetResourcePolicyCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/GetResourcePolicyCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/GetResourcePolicyCommandOutput/)
285
+
270
286
  </details>
271
287
  <details>
272
288
  <summary>
@@ -299,6 +315,14 @@ ModifyCluster
299
315
 
300
316
  [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudhsm-v2/command/ModifyClusterCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/ModifyClusterCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/ModifyClusterCommandOutput/)
301
317
 
318
+ </details>
319
+ <details>
320
+ <summary>
321
+ PutResourcePolicy
322
+ </summary>
323
+
324
+ [Command API Reference](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/client/cloudhsm-v2/command/PutResourcePolicyCommand/) / [Input](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/PutResourcePolicyCommandInput/) / [Output](https://docs.aws.amazon.com/AWSJavaScriptSDK/v3/latest/Package/-aws-sdk-client-cloudhsm-v2/Interface/PutResourcePolicyCommandOutput/)
325
+
302
326
  </details>
303
327
  <details>
304
328
  <summary>
package/dist-cjs/index.js CHANGED
@@ -41,13 +41,16 @@ __export(src_exports, {
41
41
  DeleteBackupCommand: () => DeleteBackupCommand,
42
42
  DeleteClusterCommand: () => DeleteClusterCommand,
43
43
  DeleteHsmCommand: () => DeleteHsmCommand,
44
+ DeleteResourcePolicyCommand: () => DeleteResourcePolicyCommand,
44
45
  DescribeBackupsCommand: () => DescribeBackupsCommand,
45
46
  DescribeClustersCommand: () => DescribeClustersCommand,
47
+ GetResourcePolicyCommand: () => GetResourcePolicyCommand,
46
48
  HsmState: () => HsmState,
47
49
  InitializeClusterCommand: () => InitializeClusterCommand,
48
50
  ListTagsCommand: () => ListTagsCommand,
49
51
  ModifyBackupAttributesCommand: () => ModifyBackupAttributesCommand,
50
52
  ModifyClusterCommand: () => ModifyClusterCommand,
53
+ PutResourcePolicyCommand: () => PutResourcePolicyCommand,
51
54
  RestoreBackupCommand: () => RestoreBackupCommand,
52
55
  TagResourceCommand: () => TagResourceCommand,
53
56
  UntagResourceCommand: () => UntagResourceCommand,
@@ -409,6 +412,12 @@ var se_DeleteHsmCommand = /* @__PURE__ */ __name(async (input, context) => {
409
412
  body = JSON.stringify((0, import_smithy_client._json)(input));
410
413
  return buildHttpRpcRequest(context, headers, "/", void 0, body);
411
414
  }, "se_DeleteHsmCommand");
415
+ var se_DeleteResourcePolicyCommand = /* @__PURE__ */ __name(async (input, context) => {
416
+ const headers = sharedHeaders("DeleteResourcePolicy");
417
+ let body;
418
+ body = JSON.stringify((0, import_smithy_client._json)(input));
419
+ return buildHttpRpcRequest(context, headers, "/", void 0, body);
420
+ }, "se_DeleteResourcePolicyCommand");
412
421
  var se_DescribeBackupsCommand = /* @__PURE__ */ __name(async (input, context) => {
413
422
  const headers = sharedHeaders("DescribeBackups");
414
423
  let body;
@@ -421,6 +430,12 @@ var se_DescribeClustersCommand = /* @__PURE__ */ __name(async (input, context) =
421
430
  body = JSON.stringify((0, import_smithy_client._json)(input));
422
431
  return buildHttpRpcRequest(context, headers, "/", void 0, body);
423
432
  }, "se_DescribeClustersCommand");
433
+ var se_GetResourcePolicyCommand = /* @__PURE__ */ __name(async (input, context) => {
434
+ const headers = sharedHeaders("GetResourcePolicy");
435
+ let body;
436
+ body = JSON.stringify((0, import_smithy_client._json)(input));
437
+ return buildHttpRpcRequest(context, headers, "/", void 0, body);
438
+ }, "se_GetResourcePolicyCommand");
424
439
  var se_InitializeClusterCommand = /* @__PURE__ */ __name(async (input, context) => {
425
440
  const headers = sharedHeaders("InitializeCluster");
426
441
  let body;
@@ -445,6 +460,12 @@ var se_ModifyClusterCommand = /* @__PURE__ */ __name(async (input, context) => {
445
460
  body = JSON.stringify((0, import_smithy_client._json)(input));
446
461
  return buildHttpRpcRequest(context, headers, "/", void 0, body);
447
462
  }, "se_ModifyClusterCommand");
463
+ var se_PutResourcePolicyCommand = /* @__PURE__ */ __name(async (input, context) => {
464
+ const headers = sharedHeaders("PutResourcePolicy");
465
+ let body;
466
+ body = JSON.stringify((0, import_smithy_client._json)(input));
467
+ return buildHttpRpcRequest(context, headers, "/", void 0, body);
468
+ }, "se_PutResourcePolicyCommand");
448
469
  var se_RestoreBackupCommand = /* @__PURE__ */ __name(async (input, context) => {
449
470
  const headers = sharedHeaders("RestoreBackup");
450
471
  let body;
@@ -541,6 +562,19 @@ var de_DeleteHsmCommand = /* @__PURE__ */ __name(async (output, context) => {
541
562
  };
542
563
  return response;
543
564
  }, "de_DeleteHsmCommand");
565
+ var de_DeleteResourcePolicyCommand = /* @__PURE__ */ __name(async (output, context) => {
566
+ if (output.statusCode >= 300) {
567
+ return de_CommandError(output, context);
568
+ }
569
+ const data = await (0, import_core2.parseJsonBody)(output.body, context);
570
+ let contents = {};
571
+ contents = (0, import_smithy_client._json)(data);
572
+ const response = {
573
+ $metadata: deserializeMetadata(output),
574
+ ...contents
575
+ };
576
+ return response;
577
+ }, "de_DeleteResourcePolicyCommand");
544
578
  var de_DescribeBackupsCommand = /* @__PURE__ */ __name(async (output, context) => {
545
579
  if (output.statusCode >= 300) {
546
580
  return de_CommandError(output, context);
@@ -567,6 +601,19 @@ var de_DescribeClustersCommand = /* @__PURE__ */ __name(async (output, context)
567
601
  };
568
602
  return response;
569
603
  }, "de_DescribeClustersCommand");
604
+ var de_GetResourcePolicyCommand = /* @__PURE__ */ __name(async (output, context) => {
605
+ if (output.statusCode >= 300) {
606
+ return de_CommandError(output, context);
607
+ }
608
+ const data = await (0, import_core2.parseJsonBody)(output.body, context);
609
+ let contents = {};
610
+ contents = (0, import_smithy_client._json)(data);
611
+ const response = {
612
+ $metadata: deserializeMetadata(output),
613
+ ...contents
614
+ };
615
+ return response;
616
+ }, "de_GetResourcePolicyCommand");
570
617
  var de_InitializeClusterCommand = /* @__PURE__ */ __name(async (output, context) => {
571
618
  if (output.statusCode >= 300) {
572
619
  return de_CommandError(output, context);
@@ -619,6 +666,19 @@ var de_ModifyClusterCommand = /* @__PURE__ */ __name(async (output, context) =>
619
666
  };
620
667
  return response;
621
668
  }, "de_ModifyClusterCommand");
669
+ var de_PutResourcePolicyCommand = /* @__PURE__ */ __name(async (output, context) => {
670
+ if (output.statusCode >= 300) {
671
+ return de_CommandError(output, context);
672
+ }
673
+ const data = await (0, import_core2.parseJsonBody)(output.body, context);
674
+ let contents = {};
675
+ contents = (0, import_smithy_client._json)(data);
676
+ const response = {
677
+ $metadata: deserializeMetadata(output),
678
+ ...contents
679
+ };
680
+ return response;
681
+ }, "de_PutResourcePolicyCommand");
622
682
  var de_RestoreBackupCommand = /* @__PURE__ */ __name(async (output, context) => {
623
683
  if (output.statusCode >= 300) {
624
684
  return de_CommandError(output, context);
@@ -748,6 +808,7 @@ var de_CloudHsmTagExceptionRes = /* @__PURE__ */ __name(async (parsedOutput, con
748
808
  }, "de_CloudHsmTagExceptionRes");
749
809
  var de_Backup = /* @__PURE__ */ __name((output, context) => {
750
810
  return (0, import_smithy_client.take)(output, {
811
+ BackupArn: import_smithy_client.expectString,
751
812
  BackupId: import_smithy_client.expectString,
752
813
  BackupState: import_smithy_client.expectString,
753
814
  ClusterId: import_smithy_client.expectString,
@@ -976,6 +1037,22 @@ var _DeleteHsmCommand = class _DeleteHsmCommand extends import_smithy_client.Com
976
1037
  __name(_DeleteHsmCommand, "DeleteHsmCommand");
977
1038
  var DeleteHsmCommand = _DeleteHsmCommand;
978
1039
 
1040
+ // src/commands/DeleteResourcePolicyCommand.ts
1041
+
1042
+
1043
+
1044
+ var _DeleteResourcePolicyCommand = class _DeleteResourcePolicyCommand extends import_smithy_client.Command.classBuilder().ep({
1045
+ ...commonParams
1046
+ }).m(function(Command, cs, config, o) {
1047
+ return [
1048
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1049
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1050
+ ];
1051
+ }).s("BaldrApiService", "DeleteResourcePolicy", {}).n("CloudHSMV2Client", "DeleteResourcePolicyCommand").f(void 0, void 0).ser(se_DeleteResourcePolicyCommand).de(de_DeleteResourcePolicyCommand).build() {
1052
+ };
1053
+ __name(_DeleteResourcePolicyCommand, "DeleteResourcePolicyCommand");
1054
+ var DeleteResourcePolicyCommand = _DeleteResourcePolicyCommand;
1055
+
979
1056
  // src/commands/DescribeBackupsCommand.ts
980
1057
 
981
1058
 
@@ -1008,6 +1085,22 @@ var _DescribeClustersCommand = class _DescribeClustersCommand extends import_smi
1008
1085
  __name(_DescribeClustersCommand, "DescribeClustersCommand");
1009
1086
  var DescribeClustersCommand = _DescribeClustersCommand;
1010
1087
 
1088
+ // src/commands/GetResourcePolicyCommand.ts
1089
+
1090
+
1091
+
1092
+ var _GetResourcePolicyCommand = class _GetResourcePolicyCommand extends import_smithy_client.Command.classBuilder().ep({
1093
+ ...commonParams
1094
+ }).m(function(Command, cs, config, o) {
1095
+ return [
1096
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1097
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1098
+ ];
1099
+ }).s("BaldrApiService", "GetResourcePolicy", {}).n("CloudHSMV2Client", "GetResourcePolicyCommand").f(void 0, void 0).ser(se_GetResourcePolicyCommand).de(de_GetResourcePolicyCommand).build() {
1100
+ };
1101
+ __name(_GetResourcePolicyCommand, "GetResourcePolicyCommand");
1102
+ var GetResourcePolicyCommand = _GetResourcePolicyCommand;
1103
+
1011
1104
  // src/commands/InitializeClusterCommand.ts
1012
1105
 
1013
1106
 
@@ -1072,6 +1165,22 @@ var _ModifyClusterCommand = class _ModifyClusterCommand extends import_smithy_cl
1072
1165
  __name(_ModifyClusterCommand, "ModifyClusterCommand");
1073
1166
  var ModifyClusterCommand = _ModifyClusterCommand;
1074
1167
 
1168
+ // src/commands/PutResourcePolicyCommand.ts
1169
+
1170
+
1171
+
1172
+ var _PutResourcePolicyCommand = class _PutResourcePolicyCommand extends import_smithy_client.Command.classBuilder().ep({
1173
+ ...commonParams
1174
+ }).m(function(Command, cs, config, o) {
1175
+ return [
1176
+ (0, import_middleware_serde.getSerdePlugin)(config, this.serialize, this.deserialize),
1177
+ (0, import_middleware_endpoint.getEndpointPlugin)(config, Command.getEndpointParameterInstructions())
1178
+ ];
1179
+ }).s("BaldrApiService", "PutResourcePolicy", {}).n("CloudHSMV2Client", "PutResourcePolicyCommand").f(void 0, void 0).ser(se_PutResourcePolicyCommand).de(de_PutResourcePolicyCommand).build() {
1180
+ };
1181
+ __name(_PutResourcePolicyCommand, "PutResourcePolicyCommand");
1182
+ var PutResourcePolicyCommand = _PutResourcePolicyCommand;
1183
+
1075
1184
  // src/commands/RestoreBackupCommand.ts
1076
1185
 
1077
1186
 
@@ -1128,12 +1237,15 @@ var commands = {
1128
1237
  DeleteBackupCommand,
1129
1238
  DeleteClusterCommand,
1130
1239
  DeleteHsmCommand,
1240
+ DeleteResourcePolicyCommand,
1131
1241
  DescribeBackupsCommand,
1132
1242
  DescribeClustersCommand,
1243
+ GetResourcePolicyCommand,
1133
1244
  InitializeClusterCommand,
1134
1245
  ListTagsCommand,
1135
1246
  ModifyBackupAttributesCommand,
1136
1247
  ModifyClusterCommand,
1248
+ PutResourcePolicyCommand,
1137
1249
  RestoreBackupCommand,
1138
1250
  TagResourceCommand,
1139
1251
  UntagResourceCommand
@@ -1169,12 +1281,15 @@ var paginateListTags = (0, import_core.createPaginator)(CloudHSMV2Client, ListTa
1169
1281
  DeleteBackupCommand,
1170
1282
  DeleteClusterCommand,
1171
1283
  DeleteHsmCommand,
1284
+ DeleteResourcePolicyCommand,
1172
1285
  DescribeBackupsCommand,
1173
1286
  DescribeClustersCommand,
1287
+ GetResourcePolicyCommand,
1174
1288
  InitializeClusterCommand,
1175
1289
  ListTagsCommand,
1176
1290
  ModifyBackupAttributesCommand,
1177
1291
  ModifyClusterCommand,
1292
+ PutResourcePolicyCommand,
1178
1293
  RestoreBackupCommand,
1179
1294
  TagResourceCommand,
1180
1295
  UntagResourceCommand,
@@ -6,12 +6,15 @@ import { CreateHsmCommand } from "./commands/CreateHsmCommand";
6
6
  import { DeleteBackupCommand, } from "./commands/DeleteBackupCommand";
7
7
  import { DeleteClusterCommand, } from "./commands/DeleteClusterCommand";
8
8
  import { DeleteHsmCommand } from "./commands/DeleteHsmCommand";
9
+ import { DeleteResourcePolicyCommand, } from "./commands/DeleteResourcePolicyCommand";
9
10
  import { DescribeBackupsCommand, } from "./commands/DescribeBackupsCommand";
10
11
  import { DescribeClustersCommand, } from "./commands/DescribeClustersCommand";
12
+ import { GetResourcePolicyCommand, } from "./commands/GetResourcePolicyCommand";
11
13
  import { InitializeClusterCommand, } from "./commands/InitializeClusterCommand";
12
14
  import { ListTagsCommand } from "./commands/ListTagsCommand";
13
15
  import { ModifyBackupAttributesCommand, } from "./commands/ModifyBackupAttributesCommand";
14
16
  import { ModifyClusterCommand, } from "./commands/ModifyClusterCommand";
17
+ import { PutResourcePolicyCommand, } from "./commands/PutResourcePolicyCommand";
15
18
  import { RestoreBackupCommand, } from "./commands/RestoreBackupCommand";
16
19
  import { TagResourceCommand } from "./commands/TagResourceCommand";
17
20
  import { UntagResourceCommand, } from "./commands/UntagResourceCommand";
@@ -22,12 +25,15 @@ const commands = {
22
25
  DeleteBackupCommand,
23
26
  DeleteClusterCommand,
24
27
  DeleteHsmCommand,
28
+ DeleteResourcePolicyCommand,
25
29
  DescribeBackupsCommand,
26
30
  DescribeClustersCommand,
31
+ GetResourcePolicyCommand,
27
32
  InitializeClusterCommand,
28
33
  ListTagsCommand,
29
34
  ModifyBackupAttributesCommand,
30
35
  ModifyClusterCommand,
36
+ PutResourcePolicyCommand,
31
37
  RestoreBackupCommand,
32
38
  TagResourceCommand,
33
39
  UntagResourceCommand,
@@ -0,0 +1,24 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { commonParams } from "../endpoint/EndpointParameters";
5
+ import { de_DeleteResourcePolicyCommand, se_DeleteResourcePolicyCommand } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class DeleteResourcePolicyCommand extends $Command
8
+ .classBuilder()
9
+ .ep({
10
+ ...commonParams,
11
+ })
12
+ .m(function (Command, cs, config, o) {
13
+ return [
14
+ getSerdePlugin(config, this.serialize, this.deserialize),
15
+ getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
16
+ ];
17
+ })
18
+ .s("BaldrApiService", "DeleteResourcePolicy", {})
19
+ .n("CloudHSMV2Client", "DeleteResourcePolicyCommand")
20
+ .f(void 0, void 0)
21
+ .ser(se_DeleteResourcePolicyCommand)
22
+ .de(de_DeleteResourcePolicyCommand)
23
+ .build() {
24
+ }
@@ -0,0 +1,24 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { commonParams } from "../endpoint/EndpointParameters";
5
+ import { de_GetResourcePolicyCommand, se_GetResourcePolicyCommand } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class GetResourcePolicyCommand extends $Command
8
+ .classBuilder()
9
+ .ep({
10
+ ...commonParams,
11
+ })
12
+ .m(function (Command, cs, config, o) {
13
+ return [
14
+ getSerdePlugin(config, this.serialize, this.deserialize),
15
+ getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
16
+ ];
17
+ })
18
+ .s("BaldrApiService", "GetResourcePolicy", {})
19
+ .n("CloudHSMV2Client", "GetResourcePolicyCommand")
20
+ .f(void 0, void 0)
21
+ .ser(se_GetResourcePolicyCommand)
22
+ .de(de_GetResourcePolicyCommand)
23
+ .build() {
24
+ }
@@ -0,0 +1,24 @@
1
+ import { getEndpointPlugin } from "@smithy/middleware-endpoint";
2
+ import { getSerdePlugin } from "@smithy/middleware-serde";
3
+ import { Command as $Command } from "@smithy/smithy-client";
4
+ import { commonParams } from "../endpoint/EndpointParameters";
5
+ import { de_PutResourcePolicyCommand, se_PutResourcePolicyCommand } from "../protocols/Aws_json1_1";
6
+ export { $Command };
7
+ export class PutResourcePolicyCommand extends $Command
8
+ .classBuilder()
9
+ .ep({
10
+ ...commonParams,
11
+ })
12
+ .m(function (Command, cs, config, o) {
13
+ return [
14
+ getSerdePlugin(config, this.serialize, this.deserialize),
15
+ getEndpointPlugin(config, Command.getEndpointParameterInstructions()),
16
+ ];
17
+ })
18
+ .s("BaldrApiService", "PutResourcePolicy", {})
19
+ .n("CloudHSMV2Client", "PutResourcePolicyCommand")
20
+ .f(void 0, void 0)
21
+ .ser(se_PutResourcePolicyCommand)
22
+ .de(de_PutResourcePolicyCommand)
23
+ .build() {
24
+ }
@@ -4,12 +4,15 @@ export * from "./CreateHsmCommand";
4
4
  export * from "./DeleteBackupCommand";
5
5
  export * from "./DeleteClusterCommand";
6
6
  export * from "./DeleteHsmCommand";
7
+ export * from "./DeleteResourcePolicyCommand";
7
8
  export * from "./DescribeBackupsCommand";
8
9
  export * from "./DescribeClustersCommand";
10
+ export * from "./GetResourcePolicyCommand";
9
11
  export * from "./InitializeClusterCommand";
10
12
  export * from "./ListTagsCommand";
11
13
  export * from "./ModifyBackupAttributesCommand";
12
14
  export * from "./ModifyClusterCommand";
15
+ export * from "./PutResourcePolicyCommand";
13
16
  export * from "./RestoreBackupCommand";
14
17
  export * from "./TagResourceCommand";
15
18
  export * from "./UntagResourceCommand";
@@ -39,6 +39,12 @@ export const se_DeleteHsmCommand = async (input, context) => {
39
39
  body = JSON.stringify(_json(input));
40
40
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
41
41
  };
42
+ export const se_DeleteResourcePolicyCommand = async (input, context) => {
43
+ const headers = sharedHeaders("DeleteResourcePolicy");
44
+ let body;
45
+ body = JSON.stringify(_json(input));
46
+ return buildHttpRpcRequest(context, headers, "/", undefined, body);
47
+ };
42
48
  export const se_DescribeBackupsCommand = async (input, context) => {
43
49
  const headers = sharedHeaders("DescribeBackups");
44
50
  let body;
@@ -51,6 +57,12 @@ export const se_DescribeClustersCommand = async (input, context) => {
51
57
  body = JSON.stringify(_json(input));
52
58
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
53
59
  };
60
+ export const se_GetResourcePolicyCommand = async (input, context) => {
61
+ const headers = sharedHeaders("GetResourcePolicy");
62
+ let body;
63
+ body = JSON.stringify(_json(input));
64
+ return buildHttpRpcRequest(context, headers, "/", undefined, body);
65
+ };
54
66
  export const se_InitializeClusterCommand = async (input, context) => {
55
67
  const headers = sharedHeaders("InitializeCluster");
56
68
  let body;
@@ -75,6 +87,12 @@ export const se_ModifyClusterCommand = async (input, context) => {
75
87
  body = JSON.stringify(_json(input));
76
88
  return buildHttpRpcRequest(context, headers, "/", undefined, body);
77
89
  };
90
+ export const se_PutResourcePolicyCommand = async (input, context) => {
91
+ const headers = sharedHeaders("PutResourcePolicy");
92
+ let body;
93
+ body = JSON.stringify(_json(input));
94
+ return buildHttpRpcRequest(context, headers, "/", undefined, body);
95
+ };
78
96
  export const se_RestoreBackupCommand = async (input, context) => {
79
97
  const headers = sharedHeaders("RestoreBackup");
80
98
  let body;
@@ -171,6 +189,19 @@ export const de_DeleteHsmCommand = async (output, context) => {
171
189
  };
172
190
  return response;
173
191
  };
192
+ export const de_DeleteResourcePolicyCommand = async (output, context) => {
193
+ if (output.statusCode >= 300) {
194
+ return de_CommandError(output, context);
195
+ }
196
+ const data = await parseBody(output.body, context);
197
+ let contents = {};
198
+ contents = _json(data);
199
+ const response = {
200
+ $metadata: deserializeMetadata(output),
201
+ ...contents,
202
+ };
203
+ return response;
204
+ };
174
205
  export const de_DescribeBackupsCommand = async (output, context) => {
175
206
  if (output.statusCode >= 300) {
176
207
  return de_CommandError(output, context);
@@ -197,6 +228,19 @@ export const de_DescribeClustersCommand = async (output, context) => {
197
228
  };
198
229
  return response;
199
230
  };
231
+ export const de_GetResourcePolicyCommand = async (output, context) => {
232
+ if (output.statusCode >= 300) {
233
+ return de_CommandError(output, context);
234
+ }
235
+ const data = await parseBody(output.body, context);
236
+ let contents = {};
237
+ contents = _json(data);
238
+ const response = {
239
+ $metadata: deserializeMetadata(output),
240
+ ...contents,
241
+ };
242
+ return response;
243
+ };
200
244
  export const de_InitializeClusterCommand = async (output, context) => {
201
245
  if (output.statusCode >= 300) {
202
246
  return de_CommandError(output, context);
@@ -249,6 +293,19 @@ export const de_ModifyClusterCommand = async (output, context) => {
249
293
  };
250
294
  return response;
251
295
  };
296
+ export const de_PutResourcePolicyCommand = async (output, context) => {
297
+ if (output.statusCode >= 300) {
298
+ return de_CommandError(output, context);
299
+ }
300
+ const data = await parseBody(output.body, context);
301
+ let contents = {};
302
+ contents = _json(data);
303
+ const response = {
304
+ $metadata: deserializeMetadata(output),
305
+ ...contents,
306
+ };
307
+ return response;
308
+ };
252
309
  export const de_RestoreBackupCommand = async (output, context) => {
253
310
  if (output.statusCode >= 300) {
254
311
  return de_CommandError(output, context);
@@ -378,6 +435,7 @@ const de_CloudHsmTagExceptionRes = async (parsedOutput, context) => {
378
435
  };
379
436
  const de_Backup = (output, context) => {
380
437
  return take(output, {
438
+ BackupArn: __expectString,
381
439
  BackupId: __expectString,
382
440
  BackupState: __expectString,
383
441
  ClusterId: __expectString,
@@ -6,12 +6,15 @@ import { CreateHsmCommandInput, CreateHsmCommandOutput } from "./commands/Create
6
6
  import { DeleteBackupCommandInput, DeleteBackupCommandOutput } from "./commands/DeleteBackupCommand";
7
7
  import { DeleteClusterCommandInput, DeleteClusterCommandOutput } from "./commands/DeleteClusterCommand";
8
8
  import { DeleteHsmCommandInput, DeleteHsmCommandOutput } from "./commands/DeleteHsmCommand";
9
+ import { DeleteResourcePolicyCommandInput, DeleteResourcePolicyCommandOutput } from "./commands/DeleteResourcePolicyCommand";
9
10
  import { DescribeBackupsCommandInput, DescribeBackupsCommandOutput } from "./commands/DescribeBackupsCommand";
10
11
  import { DescribeClustersCommandInput, DescribeClustersCommandOutput } from "./commands/DescribeClustersCommand";
12
+ import { GetResourcePolicyCommandInput, GetResourcePolicyCommandOutput } from "./commands/GetResourcePolicyCommand";
11
13
  import { InitializeClusterCommandInput, InitializeClusterCommandOutput } from "./commands/InitializeClusterCommand";
12
14
  import { ListTagsCommandInput, ListTagsCommandOutput } from "./commands/ListTagsCommand";
13
15
  import { ModifyBackupAttributesCommandInput, ModifyBackupAttributesCommandOutput } from "./commands/ModifyBackupAttributesCommand";
14
16
  import { ModifyClusterCommandInput, ModifyClusterCommandOutput } from "./commands/ModifyClusterCommand";
17
+ import { PutResourcePolicyCommandInput, PutResourcePolicyCommandOutput } from "./commands/PutResourcePolicyCommand";
15
18
  import { RestoreBackupCommandInput, RestoreBackupCommandOutput } from "./commands/RestoreBackupCommand";
16
19
  import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
17
20
  import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
@@ -52,6 +55,13 @@ export interface CloudHSMV2 {
52
55
  deleteHsm(args: DeleteHsmCommandInput, options?: __HttpHandlerOptions): Promise<DeleteHsmCommandOutput>;
53
56
  deleteHsm(args: DeleteHsmCommandInput, cb: (err: any, data?: DeleteHsmCommandOutput) => void): void;
54
57
  deleteHsm(args: DeleteHsmCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DeleteHsmCommandOutput) => void): void;
58
+ /**
59
+ * @see {@link DeleteResourcePolicyCommand}
60
+ */
61
+ deleteResourcePolicy(): Promise<DeleteResourcePolicyCommandOutput>;
62
+ deleteResourcePolicy(args: DeleteResourcePolicyCommandInput, options?: __HttpHandlerOptions): Promise<DeleteResourcePolicyCommandOutput>;
63
+ deleteResourcePolicy(args: DeleteResourcePolicyCommandInput, cb: (err: any, data?: DeleteResourcePolicyCommandOutput) => void): void;
64
+ deleteResourcePolicy(args: DeleteResourcePolicyCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DeleteResourcePolicyCommandOutput) => void): void;
55
65
  /**
56
66
  * @see {@link DescribeBackupsCommand}
57
67
  */
@@ -66,6 +76,13 @@ export interface CloudHSMV2 {
66
76
  describeClusters(args: DescribeClustersCommandInput, options?: __HttpHandlerOptions): Promise<DescribeClustersCommandOutput>;
67
77
  describeClusters(args: DescribeClustersCommandInput, cb: (err: any, data?: DescribeClustersCommandOutput) => void): void;
68
78
  describeClusters(args: DescribeClustersCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: DescribeClustersCommandOutput) => void): void;
79
+ /**
80
+ * @see {@link GetResourcePolicyCommand}
81
+ */
82
+ getResourcePolicy(): Promise<GetResourcePolicyCommandOutput>;
83
+ getResourcePolicy(args: GetResourcePolicyCommandInput, options?: __HttpHandlerOptions): Promise<GetResourcePolicyCommandOutput>;
84
+ getResourcePolicy(args: GetResourcePolicyCommandInput, cb: (err: any, data?: GetResourcePolicyCommandOutput) => void): void;
85
+ getResourcePolicy(args: GetResourcePolicyCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: GetResourcePolicyCommandOutput) => void): void;
69
86
  /**
70
87
  * @see {@link InitializeClusterCommand}
71
88
  */
@@ -90,6 +107,13 @@ export interface CloudHSMV2 {
90
107
  modifyCluster(args: ModifyClusterCommandInput, options?: __HttpHandlerOptions): Promise<ModifyClusterCommandOutput>;
91
108
  modifyCluster(args: ModifyClusterCommandInput, cb: (err: any, data?: ModifyClusterCommandOutput) => void): void;
92
109
  modifyCluster(args: ModifyClusterCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: ModifyClusterCommandOutput) => void): void;
110
+ /**
111
+ * @see {@link PutResourcePolicyCommand}
112
+ */
113
+ putResourcePolicy(): Promise<PutResourcePolicyCommandOutput>;
114
+ putResourcePolicy(args: PutResourcePolicyCommandInput, options?: __HttpHandlerOptions): Promise<PutResourcePolicyCommandOutput>;
115
+ putResourcePolicy(args: PutResourcePolicyCommandInput, cb: (err: any, data?: PutResourcePolicyCommandOutput) => void): void;
116
+ putResourcePolicy(args: PutResourcePolicyCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: PutResourcePolicyCommandOutput) => void): void;
93
117
  /**
94
118
  * @see {@link RestoreBackupCommand}
95
119
  */
@@ -110,7 +134,7 @@ export interface CloudHSMV2 {
110
134
  untagResource(args: UntagResourceCommandInput, options: __HttpHandlerOptions, cb: (err: any, data?: UntagResourceCommandOutput) => void): void;
111
135
  }
112
136
  /**
113
- * <p>For more information about AWS CloudHSM, see <a href="http://aws.amazon.com/cloudhsm/">AWS CloudHSM</a> and the <a href="https://docs.aws.amazon.com/cloudhsm/latest/userguide/">AWS
137
+ * <p>For more information about CloudHSM, see <a href="http://aws.amazon.com/cloudhsm/">CloudHSM</a> and the <a href="https://docs.aws.amazon.com/cloudhsm/latest/userguide/">
114
138
  * CloudHSM User Guide</a>.</p>
115
139
  * @public
116
140
  */
@@ -13,12 +13,15 @@ import { CreateHsmCommandInput, CreateHsmCommandOutput } from "./commands/Create
13
13
  import { DeleteBackupCommandInput, DeleteBackupCommandOutput } from "./commands/DeleteBackupCommand";
14
14
  import { DeleteClusterCommandInput, DeleteClusterCommandOutput } from "./commands/DeleteClusterCommand";
15
15
  import { DeleteHsmCommandInput, DeleteHsmCommandOutput } from "./commands/DeleteHsmCommand";
16
+ import { DeleteResourcePolicyCommandInput, DeleteResourcePolicyCommandOutput } from "./commands/DeleteResourcePolicyCommand";
16
17
  import { DescribeBackupsCommandInput, DescribeBackupsCommandOutput } from "./commands/DescribeBackupsCommand";
17
18
  import { DescribeClustersCommandInput, DescribeClustersCommandOutput } from "./commands/DescribeClustersCommand";
19
+ import { GetResourcePolicyCommandInput, GetResourcePolicyCommandOutput } from "./commands/GetResourcePolicyCommand";
18
20
  import { InitializeClusterCommandInput, InitializeClusterCommandOutput } from "./commands/InitializeClusterCommand";
19
21
  import { ListTagsCommandInput, ListTagsCommandOutput } from "./commands/ListTagsCommand";
20
22
  import { ModifyBackupAttributesCommandInput, ModifyBackupAttributesCommandOutput } from "./commands/ModifyBackupAttributesCommand";
21
23
  import { ModifyClusterCommandInput, ModifyClusterCommandOutput } from "./commands/ModifyClusterCommand";
24
+ import { PutResourcePolicyCommandInput, PutResourcePolicyCommandOutput } from "./commands/PutResourcePolicyCommand";
22
25
  import { RestoreBackupCommandInput, RestoreBackupCommandOutput } from "./commands/RestoreBackupCommand";
23
26
  import { TagResourceCommandInput, TagResourceCommandOutput } from "./commands/TagResourceCommand";
24
27
  import { UntagResourceCommandInput, UntagResourceCommandOutput } from "./commands/UntagResourceCommand";
@@ -28,11 +31,11 @@ export { __Client };
28
31
  /**
29
32
  * @public
30
33
  */
31
- export type ServiceInputTypes = CopyBackupToRegionCommandInput | CreateClusterCommandInput | CreateHsmCommandInput | DeleteBackupCommandInput | DeleteClusterCommandInput | DeleteHsmCommandInput | DescribeBackupsCommandInput | DescribeClustersCommandInput | InitializeClusterCommandInput | ListTagsCommandInput | ModifyBackupAttributesCommandInput | ModifyClusterCommandInput | RestoreBackupCommandInput | TagResourceCommandInput | UntagResourceCommandInput;
34
+ export type ServiceInputTypes = CopyBackupToRegionCommandInput | CreateClusterCommandInput | CreateHsmCommandInput | DeleteBackupCommandInput | DeleteClusterCommandInput | DeleteHsmCommandInput | DeleteResourcePolicyCommandInput | DescribeBackupsCommandInput | DescribeClustersCommandInput | GetResourcePolicyCommandInput | InitializeClusterCommandInput | ListTagsCommandInput | ModifyBackupAttributesCommandInput | ModifyClusterCommandInput | PutResourcePolicyCommandInput | RestoreBackupCommandInput | TagResourceCommandInput | UntagResourceCommandInput;
32
35
  /**
33
36
  * @public
34
37
  */
35
- export type ServiceOutputTypes = CopyBackupToRegionCommandOutput | CreateClusterCommandOutput | CreateHsmCommandOutput | DeleteBackupCommandOutput | DeleteClusterCommandOutput | DeleteHsmCommandOutput | DescribeBackupsCommandOutput | DescribeClustersCommandOutput | InitializeClusterCommandOutput | ListTagsCommandOutput | ModifyBackupAttributesCommandOutput | ModifyClusterCommandOutput | RestoreBackupCommandOutput | TagResourceCommandOutput | UntagResourceCommandOutput;
38
+ export type ServiceOutputTypes = CopyBackupToRegionCommandOutput | CreateClusterCommandOutput | CreateHsmCommandOutput | DeleteBackupCommandOutput | DeleteClusterCommandOutput | DeleteHsmCommandOutput | DeleteResourcePolicyCommandOutput | DescribeBackupsCommandOutput | DescribeClustersCommandOutput | GetResourcePolicyCommandOutput | InitializeClusterCommandOutput | ListTagsCommandOutput | ModifyBackupAttributesCommandOutput | ModifyClusterCommandOutput | PutResourcePolicyCommandOutput | RestoreBackupCommandOutput | TagResourceCommandOutput | UntagResourceCommandOutput;
36
39
  /**
37
40
  * @public
38
41
  */
@@ -166,7 +169,7 @@ export type CloudHSMV2ClientResolvedConfigType = __SmithyResolvedConfiguration<_
166
169
  export interface CloudHSMV2ClientResolvedConfig extends CloudHSMV2ClientResolvedConfigType {
167
170
  }
168
171
  /**
169
- * <p>For more information about AWS CloudHSM, see <a href="http://aws.amazon.com/cloudhsm/">AWS CloudHSM</a> and the <a href="https://docs.aws.amazon.com/cloudhsm/latest/userguide/">AWS
172
+ * <p>For more information about CloudHSM, see <a href="http://aws.amazon.com/cloudhsm/">CloudHSM</a> and the <a href="https://docs.aws.amazon.com/cloudhsm/latest/userguide/">
170
173
  * CloudHSM User Guide</a>.</p>
171
174
  * @public
172
175
  */
@@ -27,7 +27,9 @@ declare const CopyBackupToRegionCommand_base: {
27
27
  getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
28
  };
29
29
  /**
30
- * <p>Copy an AWS CloudHSM cluster backup to a different region.</p>
30
+ * <p>Copy an CloudHSM cluster backup to a different region.</p>
31
+ * <p>
32
+ * <b>Cross-account use:</b> No. You cannot perform this operation on an CloudHSM backup in a different Amazon Web Services account.</p>
31
33
  * @example
32
34
  * Use a bare-bones client and the command you need to make an API call.
33
35
  * ```javascript
@@ -68,7 +70,7 @@ declare const CopyBackupToRegionCommand_base: {
68
70
  * requested operation.</p>
69
71
  *
70
72
  * @throws {@link CloudHsmInternalFailureException} (server fault)
71
- * <p>The request was rejected because of an AWS CloudHSM internal failure. The request can
73
+ * <p>The request was rejected because of an CloudHSM internal failure. The request can
72
74
  * be retried.</p>
73
75
  *
74
76
  * @throws {@link CloudHsmInvalidRequestException} (client fault)
@@ -27,7 +27,10 @@ declare const CreateClusterCommand_base: {
27
27
  getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
28
  };
29
29
  /**
30
- * <p>Creates a new AWS CloudHSM cluster.</p>
30
+ * <p>Creates a new CloudHSM cluster.</p>
31
+ * <p>
32
+ * <b>Cross-account use:</b> Yes. To perform this operation with an CloudHSM backup in a different AWS account, specify the full backup
33
+ * ARN in the value of the SourceBackupId parameter.</p>
31
34
  * @example
32
35
  * Use a bare-bones client and the command you need to make an API call.
33
36
  * ```javascript
@@ -115,7 +118,7 @@ declare const CreateClusterCommand_base: {
115
118
  * requested operation.</p>
116
119
  *
117
120
  * @throws {@link CloudHsmInternalFailureException} (server fault)
118
- * <p>The request was rejected because of an AWS CloudHSM internal failure. The request can
121
+ * <p>The request was rejected because of an CloudHSM internal failure. The request can
119
122
  * be retried.</p>
120
123
  *
121
124
  * @throws {@link CloudHsmInvalidRequestException} (client fault)