/** * Copyright Amazon.com, Inc. or its affiliates. All Rights Reserved. * SPDX-License-Identifier: Apache-2.0. */ #pragma once #include #include #include #include namespace Aws { namespace SecretsManager { namespace Model { /** */ class DeleteSecretRequest : public SecretsManagerRequest { public: AWS_SECRETSMANAGER_API DeleteSecretRequest(); // Service request name is the Operation name which will send this request out, // each operation should has unique request name, so that we can get operation's name from this request. // Note: this is not true for response, multiple operations may have the same response name, // so we can not get operation's name from response. inline virtual const char* GetServiceRequestName() const override { return "DeleteSecret"; } AWS_SECRETSMANAGER_API Aws::String SerializePayload() const override; AWS_SECRETSMANAGER_API Aws::Http::HeaderValueCollection GetRequestSpecificHeaders() const override; /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline const Aws::String& GetSecretId() const{ return m_secretId; } /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline bool SecretIdHasBeenSet() const { return m_secretIdHasBeenSet; } /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline void SetSecretId(const Aws::String& value) { m_secretIdHasBeenSet = true; m_secretId = value; } /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline void SetSecretId(Aws::String&& value) { m_secretIdHasBeenSet = true; m_secretId = std::move(value); } /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline void SetSecretId(const char* value) { m_secretIdHasBeenSet = true; m_secretId.assign(value); } /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline DeleteSecretRequest& WithSecretId(const Aws::String& value) { SetSecretId(value); return *this;} /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline DeleteSecretRequest& WithSecretId(Aws::String&& value) { SetSecretId(std::move(value)); return *this;} /** *

The ARN or name of the secret to delete.

For an ARN, we recommend that * you specify a complete ARN rather than a partial ARN. See Finding * a secret from a partial ARN.

