{-# 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.APIGateway.DeleteClientCertificate
(
DeleteClientCertificate (..),
newDeleteClientCertificate,
deleteClientCertificate_clientCertificateId,
DeleteClientCertificateResponse (..),
newDeleteClientCertificateResponse,
)
where
import Amazonka.APIGateway.Types
import qualified Amazonka.Core as Core
import qualified Amazonka.Core.Lens.Internal as Lens
import qualified Amazonka.Data as Data
import qualified Amazonka.Prelude as Prelude
import qualified Amazonka.Request as Request
import qualified Amazonka.Response as Response
data DeleteClientCertificate = DeleteClientCertificate'
{
DeleteClientCertificate -> Text
clientCertificateId :: Prelude.Text
}
deriving (DeleteClientCertificate -> DeleteClientCertificate -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteClientCertificate -> DeleteClientCertificate -> Bool
$c/= :: DeleteClientCertificate -> DeleteClientCertificate -> Bool
== :: DeleteClientCertificate -> DeleteClientCertificate -> Bool
$c== :: DeleteClientCertificate -> DeleteClientCertificate -> Bool
Prelude.Eq, ReadPrec [DeleteClientCertificate]
ReadPrec DeleteClientCertificate
Int -> ReadS DeleteClientCertificate
ReadS [DeleteClientCertificate]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteClientCertificate]
$creadListPrec :: ReadPrec [DeleteClientCertificate]
readPrec :: ReadPrec DeleteClientCertificate
$creadPrec :: ReadPrec DeleteClientCertificate
readList :: ReadS [DeleteClientCertificate]
$creadList :: ReadS [DeleteClientCertificate]
readsPrec :: Int -> ReadS DeleteClientCertificate
$creadsPrec :: Int -> ReadS DeleteClientCertificate
Prelude.Read, Int -> DeleteClientCertificate -> ShowS
[DeleteClientCertificate] -> ShowS
DeleteClientCertificate -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteClientCertificate] -> ShowS
$cshowList :: [DeleteClientCertificate] -> ShowS
show :: DeleteClientCertificate -> String
$cshow :: DeleteClientCertificate -> String
showsPrec :: Int -> DeleteClientCertificate -> ShowS
$cshowsPrec :: Int -> DeleteClientCertificate -> ShowS
Prelude.Show, forall x. Rep DeleteClientCertificate x -> DeleteClientCertificate
forall x. DeleteClientCertificate -> Rep DeleteClientCertificate x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteClientCertificate x -> DeleteClientCertificate
$cfrom :: forall x. DeleteClientCertificate -> Rep DeleteClientCertificate x
Prelude.Generic)
newDeleteClientCertificate ::
Prelude.Text ->
DeleteClientCertificate
newDeleteClientCertificate :: Text -> DeleteClientCertificate
newDeleteClientCertificate Text
pClientCertificateId_ =
DeleteClientCertificate'
{ $sel:clientCertificateId:DeleteClientCertificate' :: Text
clientCertificateId =
Text
pClientCertificateId_
}
deleteClientCertificate_clientCertificateId :: Lens.Lens' DeleteClientCertificate Prelude.Text
deleteClientCertificate_clientCertificateId :: Lens' DeleteClientCertificate Text
deleteClientCertificate_clientCertificateId = forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteClientCertificate' {Text
clientCertificateId :: Text
$sel:clientCertificateId:DeleteClientCertificate' :: DeleteClientCertificate -> Text
clientCertificateId} -> Text
clientCertificateId) (\s :: DeleteClientCertificate
s@DeleteClientCertificate' {} Text
a -> DeleteClientCertificate
s {$sel:clientCertificateId:DeleteClientCertificate' :: Text
clientCertificateId = Text
a} :: DeleteClientCertificate)
instance Core.AWSRequest DeleteClientCertificate where
type
AWSResponse DeleteClientCertificate =
DeleteClientCertificateResponse
request :: (Service -> Service)
-> DeleteClientCertificate -> Request DeleteClientCertificate
request Service -> Service
overrides =
forall a. ToRequest a => Service -> a -> Request a
Request.delete (Service -> Service
overrides Service
defaultService)
response :: forall (m :: * -> *).
MonadResource m =>
(ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy DeleteClientCertificate
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteClientCertificate)))
response =
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull
DeleteClientCertificateResponse
DeleteClientCertificateResponse'
instance Prelude.Hashable DeleteClientCertificate where
hashWithSalt :: Int -> DeleteClientCertificate -> Int
hashWithSalt Int
_salt DeleteClientCertificate' {Text
clientCertificateId :: Text
$sel:clientCertificateId:DeleteClientCertificate' :: DeleteClientCertificate -> Text
..} =
Int
_salt forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
clientCertificateId
instance Prelude.NFData DeleteClientCertificate where
rnf :: DeleteClientCertificate -> ()
rnf DeleteClientCertificate' {Text
clientCertificateId :: Text
$sel:clientCertificateId:DeleteClientCertificate' :: DeleteClientCertificate -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
clientCertificateId
instance Data.ToHeaders DeleteClientCertificate where
toHeaders :: DeleteClientCertificate -> [Header]
toHeaders =
forall a b. a -> b -> a
Prelude.const
( forall a. Monoid a => [a] -> a
Prelude.mconcat
[ HeaderName
"Accept"
forall a. ToHeader a => HeaderName -> a -> [Header]
Data.=# (ByteString
"application/json" :: Prelude.ByteString)
]
)
instance Data.ToPath DeleteClientCertificate where
toPath :: DeleteClientCertificate -> ByteString
toPath DeleteClientCertificate' {Text
clientCertificateId :: Text
$sel:clientCertificateId:DeleteClientCertificate' :: DeleteClientCertificate -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/clientcertificates/",
forall a. ToByteString a => a -> ByteString
Data.toBS Text
clientCertificateId
]
instance Data.ToQuery DeleteClientCertificate where
toQuery :: DeleteClientCertificate -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data DeleteClientCertificateResponse = DeleteClientCertificateResponse'
{
}
deriving (DeleteClientCertificateResponse
-> DeleteClientCertificateResponse -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteClientCertificateResponse
-> DeleteClientCertificateResponse -> Bool
$c/= :: DeleteClientCertificateResponse
-> DeleteClientCertificateResponse -> Bool
== :: DeleteClientCertificateResponse
-> DeleteClientCertificateResponse -> Bool
$c== :: DeleteClientCertificateResponse
-> DeleteClientCertificateResponse -> Bool
Prelude.Eq, ReadPrec [DeleteClientCertificateResponse]
ReadPrec DeleteClientCertificateResponse
Int -> ReadS DeleteClientCertificateResponse
ReadS [DeleteClientCertificateResponse]
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteClientCertificateResponse]
$creadListPrec :: ReadPrec [DeleteClientCertificateResponse]
readPrec :: ReadPrec DeleteClientCertificateResponse
$creadPrec :: ReadPrec DeleteClientCertificateResponse
readList :: ReadS [DeleteClientCertificateResponse]
$creadList :: ReadS [DeleteClientCertificateResponse]
readsPrec :: Int -> ReadS DeleteClientCertificateResponse
$creadsPrec :: Int -> ReadS DeleteClientCertificateResponse
Prelude.Read, Int -> DeleteClientCertificateResponse -> ShowS
[DeleteClientCertificateResponse] -> ShowS
DeleteClientCertificateResponse -> String
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteClientCertificateResponse] -> ShowS
$cshowList :: [DeleteClientCertificateResponse] -> ShowS
show :: DeleteClientCertificateResponse -> String
$cshow :: DeleteClientCertificateResponse -> String
showsPrec :: Int -> DeleteClientCertificateResponse -> ShowS
$cshowsPrec :: Int -> DeleteClientCertificateResponse -> ShowS
Prelude.Show, forall x.
Rep DeleteClientCertificateResponse x
-> DeleteClientCertificateResponse
forall x.
DeleteClientCertificateResponse
-> Rep DeleteClientCertificateResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteClientCertificateResponse x
-> DeleteClientCertificateResponse
$cfrom :: forall x.
DeleteClientCertificateResponse
-> Rep DeleteClientCertificateResponse x
Prelude.Generic)
newDeleteClientCertificateResponse ::
DeleteClientCertificateResponse
newDeleteClientCertificateResponse :: DeleteClientCertificateResponse
newDeleteClientCertificateResponse =
DeleteClientCertificateResponse
DeleteClientCertificateResponse'
instance
Prelude.NFData
DeleteClientCertificateResponse
where
rnf :: DeleteClientCertificateResponse -> ()
rnf DeleteClientCertificateResponse
_ = ()