@aws-sdk/client-secrets-manager 3.34.0 → 3.37.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +47 -0
- package/{dist/cjs → dist-cjs}/SecretsManager.js +2 -68
- package/dist-cjs/SecretsManagerClient.js +35 -0
- package/dist-cjs/commands/CancelRotateSecretCommand.js +36 -0
- package/dist-cjs/commands/CreateSecretCommand.js +36 -0
- package/dist-cjs/commands/DeleteResourcePolicyCommand.js +36 -0
- package/dist-cjs/commands/DeleteSecretCommand.js +36 -0
- package/dist-cjs/commands/DescribeSecretCommand.js +36 -0
- package/{dist/cjs → dist-cjs}/commands/GetRandomPasswordCommand.js +2 -39
- package/dist-cjs/commands/GetResourcePolicyCommand.js +36 -0
- package/dist-cjs/commands/GetSecretValueCommand.js +36 -0
- package/dist-cjs/commands/ListSecretVersionIdsCommand.js +36 -0
- package/dist-cjs/commands/ListSecretsCommand.js +36 -0
- package/dist-cjs/commands/PutResourcePolicyCommand.js +36 -0
- package/dist-cjs/commands/PutSecretValueCommand.js +36 -0
- package/{dist/cjs → dist-cjs}/commands/RemoveRegionsFromReplicationCommand.js +2 -27
- package/{dist/cjs → dist-cjs}/commands/ReplicateSecretToRegionsCommand.js +2 -28
- package/dist-cjs/commands/RestoreSecretCommand.js +36 -0
- package/dist-cjs/commands/RotateSecretCommand.js +36 -0
- package/{dist/cjs → dist-cjs}/commands/StopReplicationToReplicaCommand.js +2 -27
- package/dist-cjs/commands/TagResourceCommand.js +36 -0
- package/dist-cjs/commands/UntagResourceCommand.js +36 -0
- package/dist-cjs/commands/UpdateSecretCommand.js +36 -0
- package/dist-cjs/commands/UpdateSecretVersionStageCommand.js +36 -0
- package/dist-cjs/commands/ValidateResourcePolicyCommand.js +36 -0
- package/{dist/cjs → dist-cjs}/endpoints.js +1 -2
- package/{dist/cjs → dist-cjs}/index.js +0 -1
- package/{dist/cjs → dist-cjs}/models/index.js +0 -1
- package/{dist/cjs → dist-cjs}/models/models_0.js +0 -187
- package/{dist/cjs → dist-cjs}/pagination/Interfaces.js +0 -1
- package/{dist/cjs → dist-cjs}/pagination/ListSecretVersionIdsPaginator.js +1 -12
- package/{dist/cjs → dist-cjs}/pagination/ListSecretsPaginator.js +1 -12
- package/{dist/cjs → dist-cjs}/protocols/Aws_json1_1.js +0 -6
- package/{dist/cjs → dist-cjs}/runtimeConfig.browser.js +1 -5
- package/{dist/cjs → dist-cjs}/runtimeConfig.js +1 -5
- package/{dist/cjs → dist-cjs}/runtimeConfig.native.js +0 -4
- package/{dist/cjs → dist-cjs}/runtimeConfig.shared.js +1 -5
- package/{dist/es → dist-es}/SecretsManager.js +2 -3
- package/{dist/es → dist-es}/SecretsManagerClient.js +1 -2
- package/{dist/es → dist-es}/commands/CancelRotateSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/CreateSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/DeleteResourcePolicyCommand.js +2 -3
- package/{dist/es → dist-es}/commands/DeleteSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/DescribeSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/GetRandomPasswordCommand.js +2 -3
- package/{dist/es → dist-es}/commands/GetResourcePolicyCommand.js +2 -3
- package/{dist/es → dist-es}/commands/GetSecretValueCommand.js +2 -3
- package/{dist/es → dist-es}/commands/ListSecretVersionIdsCommand.js +2 -3
- package/{dist/es → dist-es}/commands/ListSecretsCommand.js +2 -3
- package/{dist/es → dist-es}/commands/PutResourcePolicyCommand.js +2 -3
- package/{dist/es → dist-es}/commands/PutSecretValueCommand.js +2 -3
- package/{dist/es → dist-es}/commands/RemoveRegionsFromReplicationCommand.js +2 -3
- package/{dist/es → dist-es}/commands/ReplicateSecretToRegionsCommand.js +2 -3
- package/{dist/es → dist-es}/commands/RestoreSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/RotateSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/StopReplicationToReplicaCommand.js +2 -3
- package/{dist/es → dist-es}/commands/TagResourceCommand.js +2 -3
- package/{dist/es → dist-es}/commands/UntagResourceCommand.js +2 -3
- package/{dist/es → dist-es}/commands/UpdateSecretCommand.js +2 -3
- package/{dist/es → dist-es}/commands/UpdateSecretVersionStageCommand.js +2 -3
- package/{dist/es → dist-es}/commands/ValidateResourcePolicyCommand.js +2 -3
- package/{dist/es → dist-es}/endpoints.js +1 -2
- package/{dist/types/index.d.ts → dist-es/index.js} +0 -0
- package/{dist/types/models/index.d.ts → dist-es/models/index.js} +0 -0
- package/{dist/es → dist-es}/models/models_0.js +0 -1
- package/dist-es/pagination/Interfaces.js +1 -0
- package/{dist/es → dist-es}/pagination/ListSecretVersionIdsPaginator.js +1 -2
- package/{dist/es → dist-es}/pagination/ListSecretsPaginator.js +1 -2
- package/{dist/es → dist-es}/protocols/Aws_json1_1.js +0 -1
- package/{dist/es → dist-es}/runtimeConfig.browser.js +1 -2
- package/{dist/es → dist-es}/runtimeConfig.js +1 -2
- package/{dist/es → dist-es}/runtimeConfig.native.js +0 -1
- package/{dist/es → dist-es}/runtimeConfig.shared.js +1 -2
- package/{dist/types → dist-types}/SecretsManager.d.ts +19 -13
- package/{dist/types → dist-types}/SecretsManagerClient.d.ts +9 -9
- package/{dist/types → dist-types}/commands/CancelRotateSecretCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/CreateSecretCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/DeleteResourcePolicyCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/DeleteSecretCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/DescribeSecretCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/GetRandomPasswordCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/GetResourcePolicyCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/GetSecretValueCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/ListSecretVersionIdsCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/ListSecretsCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/PutResourcePolicyCommand.d.ts +3 -3
- package/{dist/types/ts3.4 → dist-types}/commands/PutSecretValueCommand.d.ts +123 -122
- package/{dist/types → dist-types}/commands/RemoveRegionsFromReplicationCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/ReplicateSecretToRegionsCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/RestoreSecretCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/RotateSecretCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/StopReplicationToReplicaCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/TagResourceCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/UntagResourceCommand.d.ts +3 -3
- package/{dist/types/ts3.4 → dist-types}/commands/UpdateSecretCommand.d.ts +124 -119
- package/{dist/types → dist-types}/commands/UpdateSecretVersionStageCommand.d.ts +3 -3
- package/{dist/types → dist-types}/commands/ValidateResourcePolicyCommand.d.ts +3 -3
- package/{dist/types → dist-types}/endpoints.d.ts +0 -0
- package/{index.ts → dist-types/index.d.ts} +0 -0
- package/{models/index.ts → dist-types/models/index.d.ts} +0 -0
- package/{dist/types → dist-types}/models/models_0.d.ts +54 -268
- package/{dist/types → dist-types}/pagination/Interfaces.d.ts +1 -1
- package/{dist/types → dist-types}/pagination/ListSecretVersionIdsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/pagination/ListSecretsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/protocols/Aws_json1_1.d.ts +3 -3
- package/{dist/types → dist-types}/runtimeConfig.browser.d.ts +0 -0
- package/{dist/types → dist-types}/runtimeConfig.d.ts +1 -1
- package/{dist/types → dist-types}/runtimeConfig.native.d.ts +0 -0
- package/{dist/types → dist-types}/runtimeConfig.shared.d.ts +0 -0
- package/dist-types/ts3.4/SecretsManager.d.ts +115 -0
- package/dist-types/ts3.4/SecretsManagerClient.d.ts +89 -0
- package/dist-types/ts3.4/commands/CancelRotateSecretCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/CreateSecretCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/DeleteResourcePolicyCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/DeleteSecretCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/DescribeSecretCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetRandomPasswordCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetResourcePolicyCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/GetSecretValueCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListSecretVersionIdsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ListSecretsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/PutResourcePolicyCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/PutSecretValueCommand.d.ts +17 -0
- package/{dist/types → dist-types}/ts3.4/commands/RemoveRegionsFromReplicationCommand.d.ts +5 -23
- package/dist-types/ts3.4/commands/ReplicateSecretToRegionsCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/RestoreSecretCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/RotateSecretCommand.d.ts +17 -0
- package/{dist/types → dist-types}/ts3.4/commands/StopReplicationToReplicaCommand.d.ts +5 -23
- package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateSecretCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/UpdateSecretVersionStageCommand.d.ts +17 -0
- package/dist-types/ts3.4/commands/ValidateResourcePolicyCommand.d.ts +17 -0
- package/{dist/types → dist-types}/ts3.4/endpoints.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/index.d.ts +0 -0
- package/{dist/types → dist-types}/ts3.4/models/index.d.ts +0 -0
- package/dist-types/ts3.4/models/models_0.d.ts +791 -0
- package/{dist/types → dist-types}/ts3.4/pagination/Interfaces.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/pagination/ListSecretVersionIdsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/pagination/ListSecretsPaginator.d.ts +1 -1
- package/{dist/types → dist-types}/ts3.4/protocols/Aws_json1_1.d.ts +3 -3
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.browser.d.ts +1 -3
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.d.ts +2 -4
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.native.d.ts +1 -3
- package/{dist/types → dist-types}/ts3.4/runtimeConfig.shared.d.ts +1 -3
- package/package.json +45 -42
- package/SecretsManager.ts +0 -1642
- package/SecretsManagerClient.ts +0 -384
- package/commands/CancelRotateSecretCommand.ts +0 -146
- package/commands/CreateSecretCommand.ts +0 -181
- package/commands/DeleteResourcePolicyCommand.ts +0 -117
- package/commands/DeleteSecretCommand.ts +0 -139
- package/commands/DescribeSecretCommand.ts +0 -121
- package/commands/GetRandomPasswordCommand.ts +0 -106
- package/commands/GetResourcePolicyCommand.ts +0 -120
- package/commands/GetSecretValueCommand.ts +0 -121
- package/commands/ListSecretVersionIdsCommand.ts +0 -122
- package/commands/ListSecretsCommand.ts +0 -123
- package/commands/PutResourcePolicyCommand.ts +0 -125
- package/commands/PutSecretValueCommand.ts +0 -181
- package/commands/RemoveRegionsFromReplicationCommand.ts +0 -99
- package/commands/ReplicateSecretToRegionsCommand.ts +0 -95
- package/commands/RestoreSecretCommand.ts +0 -112
- package/commands/RotateSecretCommand.ts +0 -155
- package/commands/StopReplicationToReplicaCommand.ts +0 -94
- package/commands/TagResourceCommand.ts +0 -149
- package/commands/UntagResourceCommand.ts +0 -122
- package/commands/UpdateSecretCommand.ts +0 -178
- package/commands/UpdateSecretVersionStageCommand.ts +0 -130
- package/commands/ValidateResourcePolicyCommand.ts +0 -128
- package/dist/cjs/SecretsManager.js.map +0 -1
- package/dist/cjs/SecretsManagerClient.js +0 -106
- package/dist/cjs/SecretsManagerClient.js.map +0 -1
- package/dist/cjs/commands/CancelRotateSecretCommand.js +0 -113
- package/dist/cjs/commands/CancelRotateSecretCommand.js.map +0 -1
- package/dist/cjs/commands/CreateSecretCommand.js +0 -148
- package/dist/cjs/commands/CreateSecretCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteResourcePolicyCommand.js +0 -84
- package/dist/cjs/commands/DeleteResourcePolicyCommand.js.map +0 -1
- package/dist/cjs/commands/DeleteSecretCommand.js +0 -106
- package/dist/cjs/commands/DeleteSecretCommand.js.map +0 -1
- package/dist/cjs/commands/DescribeSecretCommand.js +0 -88
- package/dist/cjs/commands/DescribeSecretCommand.js.map +0 -1
- package/dist/cjs/commands/GetRandomPasswordCommand.js.map +0 -1
- package/dist/cjs/commands/GetResourcePolicyCommand.js +0 -87
- package/dist/cjs/commands/GetResourcePolicyCommand.js.map +0 -1
- package/dist/cjs/commands/GetSecretValueCommand.js +0 -88
- package/dist/cjs/commands/GetSecretValueCommand.js.map +0 -1
- package/dist/cjs/commands/ListSecretVersionIdsCommand.js +0 -89
- package/dist/cjs/commands/ListSecretVersionIdsCommand.js.map +0 -1
- package/dist/cjs/commands/ListSecretsCommand.js +0 -90
- package/dist/cjs/commands/ListSecretsCommand.js.map +0 -1
- package/dist/cjs/commands/PutResourcePolicyCommand.js +0 -92
- package/dist/cjs/commands/PutResourcePolicyCommand.js.map +0 -1
- package/dist/cjs/commands/PutSecretValueCommand.js +0 -148
- package/dist/cjs/commands/PutSecretValueCommand.js.map +0 -1
- package/dist/cjs/commands/RemoveRegionsFromReplicationCommand.js.map +0 -1
- package/dist/cjs/commands/ReplicateSecretToRegionsCommand.js.map +0 -1
- package/dist/cjs/commands/RestoreSecretCommand.js +0 -79
- package/dist/cjs/commands/RestoreSecretCommand.js.map +0 -1
- package/dist/cjs/commands/RotateSecretCommand.js +0 -122
- package/dist/cjs/commands/RotateSecretCommand.js.map +0 -1
- package/dist/cjs/commands/StopReplicationToReplicaCommand.js.map +0 -1
- package/dist/cjs/commands/TagResourceCommand.js +0 -116
- package/dist/cjs/commands/TagResourceCommand.js.map +0 -1
- package/dist/cjs/commands/UntagResourceCommand.js +0 -89
- package/dist/cjs/commands/UntagResourceCommand.js.map +0 -1
- package/dist/cjs/commands/UpdateSecretCommand.js +0 -145
- package/dist/cjs/commands/UpdateSecretCommand.js.map +0 -1
- package/dist/cjs/commands/UpdateSecretVersionStageCommand.js +0 -97
- package/dist/cjs/commands/UpdateSecretVersionStageCommand.js.map +0 -1
- package/dist/cjs/commands/ValidateResourcePolicyCommand.js +0 -95
- package/dist/cjs/commands/ValidateResourcePolicyCommand.js.map +0 -1
- package/dist/cjs/endpoints.js.map +0 -1
- package/dist/cjs/index.js.map +0 -1
- package/dist/cjs/models/index.js.map +0 -1
- package/dist/cjs/models/models_0.js.map +0 -1
- package/dist/cjs/package.json +0 -93
- package/dist/cjs/pagination/Interfaces.js.map +0 -1
- package/dist/cjs/pagination/ListSecretVersionIdsPaginator.js.map +0 -1
- package/dist/cjs/pagination/ListSecretsPaginator.js.map +0 -1
- package/dist/cjs/protocols/Aws_json1_1.js.map +0 -1
- package/dist/cjs/runtimeConfig.browser.js.map +0 -1
- package/dist/cjs/runtimeConfig.js.map +0 -1
- package/dist/cjs/runtimeConfig.native.js.map +0 -1
- package/dist/cjs/runtimeConfig.shared.js.map +0 -1
- package/dist/es/SecretsManager.js.map +0 -1
- package/dist/es/SecretsManagerClient.js.map +0 -1
- package/dist/es/commands/CancelRotateSecretCommand.js.map +0 -1
- package/dist/es/commands/CreateSecretCommand.js.map +0 -1
- package/dist/es/commands/DeleteResourcePolicyCommand.js.map +0 -1
- package/dist/es/commands/DeleteSecretCommand.js.map +0 -1
- package/dist/es/commands/DescribeSecretCommand.js.map +0 -1
- package/dist/es/commands/GetRandomPasswordCommand.js.map +0 -1
- package/dist/es/commands/GetResourcePolicyCommand.js.map +0 -1
- package/dist/es/commands/GetSecretValueCommand.js.map +0 -1
- package/dist/es/commands/ListSecretVersionIdsCommand.js.map +0 -1
- package/dist/es/commands/ListSecretsCommand.js.map +0 -1
- package/dist/es/commands/PutResourcePolicyCommand.js.map +0 -1
- package/dist/es/commands/PutSecretValueCommand.js.map +0 -1
- package/dist/es/commands/RemoveRegionsFromReplicationCommand.js.map +0 -1
- package/dist/es/commands/ReplicateSecretToRegionsCommand.js.map +0 -1
- package/dist/es/commands/RestoreSecretCommand.js.map +0 -1
- package/dist/es/commands/RotateSecretCommand.js.map +0 -1
- package/dist/es/commands/StopReplicationToReplicaCommand.js.map +0 -1
- package/dist/es/commands/TagResourceCommand.js.map +0 -1
- package/dist/es/commands/UntagResourceCommand.js.map +0 -1
- package/dist/es/commands/UpdateSecretCommand.js.map +0 -1
- package/dist/es/commands/UpdateSecretVersionStageCommand.js.map +0 -1
- package/dist/es/commands/ValidateResourcePolicyCommand.js.map +0 -1
- package/dist/es/endpoints.js.map +0 -1
- package/dist/es/index.js +0 -29
- package/dist/es/index.js.map +0 -1
- package/dist/es/models/index.js +0 -2
- package/dist/es/models/index.js.map +0 -1
- package/dist/es/models/models_0.js.map +0 -1
- package/dist/es/package.json +0 -93
- package/dist/es/pagination/Interfaces.js +0 -2
- package/dist/es/pagination/Interfaces.js.map +0 -1
- package/dist/es/pagination/ListSecretVersionIdsPaginator.js.map +0 -1
- package/dist/es/pagination/ListSecretsPaginator.js.map +0 -1
- package/dist/es/protocols/Aws_json1_1.js.map +0 -1
- package/dist/es/runtimeConfig.browser.js.map +0 -1
- package/dist/es/runtimeConfig.js.map +0 -1
- package/dist/es/runtimeConfig.native.js.map +0 -1
- package/dist/es/runtimeConfig.shared.js.map +0 -1
- package/dist/types/commands/PutSecretValueCommand.d.ts +0 -122
- package/dist/types/commands/UpdateSecretCommand.d.ts +0 -119
- package/dist/types/ts3.4/SecretsManager.d.ts +0 -1014
- package/dist/types/ts3.4/SecretsManagerClient.d.ts +0 -216
- package/dist/types/ts3.4/commands/CancelRotateSecretCommand.d.ts +0 -87
- package/dist/types/ts3.4/commands/CreateSecretCommand.d.ts +0 -122
- package/dist/types/ts3.4/commands/DeleteResourcePolicyCommand.d.ts +0 -58
- package/dist/types/ts3.4/commands/DeleteSecretCommand.d.ts +0 -80
- package/dist/types/ts3.4/commands/DescribeSecretCommand.d.ts +0 -62
- package/dist/types/ts3.4/commands/GetRandomPasswordCommand.d.ts +0 -47
- package/dist/types/ts3.4/commands/GetResourcePolicyCommand.d.ts +0 -61
- package/dist/types/ts3.4/commands/GetSecretValueCommand.d.ts +0 -62
- package/dist/types/ts3.4/commands/ListSecretVersionIdsCommand.d.ts +0 -63
- package/dist/types/ts3.4/commands/ListSecretsCommand.d.ts +0 -64
- package/dist/types/ts3.4/commands/PutResourcePolicyCommand.d.ts +0 -66
- package/dist/types/ts3.4/commands/ReplicateSecretToRegionsCommand.d.ts +0 -36
- package/dist/types/ts3.4/commands/RestoreSecretCommand.d.ts +0 -53
- package/dist/types/ts3.4/commands/RotateSecretCommand.d.ts +0 -96
- package/dist/types/ts3.4/commands/TagResourceCommand.d.ts +0 -90
- package/dist/types/ts3.4/commands/UntagResourceCommand.d.ts +0 -63
- package/dist/types/ts3.4/commands/UpdateSecretVersionStageCommand.d.ts +0 -71
- package/dist/types/ts3.4/commands/ValidateResourcePolicyCommand.d.ts +0 -69
- package/dist/types/ts3.4/models/models_0.d.ts +0 -2041
- package/endpoints.ts +0 -86
- package/jest.config.js +0 -4
- package/models/models_0.ts +0 -2422
- package/pagination/Interfaces.ts +0 -7
- package/pagination/ListSecretVersionIdsPaginator.ts +0 -58
- package/pagination/ListSecretsPaginator.ts +0 -54
- package/protocols/Aws_json1_1.ts +0 -3421
- package/runtimeConfig.browser.ts +0 -40
- package/runtimeConfig.native.ts +0 -16
- package/runtimeConfig.shared.ts +0 -16
- package/runtimeConfig.ts +0 -45
- package/tsconfig.es.json +0 -10
- package/tsconfig.json +0 -31
- package/tsconfig.types.json +0 -8
|
@@ -1,181 +0,0 @@
|
|
|
1
|
-
import { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
|
|
2
|
-
import { PutSecretValueRequest, PutSecretValueResponse } from "../models/models_0";
|
|
3
|
-
import {
|
|
4
|
-
deserializeAws_json1_1PutSecretValueCommand,
|
|
5
|
-
serializeAws_json1_1PutSecretValueCommand,
|
|
6
|
-
} from "../protocols/Aws_json1_1";
|
|
7
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
8
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
9
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
FinalizeHandlerArguments,
|
|
12
|
-
Handler,
|
|
13
|
-
HandlerExecutionContext,
|
|
14
|
-
MiddlewareStack,
|
|
15
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
16
|
-
MetadataBearer as __MetadataBearer,
|
|
17
|
-
SerdeContext as __SerdeContext,
|
|
18
|
-
} from "@aws-sdk/types";
|
|
19
|
-
|
|
20
|
-
export interface PutSecretValueCommandInput extends PutSecretValueRequest {}
|
|
21
|
-
export interface PutSecretValueCommandOutput extends PutSecretValueResponse, __MetadataBearer {}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* <p>Stores a new encrypted secret value in the specified secret. To do this, the operation
|
|
25
|
-
* creates a new version and attaches it to the secret. The version can contain a new
|
|
26
|
-
* <code>SecretString</code> value or a new <code>SecretBinary</code> value. You can also
|
|
27
|
-
* specify the staging labels that are initially attached to the new version.</p>
|
|
28
|
-
* <note>
|
|
29
|
-
* <p>The Secrets Manager console uses only the <code>SecretString</code> field. To add binary data to a
|
|
30
|
-
* secret with the <code>SecretBinary</code> field you must use the Amazon Web Services CLI or one of the
|
|
31
|
-
* Amazon Web Services SDKs.</p>
|
|
32
|
-
* </note>
|
|
33
|
-
* <ul>
|
|
34
|
-
* <li>
|
|
35
|
-
* <p>If this operation creates the first version for the secret then Secrets Manager
|
|
36
|
-
* automatically attaches the staging label <code>AWSCURRENT</code> to the new version.</p>
|
|
37
|
-
* </li>
|
|
38
|
-
* <li>
|
|
39
|
-
* <p>If you do not specify a value for VersionStages then Secrets Manager automatically
|
|
40
|
-
* moves the staging label <code>AWSCURRENT</code> to this new version.</p>
|
|
41
|
-
* </li>
|
|
42
|
-
* <li>
|
|
43
|
-
* <p>If this operation moves the staging label <code>AWSCURRENT</code> from another version to this
|
|
44
|
-
* version, then Secrets Manager also automatically moves the staging label <code>AWSPREVIOUS</code> to
|
|
45
|
-
* the version that <code>AWSCURRENT</code> was removed from.</p>
|
|
46
|
-
* </li>
|
|
47
|
-
* <li>
|
|
48
|
-
* <p>This operation is idempotent. If a version with a <code>VersionId</code> with the same
|
|
49
|
-
* value as the <code>ClientRequestToken</code> parameter already exists and you specify the
|
|
50
|
-
* same secret data, the operation succeeds but does nothing. However, if the secret data is
|
|
51
|
-
* different, then the operation fails because you cannot modify an existing version; you can
|
|
52
|
-
* only create new ones.</p>
|
|
53
|
-
* </li>
|
|
54
|
-
* </ul>
|
|
55
|
-
* <note>
|
|
56
|
-
* <ul>
|
|
57
|
-
* <li>
|
|
58
|
-
* <p>If you call an operation to encrypt or decrypt the <code>SecretString</code>
|
|
59
|
-
* or <code>SecretBinary</code> for a secret in the same account as the calling user and that
|
|
60
|
-
* secret doesn't specify a Amazon Web Services KMS encryption key, Secrets Manager uses the account's default
|
|
61
|
-
* Amazon Web Services managed customer master key (CMK) with the alias <code>aws/secretsmanager</code>. If this key
|
|
62
|
-
* doesn't already exist in your account then Secrets Manager creates it for you automatically. All
|
|
63
|
-
* users and roles in the same Amazon Web Services account automatically have access to use the default CMK.
|
|
64
|
-
* Note that if an Secrets Manager API call results in Amazon Web Services creating the account's
|
|
65
|
-
* Amazon Web Services-managed CMK, it can result in a one-time significant delay in returning the
|
|
66
|
-
* result.</p>
|
|
67
|
-
* </li>
|
|
68
|
-
* <li>
|
|
69
|
-
* <p>If the secret resides in a different Amazon Web Services account from the credentials calling an API that
|
|
70
|
-
* requires encryption or decryption of the secret value then you must create and use a custom
|
|
71
|
-
* Amazon Web Services KMS CMK because you can't access the default CMK for the account using credentials
|
|
72
|
-
* from a different Amazon Web Services account. Store the ARN of the CMK in the secret when you create the
|
|
73
|
-
* secret or when you update it by including it in the <code>KMSKeyId</code>. If you call an
|
|
74
|
-
* API that must encrypt or decrypt <code>SecretString</code> or <code>SecretBinary</code>
|
|
75
|
-
* using credentials from a different account then the Amazon Web Services KMS key policy must grant cross-account
|
|
76
|
-
* access to that other account's user or role for both the kms:GenerateDataKey and
|
|
77
|
-
* kms:Decrypt operations.</p>
|
|
78
|
-
* </li>
|
|
79
|
-
* </ul>
|
|
80
|
-
* </note>
|
|
81
|
-
* <p>
|
|
82
|
-
* <b>Minimum permissions</b>
|
|
83
|
-
* </p>
|
|
84
|
-
* <p>To run this command, you must have the following permissions:</p>
|
|
85
|
-
* <ul>
|
|
86
|
-
* <li>
|
|
87
|
-
* <p>secretsmanager:PutSecretValue</p>
|
|
88
|
-
* </li>
|
|
89
|
-
* <li>
|
|
90
|
-
* <p>kms:GenerateDataKey - needed only if you use a customer-managed Amazon Web Services KMS key to encrypt
|
|
91
|
-
* the secret. You do not need this permission to use the account's default Amazon Web Services managed CMK
|
|
92
|
-
* for Secrets Manager.</p>
|
|
93
|
-
* </li>
|
|
94
|
-
* </ul>
|
|
95
|
-
* <p>
|
|
96
|
-
* <b>Related operations</b>
|
|
97
|
-
* </p>
|
|
98
|
-
* <ul>
|
|
99
|
-
* <li>
|
|
100
|
-
* <p>To retrieve the encrypted value you store in the version of a secret, use <a>GetSecretValue</a>.</p>
|
|
101
|
-
* </li>
|
|
102
|
-
* <li>
|
|
103
|
-
* <p>To create a secret, use <a>CreateSecret</a>.</p>
|
|
104
|
-
* </li>
|
|
105
|
-
* <li>
|
|
106
|
-
* <p>To get the details for a secret, use <a>DescribeSecret</a>.</p>
|
|
107
|
-
* </li>
|
|
108
|
-
* <li>
|
|
109
|
-
* <p>To list the versions attached to a secret, use <a>ListSecretVersionIds</a>.</p>
|
|
110
|
-
* </li>
|
|
111
|
-
* </ul>
|
|
112
|
-
* @example
|
|
113
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
114
|
-
* ```javascript
|
|
115
|
-
* import { SecretsManagerClient, PutSecretValueCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
|
|
116
|
-
* // const { SecretsManagerClient, PutSecretValueCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
|
|
117
|
-
* const client = new SecretsManagerClient(config);
|
|
118
|
-
* const command = new PutSecretValueCommand(input);
|
|
119
|
-
* const response = await client.send(command);
|
|
120
|
-
* ```
|
|
121
|
-
*
|
|
122
|
-
* @see {@link PutSecretValueCommandInput} for command's `input` shape.
|
|
123
|
-
* @see {@link PutSecretValueCommandOutput} for command's `response` shape.
|
|
124
|
-
* @see {@link SecretsManagerClientResolvedConfig | config} for command's `input` shape.
|
|
125
|
-
*
|
|
126
|
-
*/
|
|
127
|
-
export class PutSecretValueCommand extends $Command<
|
|
128
|
-
PutSecretValueCommandInput,
|
|
129
|
-
PutSecretValueCommandOutput,
|
|
130
|
-
SecretsManagerClientResolvedConfig
|
|
131
|
-
> {
|
|
132
|
-
// Start section: command_properties
|
|
133
|
-
// End section: command_properties
|
|
134
|
-
|
|
135
|
-
constructor(readonly input: PutSecretValueCommandInput) {
|
|
136
|
-
// Start section: command_constructor
|
|
137
|
-
super();
|
|
138
|
-
// End section: command_constructor
|
|
139
|
-
}
|
|
140
|
-
|
|
141
|
-
/**
|
|
142
|
-
* @internal
|
|
143
|
-
*/
|
|
144
|
-
resolveMiddleware(
|
|
145
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
146
|
-
configuration: SecretsManagerClientResolvedConfig,
|
|
147
|
-
options?: __HttpHandlerOptions
|
|
148
|
-
): Handler<PutSecretValueCommandInput, PutSecretValueCommandOutput> {
|
|
149
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
150
|
-
|
|
151
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
152
|
-
|
|
153
|
-
const { logger } = configuration;
|
|
154
|
-
const clientName = "SecretsManagerClient";
|
|
155
|
-
const commandName = "PutSecretValueCommand";
|
|
156
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
157
|
-
logger,
|
|
158
|
-
clientName,
|
|
159
|
-
commandName,
|
|
160
|
-
inputFilterSensitiveLog: PutSecretValueRequest.filterSensitiveLog,
|
|
161
|
-
outputFilterSensitiveLog: PutSecretValueResponse.filterSensitiveLog,
|
|
162
|
-
};
|
|
163
|
-
const { requestHandler } = configuration;
|
|
164
|
-
return stack.resolve(
|
|
165
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
166
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
167
|
-
handlerExecutionContext
|
|
168
|
-
);
|
|
169
|
-
}
|
|
170
|
-
|
|
171
|
-
private serialize(input: PutSecretValueCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
172
|
-
return serializeAws_json1_1PutSecretValueCommand(input, context);
|
|
173
|
-
}
|
|
174
|
-
|
|
175
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<PutSecretValueCommandOutput> {
|
|
176
|
-
return deserializeAws_json1_1PutSecretValueCommand(output, context);
|
|
177
|
-
}
|
|
178
|
-
|
|
179
|
-
// Start section: command_body_extra
|
|
180
|
-
// End section: command_body_extra
|
|
181
|
-
}
|
|
@@ -1,99 +0,0 @@
|
|
|
1
|
-
import { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
|
|
2
|
-
import { RemoveRegionsFromReplicationRequest, RemoveRegionsFromReplicationResponse } from "../models/models_0";
|
|
3
|
-
import {
|
|
4
|
-
deserializeAws_json1_1RemoveRegionsFromReplicationCommand,
|
|
5
|
-
serializeAws_json1_1RemoveRegionsFromReplicationCommand,
|
|
6
|
-
} from "../protocols/Aws_json1_1";
|
|
7
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
8
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
9
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
FinalizeHandlerArguments,
|
|
12
|
-
Handler,
|
|
13
|
-
HandlerExecutionContext,
|
|
14
|
-
MiddlewareStack,
|
|
15
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
16
|
-
MetadataBearer as __MetadataBearer,
|
|
17
|
-
SerdeContext as __SerdeContext,
|
|
18
|
-
} from "@aws-sdk/types";
|
|
19
|
-
|
|
20
|
-
export interface RemoveRegionsFromReplicationCommandInput extends RemoveRegionsFromReplicationRequest {}
|
|
21
|
-
export interface RemoveRegionsFromReplicationCommandOutput
|
|
22
|
-
extends RemoveRegionsFromReplicationResponse,
|
|
23
|
-
__MetadataBearer {}
|
|
24
|
-
|
|
25
|
-
/**
|
|
26
|
-
* <p>Remove regions from replication.</p>
|
|
27
|
-
* @example
|
|
28
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
29
|
-
* ```javascript
|
|
30
|
-
* import { SecretsManagerClient, RemoveRegionsFromReplicationCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
|
|
31
|
-
* // const { SecretsManagerClient, RemoveRegionsFromReplicationCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
|
|
32
|
-
* const client = new SecretsManagerClient(config);
|
|
33
|
-
* const command = new RemoveRegionsFromReplicationCommand(input);
|
|
34
|
-
* const response = await client.send(command);
|
|
35
|
-
* ```
|
|
36
|
-
*
|
|
37
|
-
* @see {@link RemoveRegionsFromReplicationCommandInput} for command's `input` shape.
|
|
38
|
-
* @see {@link RemoveRegionsFromReplicationCommandOutput} for command's `response` shape.
|
|
39
|
-
* @see {@link SecretsManagerClientResolvedConfig | config} for command's `input` shape.
|
|
40
|
-
*
|
|
41
|
-
*/
|
|
42
|
-
export class RemoveRegionsFromReplicationCommand extends $Command<
|
|
43
|
-
RemoveRegionsFromReplicationCommandInput,
|
|
44
|
-
RemoveRegionsFromReplicationCommandOutput,
|
|
45
|
-
SecretsManagerClientResolvedConfig
|
|
46
|
-
> {
|
|
47
|
-
// Start section: command_properties
|
|
48
|
-
// End section: command_properties
|
|
49
|
-
|
|
50
|
-
constructor(readonly input: RemoveRegionsFromReplicationCommandInput) {
|
|
51
|
-
// Start section: command_constructor
|
|
52
|
-
super();
|
|
53
|
-
// End section: command_constructor
|
|
54
|
-
}
|
|
55
|
-
|
|
56
|
-
/**
|
|
57
|
-
* @internal
|
|
58
|
-
*/
|
|
59
|
-
resolveMiddleware(
|
|
60
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
61
|
-
configuration: SecretsManagerClientResolvedConfig,
|
|
62
|
-
options?: __HttpHandlerOptions
|
|
63
|
-
): Handler<RemoveRegionsFromReplicationCommandInput, RemoveRegionsFromReplicationCommandOutput> {
|
|
64
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
65
|
-
|
|
66
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
67
|
-
|
|
68
|
-
const { logger } = configuration;
|
|
69
|
-
const clientName = "SecretsManagerClient";
|
|
70
|
-
const commandName = "RemoveRegionsFromReplicationCommand";
|
|
71
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
72
|
-
logger,
|
|
73
|
-
clientName,
|
|
74
|
-
commandName,
|
|
75
|
-
inputFilterSensitiveLog: RemoveRegionsFromReplicationRequest.filterSensitiveLog,
|
|
76
|
-
outputFilterSensitiveLog: RemoveRegionsFromReplicationResponse.filterSensitiveLog,
|
|
77
|
-
};
|
|
78
|
-
const { requestHandler } = configuration;
|
|
79
|
-
return stack.resolve(
|
|
80
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
81
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
82
|
-
handlerExecutionContext
|
|
83
|
-
);
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
private serialize(input: RemoveRegionsFromReplicationCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
87
|
-
return serializeAws_json1_1RemoveRegionsFromReplicationCommand(input, context);
|
|
88
|
-
}
|
|
89
|
-
|
|
90
|
-
private deserialize(
|
|
91
|
-
output: __HttpResponse,
|
|
92
|
-
context: __SerdeContext
|
|
93
|
-
): Promise<RemoveRegionsFromReplicationCommandOutput> {
|
|
94
|
-
return deserializeAws_json1_1RemoveRegionsFromReplicationCommand(output, context);
|
|
95
|
-
}
|
|
96
|
-
|
|
97
|
-
// Start section: command_body_extra
|
|
98
|
-
// End section: command_body_extra
|
|
99
|
-
}
|
|
@@ -1,95 +0,0 @@
|
|
|
1
|
-
import { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
|
|
2
|
-
import { ReplicateSecretToRegionsRequest, ReplicateSecretToRegionsResponse } from "../models/models_0";
|
|
3
|
-
import {
|
|
4
|
-
deserializeAws_json1_1ReplicateSecretToRegionsCommand,
|
|
5
|
-
serializeAws_json1_1ReplicateSecretToRegionsCommand,
|
|
6
|
-
} from "../protocols/Aws_json1_1";
|
|
7
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
8
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
9
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
FinalizeHandlerArguments,
|
|
12
|
-
Handler,
|
|
13
|
-
HandlerExecutionContext,
|
|
14
|
-
MiddlewareStack,
|
|
15
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
16
|
-
MetadataBearer as __MetadataBearer,
|
|
17
|
-
SerdeContext as __SerdeContext,
|
|
18
|
-
} from "@aws-sdk/types";
|
|
19
|
-
|
|
20
|
-
export interface ReplicateSecretToRegionsCommandInput extends ReplicateSecretToRegionsRequest {}
|
|
21
|
-
export interface ReplicateSecretToRegionsCommandOutput extends ReplicateSecretToRegionsResponse, __MetadataBearer {}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* <p>Converts an existing secret to a multi-Region secret and begins replication the secret to a
|
|
25
|
-
* list of new regions. </p>
|
|
26
|
-
* @example
|
|
27
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
28
|
-
* ```javascript
|
|
29
|
-
* import { SecretsManagerClient, ReplicateSecretToRegionsCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
|
|
30
|
-
* // const { SecretsManagerClient, ReplicateSecretToRegionsCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
|
|
31
|
-
* const client = new SecretsManagerClient(config);
|
|
32
|
-
* const command = new ReplicateSecretToRegionsCommand(input);
|
|
33
|
-
* const response = await client.send(command);
|
|
34
|
-
* ```
|
|
35
|
-
*
|
|
36
|
-
* @see {@link ReplicateSecretToRegionsCommandInput} for command's `input` shape.
|
|
37
|
-
* @see {@link ReplicateSecretToRegionsCommandOutput} for command's `response` shape.
|
|
38
|
-
* @see {@link SecretsManagerClientResolvedConfig | config} for command's `input` shape.
|
|
39
|
-
*
|
|
40
|
-
*/
|
|
41
|
-
export class ReplicateSecretToRegionsCommand extends $Command<
|
|
42
|
-
ReplicateSecretToRegionsCommandInput,
|
|
43
|
-
ReplicateSecretToRegionsCommandOutput,
|
|
44
|
-
SecretsManagerClientResolvedConfig
|
|
45
|
-
> {
|
|
46
|
-
// Start section: command_properties
|
|
47
|
-
// End section: command_properties
|
|
48
|
-
|
|
49
|
-
constructor(readonly input: ReplicateSecretToRegionsCommandInput) {
|
|
50
|
-
// Start section: command_constructor
|
|
51
|
-
super();
|
|
52
|
-
// End section: command_constructor
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
/**
|
|
56
|
-
* @internal
|
|
57
|
-
*/
|
|
58
|
-
resolveMiddleware(
|
|
59
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
60
|
-
configuration: SecretsManagerClientResolvedConfig,
|
|
61
|
-
options?: __HttpHandlerOptions
|
|
62
|
-
): Handler<ReplicateSecretToRegionsCommandInput, ReplicateSecretToRegionsCommandOutput> {
|
|
63
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
64
|
-
|
|
65
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
66
|
-
|
|
67
|
-
const { logger } = configuration;
|
|
68
|
-
const clientName = "SecretsManagerClient";
|
|
69
|
-
const commandName = "ReplicateSecretToRegionsCommand";
|
|
70
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
71
|
-
logger,
|
|
72
|
-
clientName,
|
|
73
|
-
commandName,
|
|
74
|
-
inputFilterSensitiveLog: ReplicateSecretToRegionsRequest.filterSensitiveLog,
|
|
75
|
-
outputFilterSensitiveLog: ReplicateSecretToRegionsResponse.filterSensitiveLog,
|
|
76
|
-
};
|
|
77
|
-
const { requestHandler } = configuration;
|
|
78
|
-
return stack.resolve(
|
|
79
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
80
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
81
|
-
handlerExecutionContext
|
|
82
|
-
);
|
|
83
|
-
}
|
|
84
|
-
|
|
85
|
-
private serialize(input: ReplicateSecretToRegionsCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
86
|
-
return serializeAws_json1_1ReplicateSecretToRegionsCommand(input, context);
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<ReplicateSecretToRegionsCommandOutput> {
|
|
90
|
-
return deserializeAws_json1_1ReplicateSecretToRegionsCommand(output, context);
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
// Start section: command_body_extra
|
|
94
|
-
// End section: command_body_extra
|
|
95
|
-
}
|
|
@@ -1,112 +0,0 @@
|
|
|
1
|
-
import { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
|
|
2
|
-
import { RestoreSecretRequest, RestoreSecretResponse } from "../models/models_0";
|
|
3
|
-
import {
|
|
4
|
-
deserializeAws_json1_1RestoreSecretCommand,
|
|
5
|
-
serializeAws_json1_1RestoreSecretCommand,
|
|
6
|
-
} from "../protocols/Aws_json1_1";
|
|
7
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
8
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
9
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
FinalizeHandlerArguments,
|
|
12
|
-
Handler,
|
|
13
|
-
HandlerExecutionContext,
|
|
14
|
-
MiddlewareStack,
|
|
15
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
16
|
-
MetadataBearer as __MetadataBearer,
|
|
17
|
-
SerdeContext as __SerdeContext,
|
|
18
|
-
} from "@aws-sdk/types";
|
|
19
|
-
|
|
20
|
-
export interface RestoreSecretCommandInput extends RestoreSecretRequest {}
|
|
21
|
-
export interface RestoreSecretCommandOutput extends RestoreSecretResponse, __MetadataBearer {}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* <p>Cancels the scheduled deletion of a secret by removing the <code>DeletedDate</code> time
|
|
25
|
-
* stamp. This makes the secret accessible to query once again.</p>
|
|
26
|
-
* <p>
|
|
27
|
-
* <b>Minimum permissions</b>
|
|
28
|
-
* </p>
|
|
29
|
-
* <p>To run this command, you must have the following permissions:</p>
|
|
30
|
-
* <ul>
|
|
31
|
-
* <li>
|
|
32
|
-
* <p>secretsmanager:RestoreSecret</p>
|
|
33
|
-
* </li>
|
|
34
|
-
* </ul>
|
|
35
|
-
* <p>
|
|
36
|
-
* <b>Related operations</b>
|
|
37
|
-
* </p>
|
|
38
|
-
* <ul>
|
|
39
|
-
* <li>
|
|
40
|
-
* <p>To delete a secret, use <a>DeleteSecret</a>.</p>
|
|
41
|
-
* </li>
|
|
42
|
-
* </ul>
|
|
43
|
-
* @example
|
|
44
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
45
|
-
* ```javascript
|
|
46
|
-
* import { SecretsManagerClient, RestoreSecretCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
|
|
47
|
-
* // const { SecretsManagerClient, RestoreSecretCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
|
|
48
|
-
* const client = new SecretsManagerClient(config);
|
|
49
|
-
* const command = new RestoreSecretCommand(input);
|
|
50
|
-
* const response = await client.send(command);
|
|
51
|
-
* ```
|
|
52
|
-
*
|
|
53
|
-
* @see {@link RestoreSecretCommandInput} for command's `input` shape.
|
|
54
|
-
* @see {@link RestoreSecretCommandOutput} for command's `response` shape.
|
|
55
|
-
* @see {@link SecretsManagerClientResolvedConfig | config} for command's `input` shape.
|
|
56
|
-
*
|
|
57
|
-
*/
|
|
58
|
-
export class RestoreSecretCommand extends $Command<
|
|
59
|
-
RestoreSecretCommandInput,
|
|
60
|
-
RestoreSecretCommandOutput,
|
|
61
|
-
SecretsManagerClientResolvedConfig
|
|
62
|
-
> {
|
|
63
|
-
// Start section: command_properties
|
|
64
|
-
// End section: command_properties
|
|
65
|
-
|
|
66
|
-
constructor(readonly input: RestoreSecretCommandInput) {
|
|
67
|
-
// Start section: command_constructor
|
|
68
|
-
super();
|
|
69
|
-
// End section: command_constructor
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
/**
|
|
73
|
-
* @internal
|
|
74
|
-
*/
|
|
75
|
-
resolveMiddleware(
|
|
76
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
77
|
-
configuration: SecretsManagerClientResolvedConfig,
|
|
78
|
-
options?: __HttpHandlerOptions
|
|
79
|
-
): Handler<RestoreSecretCommandInput, RestoreSecretCommandOutput> {
|
|
80
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
81
|
-
|
|
82
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
83
|
-
|
|
84
|
-
const { logger } = configuration;
|
|
85
|
-
const clientName = "SecretsManagerClient";
|
|
86
|
-
const commandName = "RestoreSecretCommand";
|
|
87
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
88
|
-
logger,
|
|
89
|
-
clientName,
|
|
90
|
-
commandName,
|
|
91
|
-
inputFilterSensitiveLog: RestoreSecretRequest.filterSensitiveLog,
|
|
92
|
-
outputFilterSensitiveLog: RestoreSecretResponse.filterSensitiveLog,
|
|
93
|
-
};
|
|
94
|
-
const { requestHandler } = configuration;
|
|
95
|
-
return stack.resolve(
|
|
96
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
97
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
98
|
-
handlerExecutionContext
|
|
99
|
-
);
|
|
100
|
-
}
|
|
101
|
-
|
|
102
|
-
private serialize(input: RestoreSecretCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
103
|
-
return serializeAws_json1_1RestoreSecretCommand(input, context);
|
|
104
|
-
}
|
|
105
|
-
|
|
106
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<RestoreSecretCommandOutput> {
|
|
107
|
-
return deserializeAws_json1_1RestoreSecretCommand(output, context);
|
|
108
|
-
}
|
|
109
|
-
|
|
110
|
-
// Start section: command_body_extra
|
|
111
|
-
// End section: command_body_extra
|
|
112
|
-
}
|
|
@@ -1,155 +0,0 @@
|
|
|
1
|
-
import { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
|
|
2
|
-
import { RotateSecretRequest, RotateSecretResponse } from "../models/models_0";
|
|
3
|
-
import {
|
|
4
|
-
deserializeAws_json1_1RotateSecretCommand,
|
|
5
|
-
serializeAws_json1_1RotateSecretCommand,
|
|
6
|
-
} from "../protocols/Aws_json1_1";
|
|
7
|
-
import { getSerdePlugin } from "@aws-sdk/middleware-serde";
|
|
8
|
-
import { HttpRequest as __HttpRequest, HttpResponse as __HttpResponse } from "@aws-sdk/protocol-http";
|
|
9
|
-
import { Command as $Command } from "@aws-sdk/smithy-client";
|
|
10
|
-
import {
|
|
11
|
-
FinalizeHandlerArguments,
|
|
12
|
-
Handler,
|
|
13
|
-
HandlerExecutionContext,
|
|
14
|
-
MiddlewareStack,
|
|
15
|
-
HttpHandlerOptions as __HttpHandlerOptions,
|
|
16
|
-
MetadataBearer as __MetadataBearer,
|
|
17
|
-
SerdeContext as __SerdeContext,
|
|
18
|
-
} from "@aws-sdk/types";
|
|
19
|
-
|
|
20
|
-
export interface RotateSecretCommandInput extends RotateSecretRequest {}
|
|
21
|
-
export interface RotateSecretCommandOutput extends RotateSecretResponse, __MetadataBearer {}
|
|
22
|
-
|
|
23
|
-
/**
|
|
24
|
-
* <p>Configures and starts the asynchronous process of rotating this secret. If you include the
|
|
25
|
-
* configuration parameters, the operation sets those values for the secret and then immediately
|
|
26
|
-
* starts a rotation. If you do not include the configuration parameters, the operation starts a
|
|
27
|
-
* rotation with the values already stored in the secret. After the rotation completes, the
|
|
28
|
-
* protected service and its clients all use the new version of the secret. </p>
|
|
29
|
-
* <p>This required configuration information includes the ARN of an Amazon Web Services Lambda function and
|
|
30
|
-
* optionally, the time between scheduled rotations. The Lambda rotation function creates a new
|
|
31
|
-
* version of the secret and creates or updates the credentials on the protected service to
|
|
32
|
-
* match. After testing the new credentials, the function marks the new secret with the staging
|
|
33
|
-
* label <code>AWSCURRENT</code> so that your clients all immediately begin to use the new version. For more
|
|
34
|
-
* information about rotating secrets and how to configure a Lambda function to rotate the
|
|
35
|
-
* secrets for your protected service, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/rotating-secrets.html">Rotating Secrets in Amazon Web Services Secrets Manager</a> in the
|
|
36
|
-
* <i>Amazon Web Services Secrets Manager User Guide</i>.</p>
|
|
37
|
-
* <p>Secrets Manager schedules the next rotation when the previous
|
|
38
|
-
* one completes. Secrets Manager schedules the date by adding the rotation interval (number of days) to the
|
|
39
|
-
* actual date of the last rotation. The service chooses the hour within that 24-hour date window
|
|
40
|
-
* randomly. The minute is also chosen somewhat randomly, but weighted towards the top of the hour
|
|
41
|
-
* and influenced by a variety of factors that help distribute load.</p>
|
|
42
|
-
* <p>The
|
|
43
|
-
* rotation function must end with the versions of the secret in one of two states:</p>
|
|
44
|
-
* <ul>
|
|
45
|
-
* <li>
|
|
46
|
-
* <p>The <code>AWSPENDING</code> and <code>AWSCURRENT</code> staging labels are attached to the same version of
|
|
47
|
-
* the secret, or</p>
|
|
48
|
-
* </li>
|
|
49
|
-
* <li>
|
|
50
|
-
* <p>The <code>AWSPENDING</code> staging label is not attached to any version of the secret.</p>
|
|
51
|
-
* </li>
|
|
52
|
-
* </ul>
|
|
53
|
-
* <p>If the <code>AWSPENDING</code> staging label is present but not attached to the same version as
|
|
54
|
-
* <code>AWSCURRENT</code> then any later invocation of <code>RotateSecret</code> assumes that a previous
|
|
55
|
-
* rotation request is still in progress and returns an error.</p>
|
|
56
|
-
* <p>
|
|
57
|
-
* <b>Minimum permissions</b>
|
|
58
|
-
* </p>
|
|
59
|
-
* <p>To run this command, you must have the following permissions:</p>
|
|
60
|
-
* <ul>
|
|
61
|
-
* <li>
|
|
62
|
-
* <p>secretsmanager:RotateSecret</p>
|
|
63
|
-
* </li>
|
|
64
|
-
* <li>
|
|
65
|
-
* <p>lambda:InvokeFunction (on the function specified in the secret's metadata)</p>
|
|
66
|
-
* </li>
|
|
67
|
-
* </ul>
|
|
68
|
-
* <p>
|
|
69
|
-
* <b>Related operations</b>
|
|
70
|
-
* </p>
|
|
71
|
-
* <ul>
|
|
72
|
-
* <li>
|
|
73
|
-
* <p>To list the secrets in your account, use <a>ListSecrets</a>.</p>
|
|
74
|
-
* </li>
|
|
75
|
-
* <li>
|
|
76
|
-
* <p>To get the details for a version of a secret, use <a>DescribeSecret</a>.</p>
|
|
77
|
-
* </li>
|
|
78
|
-
* <li>
|
|
79
|
-
* <p>To create a new version of a secret, use <a>CreateSecret</a>.</p>
|
|
80
|
-
* </li>
|
|
81
|
-
* <li>
|
|
82
|
-
* <p>To attach staging labels to or remove staging labels from a version of a secret, use
|
|
83
|
-
* <a>UpdateSecretVersionStage</a>.</p>
|
|
84
|
-
* </li>
|
|
85
|
-
* </ul>
|
|
86
|
-
* @example
|
|
87
|
-
* Use a bare-bones client and the command you need to make an API call.
|
|
88
|
-
* ```javascript
|
|
89
|
-
* import { SecretsManagerClient, RotateSecretCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
|
|
90
|
-
* // const { SecretsManagerClient, RotateSecretCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
|
|
91
|
-
* const client = new SecretsManagerClient(config);
|
|
92
|
-
* const command = new RotateSecretCommand(input);
|
|
93
|
-
* const response = await client.send(command);
|
|
94
|
-
* ```
|
|
95
|
-
*
|
|
96
|
-
* @see {@link RotateSecretCommandInput} for command's `input` shape.
|
|
97
|
-
* @see {@link RotateSecretCommandOutput} for command's `response` shape.
|
|
98
|
-
* @see {@link SecretsManagerClientResolvedConfig | config} for command's `input` shape.
|
|
99
|
-
*
|
|
100
|
-
*/
|
|
101
|
-
export class RotateSecretCommand extends $Command<
|
|
102
|
-
RotateSecretCommandInput,
|
|
103
|
-
RotateSecretCommandOutput,
|
|
104
|
-
SecretsManagerClientResolvedConfig
|
|
105
|
-
> {
|
|
106
|
-
// Start section: command_properties
|
|
107
|
-
// End section: command_properties
|
|
108
|
-
|
|
109
|
-
constructor(readonly input: RotateSecretCommandInput) {
|
|
110
|
-
// Start section: command_constructor
|
|
111
|
-
super();
|
|
112
|
-
// End section: command_constructor
|
|
113
|
-
}
|
|
114
|
-
|
|
115
|
-
/**
|
|
116
|
-
* @internal
|
|
117
|
-
*/
|
|
118
|
-
resolveMiddleware(
|
|
119
|
-
clientStack: MiddlewareStack<ServiceInputTypes, ServiceOutputTypes>,
|
|
120
|
-
configuration: SecretsManagerClientResolvedConfig,
|
|
121
|
-
options?: __HttpHandlerOptions
|
|
122
|
-
): Handler<RotateSecretCommandInput, RotateSecretCommandOutput> {
|
|
123
|
-
this.middlewareStack.use(getSerdePlugin(configuration, this.serialize, this.deserialize));
|
|
124
|
-
|
|
125
|
-
const stack = clientStack.concat(this.middlewareStack);
|
|
126
|
-
|
|
127
|
-
const { logger } = configuration;
|
|
128
|
-
const clientName = "SecretsManagerClient";
|
|
129
|
-
const commandName = "RotateSecretCommand";
|
|
130
|
-
const handlerExecutionContext: HandlerExecutionContext = {
|
|
131
|
-
logger,
|
|
132
|
-
clientName,
|
|
133
|
-
commandName,
|
|
134
|
-
inputFilterSensitiveLog: RotateSecretRequest.filterSensitiveLog,
|
|
135
|
-
outputFilterSensitiveLog: RotateSecretResponse.filterSensitiveLog,
|
|
136
|
-
};
|
|
137
|
-
const { requestHandler } = configuration;
|
|
138
|
-
return stack.resolve(
|
|
139
|
-
(request: FinalizeHandlerArguments<any>) =>
|
|
140
|
-
requestHandler.handle(request.request as __HttpRequest, options || {}),
|
|
141
|
-
handlerExecutionContext
|
|
142
|
-
);
|
|
143
|
-
}
|
|
144
|
-
|
|
145
|
-
private serialize(input: RotateSecretCommandInput, context: __SerdeContext): Promise<__HttpRequest> {
|
|
146
|
-
return serializeAws_json1_1RotateSecretCommand(input, context);
|
|
147
|
-
}
|
|
148
|
-
|
|
149
|
-
private deserialize(output: __HttpResponse, context: __SerdeContext): Promise<RotateSecretCommandOutput> {
|
|
150
|
-
return deserializeAws_json1_1RotateSecretCommand(output, context);
|
|
151
|
-
}
|
|
152
|
-
|
|
153
|
-
// Start section: command_body_extra
|
|
154
|
-
// End section: command_body_extra
|
|
155
|
-
}
|