@depup/aws-sdk__client-secrets-manager 3.1010.0-depup.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 (159) hide show
  1. package/LICENSE +201 -0
  2. package/README.md +39 -0
  3. package/changes.json +42 -0
  4. package/dist-cjs/auth/httpAuthSchemeProvider.js +46 -0
  5. package/dist-cjs/endpoint/endpointResolver.js +18 -0
  6. package/dist-cjs/endpoint/ruleset.js +7 -0
  7. package/dist-cjs/index.js +511 -0
  8. package/dist-cjs/models/SecretsManagerServiceException.js +12 -0
  9. package/dist-cjs/models/errors.js +184 -0
  10. package/dist-cjs/runtimeConfig.browser.js +38 -0
  11. package/dist-cjs/runtimeConfig.js +53 -0
  12. package/dist-cjs/runtimeConfig.native.js +15 -0
  13. package/dist-cjs/runtimeConfig.shared.js +43 -0
  14. package/dist-cjs/schemas/schemas_0.js +665 -0
  15. package/dist-es/SecretsManager.js +61 -0
  16. package/dist-es/SecretsManagerClient.js +50 -0
  17. package/dist-es/auth/httpAuthExtensionConfiguration.js +38 -0
  18. package/dist-es/auth/httpAuthSchemeProvider.js +40 -0
  19. package/dist-es/commands/BatchGetSecretValueCommand.js +16 -0
  20. package/dist-es/commands/CancelRotateSecretCommand.js +16 -0
  21. package/dist-es/commands/CreateSecretCommand.js +16 -0
  22. package/dist-es/commands/DeleteResourcePolicyCommand.js +16 -0
  23. package/dist-es/commands/DeleteSecretCommand.js +16 -0
  24. package/dist-es/commands/DescribeSecretCommand.js +16 -0
  25. package/dist-es/commands/GetRandomPasswordCommand.js +16 -0
  26. package/dist-es/commands/GetResourcePolicyCommand.js +16 -0
  27. package/dist-es/commands/GetSecretValueCommand.js +16 -0
  28. package/dist-es/commands/ListSecretVersionIdsCommand.js +16 -0
  29. package/dist-es/commands/ListSecretsCommand.js +16 -0
  30. package/dist-es/commands/PutResourcePolicyCommand.js +16 -0
  31. package/dist-es/commands/PutSecretValueCommand.js +16 -0
  32. package/dist-es/commands/RemoveRegionsFromReplicationCommand.js +16 -0
  33. package/dist-es/commands/ReplicateSecretToRegionsCommand.js +16 -0
  34. package/dist-es/commands/RestoreSecretCommand.js +16 -0
  35. package/dist-es/commands/RotateSecretCommand.js +16 -0
  36. package/dist-es/commands/StopReplicationToReplicaCommand.js +16 -0
  37. package/dist-es/commands/TagResourceCommand.js +16 -0
  38. package/dist-es/commands/UntagResourceCommand.js +16 -0
  39. package/dist-es/commands/UpdateSecretCommand.js +16 -0
  40. package/dist-es/commands/UpdateSecretVersionStageCommand.js +16 -0
  41. package/dist-es/commands/ValidateResourcePolicyCommand.js +16 -0
  42. package/dist-es/commands/index.js +23 -0
  43. package/dist-es/endpoint/EndpointParameters.js +13 -0
  44. package/dist-es/endpoint/endpointResolver.js +14 -0
  45. package/dist-es/endpoint/ruleset.js +4 -0
  46. package/dist-es/extensionConfiguration.js +1 -0
  47. package/dist-es/index.js +9 -0
  48. package/dist-es/models/SecretsManagerServiceException.js +8 -0
  49. package/dist-es/models/enums.js +24 -0
  50. package/dist-es/models/errors.js +169 -0
  51. package/dist-es/models/models_0.js +1 -0
  52. package/dist-es/pagination/BatchGetSecretValuePaginator.js +4 -0
  53. package/dist-es/pagination/Interfaces.js +1 -0
  54. package/dist-es/pagination/ListSecretVersionIdsPaginator.js +4 -0
  55. package/dist-es/pagination/ListSecretsPaginator.js +4 -0
  56. package/dist-es/pagination/index.js +4 -0
  57. package/dist-es/runtimeConfig.browser.js +33 -0
  58. package/dist-es/runtimeConfig.js +48 -0
  59. package/dist-es/runtimeConfig.native.js +11 -0
  60. package/dist-es/runtimeConfig.shared.js +39 -0
  61. package/dist-es/runtimeExtensions.js +9 -0
  62. package/dist-es/schemas/schemas_0.js +661 -0
  63. package/dist-types/SecretsManager.d.ts +220 -0
  64. package/dist-types/SecretsManagerClient.d.ts +235 -0
  65. package/dist-types/auth/httpAuthExtensionConfiguration.d.ts +29 -0
  66. package/dist-types/auth/httpAuthSchemeProvider.d.ts +75 -0
  67. package/dist-types/commands/BatchGetSecretValueCommand.d.ts +210 -0
  68. package/dist-types/commands/CancelRotateSecretCommand.d.ts +135 -0
  69. package/dist-types/commands/CreateSecretCommand.d.ts +218 -0
  70. package/dist-types/commands/DeleteResourcePolicyCommand.d.ts +126 -0
  71. package/dist-types/commands/DeleteSecretCommand.d.ts +135 -0
  72. package/dist-types/commands/DescribeSecretCommand.d.ts +137 -0
  73. package/dist-types/commands/GetRandomPasswordCommand.d.ts +135 -0
  74. package/dist-types/commands/GetResourcePolicyCommand.d.ts +138 -0
  75. package/dist-types/commands/GetSecretValueCommand.d.ts +157 -0
  76. package/dist-types/commands/ListSecretVersionIdsCommand.d.ts +151 -0
  77. package/dist-types/commands/ListSecretsCommand.d.ts +208 -0
  78. package/dist-types/commands/PutResourcePolicyCommand.d.ts +147 -0
  79. package/dist-types/commands/PutSecretValueCommand.d.ts +183 -0
  80. package/dist-types/commands/RemoveRegionsFromReplicationCommand.d.ts +122 -0
  81. package/dist-types/commands/ReplicateSecretToRegionsCommand.d.ts +157 -0
  82. package/dist-types/commands/RestoreSecretCommand.d.ts +126 -0
  83. package/dist-types/commands/RotateSecretCommand.d.ts +180 -0
  84. package/dist-types/commands/StopReplicationToReplicaCommand.d.ts +111 -0
  85. package/dist-types/commands/TagResourceCommand.d.ts +145 -0
  86. package/dist-types/commands/UntagResourceCommand.d.ts +134 -0
  87. package/dist-types/commands/UpdateSecretCommand.d.ts +221 -0
  88. package/dist-types/commands/UpdateSecretVersionStageCommand.d.ts +187 -0
  89. package/dist-types/commands/ValidateResourcePolicyCommand.d.ts +161 -0
  90. package/dist-types/commands/index.d.ts +23 -0
  91. package/dist-types/endpoint/EndpointParameters.d.ts +50 -0
  92. package/dist-types/endpoint/endpointResolver.d.ts +8 -0
  93. package/dist-types/endpoint/ruleset.d.ts +2 -0
  94. package/dist-types/extensionConfiguration.d.ts +9 -0
  95. package/dist-types/index.d.ts +42 -0
  96. package/dist-types/models/SecretsManagerServiceException.d.ts +14 -0
  97. package/dist-types/models/enums.d.ts +56 -0
  98. package/dist-types/models/errors.d.ts +175 -0
  99. package/dist-types/models/models_0.d.ts +1957 -0
  100. package/dist-types/pagination/BatchGetSecretValuePaginator.d.ts +7 -0
  101. package/dist-types/pagination/Interfaces.d.ts +8 -0
  102. package/dist-types/pagination/ListSecretVersionIdsPaginator.d.ts +7 -0
  103. package/dist-types/pagination/ListSecretsPaginator.d.ts +7 -0
  104. package/dist-types/pagination/index.d.ts +4 -0
  105. package/dist-types/runtimeConfig.browser.d.ts +55 -0
  106. package/dist-types/runtimeConfig.d.ts +55 -0
  107. package/dist-types/runtimeConfig.native.d.ts +54 -0
  108. package/dist-types/runtimeConfig.shared.d.ts +27 -0
  109. package/dist-types/runtimeExtensions.d.ts +17 -0
  110. package/dist-types/schemas/schemas_0.d.ts +99 -0
  111. package/dist-types/ts3.4/SecretsManager.d.ts +426 -0
  112. package/dist-types/ts3.4/SecretsManagerClient.d.ts +258 -0
  113. package/dist-types/ts3.4/auth/httpAuthExtensionConfiguration.d.ts +32 -0
  114. package/dist-types/ts3.4/auth/httpAuthSchemeProvider.d.ts +47 -0
  115. package/dist-types/ts3.4/commands/BatchGetSecretValueCommand.d.ts +51 -0
  116. package/dist-types/ts3.4/commands/CancelRotateSecretCommand.d.ts +51 -0
  117. package/dist-types/ts3.4/commands/CreateSecretCommand.d.ts +47 -0
  118. package/dist-types/ts3.4/commands/DeleteResourcePolicyCommand.d.ts +51 -0
  119. package/dist-types/ts3.4/commands/DeleteSecretCommand.d.ts +47 -0
  120. package/dist-types/ts3.4/commands/DescribeSecretCommand.d.ts +50 -0
  121. package/dist-types/ts3.4/commands/GetRandomPasswordCommand.d.ts +51 -0
  122. package/dist-types/ts3.4/commands/GetResourcePolicyCommand.d.ts +51 -0
  123. package/dist-types/ts3.4/commands/GetSecretValueCommand.d.ts +50 -0
  124. package/dist-types/ts3.4/commands/ListSecretVersionIdsCommand.d.ts +51 -0
  125. package/dist-types/ts3.4/commands/ListSecretsCommand.d.ts +47 -0
  126. package/dist-types/ts3.4/commands/PutResourcePolicyCommand.d.ts +51 -0
  127. package/dist-types/ts3.4/commands/PutSecretValueCommand.d.ts +50 -0
  128. package/dist-types/ts3.4/commands/RemoveRegionsFromReplicationCommand.d.ts +51 -0
  129. package/dist-types/ts3.4/commands/ReplicateSecretToRegionsCommand.d.ts +51 -0
  130. package/dist-types/ts3.4/commands/RestoreSecretCommand.d.ts +50 -0
  131. package/dist-types/ts3.4/commands/RotateSecretCommand.d.ts +47 -0
  132. package/dist-types/ts3.4/commands/StopReplicationToReplicaCommand.d.ts +51 -0
  133. package/dist-types/ts3.4/commands/TagResourceCommand.d.ts +45 -0
  134. package/dist-types/ts3.4/commands/UntagResourceCommand.d.ts +45 -0
  135. package/dist-types/ts3.4/commands/UpdateSecretCommand.d.ts +47 -0
  136. package/dist-types/ts3.4/commands/UpdateSecretVersionStageCommand.d.ts +51 -0
  137. package/dist-types/ts3.4/commands/ValidateResourcePolicyCommand.d.ts +51 -0
  138. package/dist-types/ts3.4/commands/index.d.ts +23 -0
  139. package/dist-types/ts3.4/endpoint/EndpointParameters.d.ts +51 -0
  140. package/dist-types/ts3.4/endpoint/endpointResolver.d.ts +8 -0
  141. package/dist-types/ts3.4/endpoint/ruleset.d.ts +2 -0
  142. package/dist-types/ts3.4/extensionConfiguration.d.ts +9 -0
  143. package/dist-types/ts3.4/index.d.ts +12 -0
  144. package/dist-types/ts3.4/models/SecretsManagerServiceException.d.ts +9 -0
  145. package/dist-types/ts3.4/models/enums.d.ts +29 -0
  146. package/dist-types/ts3.4/models/errors.d.ts +97 -0
  147. package/dist-types/ts3.4/models/models_0.d.ts +333 -0
  148. package/dist-types/ts3.4/pagination/BatchGetSecretValuePaginator.d.ts +11 -0
  149. package/dist-types/ts3.4/pagination/Interfaces.d.ts +6 -0
  150. package/dist-types/ts3.4/pagination/ListSecretVersionIdsPaginator.d.ts +11 -0
  151. package/dist-types/ts3.4/pagination/ListSecretsPaginator.d.ts +11 -0
  152. package/dist-types/ts3.4/pagination/index.d.ts +4 -0
  153. package/dist-types/ts3.4/runtimeConfig.browser.d.ts +100 -0
  154. package/dist-types/ts3.4/runtimeConfig.d.ts +95 -0
  155. package/dist-types/ts3.4/runtimeConfig.native.d.ts +104 -0
  156. package/dist-types/ts3.4/runtimeConfig.shared.d.ts +30 -0
  157. package/dist-types/ts3.4/runtimeExtensions.d.ts +11 -0
  158. package/dist-types/ts3.4/schemas/schemas_0.d.ts +98 -0
  159. package/package.json +159 -0