*/ inline DeleteSecretRequest& WithSecretId(const char* value) { SetSecretId(value); return *this;} /** *

The number of days from 7 to 30 that Secrets Manager waits before permanently * deleting the secret. You can't use both this parameter and * ForceDeleteWithoutRecovery in the same call. If you don't use * either, then by default Secrets Manager uses a 30 day recovery window.

*/ inline long long GetRecoveryWindowInDays() const{ return m_recoveryWindowInDays; } /** *

The number of days from 7 to 30 that Secrets Manager waits before permanently * deleting the secret. You can't use both this parameter and * ForceDeleteWithoutRecovery in the same call. If you don't use * either, then by default Secrets Manager uses a 30 day recovery window.

*/ inline bool RecoveryWindowInDaysHasBeenSet() const { return m_recoveryWindowInDaysHasBeenSet; } /** *

The number of days from 7 to 30 that Secrets Manager waits before permanently * deleting the secret. You can't use both this parameter and * ForceDeleteWithoutRecovery in the same call. If you don't use * either, then by default Secrets Manager uses a 30 day recovery window.

*/ inline void SetRecoveryWindowInDays(long long value) { m_recoveryWindowInDaysHasBeenSet = true; m_recoveryWindowInDays = value; } /** *

The number of days from 7 to 30 that Secrets Manager waits before permanently * deleting the secret. You can't use both this parameter and * ForceDeleteWithoutRecovery in the same call. If you don't use * either, then by default Secrets Manager uses a 30 day recovery window.

*/ inline DeleteSecretRequest& WithRecoveryWindowInDays(long long value) { SetRecoveryWindowInDays(value); return *this;} /** *

Specifies whether to delete the secret without any recovery window. You can't * use both this parameter and RecoveryWindowInDays in the same call. * If you don't use either, then by default Secrets Manager uses a 30 day recovery * window.

Secrets Manager performs the actual deletion with an asynchronous * background process, so there might be a short delay before the secret is * permanently deleted. If you delete a secret and then immediately create a secret * with the same name, use appropriate back off and retry logic.

If you * forcibly delete an already deleted or nonexistent secret, the operation does not * return ResourceNotFoundException.

Use this * parameter with caution. This parameter causes the operation to skip the normal * recovery window before the permanent deletion that Secrets Manager would * normally impose with the RecoveryWindowInDays parameter. If you * delete a secret with the ForceDeleteWithoutRecovery parameter, then * you have no opportunity to recover the secret. You lose the secret * permanently.

*/ inline bool GetForceDeleteWithoutRecovery() const{ return m_forceDeleteWithoutRecovery; } /** *

Specifies whether to delete the secret without any recovery window. You can't * use both this parameter and RecoveryWindowInDays in the same call. * If you don't use either, then by default Secrets Manager uses a 30 day recovery * window.

Secrets Manager performs the actual deletion with an asynchronous * background process, so there might be a short delay before the secret is * permanently deleted. If you delete a secret and then immediately create a secret * with the same name, use appropriate back off and retry logic.

If you * forcibly delete an already deleted or nonexistent secret, the operation does not * return ResourceNotFoundException.

Use this * parameter with caution. This parameter causes the operation to skip the normal * recovery window before the permanent deletion that Secrets Manager would * normally impose with the RecoveryWindowInDays parameter. If you * delete a secret with the ForceDeleteWithoutRecovery parameter, then * you have no opportunity to recover the secret. You lose the secret * permanently.

*/ inline bool ForceDeleteWithoutRecoveryHasBeenSet() const { return m_forceDeleteWithoutRecoveryHasBeenSet; } /** *

Specifies whether to delete the secret without any recovery window. You can't * use both this parameter and RecoveryWindowInDays in the same call. * If you don't use either, then by default Secrets Manager uses a 30 day recovery * window.

Secrets Manager performs the actual deletion with an asynchronous * background process, so there might be a short delay before the secret is * permanently deleted. If you delete a secret and then immediately create a secret * with the same name, use appropriate back off and retry logic.

If you * forcibly delete an already deleted or nonexistent secret, the operation does not * return ResourceNotFoundException.

Use this * parameter with caution. This parameter causes the operation to skip the normal * recovery window before the permanent deletion that Secrets Manager would * normally impose with the RecoveryWindowInDays parameter. If you * delete a secret with the ForceDeleteWithoutRecovery parameter, then * you have no opportunity to recover the secret. You lose the secret * permanently.

*/ inline void SetForceDeleteWithoutRecovery(bool value) { m_forceDeleteWithoutRecoveryHasBeenSet = true; m_forceDeleteWithoutRecovery = value; } /** *

Specifies whether to delete the secret without any recovery window. You can't * use both this parameter and RecoveryWindowInDays in the same call. * If you don't use either, then by default Secrets Manager uses a 30 day recovery * window.

Secrets Manager performs the actual deletion with an asynchronous * background process, so there might be a short delay before the secret is * permanently deleted. If you delete a secret and then immediately create a secret * with the same name, use appropriate back off and retry logic.

If you * forcibly delete an already deleted or nonexistent secret, the operation does not * return ResourceNotFoundException.

Use this * parameter with caution. This parameter causes the operation to skip the normal * recovery window before the permanent deletion that Secrets Manager would * normally impose with the RecoveryWindowInDays parameter. If you * delete a secret with the ForceDeleteWithoutRecovery parameter, then * you have no opportunity to recover the secret. You lose the secret * permanently.

*/ inline DeleteSecretRequest& WithForceDeleteWithoutRecovery(bool value) { SetForceDeleteWithoutRecovery(value); return *this;} private: Aws::String m_secretId; bool m_secretIdHasBeenSet = false; long long m_recoveryWindowInDays; bool m_recoveryWindowInDaysHasBeenSet = false; bool m_forceDeleteWithoutRecovery; bool m_forceDeleteWithoutRecoveryHasBeenSet = false; }; } // namespace Model } // namespace SecretsManager } // namespace Aws