{-# 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.IoT.DisableTopicRule
(
disableTopicRule
, DisableTopicRule
, dtrRuleName
, disableTopicRuleResponse
, DisableTopicRuleResponse
) where
import Network.AWS.IoT.Types
import Network.AWS.IoT.Types.Product
import Network.AWS.Lens
import Network.AWS.Prelude
import Network.AWS.Request
import Network.AWS.Response
newtype DisableTopicRule = DisableTopicRule'
{ _dtrRuleName :: Text
} deriving (Eq, Read, Show, Data, Typeable, Generic)
disableTopicRule
:: Text
-> DisableTopicRule
disableTopicRule pRuleName_ = DisableTopicRule' {_dtrRuleName = pRuleName_}
dtrRuleName :: Lens' DisableTopicRule Text
dtrRuleName = lens _dtrRuleName (\ s a -> s{_dtrRuleName = a})
instance AWSRequest DisableTopicRule where
type Rs DisableTopicRule = DisableTopicRuleResponse
request = postJSON ioT
response = receiveNull DisableTopicRuleResponse'
instance Hashable DisableTopicRule where
instance NFData DisableTopicRule where
instance ToHeaders DisableTopicRule where
toHeaders = const mempty
instance ToJSON DisableTopicRule where
toJSON = const (Object mempty)
instance ToPath DisableTopicRule where
toPath DisableTopicRule'{..}
= mconcat ["/rules/", toBS _dtrRuleName, "/disable"]
instance ToQuery DisableTopicRule where
toQuery = const mempty
data DisableTopicRuleResponse =
DisableTopicRuleResponse'
deriving (Eq, Read, Show, Data, Typeable, Generic)
disableTopicRuleResponse
:: DisableTopicRuleResponse
disableTopicRuleResponse = DisableTopicRuleResponse'
instance NFData DisableTopicRuleResponse where