module Network.AWS.IAM.ListSAMLProviders
(
ListSAMLProviders
, listSAMLProviders
, ListSAMLProvidersResponse
, listSAMLProvidersResponse
, lsamlprSAMLProviderList
) where
import Network.AWS.Prelude
import Network.AWS.Request.Query
import Network.AWS.IAM.Types
import qualified GHC.Exts
data ListSAMLProviders = ListSAMLProviders
deriving (Eq, Ord, Read, Show, Generic)
listSAMLProviders :: ListSAMLProviders
listSAMLProviders = ListSAMLProviders
newtype ListSAMLProvidersResponse = ListSAMLProvidersResponse
{ _lsamlprSAMLProviderList :: List "member" SAMLProviderListEntry
} deriving (Eq, Read, Show, Monoid, Semigroup)
instance GHC.Exts.IsList ListSAMLProvidersResponse where
type Item ListSAMLProvidersResponse = SAMLProviderListEntry
fromList = ListSAMLProvidersResponse . GHC.Exts.fromList
toList = GHC.Exts.toList . _lsamlprSAMLProviderList
listSAMLProvidersResponse :: ListSAMLProvidersResponse
listSAMLProvidersResponse = ListSAMLProvidersResponse
{ _lsamlprSAMLProviderList = mempty
}
lsamlprSAMLProviderList :: Lens' ListSAMLProvidersResponse [SAMLProviderListEntry]
lsamlprSAMLProviderList =
lens _lsamlprSAMLProviderList (\s a -> s { _lsamlprSAMLProviderList = a })
. _List
instance ToPath ListSAMLProviders where
toPath = const "/"
instance ToQuery ListSAMLProviders where
toQuery = const mempty
instance ToHeaders ListSAMLProviders
instance AWSRequest ListSAMLProviders where
type Sv ListSAMLProviders = IAM
type Rs ListSAMLProviders = ListSAMLProvidersResponse
request = post "ListSAMLProviders"
response = xmlResponse
instance FromXML ListSAMLProvidersResponse where
parseXML = withElement "ListSAMLProvidersResult" $ \x -> ListSAMLProvidersResponse
<$> x .@? "SAMLProviderList" .!@ mempty