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