@@ -0,0 +1,126 @@
1
+ import { Command as $Command } from "@smithy/smithy-client";
2
+ import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
3
+ import type { DeleteResourcePolicyRequest, DeleteResourcePolicyResponse } from "../models/models_0";
4
+ import type { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link DeleteResourcePolicyCommand}.
14
+ */
15
+ export interface DeleteResourcePolicyCommandInput extends DeleteResourcePolicyRequest {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link DeleteResourcePolicyCommand}.
21
+ */
22
+ export interface DeleteResourcePolicyCommandOutput extends DeleteResourcePolicyResponse, __MetadataBearer {
23
+ }
24
+ declare const DeleteResourcePolicyCommand_base: {
25
+ new (input: DeleteResourcePolicyCommandInput): import("@smithy/smithy-client").CommandImpl<DeleteResourcePolicyCommandInput, DeleteResourcePolicyCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (input: DeleteResourcePolicyCommandInput): import("@smithy/smithy-client").CommandImpl<DeleteResourcePolicyCommandInput, DeleteResourcePolicyCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * <p>Deletes the resource-based permission policy attached to the secret. To attach a
31
+ * policy to a secret, use <a>PutResourcePolicy</a>.</p>
32
+ * <p>Secrets Manager generates a CloudTrail log entry when you call this action. Do not include sensitive information in request parameters because it might be logged. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/retrieve-ct-entries.html">Logging Secrets Manager events with CloudTrail</a>.</p>
33
+ * <p>
34
+ * <b>Required permissions:
35
+ * </b>
36
+ * <code>secretsmanager:DeleteResourcePolicy</code>. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/reference_iam-permissions.html#reference_iam-permissions_actions">
37
+ * IAM policy actions for Secrets Manager</a> and <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/auth-and-access.html">Authentication
38
+ * and access control in Secrets Manager</a>. </p>
39
+ * @example
40
+ * Use a bare-bones client and the command you need to make an API call.
41
+ * ```javascript
42
+ * import { SecretsManagerClient, DeleteResourcePolicyCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
43
+ * // const { SecretsManagerClient, DeleteResourcePolicyCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
44
+ * // import type { SecretsManagerClientConfig } from "@aws-sdk/client-secrets-manager";
45
+ * const config = {}; // type is SecretsManagerClientConfig
46
+ * const client = new SecretsManagerClient(config);
47
+ * const input = { // DeleteResourcePolicyRequest
48
+ * SecretId: "STRING_VALUE", // required
49
+ * };
50
+ * const command = new DeleteResourcePolicyCommand(input);
51
+ * const response = await client.send(command);
52
+ * // { // DeleteResourcePolicyResponse
53
+ * // ARN: "STRING_VALUE",
54
+ * // Name: "STRING_VALUE",
55
+ * // };
56
+ *
57
+ * ```
58
+ *
59
+ * @param DeleteResourcePolicyCommandInput - {@link DeleteResourcePolicyCommandInput}
60
+ * @returns {@link DeleteResourcePolicyCommandOutput}
61
+ * @see {@link DeleteResourcePolicyCommandInput} for command's `input` shape.
62
+ * @see {@link DeleteResourcePolicyCommandOutput} for command's `response` shape.
63
+ * @see {@link SecretsManagerClientResolvedConfig | config} for SecretsManagerClient's `config` shape.
64
+ *
65
+ * @throws {@link InternalServiceError} (server fault)
66
+ * <p>An error occurred on the server side.</p>
67
+ *
68
+ * @throws {@link InvalidParameterException} (client fault)
69
+ * <p>The parameter name or value is invalid.</p>
70
+ *
71
+ * @throws {@link InvalidRequestException} (client fault)
72
+ * <p>A parameter value is not valid for the current state of the
73
+ * resource.</p>
74
+ * <p>Possible causes:</p>
75
+ * <ul>
76
+ * <li>
77
+ * <p>The secret is scheduled for deletion.</p>
78
+ * </li>
79
+ * <li>
80
+ * <p>You tried to enable rotation on a secret that doesn't already have a Lambda function
81
+ * ARN configured and you didn't include such an ARN as a parameter in this call. </p>
82
+ * </li>
83
+ * <li>
84
+ * <p>The secret is managed by another service, and you must use that service to update it.
85
+ * For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/service-linked-secrets.html">Secrets managed by other Amazon Web Services services</a>.</p>
86
+ * </li>
87
+ * </ul>
88
+ *
89
+ * @throws {@link ResourceNotFoundException} (client fault)
90
+ * <p>Secrets Manager can't find the resource that you asked for.</p>
91
+ *
92
+ * @throws {@link SecretsManagerServiceException}
93
+ * <p>Base exception class for all service exceptions from SecretsManager service.</p>
94
+ *
95
+ *
96
+ * @example To delete the resource-based policy attached to a secret
97
+ * ```javascript
98
+ * // The following example shows how to delete the resource-based policy that is attached to a secret.
99
+ * const input = {
100
+ * SecretId: "MyTestDatabaseSecret"
101
+ * };
102
+ * const command = new DeleteResourcePolicyCommand(input);
103
+ * const response = await client.send(command);
104
+ * /* response is
105
+ * {
106
+ * ARN: "arn:aws:secretsmanager:us-west-2:123456789012:secret:MyTestDatabaseSecret-a1b2c3",
107
+ * Name: "MyTestDatabaseSecret"
108
+ * }
109
+ * *\/
110
+ * ```
111
+ *
112
+ * @public
113
+ */
114
+ export declare class DeleteResourcePolicyCommand extends DeleteResourcePolicyCommand_base {
115
+ /** @internal type navigation helper, not in runtime. */
116
+ protected static __types: {
117
+ api: {
118
+ input: DeleteResourcePolicyRequest;
119
+ output: DeleteResourcePolicyResponse;
120
+ };
121
+ sdk: {
122
+ input: DeleteResourcePolicyCommandInput;
123
+ output: DeleteResourcePolicyCommandOutput;
124
+ };
125
+ };
126
+ }
@@ -0,0 +1,135 @@
1
+ import { Command as $Command } from "@smithy/smithy-client";
2
+ import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
3
+ import type { DeleteSecretRequest, DeleteSecretResponse } from "../models/models_0";
4
+ import type { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link DeleteSecretCommand}.
14
+ */
15
+ export interface DeleteSecretCommandInput extends DeleteSecretRequest {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link DeleteSecretCommand}.
21
+ */
22
+ export interface DeleteSecretCommandOutput extends DeleteSecretResponse, __MetadataBearer {
23
+ }
24
+ declare const DeleteSecretCommand_base: {
25
+ new (input: DeleteSecretCommandInput): import("@smithy/smithy-client").CommandImpl<DeleteSecretCommandInput, DeleteSecretCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (input: DeleteSecretCommandInput): import("@smithy/smithy-client").CommandImpl<DeleteSecretCommandInput, DeleteSecretCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * <p>Deletes a secret and all of its versions. You can specify a recovery window during
31
+ * which you can restore the secret. The minimum recovery window is 7 days. The default
32
+ * recovery window is 30 days. Secrets Manager attaches a <code>DeletionDate</code> stamp to the
33
+ * secret that specifies the end of the recovery window. At the end of the recovery window,
34
+ * Secrets Manager deletes the secret permanently.</p>
35
+ * <p>You can't delete a primary secret that is replicated to other Regions. You must first
36
+ * delete the replicas using <a>RemoveRegionsFromReplication</a>, and then
37
+ * delete the primary secret. When you delete a replica, it is deleted immediately.</p>
38
+ * <p>You can't directly delete a version of a secret. Instead, you remove all staging
39
+ * labels from the version using <a>UpdateSecretVersionStage</a>. This marks the
40
+ * version as deprecated, and then Secrets Manager can automatically delete the version in the
41
+ * background.</p>
42
+ * <p>To determine whether an application still uses a secret, you can create an Amazon CloudWatch alarm
43
+ * to alert you to any attempts to access a secret during the recovery window. For more
44
+ * information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/monitoring_cloudwatch_deleted-secrets.html">
45
+ * Monitor secrets scheduled for deletion</a>.</p>
46
+ * <p>Secrets Manager performs the permanent secret deletion at the end of the waiting period as a
47
+ * background task with low priority. There is no guarantee of a specific time after the
48
+ * recovery window for the permanent delete to occur.</p>
49
+ * <p>At any time before recovery window ends, you can use <a>RestoreSecret</a>
50
+ * to remove the <code>DeletionDate</code> and cancel the deletion of the secret.</p>
51
+ * <p>When a secret is scheduled for deletion, you cannot retrieve the secret value. You
52
+ * must first cancel the deletion with <a>RestoreSecret</a> and then you can
53
+ * retrieve the secret.</p>
54
+ * <p>Secrets Manager generates a CloudTrail log entry when you call this action. Do not include sensitive information in request parameters because it might be logged. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/retrieve-ct-entries.html">Logging Secrets Manager events with CloudTrail</a>.</p>
55
+ * <p>
56
+ * <b>Required permissions:
57
+ * </b>
58
+ * <code>secretsmanager:DeleteSecret</code>. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/reference_iam-permissions.html#reference_iam-permissions_actions">
59
+ * IAM policy actions for Secrets Manager</a> and <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/auth-and-access.html">Authentication
60
+ * and access control in Secrets Manager</a>. </p>
61
+ * @example
62
+ * Use a bare-bones client and the command you need to make an API call.
63
+ * ```javascript
64
+ * import { SecretsManagerClient, DeleteSecretCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
65
+ * // const { SecretsManagerClient, DeleteSecretCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
66
+ * // import type { SecretsManagerClientConfig } from "@aws-sdk/client-secrets-manager";
67
+ * const config = {}; // type is SecretsManagerClientConfig
68
+ * const client = new SecretsManagerClient(config);
69
+ * const input = { // DeleteSecretRequest
70
+ * SecretId: "STRING_VALUE", // required
71
+ * RecoveryWindowInDays: Number("long"),
72
+ * ForceDeleteWithoutRecovery: true || false,
73
+ * };
74
+ * const command = new DeleteSecretCommand(input);
75
+ * const response = await client.send(command);
76
+ * // { // DeleteSecretResponse
77
+ * // ARN: "STRING_VALUE",
78
+ * // Name: "STRING_VALUE",
79
+ * // DeletionDate: new Date("TIMESTAMP"),
80
+ * // };
81
+ *
82
+ * ```
83
+ *
84
+ * @param DeleteSecretCommandInput - {@link DeleteSecretCommandInput}
85
+ * @returns {@link DeleteSecretCommandOutput}
86
+ * @see {@link DeleteSecretCommandInput} for command's `input` shape.
87
+ * @see {@link DeleteSecretCommandOutput} for command's `response` shape.
88
+ * @see {@link SecretsManagerClientResolvedConfig | config} for SecretsManagerClient's `config` shape.
89
+ *
90
+ * @throws {@link InternalServiceError} (server fault)
91
+ * <p>An error occurred on the server side.</p>
92
+ *
93
+ * @throws {@link InvalidParameterException} (client fault)
94
+ * <p>The parameter name or value is invalid.</p>
95
+ *
96
+ * @throws {@link InvalidRequestException} (client fault)
97
+ * <p>A parameter value is not valid for the current state of the
98
+ * resource.</p>
99
+ * <p>Possible causes:</p>
100
+ * <ul>
101
+ * <li>
102
+ * <p>The secret is scheduled for deletion.</p>
103
+ * </li>
104
+ * <li>
105
+ * <p>You tried to enable rotation on a secret that doesn't already have a Lambda function
106
+ * ARN configured and you didn't include such an ARN as a parameter in this call. </p>
107
+ * </li>
108
+ * <li>
109
+ * <p>The secret is managed by another service, and you must use that service to update it.
110
+ * For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/service-linked-secrets.html">Secrets managed by other Amazon Web Services services</a>.</p>
111
+ * </li>
112
+ * </ul>
113
+ *
114
+ * @throws {@link ResourceNotFoundException} (client fault)
115
+ * <p>Secrets Manager can't find the resource that you asked for.</p>
116
+ *
117
+ * @throws {@link SecretsManagerServiceException}
118
+ * <p>Base exception class for all service exceptions from SecretsManager service.</p>
119
+ *
120
+ *
121
+ * @public
122
+ */
123
+ export declare class DeleteSecretCommand extends DeleteSecretCommand_base {
124
+ /** @internal type navigation helper, not in runtime. */
125
+ protected static __types: {
126
+ api: {
127
+ input: DeleteSecretRequest;
128
+ output: DeleteSecretResponse;
129
+ };
130
+ sdk: {
131
+ input: DeleteSecretCommandInput;
132
+ output: DeleteSecretCommandOutput;
133
+ };
134
+ };
135
+ }
@@ -0,0 +1,137 @@
1
+ import { Command as $Command } from "@smithy/smithy-client";
2
+ import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
3
+ import type { DescribeSecretRequest, DescribeSecretResponse } from "../models/models_0";
4
+ import type { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link DescribeSecretCommand}.
14
+ */
15
+ export interface DescribeSecretCommandInput extends DescribeSecretRequest {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link DescribeSecretCommand}.
21
+ */
22
+ export interface DescribeSecretCommandOutput extends DescribeSecretResponse, __MetadataBearer {
23
+ }
24
+ declare const DescribeSecretCommand_base: {
25
+ new (input: DescribeSecretCommandInput): import("@smithy/smithy-client").CommandImpl<DescribeSecretCommandInput, DescribeSecretCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (input: DescribeSecretCommandInput): import("@smithy/smithy-client").CommandImpl<DescribeSecretCommandInput, DescribeSecretCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * <p>Retrieves the details of a secret. It does not include the encrypted secret value.
31
+ * Secrets Manager only returns fields that have a value in the response. </p>
32
+ * <p>Secrets Manager generates a CloudTrail log entry when you call this action. Do not include sensitive information in request parameters because it might be logged. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/retrieve-ct-entries.html">Logging Secrets Manager events with CloudTrail</a>.</p>
33
+ * <p>
34
+ * <b>Required permissions:
35
+ * </b>
36
+ * <code>secretsmanager:DescribeSecret</code>. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/reference_iam-permissions.html#reference_iam-permissions_actions">
37
+ * IAM policy actions for Secrets Manager</a> and <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/auth-and-access.html">Authentication
38
+ * and access control in Secrets Manager</a>. </p>
39
+ * @example
40
+ * Use a bare-bones client and the command you need to make an API call.
41
+ * ```javascript
42
+ * import { SecretsManagerClient, DescribeSecretCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
43
+ * // const { SecretsManagerClient, DescribeSecretCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
44
+ * // import type { SecretsManagerClientConfig } from "@aws-sdk/client-secrets-manager";
45
+ * const config = {}; // type is SecretsManagerClientConfig
46
+ * const client = new SecretsManagerClient(config);
47
+ * const input = { // DescribeSecretRequest
48
+ * SecretId: "STRING_VALUE", // required
49
+ * };
50
+ * const command = new DescribeSecretCommand(input);
51
+ * const response = await client.send(command);
52
+ * // { // DescribeSecretResponse
53
+ * // ARN: "STRING_VALUE",
54
+ * // Name: "STRING_VALUE",
55
+ * // Type: "STRING_VALUE",
56
+ * // Description: "STRING_VALUE",
57
+ * // KmsKeyId: "STRING_VALUE",
58
+ * // RotationEnabled: true || false,
59
+ * // RotationLambdaARN: "STRING_VALUE",
60
+ * // RotationRules: { // RotationRulesType
61
+ * // AutomaticallyAfterDays: Number("long"),
62
+ * // Duration: "STRING_VALUE",
63
+ * // ScheduleExpression: "STRING_VALUE",
64
+ * // },
65
+ * // ExternalSecretRotationMetadata: [ // ExternalSecretRotationMetadataType
66
+ * // { // ExternalSecretRotationMetadataItem
67
+ * // Key: "STRING_VALUE",
68
+ * // Value: "STRING_VALUE",
69
+ * // },
70
+ * // ],
71
+ * // ExternalSecretRotationRoleArn: "STRING_VALUE",
72
+ * // LastRotatedDate: new Date("TIMESTAMP"),
73
+ * // LastChangedDate: new Date("TIMESTAMP"),
74
+ * // LastAccessedDate: new Date("TIMESTAMP"),
75
+ * // DeletedDate: new Date("TIMESTAMP"),
76
+ * // NextRotationDate: new Date("TIMESTAMP"),
77
+ * // Tags: [ // TagListType
78
+ * // { // Tag
79
+ * // Key: "STRING_VALUE",
80
+ * // Value: "STRING_VALUE",
81
+ * // },
82
+ * // ],
83
+ * // VersionIdsToStages: { // SecretVersionsToStagesMapType
84
+ * // "<keys>": [ // SecretVersionStagesType
85
+ * // "STRING_VALUE",
86
+ * // ],
87
+ * // },
88
+ * // OwningService: "STRING_VALUE",
89
+ * // CreatedDate: new Date("TIMESTAMP"),
90
+ * // PrimaryRegion: "STRING_VALUE",
91
+ * // ReplicationStatus: [ // ReplicationStatusListType
92
+ * // { // ReplicationStatusType
93
+ * // Region: "STRING_VALUE",
94
+ * // KmsKeyId: "STRING_VALUE",
95
+ * // Status: "InSync" || "Failed" || "InProgress",
96
+ * // StatusMessage: "STRING_VALUE",
97
+ * // LastAccessedDate: new Date("TIMESTAMP"),
98
+ * // },
99
+ * // ],
100
+ * // };
101
+ *
102
+ * ```
103
+ *
104
+ * @param DescribeSecretCommandInput - {@link DescribeSecretCommandInput}
105
+ * @returns {@link DescribeSecretCommandOutput}
106
+ * @see {@link DescribeSecretCommandInput} for command's `input` shape.
107
+ * @see {@link DescribeSecretCommandOutput} for command's `response` shape.
108
+ * @see {@link SecretsManagerClientResolvedConfig | config} for SecretsManagerClient's `config` shape.
109
+ *
110
+ * @throws {@link InternalServiceError} (server fault)
111
+ * <p>An error occurred on the server side.</p>
112
+ *
113
+ * @throws {@link InvalidParameterException} (client fault)
114
+ * <p>The parameter name or value is invalid.</p>
115
+ *
116
+ * @throws {@link ResourceNotFoundException} (client fault)
117
+ * <p>Secrets Manager can't find the resource that you asked for.</p>
118
+ *
119
+ * @throws {@link SecretsManagerServiceException}
120
+ * <p>Base exception class for all service exceptions from SecretsManager service.</p>
121
+ *
122
+ *
123
+ * @public
124
+ */
125
+ export declare class DescribeSecretCommand extends DescribeSecretCommand_base {
126
+ /** @internal type navigation helper, not in runtime. */
127
+ protected static __types: {
128
+ api: {
129
+ input: DescribeSecretRequest;
130
+ output: DescribeSecretResponse;
131
+ };
132
+ sdk: {
133
+ input: DescribeSecretCommandInput;
134
+ output: DescribeSecretCommandOutput;
135
+ };
136
+ };
137
+ }
@@ -0,0 +1,135 @@
1
+ import { Command as $Command } from "@smithy/smithy-client";
2
+ import type { MetadataBearer as __MetadataBearer } from "@smithy/types";
3
+ import type { GetRandomPasswordRequest, GetRandomPasswordResponse } from "../models/models_0";
4
+ import type { SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes } from "../SecretsManagerClient";
5
+ /**
6
+ * @public
7
+ */
8
+ export type { __MetadataBearer };
9
+ export { $Command };
10
+ /**
11
+ * @public
12
+ *
13
+ * The input for {@link GetRandomPasswordCommand}.
14
+ */
15
+ export interface GetRandomPasswordCommandInput extends GetRandomPasswordRequest {
16
+ }
17
+ /**
18
+ * @public
19
+ *
20
+ * The output of {@link GetRandomPasswordCommand}.
21
+ */
22
+ export interface GetRandomPasswordCommandOutput extends GetRandomPasswordResponse, __MetadataBearer {
23
+ }
24
+ declare const GetRandomPasswordCommand_base: {
25
+ new (input: GetRandomPasswordCommandInput): import("@smithy/smithy-client").CommandImpl<GetRandomPasswordCommandInput, GetRandomPasswordCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
26
+ new (...[input]: [] | [GetRandomPasswordCommandInput]): import("@smithy/smithy-client").CommandImpl<GetRandomPasswordCommandInput, GetRandomPasswordCommandOutput, SecretsManagerClientResolvedConfig, ServiceInputTypes, ServiceOutputTypes>;
27
+ getEndpointParameterInstructions(): import("@smithy/middleware-endpoint").EndpointParameterInstructions;
28
+ };
29
+ /**
30
+ * <p>Generates a random password. We recommend that you specify the maximum length and
31
+ * include every character type that the system you are generating a password for can
32
+ * support. By default, Secrets Manager uses uppercase and lowercase letters, numbers, and the
33
+ * following characters in passwords:
34
+ * <code>!\"#$%&'()*+,-./:;<=>?@[\\]^_`\{|\}~</code>
35
+ * </p>
36
+ * <p>Secrets Manager generates a CloudTrail log entry when you call this
37
+ * action.</p>
38
+ * <p>
39
+ * <b>Required permissions:
40
+ * </b>
41
+ * <code>secretsmanager:GetRandomPassword</code>. For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/reference_iam-permissions.html#reference_iam-permissions_actions">
42
+ * IAM policy actions for Secrets Manager</a> and <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/auth-and-access.html">Authentication
43
+ * and access control in Secrets Manager</a>. </p>
44
+ * @example
45
+ * Use a bare-bones client and the command you need to make an API call.
46
+ * ```javascript
47
+ * import { SecretsManagerClient, GetRandomPasswordCommand } from "@aws-sdk/client-secrets-manager"; // ES Modules import
48
+ * // const { SecretsManagerClient, GetRandomPasswordCommand } = require("@aws-sdk/client-secrets-manager"); // CommonJS import
49
+ * // import type { SecretsManagerClientConfig } from "@aws-sdk/client-secrets-manager";
50
+ * const config = {}; // type is SecretsManagerClientConfig
51
+ * const client = new SecretsManagerClient(config);
52
+ * const input = { // GetRandomPasswordRequest
53
+ * PasswordLength: Number("long"),
54
+ * ExcludeCharacters: "STRING_VALUE",
55
+ * ExcludeNumbers: true || false,
56
+ * ExcludePunctuation: true || false,
57
+ * ExcludeUppercase: true || false,
58
+ * ExcludeLowercase: true || false,
59
+ * IncludeSpace: true || false,
60
+ * RequireEachIncludedType: true || false,
61
+ * };
62
+ * const command = new GetRandomPasswordCommand(input);
63
+ * const response = await client.send(command);
64
+ * // { // GetRandomPasswordResponse
65
+ * // RandomPassword: "STRING_VALUE",
66
+ * // };
67
+ *
68
+ * ```
69
+ *
70
+ * @param GetRandomPasswordCommandInput - {@link GetRandomPasswordCommandInput}
71
+ * @returns {@link GetRandomPasswordCommandOutput}
72
+ * @see {@link GetRandomPasswordCommandInput} for command's `input` shape.
73
+ * @see {@link GetRandomPasswordCommandOutput} for command's `response` shape.
74
+ * @see {@link SecretsManagerClientResolvedConfig | config} for SecretsManagerClient's `config` shape.
75
+ *
76
+ * @throws {@link InternalServiceError} (server fault)
77
+ * <p>An error occurred on the server side.</p>
78
+ *
79
+ * @throws {@link InvalidParameterException} (client fault)
80
+ * <p>The parameter name or value is invalid.</p>
81
+ *
82
+ * @throws {@link InvalidRequestException} (client fault)
83
+ * <p>A parameter value is not valid for the current state of the
84
+ * resource.</p>
85
+ * <p>Possible causes:</p>
86
+ * <ul>
87
+ * <li>
88
+ * <p>The secret is scheduled for deletion.</p>
89
+ * </li>
90
+ * <li>
91
+ * <p>You tried to enable rotation on a secret that doesn't already have a Lambda function
92
+ * ARN configured and you didn't include such an ARN as a parameter in this call. </p>
93
+ * </li>
94
+ * <li>
95
+ * <p>The secret is managed by another service, and you must use that service to update it.
96
+ * For more information, see <a href="https://docs.aws.amazon.com/secretsmanager/latest/userguide/service-linked-secrets.html">Secrets managed by other Amazon Web Services services</a>.</p>
97
+ * </li>
98
+ * </ul>
99
+ *
100
+ * @throws {@link SecretsManagerServiceException}
101
+ * <p>Base exception class for all service exceptions from SecretsManager service.</p>
102
+ *
103
+ *
104
+ * @example To generate a random password
105
+ * ```javascript
106
+ * // The following example shows how to request a randomly generated password. This example includes the optional flags to require spaces and at least one character of each included type. It specifies a length of 20 characters.
107
+ * const input = {
108
+ * IncludeSpace: true,
109
+ * PasswordLength: 20,
110
+ * RequireEachIncludedType: true
111
+ * };
112
+ * const command = new GetRandomPasswordCommand(input);
113
+ * const response = await client.send(command);
114
+ * /* response is
115
+ * {
116
+ * RandomPassword: "EXAMPLE-PASSWORD"
117
+ * }
118
+ * *\/
119
+ * ```
120
+ *
121
+ * @public
122
+ */
123
+ export declare class GetRandomPasswordCommand extends GetRandomPasswordCommand_base {
124
+ /** @internal type navigation helper, not in runtime. */
125
+ protected static __types: {
126
+ api: {
127
+ input: GetRandomPasswordRequest;
128
+ output: GetRandomPasswordResponse;
129
+ };
130
+ sdk: {
131
+ input: GetRandomPasswordCommandInput;
132
+ output: GetRandomPasswordCommandOutput;
133
+ };
134
+ };
135
+ }