Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Sets the key state of a KMS key to enabled. This allows you to use the KMS key for cryptographic operations.
The KMS key that you use for this operation must be in a compatible key state. For details, see Key state: Effect on your KMS key in the Key Management Service Developer Guide.
Cross-account use: No. You cannot perform this operation on a KMS key in a different Amazon Web Services account.
Required permissions: kms:EnableKey (key policy)
Related operations: DisableKey
Synopsis
- data EnableKey = EnableKey' {}
- newEnableKey :: Text -> EnableKey
- enableKey_keyId :: Lens' EnableKey Text
- data EnableKeyResponse = EnableKeyResponse' {
- newEnableKeyResponse :: EnableKeyResponse
Creating a Request
See: newEnableKey
smart constructor.
EnableKey' | |
|
Instances
Eq EnableKey Source # | |
Read EnableKey Source # | |
Show EnableKey Source # | |
Generic EnableKey Source # | |
NFData EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey | |
Hashable EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey | |
ToJSON EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey | |
AWSRequest EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey type AWSResponse EnableKey # request :: EnableKey -> Request EnableKey # response :: MonadResource m => Logger -> Service -> Proxy EnableKey -> ClientResponse ClientBody -> m (Either Error (ClientResponse (AWSResponse EnableKey))) # | |
ToHeaders EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey | |
ToPath EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey toPath :: EnableKey -> ByteString # | |
ToQuery EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey toQuery :: EnableKey -> QueryString # | |
type Rep EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey | |
type AWSResponse EnableKey Source # | |
Defined in Amazonka.KMS.EnableKey |
Create a value of EnableKey
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:keyId:EnableKey'
, enableKey_keyId
- Identifies the KMS key to enable.
Specify the key ID or key ARN of the KMS key.
For example:
- Key ID:
1234abcd-12ab-34cd-56ef-1234567890ab
- Key ARN:
arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.
Request Lenses
enableKey_keyId :: Lens' EnableKey Text Source #
Identifies the KMS key to enable.
Specify the key ID or key ARN of the KMS key.
For example:
- Key ID:
1234abcd-12ab-34cd-56ef-1234567890ab
- Key ARN:
arn:aws:kms:us-east-2:111122223333:key/1234abcd-12ab-34cd-56ef-1234567890ab
To get the key ID and key ARN for a KMS key, use ListKeys or DescribeKey.
Destructuring the Response
data EnableKeyResponse Source #
See: newEnableKeyResponse
smart constructor.
Instances
Eq EnableKeyResponse Source # | |
Defined in Amazonka.KMS.EnableKey (==) :: EnableKeyResponse -> EnableKeyResponse -> Bool # (/=) :: EnableKeyResponse -> EnableKeyResponse -> Bool # | |
Read EnableKeyResponse Source # | |
Defined in Amazonka.KMS.EnableKey | |
Show EnableKeyResponse Source # | |
Defined in Amazonka.KMS.EnableKey showsPrec :: Int -> EnableKeyResponse -> ShowS # show :: EnableKeyResponse -> String # showList :: [EnableKeyResponse] -> ShowS # | |
Generic EnableKeyResponse Source # | |
Defined in Amazonka.KMS.EnableKey type Rep EnableKeyResponse :: Type -> Type # from :: EnableKeyResponse -> Rep EnableKeyResponse x # to :: Rep EnableKeyResponse x -> EnableKeyResponse # | |
NFData EnableKeyResponse Source # | |
Defined in Amazonka.KMS.EnableKey rnf :: EnableKeyResponse -> () # | |
type Rep EnableKeyResponse Source # | |
newEnableKeyResponse :: EnableKeyResponse Source #
Create a value of EnableKeyResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.