{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-matches #-}
module Network.AWS.APIGateway.DeleteIntegration
(
deleteIntegration
, DeleteIntegration
, delRestAPIId
, delResourceId
, delHttpMethod
, deleteIntegrationResponse'
, DeleteIntegrationResponse'
) where
import Network.AWS.APIGateway.Types
import Network.AWS.APIGateway.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
data DeleteIntegration = DeleteIntegration'
{ _delRestAPIId :: !Text
, _delResourceId :: !Text
, _delHttpMethod :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
deleteIntegration
:: Text
-> Text
-> Text
-> DeleteIntegration
deleteIntegration pRestAPIId_ pResourceId_ pHttpMethod_ =
DeleteIntegration'
{ _delRestAPIId = pRestAPIId_
, _delResourceId = pResourceId_
, _delHttpMethod = pHttpMethod_
}
delRestAPIId :: Lens' DeleteIntegration Text
delRestAPIId = lens _delRestAPIId (\ s a -> s{_delRestAPIId = a})
delResourceId :: Lens' DeleteIntegration Text
delResourceId = lens _delResourceId (\ s a -> s{_delResourceId = a})
delHttpMethod :: Lens' DeleteIntegration Text
delHttpMethod = lens _delHttpMethod (\ s a -> s{_delHttpMethod = a})
instance AWSRequest DeleteIntegration where
type Rs DeleteIntegration =
DeleteIntegrationResponse'
request = delete apiGateway
response = receiveNull DeleteIntegrationResponse''
instance Hashable DeleteIntegration where
instance NFData DeleteIntegration where
instance ToHeaders DeleteIntegration where
toHeaders
= const
(mconcat
["Accept" =# ("application/json" :: ByteString)])
instance ToPath DeleteIntegration where
toPath DeleteIntegration'{..}
= mconcat
["/restapis/", toBS _delRestAPIId, "/resources/",
toBS _delResourceId, "/methods/",
toBS _delHttpMethod, "/integration"]
instance ToQuery DeleteIntegration where
toQuery = const mempty
data DeleteIntegrationResponse' =
DeleteIntegrationResponse''
deriving (Eq, Read, Show, Data, Typeable, Generic)
deleteIntegrationResponse'
:: DeleteIntegrationResponse'
deleteIntegrationResponse' = DeleteIntegrationResponse''
instance NFData DeleteIntegrationResponse' where