{-# 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.GetIndexingConfiguration
(
getIndexingConfiguration
, GetIndexingConfiguration
, getIndexingConfigurationResponse
, GetIndexingConfigurationResponse
, gicrsThingIndexingConfiguration
, gicrsResponseStatus
) 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
data GetIndexingConfiguration =
GetIndexingConfiguration'
deriving (Eq, Read, Show, Data, Typeable, Generic)
getIndexingConfiguration
:: GetIndexingConfiguration
getIndexingConfiguration = GetIndexingConfiguration'
instance AWSRequest GetIndexingConfiguration where
type Rs GetIndexingConfiguration =
GetIndexingConfigurationResponse
request = get ioT
response
= receiveJSON
(\ s h x ->
GetIndexingConfigurationResponse' <$>
(x .?> "thingIndexingConfiguration") <*>
(pure (fromEnum s)))
instance Hashable GetIndexingConfiguration where
instance NFData GetIndexingConfiguration where
instance ToHeaders GetIndexingConfiguration where
toHeaders = const mempty
instance ToPath GetIndexingConfiguration where
toPath = const "/indexing/config"
instance ToQuery GetIndexingConfiguration where
toQuery = const mempty
data GetIndexingConfigurationResponse = GetIndexingConfigurationResponse'
{ _gicrsThingIndexingConfiguration :: !(Maybe ThingIndexingConfiguration)
, _gicrsResponseStatus :: !Int
} deriving (Eq, Read, Show, Data, Typeable, Generic)
getIndexingConfigurationResponse
:: Int
-> GetIndexingConfigurationResponse
getIndexingConfigurationResponse pResponseStatus_ =
GetIndexingConfigurationResponse'
{ _gicrsThingIndexingConfiguration = Nothing
, _gicrsResponseStatus = pResponseStatus_
}
gicrsThingIndexingConfiguration :: Lens' GetIndexingConfigurationResponse (Maybe ThingIndexingConfiguration)
gicrsThingIndexingConfiguration = lens _gicrsThingIndexingConfiguration (\ s a -> s{_gicrsThingIndexingConfiguration = a})
gicrsResponseStatus :: Lens' GetIndexingConfigurationResponse Int
gicrsResponseStatus = lens _gicrsResponseStatus (\ s a -> s{_gicrsResponseStatus = a})
instance NFData GetIndexingConfigurationResponse
where