{-# 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.Chime.DeleteProxySession
(
DeleteProxySession (..),
newDeleteProxySession,
deleteProxySession_voiceConnectorId,
deleteProxySession_proxySessionId,
DeleteProxySessionResponse (..),
newDeleteProxySessionResponse,
)
where
import Amazonka.Chime.Types
import qualified Amazonka.Core as Core
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 DeleteProxySession = DeleteProxySession'
{
DeleteProxySession -> Text
voiceConnectorId :: Prelude.Text,
DeleteProxySession -> Text
proxySessionId :: Prelude.Text
}
deriving (DeleteProxySession -> DeleteProxySession -> Bool
(DeleteProxySession -> DeleteProxySession -> Bool)
-> (DeleteProxySession -> DeleteProxySession -> Bool)
-> Eq DeleteProxySession
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteProxySession -> DeleteProxySession -> Bool
$c/= :: DeleteProxySession -> DeleteProxySession -> Bool
== :: DeleteProxySession -> DeleteProxySession -> Bool
$c== :: DeleteProxySession -> DeleteProxySession -> Bool
Prelude.Eq, ReadPrec [DeleteProxySession]
ReadPrec DeleteProxySession
Int -> ReadS DeleteProxySession
ReadS [DeleteProxySession]
(Int -> ReadS DeleteProxySession)
-> ReadS [DeleteProxySession]
-> ReadPrec DeleteProxySession
-> ReadPrec [DeleteProxySession]
-> Read DeleteProxySession
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteProxySession]
$creadListPrec :: ReadPrec [DeleteProxySession]
readPrec :: ReadPrec DeleteProxySession
$creadPrec :: ReadPrec DeleteProxySession
readList :: ReadS [DeleteProxySession]
$creadList :: ReadS [DeleteProxySession]
readsPrec :: Int -> ReadS DeleteProxySession
$creadsPrec :: Int -> ReadS DeleteProxySession
Prelude.Read, Int -> DeleteProxySession -> ShowS
[DeleteProxySession] -> ShowS
DeleteProxySession -> String
(Int -> DeleteProxySession -> ShowS)
-> (DeleteProxySession -> String)
-> ([DeleteProxySession] -> ShowS)
-> Show DeleteProxySession
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteProxySession] -> ShowS
$cshowList :: [DeleteProxySession] -> ShowS
show :: DeleteProxySession -> String
$cshow :: DeleteProxySession -> String
showsPrec :: Int -> DeleteProxySession -> ShowS
$cshowsPrec :: Int -> DeleteProxySession -> ShowS
Prelude.Show, (forall x. DeleteProxySession -> Rep DeleteProxySession x)
-> (forall x. Rep DeleteProxySession x -> DeleteProxySession)
-> Generic DeleteProxySession
forall x. Rep DeleteProxySession x -> DeleteProxySession
forall x. DeleteProxySession -> Rep DeleteProxySession x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x. Rep DeleteProxySession x -> DeleteProxySession
$cfrom :: forall x. DeleteProxySession -> Rep DeleteProxySession x
Prelude.Generic)
newDeleteProxySession ::
Prelude.Text ->
Prelude.Text ->
DeleteProxySession
newDeleteProxySession :: Text -> Text -> DeleteProxySession
newDeleteProxySession
Text
pVoiceConnectorId_
Text
pProxySessionId_ =
DeleteProxySession' :: Text -> Text -> DeleteProxySession
DeleteProxySession'
{ $sel:voiceConnectorId:DeleteProxySession' :: Text
voiceConnectorId =
Text
pVoiceConnectorId_,
$sel:proxySessionId:DeleteProxySession' :: Text
proxySessionId = Text
pProxySessionId_
}
deleteProxySession_voiceConnectorId :: Lens.Lens' DeleteProxySession Prelude.Text
deleteProxySession_voiceConnectorId :: (Text -> f Text) -> DeleteProxySession -> f DeleteProxySession
deleteProxySession_voiceConnectorId = (DeleteProxySession -> Text)
-> (DeleteProxySession -> Text -> DeleteProxySession)
-> Lens DeleteProxySession DeleteProxySession Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteProxySession' {Text
voiceConnectorId :: Text
$sel:voiceConnectorId:DeleteProxySession' :: DeleteProxySession -> Text
voiceConnectorId} -> Text
voiceConnectorId) (\s :: DeleteProxySession
s@DeleteProxySession' {} Text
a -> DeleteProxySession
s {$sel:voiceConnectorId:DeleteProxySession' :: Text
voiceConnectorId = Text
a} :: DeleteProxySession)
deleteProxySession_proxySessionId :: Lens.Lens' DeleteProxySession Prelude.Text
deleteProxySession_proxySessionId :: (Text -> f Text) -> DeleteProxySession -> f DeleteProxySession
deleteProxySession_proxySessionId = (DeleteProxySession -> Text)
-> (DeleteProxySession -> Text -> DeleteProxySession)
-> Lens DeleteProxySession DeleteProxySession Text Text
forall s a b t. (s -> a) -> (s -> b -> t) -> Lens s t a b
Lens.lens (\DeleteProxySession' {Text
proxySessionId :: Text
$sel:proxySessionId:DeleteProxySession' :: DeleteProxySession -> Text
proxySessionId} -> Text
proxySessionId) (\s :: DeleteProxySession
s@DeleteProxySession' {} Text
a -> DeleteProxySession
s {$sel:proxySessionId:DeleteProxySession' :: Text
proxySessionId = Text
a} :: DeleteProxySession)
instance Core.AWSRequest DeleteProxySession where
type
AWSResponse DeleteProxySession =
DeleteProxySessionResponse
request :: DeleteProxySession -> Request DeleteProxySession
request = Service -> DeleteProxySession -> Request DeleteProxySession
forall a. ToRequest a => Service -> a -> Request a
Request.delete Service
defaultService
response :: Logger
-> Service
-> Proxy DeleteProxySession
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteProxySession)))
response =
AWSResponse DeleteProxySession
-> Logger
-> Service
-> Proxy DeleteProxySession
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteProxySession)))
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> Logger
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull AWSResponse DeleteProxySession
DeleteProxySessionResponse
DeleteProxySessionResponse'
instance Prelude.Hashable DeleteProxySession
instance Prelude.NFData DeleteProxySession
instance Core.ToHeaders DeleteProxySession where
toHeaders :: DeleteProxySession -> [Header]
toHeaders = [Header] -> DeleteProxySession -> [Header]
forall a b. a -> b -> a
Prelude.const [Header]
forall a. Monoid a => a
Prelude.mempty
instance Core.ToPath DeleteProxySession where
toPath :: DeleteProxySession -> ByteString
toPath DeleteProxySession' {Text
proxySessionId :: Text
voiceConnectorId :: Text
$sel:proxySessionId:DeleteProxySession' :: DeleteProxySession -> Text
$sel:voiceConnectorId:DeleteProxySession' :: DeleteProxySession -> Text
..} =
[ByteString] -> ByteString
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/voice-connectors/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
voiceConnectorId,
ByteString
"/proxy-sessions/",
Text -> ByteString
forall a. ToByteString a => a -> ByteString
Core.toBS Text
proxySessionId
]
instance Core.ToQuery DeleteProxySession where
toQuery :: DeleteProxySession -> QueryString
toQuery = QueryString -> DeleteProxySession -> QueryString
forall a b. a -> b -> a
Prelude.const QueryString
forall a. Monoid a => a
Prelude.mempty
data DeleteProxySessionResponse = DeleteProxySessionResponse'
{
}
deriving (DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool
(DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool)
-> (DeleteProxySessionResponse
-> DeleteProxySessionResponse -> Bool)
-> Eq DeleteProxySessionResponse
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool
$c/= :: DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool
== :: DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool
$c== :: DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool
Prelude.Eq, ReadPrec [DeleteProxySessionResponse]
ReadPrec DeleteProxySessionResponse
Int -> ReadS DeleteProxySessionResponse
ReadS [DeleteProxySessionResponse]
(Int -> ReadS DeleteProxySessionResponse)
-> ReadS [DeleteProxySessionResponse]
-> ReadPrec DeleteProxySessionResponse
-> ReadPrec [DeleteProxySessionResponse]
-> Read DeleteProxySessionResponse
forall a.
(Int -> ReadS a)
-> ReadS [a] -> ReadPrec a -> ReadPrec [a] -> Read a
readListPrec :: ReadPrec [DeleteProxySessionResponse]
$creadListPrec :: ReadPrec [DeleteProxySessionResponse]
readPrec :: ReadPrec DeleteProxySessionResponse
$creadPrec :: ReadPrec DeleteProxySessionResponse
readList :: ReadS [DeleteProxySessionResponse]
$creadList :: ReadS [DeleteProxySessionResponse]
readsPrec :: Int -> ReadS DeleteProxySessionResponse
$creadsPrec :: Int -> ReadS DeleteProxySessionResponse
Prelude.Read, Int -> DeleteProxySessionResponse -> ShowS
[DeleteProxySessionResponse] -> ShowS
DeleteProxySessionResponse -> String
(Int -> DeleteProxySessionResponse -> ShowS)
-> (DeleteProxySessionResponse -> String)
-> ([DeleteProxySessionResponse] -> ShowS)
-> Show DeleteProxySessionResponse
forall a.
(Int -> a -> ShowS) -> (a -> String) -> ([a] -> ShowS) -> Show a
showList :: [DeleteProxySessionResponse] -> ShowS
$cshowList :: [DeleteProxySessionResponse] -> ShowS
show :: DeleteProxySessionResponse -> String
$cshow :: DeleteProxySessionResponse -> String
showsPrec :: Int -> DeleteProxySessionResponse -> ShowS
$cshowsPrec :: Int -> DeleteProxySessionResponse -> ShowS
Prelude.Show, (forall x.
DeleteProxySessionResponse -> Rep DeleteProxySessionResponse x)
-> (forall x.
Rep DeleteProxySessionResponse x -> DeleteProxySessionResponse)
-> Generic DeleteProxySessionResponse
forall x.
Rep DeleteProxySessionResponse x -> DeleteProxySessionResponse
forall x.
DeleteProxySessionResponse -> Rep DeleteProxySessionResponse x
forall a.
(forall x. a -> Rep a x) -> (forall x. Rep a x -> a) -> Generic a
$cto :: forall x.
Rep DeleteProxySessionResponse x -> DeleteProxySessionResponse
$cfrom :: forall x.
DeleteProxySessionResponse -> Rep DeleteProxySessionResponse x
Prelude.Generic)
newDeleteProxySessionResponse ::
DeleteProxySessionResponse
newDeleteProxySessionResponse :: DeleteProxySessionResponse
newDeleteProxySessionResponse =
DeleteProxySessionResponse
DeleteProxySessionResponse'
instance Prelude.NFData DeleteProxySessionResponse