{-# 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.ChimeSdkVoice.DeleteProxySession
(
DeleteProxySession (..),
newDeleteProxySession,
deleteProxySession_voiceConnectorId,
deleteProxySession_proxySessionId,
DeleteProxySessionResponse (..),
newDeleteProxySessionResponse,
)
where
import Amazonka.ChimeSdkVoice.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 DeleteProxySession = DeleteProxySession'
{ DeleteProxySession -> Text
voiceConnectorId :: Prelude.Text,
DeleteProxySession -> Text
proxySessionId :: Prelude.Text
}
deriving (DeleteProxySession -> DeleteProxySession -> Bool
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]
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
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. 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'
{ $sel:voiceConnectorId:DeleteProxySession' :: Text
voiceConnectorId =
Text
pVoiceConnectorId_,
$sel:proxySessionId:DeleteProxySession' :: Text
proxySessionId = Text
pProxySessionId_
}
deleteProxySession_voiceConnectorId :: Lens.Lens' DeleteProxySession Prelude.Text
deleteProxySession_voiceConnectorId :: Lens' DeleteProxySession Text
deleteProxySession_voiceConnectorId = 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 :: Lens' DeleteProxySession Text
deleteProxySession_proxySessionId = 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 :: (Service -> Service)
-> DeleteProxySession -> Request DeleteProxySession
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 DeleteProxySession
-> ClientResponse ClientBody
-> m (Either
Error (ClientResponse (AWSResponse DeleteProxySession)))
response =
forall (m :: * -> *) a.
MonadResource m =>
AWSResponse a
-> (ByteStringLazy -> IO ByteStringLazy)
-> Service
-> Proxy a
-> ClientResponse ClientBody
-> m (Either Error (ClientResponse (AWSResponse a)))
Response.receiveNull DeleteProxySessionResponse
DeleteProxySessionResponse'
instance Prelude.Hashable DeleteProxySession where
hashWithSalt :: Int -> DeleteProxySession -> Int
hashWithSalt Int
_salt DeleteProxySession' {Text
proxySessionId :: Text
voiceConnectorId :: Text
$sel:proxySessionId:DeleteProxySession' :: DeleteProxySession -> Text
$sel:voiceConnectorId:DeleteProxySession' :: DeleteProxySession -> Text
..} =
Int
_salt
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
voiceConnectorId
forall a. Hashable a => Int -> a -> Int
`Prelude.hashWithSalt` Text
proxySessionId
instance Prelude.NFData DeleteProxySession where
rnf :: DeleteProxySession -> ()
rnf DeleteProxySession' {Text
proxySessionId :: Text
voiceConnectorId :: Text
$sel:proxySessionId:DeleteProxySession' :: DeleteProxySession -> Text
$sel:voiceConnectorId:DeleteProxySession' :: DeleteProxySession -> Text
..} =
forall a. NFData a => a -> ()
Prelude.rnf Text
voiceConnectorId
seq :: forall a b. a -> b -> b
`Prelude.seq` forall a. NFData a => a -> ()
Prelude.rnf Text
proxySessionId
instance Data.ToHeaders DeleteProxySession where
toHeaders :: DeleteProxySession -> [Header]
toHeaders = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
instance Data.ToPath DeleteProxySession where
toPath :: DeleteProxySession -> ByteString
toPath DeleteProxySession' {Text
proxySessionId :: Text
voiceConnectorId :: Text
$sel:proxySessionId:DeleteProxySession' :: DeleteProxySession -> Text
$sel:voiceConnectorId:DeleteProxySession' :: DeleteProxySession -> Text
..} =
forall a. Monoid a => [a] -> a
Prelude.mconcat
[ ByteString
"/voice-connectors/",
forall a. ToByteString a => a -> ByteString
Data.toBS Text
voiceConnectorId,
ByteString
"/proxy-sessions/",
forall a. ToByteString a => a -> ByteString
Data.toBS Text
proxySessionId
]
instance Data.ToQuery DeleteProxySession where
toQuery :: DeleteProxySession -> QueryString
toQuery = forall a b. a -> b -> a
Prelude.const forall a. Monoid a => a
Prelude.mempty
data DeleteProxySessionResponse = DeleteProxySessionResponse'
{
}
deriving (DeleteProxySessionResponse -> DeleteProxySessionResponse -> Bool
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]
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
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.
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 where
rnf :: DeleteProxySessionResponse -> ()
rnf DeleteProxySessionResponse
_ = ()