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