{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE DuplicateRecordFields #-}
{-# LANGUAGE NamedFieldPuns #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE StrictData #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Amazonka.IAM.UntagMFADevice
(
UntagMFADevice (..),
newUntagMFADevice,
untagMFADevice_serialNumber,
untagMFADevice_tagKeys,
UntagMFADeviceResponse (..),
newUntagMFADeviceResponse,
)
where
import qualified Amazonka.Core as Core
import Amazonka.IAM.Types
import qualified Amazonka.Lens as Lens
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data UntagMFADevice = UntagMFADevice'
{
UntagMFADevice -> Text
serialNumber :: Prelude.Text,
UntagMFADevice -> [Text]
tagKeys :: [Prelude.Text]
}
deriving (UntagMFADevice -> UntagMFADevice -> Bool
(UntagMFADevice -> UntagMFADevice -> Bool)
-> (UntagMFADevice -> UntagMFADevice -> Bool) -> Eq UntagMFADevice
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UntagMFADevice -> UntagMFADevice -> Bool
$c/= :: UntagMFADevice -> UntagMFADevice -> Bool
== :: UntagMFADevice -> UntagMFADevice -> Bool
$c== :: UntagMFADevice -> UntagMFADevice -> Bool
Prelude.Eq, ReadPrec [UntagMFADevice]
ReadPrec UntagMFADevice
Int -> ReadS UntagMFADevice
ReadS [UntagMFADevice]
(Int -> ReadS UntagMFADevice)
-> ReadS [UntagMFADevice]
-> ReadPrec UntagMFADevice
-> ReadPrec [UntagMFADevice]
-> Read UntagMFADevice
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UntagMFADevice]
$creadListPrec :: ReadPrec [UntagMFADevice]
readPrec :: ReadPrec UntagMFADevice
$creadPrec :: ReadPrec UntagMFADevice
readList :: ReadS [UntagMFADevice]
$creadList :: ReadS [UntagMFADevice]
readsPrec :: Int -> ReadS UntagMFADevice
$creadsPrec :: Int -> ReadS UntagMFADevice
Prelude.Read, Int -> UntagMFADevice -> ShowS
[UntagMFADevice] -> ShowS
UntagMFADevice -> String
(Int -> UntagMFADevice -> ShowS)
-> (UntagMFADevice -> String)
-> ([UntagMFADevice] -> ShowS)
-> Show UntagMFADevice
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UntagMFADevice] -> ShowS
$cshowList :: [UntagMFADevice] -> ShowS
show :: UntagMFADevice -> String
$cshow :: UntagMFADevice -> String
showsPrec :: Int -> UntagMFADevice -> ShowS
$cshowsPrec :: Int -> UntagMFADevice -> ShowS
Prelude.Show, (forall x. UntagMFADevice -> Rep UntagMFADevice x)
-> (forall x. Rep UntagMFADevice x -> UntagMFADevice)
-> Generic UntagMFADevice
forall x. Rep UntagMFADevice x -> UntagMFADevice
forall x. UntagMFADevice -> Rep UntagMFADevice x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UntagMFADevice x -> UntagMFADevice
$cfrom :: forall x. UntagMFADevice -> Rep UntagMFADevice x
Prelude.Generic)
newUntagMFADevice ::
Prelude.Text ->
UntagMFADevice
newUntagMFADevice :: Text -> UntagMFADevice
newUntagMFADevice Text
pSerialNumber_ =
UntagMFADevice' :: Text -> [Text] -> UntagMFADevice
UntagMFADevice'
{ $sel:serialNumber:UntagMFADevice' :: Text
serialNumber = Text
pSerialNumber_,
$sel:tagKeys:UntagMFADevice' :: [Text]
tagKeys = [Text]
forall a. Monoid a => a
Prelude.mempty
}
untagMFADevice_serialNumber :: Lens.Lens' UntagMFADevice Prelude.Text
untagMFADevice_serialNumber :: (Text -> f Text) -> UntagMFADevice -> f UntagMFADevice
untagMFADevice_serialNumber = (UntagMFADevice -> Text)
-> (UntagMFADevice -> Text -> UntagMFADevice)
-> Lens UntagMFADevice UntagMFADevice Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UntagMFADevice' {Text
serialNumber :: Text
$sel:serialNumber:UntagMFADevice' :: UntagMFADevice -> Text
serialNumber} -> Text
serialNumber) (\s :: UntagMFADevice
s@UntagMFADevice' {} Text
a -> UntagMFADevice
s {$sel:serialNumber:UntagMFADevice' :: Text
serialNumber = Text
a} :: UntagMFADevice)
untagMFADevice_tagKeys :: Lens.Lens' UntagMFADevice [Prelude.Text]
untagMFADevice_tagKeys :: ([Text] -> f [Text]) -> UntagMFADevice -> f UntagMFADevice
untagMFADevice_tagKeys = (UntagMFADevice -> [Text])
-> (UntagMFADevice -> [Text] -> UntagMFADevice)
-> Lens UntagMFADevice UntagMFADevice [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UntagMFADevice' {[Text]
tagKeys :: [Text]
$sel:tagKeys:UntagMFADevice' :: UntagMFADevice -> [Text]
tagKeys} -> [Text]
tagKeys) (\s :: UntagMFADevice
s@UntagMFADevice' {} [Text]
a -> UntagMFADevice
s {$sel:tagKeys:UntagMFADevice' :: [Text]
tagKeys = [Text]
a} :: UntagMFADevice) (([Text] -> f [Text]) -> UntagMFADevice -> f UntagMFADevice)
-> (([Text] -> f [Text]) -> [Text] -> f [Text])
-> ([Text] -> f [Text])
-> UntagMFADevice
-> f UntagMFADevice
forall b c a. (b -> c) -> (a -> b) -> a -> c
Prelude.. ([Text] -> f [Text]) -> [Text] -> f [Text]
forall s t a b. (Coercible s a, Coercible t b) => Iso s t a b
Lens.coerced
instance Core.AWSRequest UntagMFADevice where
type
AWSResponse UntagMFADevice =
UntagMFADeviceResponse
request :: UntagMFADevice -> Request UntagMFADevice
request = Service -> UntagMFADevice -> Request UntagMFADevice
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery Service
defaultService
response :: Logger
-> Service
-> Proxy UntagMFADevice
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UntagMFADevice)))
response =
AWSResponse UntagMFADevice
-> Logger
-> Service
-> Proxy UntagMFADevice
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse UntagMFADevice)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull AWSResponse UntagMFADevice
UntagMFADeviceResponse
UntagMFADeviceResponse'
instance Prelude.Hashable UntagMFADevice
instance Prelude.NFData UntagMFADevice
instance Core.ToHeaders UntagMFADevice where
toHeaders :: UntagMFADevice -> [Header]
toHeaders = [Header] -> UntagMFADevice -> [Header]
forall a b. a -> b -> a
Prelude.const [Header]
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath UntagMFADevice where
toPath :: UntagMFADevice -> ByteString
toPath = ByteString -> UntagMFADevice -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery UntagMFADevice where
toQuery :: UntagMFADevice -> QueryString
toQuery UntagMFADevice' {[Text]
Text
tagKeys :: [Text]
serialNumber :: Text
$sel:tagKeys:UntagMFADevice' :: UntagMFADevice -> [Text]
$sel:serialNumber:UntagMFADevice' :: UntagMFADevice -> Text
..} =
[QueryString] -> QueryString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"Action"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"UntagMFADevice" :: Prelude.ByteString),
ByteString
"Version"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"2010-05-08" :: Prelude.ByteString),
ByteString
"SerialNumber" ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
serialNumber,
ByteString
"TagKeys" ByteString -> QueryString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: ByteString -> [Text] -> QueryString
forall a.
(IsList a, ToQuery (Item a)) =>
ByteString -> a -> QueryString
Core.toQueryList ByteString
"member" [Text]
tagKeys
]
data UntagMFADeviceResponse = UntagMFADeviceResponse'
{
}
deriving (UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool
(UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool)
-> (UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool)
-> Eq UntagMFADeviceResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool
$c/= :: UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool
== :: UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool
$c== :: UntagMFADeviceResponse -> UntagMFADeviceResponse -> Bool
Prelude.Eq, ReadPrec [UntagMFADeviceResponse]
ReadPrec UntagMFADeviceResponse
Int -> ReadS UntagMFADeviceResponse
ReadS [UntagMFADeviceResponse]
(Int -> ReadS UntagMFADeviceResponse)
-> ReadS [UntagMFADeviceResponse]
-> ReadPrec UntagMFADeviceResponse
-> ReadPrec [UntagMFADeviceResponse]
-> Read UntagMFADeviceResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UntagMFADeviceResponse]
$creadListPrec :: ReadPrec [UntagMFADeviceResponse]
readPrec :: ReadPrec UntagMFADeviceResponse
$creadPrec :: ReadPrec UntagMFADeviceResponse
readList :: ReadS [UntagMFADeviceResponse]
$creadList :: ReadS [UntagMFADeviceResponse]
readsPrec :: Int -> ReadS UntagMFADeviceResponse
$creadsPrec :: Int -> ReadS UntagMFADeviceResponse
Prelude.Read, Int -> UntagMFADeviceResponse -> ShowS
[UntagMFADeviceResponse] -> ShowS
UntagMFADeviceResponse -> String
(Int -> UntagMFADeviceResponse -> ShowS)
-> (UntagMFADeviceResponse -> String)
-> ([UntagMFADeviceResponse] -> ShowS)
-> Show UntagMFADeviceResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UntagMFADeviceResponse] -> ShowS
$cshowList :: [UntagMFADeviceResponse] -> ShowS
show :: UntagMFADeviceResponse -> String
$cshow :: UntagMFADeviceResponse -> String
showsPrec :: Int -> UntagMFADeviceResponse -> ShowS
$cshowsPrec :: Int -> UntagMFADeviceResponse -> ShowS
Prelude.Show, (forall x. UntagMFADeviceResponse -> Rep UntagMFADeviceResponse x)
-> (forall x.
Rep UntagMFADeviceResponse x -> UntagMFADeviceResponse)
-> Generic UntagMFADeviceResponse
forall x. Rep UntagMFADeviceResponse x -> UntagMFADeviceResponse
forall x. UntagMFADeviceResponse -> Rep UntagMFADeviceResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UntagMFADeviceResponse x -> UntagMFADeviceResponse
$cfrom :: forall x. UntagMFADeviceResponse -> Rep UntagMFADeviceResponse x
Prelude.Generic)
newUntagMFADeviceResponse ::
UntagMFADeviceResponse
newUntagMFADeviceResponse :: UntagMFADeviceResponse
newUntagMFADeviceResponse = UntagMFADeviceResponse
UntagMFADeviceResponse'
instance Prelude.NFData UntagMFADeviceResponse