{-# 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.UpdateIndexingConfiguration
(
updateIndexingConfiguration
, UpdateIndexingConfiguration
, uicThingIndexingConfiguration
, updateIndexingConfigurationResponse
, UpdateIndexingConfigurationResponse
, uicrsResponseStatus
) 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 UpdateIndexingConfiguration = UpdateIndexingConfiguration'
{ _uicThingIndexingConfiguration :: Maybe ThingIndexingConfiguration
} deriving (Eq, Read, Show, Data, Typeable, Generic)
updateIndexingConfiguration
:: UpdateIndexingConfiguration
updateIndexingConfiguration =
UpdateIndexingConfiguration' {_uicThingIndexingConfiguration = Nothing}
uicThingIndexingConfiguration :: Lens' UpdateIndexingConfiguration (Maybe ThingIndexingConfiguration)
uicThingIndexingConfiguration = lens _uicThingIndexingConfiguration (\ s a -> s{_uicThingIndexingConfiguration = a})
instance AWSRequest UpdateIndexingConfiguration where
type Rs UpdateIndexingConfiguration =
UpdateIndexingConfigurationResponse
request = postJSON ioT
response
= receiveEmpty
(\ s h x ->
UpdateIndexingConfigurationResponse' <$>
(pure (fromEnum s)))
instance Hashable UpdateIndexingConfiguration where
instance NFData UpdateIndexingConfiguration where
instance ToHeaders UpdateIndexingConfiguration where
toHeaders = const mempty
instance ToJSON UpdateIndexingConfiguration where
toJSON UpdateIndexingConfiguration'{..}
= object
(catMaybes
[("thingIndexingConfiguration" .=) <$>
_uicThingIndexingConfiguration])
instance ToPath UpdateIndexingConfiguration where
toPath = const "/indexing/config"
instance ToQuery UpdateIndexingConfiguration where
toQuery = const mempty
newtype UpdateIndexingConfigurationResponse = UpdateIndexingConfigurationResponse'
{ _uicrsResponseStatus :: Int
} deriving (Eq, Read, Show, Data, Typeable, Generic)
updateIndexingConfigurationResponse
:: Int
-> UpdateIndexingConfigurationResponse
updateIndexingConfigurationResponse pResponseStatus_ =
UpdateIndexingConfigurationResponse' {_uicrsResponseStatus = pResponseStatus_}
uicrsResponseStatus :: Lens' UpdateIndexingConfigurationResponse Int
uicrsResponseStatus = lens _uicrsResponseStatus (\ s a -> s{_uicrsResponseStatus = a})
instance NFData UpdateIndexingConfigurationResponse
where