@aws-sdk/client-kms 3.774.0 → 3.777.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 (60) hide show
  1. package/dist-cjs/auth/httpAuthSchemeProvider.js +1 -3
  2. package/dist-cjs/index.js +17 -18
  3. package/dist-es/KMSClient.js +2 -1
  4. package/dist-es/auth/httpAuthSchemeProvider.js +1 -3
  5. package/dist-es/endpoint/EndpointParameters.js +2 -3
  6. package/dist-es/runtimeExtensions.js +2 -14
  7. package/dist-types/commands/CancelKeyDeletionCommand.d.ts +5 -5
  8. package/dist-types/commands/ConnectCustomKeyStoreCommand.d.ts +7 -4
  9. package/dist-types/commands/CreateAliasCommand.d.ts +8 -5
  10. package/dist-types/commands/CreateCustomKeyStoreCommand.d.ts +8 -57
  11. package/dist-types/commands/CreateGrantCommand.d.ts +8 -8
  12. package/dist-types/commands/CreateKeyCommand.d.ts +1 -283
  13. package/dist-types/commands/DecryptCommand.d.ts +15 -39
  14. package/dist-types/commands/DeleteAliasCommand.d.ts +7 -4
  15. package/dist-types/commands/DeleteCustomKeyStoreCommand.d.ts +7 -4
  16. package/dist-types/commands/DeleteImportedKeyMaterialCommand.d.ts +7 -4
  17. package/dist-types/commands/DeriveSharedSecretCommand.d.ts +10 -10
  18. package/dist-types/commands/DescribeCustomKeyStoresCommand.d.ts +5 -92
  19. package/dist-types/commands/DescribeKeyCommand.d.ts +101 -138
  20. package/dist-types/commands/DisableKeyCommand.d.ts +7 -4
  21. package/dist-types/commands/DisableKeyRotationCommand.d.ts +7 -4
  22. package/dist-types/commands/DisconnectCustomKeyStoreCommand.d.ts +7 -4
  23. package/dist-types/commands/EnableKeyCommand.d.ts +7 -4
  24. package/dist-types/commands/EnableKeyRotationCommand.d.ts +8 -5
  25. package/dist-types/commands/EncryptCommand.d.ts +15 -16
  26. package/dist-types/commands/GenerateDataKeyCommand.d.ts +8 -32
  27. package/dist-types/commands/GenerateDataKeyPairCommand.d.ts +10 -36
  28. package/dist-types/commands/GenerateDataKeyPairWithoutPlaintextCommand.d.ts +9 -9
  29. package/dist-types/commands/GenerateDataKeyWithoutPlaintextCommand.d.ts +7 -7
  30. package/dist-types/commands/GenerateMacCommand.d.ts +9 -9
  31. package/dist-types/commands/GenerateRandomCommand.d.ts +5 -26
  32. package/dist-types/commands/GetKeyPolicyCommand.d.ts +18 -6
  33. package/dist-types/commands/GetKeyRotationStatusCommand.d.ts +1 -20
  34. package/dist-types/commands/GetParametersForImportCommand.d.ts +1 -84
  35. package/dist-types/commands/GetPublicKeyCommand.d.ts +9 -9
  36. package/dist-types/commands/ImportKeyMaterialCommand.d.ts +10 -22
  37. package/dist-types/commands/ListAliasesCommand.d.ts +30 -30
  38. package/dist-types/commands/ListGrantsCommand.d.ts +1 -69
  39. package/dist-types/commands/ListKeyPoliciesCommand.d.ts +6 -6
  40. package/dist-types/commands/ListKeyRotationsCommand.d.ts +1 -28
  41. package/dist-types/commands/ListKeysCommand.d.ts +20 -20
  42. package/dist-types/commands/ListResourceTagsCommand.d.ts +12 -12
  43. package/dist-types/commands/ListRetirableGrantsCommand.d.ts +1 -30
  44. package/dist-types/commands/PutKeyPolicyCommand.d.ts +82 -6
  45. package/dist-types/commands/ReEncryptCommand.d.ts +8 -8
  46. package/dist-types/commands/ReplicateKeyCommand.d.ts +31 -29
  47. package/dist-types/commands/RetireGrantCommand.d.ts +8 -5
  48. package/dist-types/commands/RevokeGrantCommand.d.ts +8 -5
  49. package/dist-types/commands/RotateKeyOnDemandCommand.d.ts +5 -5
  50. package/dist-types/commands/ScheduleKeyDeletionCommand.d.ts +1 -18
  51. package/dist-types/commands/SignCommand.d.ts +18 -19
  52. package/dist-types/commands/TagResourceCommand.d.ts +10 -7
  53. package/dist-types/commands/UntagResourceCommand.d.ts +8 -5
  54. package/dist-types/commands/UpdateAliasCommand.d.ts +8 -5
  55. package/dist-types/commands/UpdateCustomKeyStoreCommand.d.ts +34 -38
  56. package/dist-types/commands/UpdateKeyDescriptionCommand.d.ts +8 -5
  57. package/dist-types/commands/UpdatePrimaryRegionCommand.d.ts +12 -9
  58. package/dist-types/commands/VerifyCommand.d.ts +20 -21
  59. package/dist-types/commands/VerifyMacCommand.d.ts +10 -10
  60. package/package.json +33 -33
