module Network.AWS.APIGateway.FlushStageCache
(
flushStageCache
, FlushStageCache
, fscRestAPIId
, fscStageName
, flushStageCacheResponse
, FlushStageCacheResponse
) 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 FlushStageCache = FlushStageCache'
{ _fscRestAPIId :: !Text
, _fscStageName :: !Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
flushStageCache
:: Text
-> Text
-> FlushStageCache
flushStageCache pRestAPIId_ pStageName_ =
FlushStageCache' {_fscRestAPIId = pRestAPIId_, _fscStageName = pStageName_}
fscRestAPIId :: Lens' FlushStageCache Text
fscRestAPIId = lens _fscRestAPIId (\ s a -> s{_fscRestAPIId = a});
fscStageName :: Lens' FlushStageCache Text
fscStageName = lens _fscStageName (\ s a -> s{_fscStageName = a});
instance AWSRequest FlushStageCache where
type Rs FlushStageCache = FlushStageCacheResponse
request = delete apiGateway
response = receiveNull FlushStageCacheResponse'
instance Hashable FlushStageCache where
instance NFData FlushStageCache where
instance ToHeaders FlushStageCache where
toHeaders
= const
(mconcat
["Accept" =# ("application/json" :: ByteString)])
instance ToPath FlushStageCache where
toPath FlushStageCache'{..}
= mconcat
["/restapis/", toBS _fscRestAPIId, "/stages/",
toBS _fscStageName, "/cache/data"]
instance ToQuery FlushStageCache where
toQuery = const mempty
data FlushStageCacheResponse =
FlushStageCacheResponse'
deriving (Eq, Read, Show, Data, Typeable, Generic)
flushStageCacheResponse
:: FlushStageCacheResponse
flushStageCacheResponse = FlushStageCacheResponse'
instance NFData FlushStageCacheResponse where