{-# 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.UntagInstanceProfile
(
UntagInstanceProfile (..),
newUntagInstanceProfile,
untagInstanceProfile_instanceProfileName,
untagInstanceProfile_tagKeys,
UntagInstanceProfileResponse (..),
newUntagInstanceProfileResponse,
)
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 UntagInstanceProfile = UntagInstanceProfile'
{
UntagInstanceProfile -> Text
instanceProfileName :: Prelude.Text,
UntagInstanceProfile -> [Text]
tagKeys :: [Prelude.Text]
}
deriving (UntagInstanceProfile -> UntagInstanceProfile -> Bool
(UntagInstanceProfile -> UntagInstanceProfile -> Bool)
-> (UntagInstanceProfile -> UntagInstanceProfile -> Bool)
-> Eq UntagInstanceProfile
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UntagInstanceProfile -> UntagInstanceProfile -> Bool
$c/= :: UntagInstanceProfile -> UntagInstanceProfile -> Bool
== :: UntagInstanceProfile -> UntagInstanceProfile -> Bool
$c== :: UntagInstanceProfile -> UntagInstanceProfile -> Bool
Prelude.Eq, ReadPrec [UntagInstanceProfile]
ReadPrec UntagInstanceProfile
Int -> ReadS UntagInstanceProfile
ReadS [UntagInstanceProfile]
(Int -> ReadS UntagInstanceProfile)
-> ReadS [UntagInstanceProfile]
-> ReadPrec UntagInstanceProfile
-> ReadPrec [UntagInstanceProfile]
-> Read UntagInstanceProfile
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UntagInstanceProfile]
$creadListPrec :: ReadPrec [UntagInstanceProfile]
readPrec :: ReadPrec UntagInstanceProfile
$creadPrec :: ReadPrec UntagInstanceProfile
readList :: ReadS [UntagInstanceProfile]
$creadList :: ReadS [UntagInstanceProfile]
readsPrec :: Int -> ReadS UntagInstanceProfile
$creadsPrec :: Int -> ReadS UntagInstanceProfile
Prelude.Read, Int -> UntagInstanceProfile -> ShowS
[UntagInstanceProfile] -> ShowS
UntagInstanceProfile -> String
(Int -> UntagInstanceProfile -> ShowS)
-> (UntagInstanceProfile -> String)
-> ([UntagInstanceProfile] -> ShowS)
-> Show UntagInstanceProfile
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UntagInstanceProfile] -> ShowS
$cshowList :: [UntagInstanceProfile] -> ShowS
show :: UntagInstanceProfile -> String
$cshow :: UntagInstanceProfile -> String
showsPrec :: Int -> UntagInstanceProfile -> ShowS
$cshowsPrec :: Int -> UntagInstanceProfile -> ShowS
Prelude.Show, (forall x. UntagInstanceProfile -> Rep UntagInstanceProfile x)
-> (forall x. Rep UntagInstanceProfile x -> UntagInstanceProfile)
-> Generic UntagInstanceProfile
forall x. Rep UntagInstanceProfile x -> UntagInstanceProfile
forall x. UntagInstanceProfile -> Rep UntagInstanceProfile x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep UntagInstanceProfile x -> UntagInstanceProfile
$cfrom :: forall x. UntagInstanceProfile -> Rep UntagInstanceProfile x
Prelude.Generic)
newUntagInstanceProfile ::
Prelude.Text ->
UntagInstanceProfile
newUntagInstanceProfile :: Text -> UntagInstanceProfile
newUntagInstanceProfile Text
pInstanceProfileName_ =
UntagInstanceProfile' :: Text -> [Text] -> UntagInstanceProfile
UntagInstanceProfile'
{ $sel:instanceProfileName:UntagInstanceProfile' :: Text
instanceProfileName =
Text
pInstanceProfileName_,
$sel:tagKeys:UntagInstanceProfile' :: [Text]
tagKeys = [Text]
forall a. Monoid a => a
Prelude.mempty
}
untagInstanceProfile_instanceProfileName :: Lens.Lens' UntagInstanceProfile Prelude.Text
untagInstanceProfile_instanceProfileName :: (Text -> f Text) -> UntagInstanceProfile -> f UntagInstanceProfile
untagInstanceProfile_instanceProfileName = (UntagInstanceProfile -> Text)
-> (UntagInstanceProfile -> Text -> UntagInstanceProfile)
-> Lens UntagInstanceProfile UntagInstanceProfile Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UntagInstanceProfile' {Text
instanceProfileName :: Text
$sel:instanceProfileName:UntagInstanceProfile' :: UntagInstanceProfile -> Text
instanceProfileName} -> Text
instanceProfileName) (\s :: UntagInstanceProfile
s@UntagInstanceProfile' {} Text
a -> UntagInstanceProfile
s {$sel:instanceProfileName:UntagInstanceProfile' :: Text
instanceProfileName = Text
a} :: UntagInstanceProfile)
untagInstanceProfile_tagKeys :: Lens.Lens' UntagInstanceProfile [Prelude.Text]
untagInstanceProfile_tagKeys :: ([Text] -> f [Text])
-> UntagInstanceProfile -> f UntagInstanceProfile
untagInstanceProfile_tagKeys = (UntagInstanceProfile -> [Text])
-> (UntagInstanceProfile -> [Text] -> UntagInstanceProfile)
-> Lens UntagInstanceProfile UntagInstanceProfile [Text] [Text]
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\UntagInstanceProfile' {[Text]
tagKeys :: [Text]
$sel:tagKeys:UntagInstanceProfile' :: UntagInstanceProfile -> [Text]
tagKeys} -> [Text]
tagKeys) (\s :: UntagInstanceProfile
s@UntagInstanceProfile' {} [Text]
a -> UntagInstanceProfile
s {$sel:tagKeys:UntagInstanceProfile' :: [Text]
tagKeys = [Text]
a} :: UntagInstanceProfile) (([Text] -> f [Text])
-> UntagInstanceProfile -> f UntagInstanceProfile)
-> (([Text] -> f [Text]) -> [Text] -> f [Text])
-> ([Text] -> f [Text])
-> UntagInstanceProfile
-> f UntagInstanceProfile
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 UntagInstanceProfile where
type
AWSResponse UntagInstanceProfile =
UntagInstanceProfileResponse
request :: UntagInstanceProfile -> Request UntagInstanceProfile
request = Service -> UntagInstanceProfile -> Request UntagInstanceProfile
forall a. ToRequest a => Service -> a -> Request a
Request.postQuery Service
defaultService
response :: Logger
-> Service
-> Proxy UntagInstanceProfile
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse UntagInstanceProfile)))
response =
AWSResponse UntagInstanceProfile
-> Logger
-> Service
-> Proxy UntagInstanceProfile
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse UntagInstanceProfile)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull AWSResponse UntagInstanceProfile
UntagInstanceProfileResponse
UntagInstanceProfileResponse'
instance Prelude.Hashable UntagInstanceProfile
instance Prelude.NFData UntagInstanceProfile
instance Core.ToHeaders UntagInstanceProfile where
toHeaders :: UntagInstanceProfile -> [Header]
toHeaders = [Header] -> UntagInstanceProfile -> [Header]
forall a b. a -> b -> a
Prelude.const [Header]
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath UntagInstanceProfile where
toPath :: UntagInstanceProfile -> ByteString
toPath = ByteString -> UntagInstanceProfile -> ByteString
forall a b. a -> b -> a
Prelude.const ByteString
"/"
instance Core.ToQuery UntagInstanceProfile where
toQuery :: UntagInstanceProfile -> QueryString
toQuery UntagInstanceProfile' {[Text]
Text
tagKeys :: [Text]
instanceProfileName :: Text
$sel:tagKeys:UntagInstanceProfile' :: UntagInstanceProfile -> [Text]
$sel:instanceProfileName:UntagInstanceProfile' :: UntagInstanceProfile -> 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
"UntagInstanceProfile" :: Prelude.ByteString),
ByteString
"Version"
ByteString -> ByteString -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: (ByteString
"2010-05-08" :: Prelude.ByteString),
ByteString
"InstanceProfileName" ByteString -> Text -> QueryString
forall a. ToQuery a => ByteString -> a -> QueryString
Core.=: Text
instanceProfileName,
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 UntagInstanceProfileResponse = UntagInstanceProfileResponse'
{
}
deriving (UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool
(UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool)
-> (UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool)
-> Eq UntagInstanceProfileResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool
$c/= :: UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool
== :: UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool
$c== :: UntagInstanceProfileResponse
-> UntagInstanceProfileResponse -> Bool
Prelude.Eq, ReadPrec [UntagInstanceProfileResponse]
ReadPrec UntagInstanceProfileResponse
Int -> ReadS UntagInstanceProfileResponse
ReadS [UntagInstanceProfileResponse]
(Int -> ReadS UntagInstanceProfileResponse)
-> ReadS [UntagInstanceProfileResponse]
-> ReadPrec UntagInstanceProfileResponse
-> ReadPrec [UntagInstanceProfileResponse]
-> Read UntagInstanceProfileResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [UntagInstanceProfileResponse]
$creadListPrec :: ReadPrec [UntagInstanceProfileResponse]
readPrec :: ReadPrec UntagInstanceProfileResponse
$creadPrec :: ReadPrec UntagInstanceProfileResponse
readList :: ReadS [UntagInstanceProfileResponse]
$creadList :: ReadS [UntagInstanceProfileResponse]
readsPrec :: Int -> ReadS UntagInstanceProfileResponse
$creadsPrec :: Int -> ReadS UntagInstanceProfileResponse
Prelude.Read, Int -> UntagInstanceProfileResponse -> ShowS
[UntagInstanceProfileResponse] -> ShowS
UntagInstanceProfileResponse -> String
(Int -> UntagInstanceProfileResponse -> ShowS)
-> (UntagInstanceProfileResponse -> String)
-> ([UntagInstanceProfileResponse] -> ShowS)
-> Show UntagInstanceProfileResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [UntagInstanceProfileResponse] -> ShowS
$cshowList :: [UntagInstanceProfileResponse] -> ShowS
show :: UntagInstanceProfileResponse -> String
$cshow :: UntagInstanceProfileResponse -> String
showsPrec :: Int -> UntagInstanceProfileResponse -> ShowS
$cshowsPrec :: Int -> UntagInstanceProfileResponse -> ShowS
Prelude.Show, (forall x.
UntagInstanceProfileResponse -> Rep UntagInstanceProfileResponse x)
-> (forall x.
Rep UntagInstanceProfileResponse x -> UntagInstanceProfileResponse)
-> Generic UntagInstanceProfileResponse
forall x.
Rep UntagInstanceProfileResponse x -> UntagInstanceProfileResponse
forall x.
UntagInstanceProfileResponse -> Rep UntagInstanceProfileResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep UntagInstanceProfileResponse x -> UntagInstanceProfileResponse
$cfrom :: forall x.
UntagInstanceProfileResponse -> Rep UntagInstanceProfileResponse x
Prelude.Generic)
newUntagInstanceProfileResponse ::
UntagInstanceProfileResponse
newUntagInstanceProfileResponse :: UntagInstanceProfileResponse
newUntagInstanceProfileResponse =
UntagInstanceProfileResponse
UntagInstanceProfileResponse'
instance Prelude.NFData UntagInstanceProfileResponse