@@ -40,8 +40,6 @@ const defaultKMSHttpAuthSchemeProvider = (authParameters) => {
40
40
  exports.defaultKMSHttpAuthSchemeProvider = defaultKMSHttpAuthSchemeProvider;
41
41
  const resolveHttpAuthSchemeConfig = (config) => {
42
42
  const config_0 = (0, core_1.resolveAwsSdkSigV4Config)(config);
43
- return {
44
- ...config_0,
45
- };
43
+ return Object.assign(config_0, {});
46
44
  };
47
45
  exports.resolveHttpAuthSchemeConfig = resolveHttpAuthSchemeConfig;
package/dist-cjs/index.js CHANGED
@@ -193,12 +193,11 @@ var import_httpAuthSchemeProvider = require("./auth/httpAuthSchemeProvider");
193
193
 
194
194
  // src/endpoint/EndpointParameters.ts
195
195
  var resolveClientEndpointParameters = /* @__PURE__ */ __name((options) => {
196
- return {
197
- ...options,
196
+ return Object.assign(options, {
198
197
  useDualstackEndpoint: options.useDualstackEndpoint ?? false,
199
198
  useFipsEndpoint: options.useFipsEndpoint ?? false,
200
199
  defaultSigningName: "kms"
201
- };
200
+ });
202
201
  }, "resolveClientEndpointParameters");
203
202
  var commonParams = {
204
203
  UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
@@ -255,22 +254,21 @@ var resolveHttpAuthRuntimeConfig = /* @__PURE__ */ __name((config) => {
255
254
  }, "resolveHttpAuthRuntimeConfig");
256
255
 
257
256
  // src/runtimeExtensions.ts
258
- var asPartial = /* @__PURE__ */ __name((t) => t, "asPartial");
259
257
  var resolveRuntimeExtensions = /* @__PURE__ */ __name((runtimeConfig, extensions) => {
260
- const extensionConfiguration = {
261
- ...asPartial((0, import_region_config_resolver.getAwsRegionExtensionConfiguration)(runtimeConfig)),
262
- ...asPartial((0, import_smithy_client.getDefaultExtensionConfiguration)(runtimeConfig)),
263
- ...asPartial((0, import_protocol_http.getHttpHandlerExtensionConfiguration)(runtimeConfig)),
264
- ...asPartial(getHttpAuthExtensionConfiguration(runtimeConfig))
265
- };
258
+ const extensionConfiguration = Object.assign(
259
+ (0, import_region_config_resolver.getAwsRegionExtensionConfiguration)(runtimeConfig),
260
+ (0, import_smithy_client.getDefaultExtensionConfiguration)(runtimeConfig),
261
+ (0, import_protocol_http.getHttpHandlerExtensionConfiguration)(runtimeConfig),
262
+ getHttpAuthExtensionConfiguration(runtimeConfig)
263
+ );
266
264
  extensions.forEach((extension) => extension.configure(extensionConfiguration));
267
- return {
268
- ...runtimeConfig,
269
- ...(0, import_region_config_resolver.resolveAwsRegionExtensionConfiguration)(extensionConfiguration),
270
- ...(0, import_smithy_client.resolveDefaultRuntimeConfig)(extensionConfiguration),
271
- ...(0, import_protocol_http.resolveHttpHandlerRuntimeConfig)(extensionConfiguration),
272
- ...resolveHttpAuthRuntimeConfig(extensionConfiguration)
273
- };
265
+ return Object.assign(
266
+ runtimeConfig,
267
+ (0, import_region_config_resolver.resolveAwsRegionExtensionConfiguration)(extensionConfiguration),
268
+ (0, import_smithy_client.resolveDefaultRuntimeConfig)(extensionConfiguration),
269
+ (0, import_protocol_http.resolveHttpHandlerRuntimeConfig)(extensionConfiguration),
270
+ resolveHttpAuthRuntimeConfig(extensionConfiguration)
271
+ );
274
272
  }, "resolveRuntimeExtensions");
275
273
 
276
274
  // src/KMSClient.ts
@@ -284,6 +282,8 @@ var KMSClient = class extends import_smithy_client.Client {
284
282
  config;
285
283
  constructor(...[configuration]) {
286
284
  const _config_0 = (0, import_runtimeConfig.getRuntimeConfig)(configuration || {});
285
+ super(_config_0);
286
+ this.initConfig = _config_0;
287
287
  const _config_1 = resolveClientEndpointParameters(_config_0);
288
288
  const _config_2 = (0, import_middleware_user_agent.resolveUserAgentConfig)(_config_1);
289
289
  const _config_3 = (0, import_middleware_retry.resolveRetryConfig)(_config_2);
@@ -292,7 +292,6 @@ var KMSClient = class extends import_smithy_client.Client {
292
292
  const _config_6 = (0, import_middleware_endpoint.resolveEndpointConfig)(_config_5);
293
293
  const _config_7 = (0, import_httpAuthSchemeProvider.resolveHttpAuthSchemeConfig)(_config_6);
294
294
  const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
295
- super(_config_8);
296
295
  this.config = _config_8;
297
296
  this.middlewareStack.use((0, import_middleware_user_agent.getUserAgentPlugin)(this.config));
298
297
  this.middlewareStack.use((0, import_middleware_retry.getRetryPlugin)(this.config));
@@ -17,6 +17,8 @@ export class KMSClient extends __Client {
17
17
  config;
18
18
  constructor(...[configuration]) {
19
19
  const _config_0 = __getRuntimeConfig(configuration || {});
20
+ super(_config_0);
21
+ this.initConfig = _config_0;
20
22
  const _config_1 = resolveClientEndpointParameters(_config_0);
21
23
  const _config_2 = resolveUserAgentConfig(_config_1);
22
24
  const _config_3 = resolveRetryConfig(_config_2);
@@ -25,7 +27,6 @@ export class KMSClient extends __Client {
25
27
  const _config_6 = resolveEndpointConfig(_config_5);
26
28
  const _config_7 = resolveHttpAuthSchemeConfig(_config_6);
27
29
  const _config_8 = resolveRuntimeExtensions(_config_7, configuration?.extensions || []);
28
- super(_config_8);
29
30
  this.config = _config_8;
30
31
  this.middlewareStack.use(getUserAgentPlugin(this.config));
31
32
  this.middlewareStack.use(getRetryPlugin(this.config));
@@ -35,7 +35,5 @@ export const defaultKMSHttpAuthSchemeProvider = (authParameters) => {
35
35
  };
36
36
  export const resolveHttpAuthSchemeConfig = (config) => {
37
37
  const config_0 = resolveAwsSdkSigV4Config(config);
38
- return {
39
- ...config_0,
40
- };
38
+ return Object.assign(config_0, {});
41
39
  };
@@ -1,10 +1,9 @@
1
1
  export const resolveClientEndpointParameters = (options) => {
2
- return {
3
- ...options,
2
+ return Object.assign(options, {
4
3
  useDualstackEndpoint: options.useDualstackEndpoint ?? false,
5
4
  useFipsEndpoint: options.useFipsEndpoint ?? false,
6
5
  defaultSigningName: "kms",
7
- };
6
+ });
8
7
  };
9
8
  export const commonParams = {
10
9
  UseFIPS: { type: "builtInParams", name: "useFipsEndpoint" },
@@ -2,20 +2,8 @@ import { getAwsRegionExtensionConfiguration, resolveAwsRegionExtensionConfigurat
2
2
  import { getHttpHandlerExtensionConfiguration, resolveHttpHandlerRuntimeConfig } from "@smithy/protocol-http";
3
3
  import { getDefaultExtensionConfiguration, resolveDefaultRuntimeConfig } from "@smithy/smithy-client";
4
4
  import { getHttpAuthExtensionConfiguration, resolveHttpAuthRuntimeConfig } from "./auth/httpAuthExtensionConfiguration";
5
- const asPartial = (t) => t;
6
5
  export const resolveRuntimeExtensions = (runtimeConfig, extensions) => {
7
- const extensionConfiguration = {
8
- ...asPartial(getAwsRegionExtensionConfiguration(runtimeConfig)),
9
- ...asPartial(getDefaultExtensionConfiguration(runtimeConfig)),
10
- ...asPartial(getHttpHandlerExtensionConfiguration(runtimeConfig)),
11
- ...asPartial(getHttpAuthExtensionConfiguration(runtimeConfig)),
12
- };
6
+ const extensionConfiguration = Object.assign(getAwsRegionExtensionConfiguration(runtimeConfig), getDefaultExtensionConfiguration(runtimeConfig), getHttpHandlerExtensionConfiguration(runtimeConfig), getHttpAuthExtensionConfiguration(runtimeConfig));
13
7
  extensions.forEach((extension) => extension.configure(extensionConfiguration));
14
- return {
15
- ...runtimeConfig,
16
- ...resolveAwsRegionExtensionConfiguration(extensionConfiguration),
17
- ...resolveDefaultRuntimeConfig(extensionConfiguration),
18
- ...resolveHttpHandlerRuntimeConfig(extensionConfiguration),
19
- ...resolveHttpAuthRuntimeConfig(extensionConfiguration),
20
- };
8
+ return Object.assign(runtimeConfig, resolveAwsRegionExtensionConfiguration(extensionConfiguration), resolveDefaultRuntimeConfig(extensionConfiguration), resolveHttpHandlerRuntimeConfig(extensionConfiguration), resolveHttpAuthRuntimeConfig(extensionConfiguration));
21
9
  };
@@ -105,23 +105,23 @@ declare const CancelKeyDeletionCommand_base: {
105
105
  * @throws {@link KMSServiceException}
106
106
  * <p>Base exception class for all service exceptions from KMS service.</p>
107
107
  *
108
- * @public
108
+ *
109
109
  * @example To cancel deletion of a KMS key
110
110
  * ```javascript
111
111
  * // The following example cancels deletion of the specified KMS key.
112
112
  * const input = {
113
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab"
113
+ * KeyId: "1234abcd-12ab-34cd-56ef-1234567890ab"
114
114
  * };
115
115
  * const command = new CancelKeyDeletionCommand(input);
116
116
  * const response = await client.send(command);
117
- * /* response ==
117
+ * /* response is
118
118
  * {
119
- * "KeyId": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab"
119
+ * KeyId: "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab"
120
120
  * }
121
121
  * *\/
122
- * // example id: to-cancel-deletion-of-a-cmk-1477428535102
123
122
  * ```
124
123
  *
124
+ * @public
125
125
  */
126
126
  export declare class CancelKeyDeletionCommand extends CancelKeyDeletionCommand_base {
127
127
  /** @internal type navigation helper, not in runtime. */
@@ -225,18 +225,21 @@ declare const ConnectCustomKeyStoreCommand_base: {
225
225
  * @throws {@link KMSServiceException}
226
226
  * <p>Base exception class for all service exceptions from KMS service.</p>
227
227
  *
228
- * @public
228
+ *
229
229
  * @example To connect a custom key store
230
230
  * ```javascript
231
231
  * // This example connects an AWS KMS custom key store to its backing key store. For an AWS CloudHSM key store, it connects the key store to its AWS CloudHSM cluster. For an external key store, it connects the key store to the external key store proxy that communicates with your external key manager. This operation does not return any data. To verify that the custom key store is connected, use the <code>DescribeCustomKeyStores</code> operation.
232
232
  * const input = {
233
- * "CustomKeyStoreId": "cks-1234567890abcdef0"
233
+ * CustomKeyStoreId: "cks-1234567890abcdef0"
234
234
  * };
235
235
  * const command = new ConnectCustomKeyStoreCommand(input);
236
- * await client.send(command);
237
- * // example id: to-connect-a-custom-key-store-1628626947750
236
+ * const response = await client.send(command);
237
+ * /* response is
238
+ * { /* empty *\/ }
239
+ * *\/
238
240
  * ```
239
241
  *
242
+ * @public
240
243
  */
241
244
  export declare class ConnectCustomKeyStoreCommand extends ConnectCustomKeyStoreCommand_base {
242
245
  /** @internal type navigation helper, not in runtime. */
@@ -155,19 +155,22 @@ declare const CreateAliasCommand_base: {
155
155
  * @throws {@link KMSServiceException}
156
156
  * <p>Base exception class for all service exceptions from KMS service.</p>
157
157
  *
158
- * @public
158
+ *
159
159
  * @example To create an alias
160
160
  * ```javascript
161
161
  * // The following example creates an alias for the specified KMS key.
162
162
  * const input = {
163
- * "AliasName": "alias/ExampleAlias",
164
- * "TargetKeyId": "1234abcd-12ab-34cd-56ef-1234567890ab"
163
+ * AliasName: "alias/ExampleAlias",
164
+ * TargetKeyId: "1234abcd-12ab-34cd-56ef-1234567890ab"
165
165
  * };
166
166
  * const command = new CreateAliasCommand(input);
167
- * await client.send(command);
168
- * // example id: to-create-an-alias-1477505685119
167
+ * const response = await client.send(command);
168
+ * /* response is
169
+ * { /* metadata only *\/ }
170
+ * *\/
169
171
  * ```
170
172
  *
173
+ * @public
171
174
  */
172
175
  export declare class CreateAliasCommand extends CreateAliasCommand_base {
173
176
  /** @internal type navigation helper, not in runtime. */
@@ -281,75 +281,26 @@ declare const CreateCustomKeyStoreCommand_base: {
281
281
  * @throws {@link KMSServiceException}
282
282
  * <p>Base exception class for all service exceptions from KMS service.</p>
283
283
  *
284
- * @public
284
+ *
285
285
  * @example To create an AWS CloudHSM key store
286
286
  * ```javascript
287
287
  * // This example creates a custom key store that is associated with an AWS CloudHSM cluster.
288
288
  * const input = {
289
- * "CloudHsmClusterId": "cluster-234abcdefABC",
290
- * "CustomKeyStoreName": "ExampleKeyStore",
291
- * "KeyStorePassword": "kmsPswd",
292
- * "TrustAnchorCertificate": "<certificate-goes-here>"
293
- * };
294
- * const command = new CreateCustomKeyStoreCommand(input);
295
- * const response = await client.send(command);
296
- * /* response ==
297
- * {
298
- * "CustomKeyStoreId": "cks-1234567890abcdef0"
299
- * }
300
- * *\/
301
- * // example id: to-create-an-aws-cloudhsm-custom-key-store-1
302
- * ```
303
- *
304
- * @example To create an external key store with VPC endpoint service connectivity
305
- * ```javascript
306
- * // This example creates an external key store that uses an Amazon VPC endpoint service to communicate with AWS KMS.
307
- * const input = {
308
- * "CustomKeyStoreName": "ExampleVPCEndpointKeyStore",
309
- * "CustomKeyStoreType": "EXTERNAL_KEY_STORE",
310
- * "XksProxyAuthenticationCredential": {
311
- * "AccessKeyId": "ABCDE12345670EXAMPLE",
312
- * "RawSecretAccessKey": "DXjSUawnel2fr6SKC7G25CNxTyWKE5PF9XX6H/u9pSo="
313
- * },
314
- * "XksProxyConnectivity": "VPC_ENDPOINT_SERVICE",
315
- * "XksProxyUriEndpoint": "https://myproxy-private.xks.example.com",
316
- * "XksProxyUriPath": "/example-prefix/kms/xks/v1",
317
- * "XksProxyVpcEndpointServiceName": "com.amazonaws.vpce.us-east-1.vpce-svc-example1"
289
+ * CloudHsmClusterId: "cluster-234abcdefABC",
290
+ * CustomKeyStoreName: "ExampleKeyStore",
291
+ * KeyStorePassword: "kmsPswd",
292
+ * TrustAnchorCertificate: "<certificate-goes-here>"
318
293
  * };
319
294
  * const command = new CreateCustomKeyStoreCommand(input);
320
295
  * const response = await client.send(command);
321
- * /* response ==
296
+ * /* response is
322
297
  * {
323
- * "CustomKeyStoreId": "cks-1234567890abcdef0"
298
+ * CustomKeyStoreId: "cks-1234567890abcdef0"
324
299
  * }
325
300
  * *\/
326
- * // example id: to-create-an-external-custom-key-store-with-vpc-connectivity-2
327
- * ```
328
- *
329
- * @example To create an external key store with public endpoint connectivity
330
- * ```javascript
331
- * // This example creates an external key store with public endpoint connectivity.
332
- * const input = {
333
- * "CustomKeyStoreName": "ExamplePublicEndpointKeyStore",
334
- * "CustomKeyStoreType": "EXTERNAL_KEY_STORE",
335
- * "XksProxyAuthenticationCredential": {
336
- * "AccessKeyId": "ABCDE12345670EXAMPLE",
337
- * "RawSecretAccessKey": "DXjSUawnel2fr6SKC7G25CNxTyWKE5PF9XX6H/u9pSo="
338
- * },
339
- * "XksProxyConnectivity": "PUBLIC_ENDPOINT",
340
- * "XksProxyUriEndpoint": "https://myproxy.xks.example.com",
341
- * "XksProxyUriPath": "/kms/xks/v1"
342
- * };
343
- * const command = new CreateCustomKeyStoreCommand(input);
344
- * const response = await client.send(command);
345
- * /* response ==
346
- * {
347
- * "CustomKeyStoreId": "cks-987654321abcdef0"
348
- * }
349
- * *\/
350
- * // example id: to-create-an-external-custom-key-store-with-a-public-endpoint-3
351
301
  * ```
352
302
  *
303
+ * @public
353
304
  */
354
305
  export declare class CreateCustomKeyStoreCommand extends CreateCustomKeyStoreCommand_base {
355
306
  /** @internal type navigation helper, not in runtime. */
@@ -186,29 +186,29 @@ declare const CreateGrantCommand_base: {
186
186
  * @throws {@link KMSServiceException}
187
187
  * <p>Base exception class for all service exceptions from KMS service.</p>
188
188
  *
189
- * @public
189
+ *
190
190
  * @example To create a grant
191
191
  * ```javascript
192
192
  * // The following example creates a grant that allows the specified IAM role to encrypt data with the specified KMS key.
193
193
  * const input = {
194
- * "GranteePrincipal": "arn:aws:iam::111122223333:role/ExampleRole",
195
- * "KeyId": "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab",
196
- * "Operations": [
194
+ * GranteePrincipal: "arn:aws:iam::111122223333:role/ExampleRole",
195
+ * KeyId: "arn:aws:kms:us-east-2:444455556666:key/1234abcd-12ab-34cd-56ef-1234567890ab",
196
+ * Operations: [
197
197
  * "Encrypt",
198
198
  * "Decrypt"
199
199
  * ]
200
200
  * };
201
201
  * const command = new CreateGrantCommand(input);
202
202
  * const response = await client.send(command);
203
- * /* response ==
203
+ * /* response is
204
204
  * {
205
- * "GrantId": "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60",
206
- * "GrantToken": "AQpAM2RhZTk1MGMyNTk2ZmZmMzEyYWVhOWViN2I1MWM4Mzc0MWFiYjc0ZDE1ODkyNGFlNTIzODZhMzgyZjBlNGY3NiKIAgEBAgB4Pa6VDCWW__MSrqnre1HIN0Grt00ViSSuUjhqOC8OT3YAAADfMIHcBgkqhkiG9w0BBwaggc4wgcsCAQAwgcUGCSqGSIb3DQEHATAeBglghkgBZQMEAS4wEQQMmqLyBTAegIn9XlK5AgEQgIGXZQjkBcl1dykDdqZBUQ6L1OfUivQy7JVYO2-ZJP7m6f1g8GzV47HX5phdtONAP7K_HQIflcgpkoCqd_fUnE114mSmiagWkbQ5sqAVV3ov-VeqgrvMe5ZFEWLMSluvBAqdjHEdMIkHMlhlj4ENZbzBfo9Wxk8b8SnwP4kc4gGivedzFXo-dwN8fxjjq_ZZ9JFOj2ijIbj5FyogDCN0drOfi8RORSEuCEmPvjFRMFAwcmwFkN2NPp89amA"
205
+ * GrantId: "0c237476b39f8bc44e45212e08498fbe3151305030726c0590dd8d3e9f3d6a60",
206
+ * GrantToken: "AQpAM2RhZTk1MGMyNTk2ZmZmMzEyYWVhOWViN2I1MWM4Mzc0MWFiYjc0ZDE1ODkyNGFlNTIzODZhMzgyZjBlNGY3NiKIAgEBAgB4Pa6VDCWW__MSrqnre1HIN0Grt00ViSSuUjhqOC8OT3YAAADfMIHcBgkqhkiG9w0BBwaggc4wgcsCAQAwgcUGCSqGSIb3DQEHATAeBglghkgBZQMEAS4wEQQMmqLyBTAegIn9XlK5AgEQgIGXZQjkBcl1dykDdqZBUQ6L1OfUivQy7JVYO2-ZJP7m6f1g8GzV47HX5phdtONAP7K_HQIflcgpkoCqd_fUnE114mSmiagWkbQ5sqAVV3ov-VeqgrvMe5ZFEWLMSluvBAqdjHEdMIkHMlhlj4ENZbzBfo9Wxk8b8SnwP4kc4gGivedzFXo-dwN8fxjjq_ZZ9JFOj2ijIbj5FyogDCN0drOfi8RORSEuCEmPvjFRMFAwcmwFkN2NPp89amA"
207
207
  * }
208
208
  * *\/
209
- * // example id: to-create-a-grant-1477972226782
210
209
  * ```
211
210
  *
211
+ * @public
212
212
  */
213
213
  export declare class CreateGrantCommand extends CreateGrantCommand_base {
214
214
  /** @internal type navigation helper, not in runtime. */
@@ -407,290 +407,8 @@ declare const CreateKeyCommand_base: {
407
407
  * @throws {@link KMSServiceException}
408
408
  * <p>Base exception class for all service exceptions from KMS service.</p>
409
409
  *
410
- * @public
411
- * @example To create a KMS key
412
- * ```javascript
413
- * // The following example creates a symmetric KMS key for encryption and decryption. No parameters are required for this operation.
414
- * const input = {};
415
- * const command = new CreateKeyCommand(input);
416
- * const response = await client.send(command);
417
- * /* response ==
418
- * {
419
- * "KeyMetadata": {
420
- * "AWSAccountId": "111122223333",
421
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
422
- * "CreationDate": "2017-07-05T14:04:55-07:00",
423
- * "CustomerMasterKeySpec": "SYMMETRIC_DEFAULT",
424
- * "Description": "",
425
- * "Enabled": true,
426
- * "EncryptionAlgorithms": [
427
- * "SYMMETRIC_DEFAULT"
428
- * ],
429
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
430
- * "KeyManager": "CUSTOMER",
431
- * "KeySpec": "SYMMETRIC_DEFAULT",
432
- * "KeyState": "Enabled",
433
- * "KeyUsage": "ENCRYPT_DECRYPT",
434
- * "MultiRegion": false,
435
- * "Origin": "AWS_KMS"
436
- * }
437
- * }
438
- * *\/
439
- * // example id: to-create-a-cmk-1
440
- * ```
441
- *
442
- * @example To create an asymmetric RSA KMS key for encryption and decryption
443
- * ```javascript
444
- * // This example creates a KMS key that contains an asymmetric RSA key pair for encryption and decryption. The key spec and key usage can't be changed after the key is created.
445
- * const input = {
446
- * "KeySpec": "RSA_4096",
447
- * "KeyUsage": "ENCRYPT_DECRYPT"
448
- * };
449
- * const command = new CreateKeyCommand(input);
450
- * const response = await client.send(command);
451
- * /* response ==
452
- * {
453
- * "KeyMetadata": {
454
- * "AWSAccountId": "111122223333",
455
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
456
- * "CreationDate": "2021-04-05T14:04:55-07:00",
457
- * "CustomerMasterKeySpec": "RSA_4096",
458
- * "Description": "",
459
- * "Enabled": true,
460
- * "EncryptionAlgorithms": [
461
- * "RSAES_OAEP_SHA_1",
462
- * "RSAES_OAEP_SHA_256"
463
- * ],
464
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
465
- * "KeyManager": "CUSTOMER",
466
- * "KeySpec": "RSA_4096",
467
- * "KeyState": "Enabled",
468
- * "KeyUsage": "ENCRYPT_DECRYPT",
469
- * "MultiRegion": false,
470
- * "Origin": "AWS_KMS"
471
- * }
472
- * }
473
- * *\/
474
- * // example id: to-create-an-asymmetric-rsa-kms-key-for-encryption-and-decryption-2
475
- * ```
476
- *
477
- * @example To create an asymmetric elliptic curve KMS key for signing and verification
478
- * ```javascript
479
- * // This example creates a KMS key that contains an asymmetric elliptic curve (ECC) key pair for signing and verification. The key usage is required even though "SIGN_VERIFY" is the only valid value for ECC KMS keys. The key spec and key usage can't be changed after the key is created.
480
- * const input = {
481
- * "KeySpec": "ECC_NIST_P521",
482
- * "KeyUsage": "SIGN_VERIFY"
483
- * };
484
- * const command = new CreateKeyCommand(input);
485
- * const response = await client.send(command);
486
- * /* response ==
487
- * {
488
- * "KeyMetadata": {
489
- * "AWSAccountId": "111122223333",
490
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
491
- * "CreationDate": "2019-12-02T07:48:55-07:00",
492
- * "CustomerMasterKeySpec": "ECC_NIST_P521",
493
- * "Description": "",
494
- * "Enabled": true,
495
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
496
- * "KeyManager": "CUSTOMER",
497
- * "KeySpec": "ECC_NIST_P521",
498
- * "KeyState": "Enabled",
499
- * "KeyUsage": "SIGN_VERIFY",
500
- * "MultiRegion": false,
501
- * "Origin": "AWS_KMS",
502
- * "SigningAlgorithms": [
503
- * "ECDSA_SHA_512"
504
- * ]
505
- * }
506
- * }
507
- * *\/
508
- * // example id: to-create-an-asymmetric-elliptic-curve-kms-key-for-signing-and-verification-3
509
- * ```
510
- *
511
- * @example To create an HMAC KMS key
512
- * ```javascript
513
- * // This example creates a 384-bit symmetric HMAC KMS key. The GENERATE_VERIFY_MAC key usage value is required even though it's the only valid value for HMAC KMS keys. The key spec and key usage can't be changed after the key is created.
514
- * const input = {
515
- * "KeySpec": "HMAC_384",
516
- * "KeyUsage": "GENERATE_VERIFY_MAC"
517
- * };
518
- * const command = new CreateKeyCommand(input);
519
- * const response = await client.send(command);
520
- * /* response ==
521
- * {
522
- * "KeyMetadata": {
523
- * "AWSAccountId": "111122223333",
524
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
525
- * "CreationDate": "2022-04-05T14:04:55-07:00",
526
- * "CustomerMasterKeySpec": "HMAC_384",
527
- * "Description": "",
528
- * "Enabled": true,
529
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
530
- * "KeyManager": "CUSTOMER",
531
- * "KeySpec": "HMAC_384",
532
- * "KeyState": "Enabled",
533
- * "KeyUsage": "GENERATE_VERIFY_MAC",
534
- * "MacAlgorithms": [
535
- * "HMAC_SHA_384"
536
- * ],
537
- * "MultiRegion": false,
538
- * "Origin": "AWS_KMS"
539
- * }
540
- * }
541
- * *\/
542
- * // example id: to-create-an-hmac-kms-key-1630628752841
543
- * ```
544
- *
545
- * @example To create a multi-Region primary KMS key
546
- * ```javascript
547
- * // This example creates a multi-Region primary symmetric encryption key. Because the default values for all parameters create a symmetric encryption key, only the MultiRegion parameter is required for this KMS key.
548
- * const input = {
549
- * "MultiRegion": true
550
- * };
551
- * const command = new CreateKeyCommand(input);
552
- * const response = await client.send(command);
553
- * /* response ==
554
- * {
555
- * "KeyMetadata": {
556
- * "AWSAccountId": "111122223333",
557
- * "Arn": "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef12345678990ab",
558
- * "CreationDate": "2021-09-02T016:15:21-09:00",
559
- * "CustomerMasterKeySpec": "SYMMETRIC_DEFAULT",
560
- * "Description": "",
561
- * "Enabled": true,
562
- * "EncryptionAlgorithms": [
563
- * "SYMMETRIC_DEFAULT"
564
- * ],
565
- * "KeyId": "mrk-1234abcd12ab34cd56ef12345678990ab",
566
- * "KeyManager": "CUSTOMER",
567
- * "KeySpec": "SYMMETRIC_DEFAULT",
568
- * "KeyState": "Enabled",
569
- * "KeyUsage": "ENCRYPT_DECRYPT",
570
- * "MultiRegion": true,
571
- * "MultiRegionConfiguration": {
572
- * "MultiRegionKeyType": "PRIMARY",
573
- * "PrimaryKey": {
574
- * "Arn": "arn:aws:kms:us-west-2:111122223333:key/mrk-1234abcd12ab34cd56ef12345678990ab",
575
- * "Region": "us-west-2"
576
- * },
577
- * "ReplicaKeys": []
578
- * },
579
- * "Origin": "AWS_KMS"
580
- * }
581
- * }
582
- * *\/
583
- * // example id: to-create-a-multi-region-primary-kms-key-4
584
- * ```
585
- *
586
- * @example To create a KMS key for imported key material
587
- * ```javascript
588
- * // This example creates a symmetric KMS key with no key material. When the operation is complete, you can import your own key material into the KMS key. To create this KMS key, set the Origin parameter to EXTERNAL.
589
- * const input = {
590
- * "Origin": "EXTERNAL"
591
- * };
592
- * const command = new CreateKeyCommand(input);
593
- * const response = await client.send(command);
594
- * /* response ==
595
- * {
596
- * "KeyMetadata": {
597
- * "AWSAccountId": "111122223333",
598
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
599
- * "CreationDate": "2019-12-02T07:48:55-07:00",
600
- * "CustomerMasterKeySpec": "SYMMETRIC_DEFAULT",
601
- * "Description": "",
602
- * "Enabled": false,
603
- * "EncryptionAlgorithms": [
604
- * "SYMMETRIC_DEFAULT"
605
- * ],
606
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
607
- * "KeyManager": "CUSTOMER",
608
- * "KeySpec": "SYMMETRIC_DEFAULT",
609
- * "KeyState": "PendingImport",
610
- * "KeyUsage": "ENCRYPT_DECRYPT",
611
- * "MultiRegion": false,
612
- * "Origin": "EXTERNAL"
613
- * }
614
- * }
615
- * *\/
616
- * // example id: to-create-a-kms-key-for-imported-key-material-5
617
- * ```
618
- *
619
- * @example To create a KMS key in an AWS CloudHSM key store
620
- * ```javascript
621
- * // This example creates a KMS key in the specified AWS CloudHSM key store. The operation creates the KMS key and its metadata in AWS KMS and creates the key material in the AWS CloudHSM cluster associated with the custom key store. This example requires the CustomKeyStoreId and Origin parameters.
622
- * const input = {
623
- * "CustomKeyStoreId": "cks-1234567890abcdef0",
624
- * "Origin": "AWS_CLOUDHSM"
625
- * };
626
- * const command = new CreateKeyCommand(input);
627
- * const response = await client.send(command);
628
- * /* response ==
629
- * {
630
- * "KeyMetadata": {
631
- * "AWSAccountId": "111122223333",
632
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab",
633
- * "CloudHsmClusterId": "cluster-234abcdefABC",
634
- * "CreationDate": "2019-12-02T07:48:55-07:00",
635
- * "CustomKeyStoreId": "cks-1234567890abcdef0",
636
- * "CustomerMasterKeySpec": "SYMMETRIC_DEFAULT",
637
- * "Description": "",
638
- * "Enabled": true,
639
- * "EncryptionAlgorithms": [
640
- * "SYMMETRIC_DEFAULT"
641
- * ],
642
- * "KeyId": "1234abcd-12ab-34cd-56ef-1234567890ab",
643
- * "KeyManager": "CUSTOMER",
644
- * "KeySpec": "SYMMETRIC_DEFAULT",
645
- * "KeyState": "Enabled",
646
- * "KeyUsage": "ENCRYPT_DECRYPT",
647
- * "MultiRegion": false,
648
- * "Origin": "AWS_CLOUDHSM"
649
- * }
650
- * }
651
- * *\/
652
- * // example id: to-create-a-kms-key-in-an-aws-cloudhsm-custom-key-store-6
653
- * ```
654
- *
655
- * @example To create a KMS key in an external key store
656
- * ```javascript
657
- * // This example creates a KMS key in the specified external key store. It uses the XksKeyId parameter to associate the KMS key with an existing symmetric encryption key in your external key manager. This CustomKeyStoreId, Origin, and XksKeyId parameters are required in this operation.
658
- * const input = {
659
- * "CustomKeyStoreId": "cks-9876543210fedcba9",
660
- * "Origin": "EXTERNAL_KEY_STORE",
661
- * "XksKeyId": "bb8562717f809024"
662
- * };
663
- * const command = new CreateKeyCommand(input);
664
- * const response = await client.send(command);
665
- * /* response ==
666
- * {
667
- * "KeyMetadata": {
668
- * "AWSAccountId": "111122223333",
669
- * "Arn": "arn:aws:kms:us-east-2:111122223333:key/0987dcba-09fe-87dc-65ba-ab0987654321",
670
- * "CreationDate": "2022-02-02T07:48:55-07:00",
671
- * "CustomKeyStoreId": "cks-9876543210fedcba9",
672
- * "CustomerMasterKeySpec": "SYMMETRIC_DEFAULT",
673
- * "Description": "",
674
- * "Enabled": true,
675
- * "EncryptionAlgorithms": [
676
- * "SYMMETRIC_DEFAULT"
677
- * ],
678
- * "KeyId": "0987dcba-09fe-87dc-65ba-ab0987654321",
679
- * "KeyManager": "CUSTOMER",
680
- * "KeySpec": "SYMMETRIC_DEFAULT",
681
- * "KeyState": "Enabled",
682
- * "KeyUsage": "ENCRYPT_DECRYPT",
683
- * "MultiRegion": false,
684
- * "Origin": "EXTERNAL_KEY_STORE",
685
- * "XksKeyConfiguration": {
686
- * "Id": "bb8562717f809024"
687
- * }
688
- * }
689
- * }
690
- * *\/
691
- * // example id: to-create-a-kms-key-in-an-external-custom-key-store-7
692
- * ```
693
410
  *
411
+ * @public
694
412
  */
695
413
  export declare class CreateKeyCommand extends CreateKeyCommand_base {
696
414
  /** @internal type navigation helper, not in runtime. */