{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.Google.Resource.Compute.RegionAutoscalers.Get
(
RegionAutoscalersGetResource
, regionAutoscalersGet
, RegionAutoscalersGet
, ragProject
, ragAutoscaler
, ragRegion
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type RegionAutoscalersGetResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"regions" :>
Capture "region" Text :>
"autoscalers" :>
Capture "autoscaler" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Autoscaler
data RegionAutoscalersGet = RegionAutoscalersGet'
{ _ragProject :: !Text
, _ragAutoscaler :: !Text
, _ragRegion :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
regionAutoscalersGet
:: Text
-> Text
-> Text
-> RegionAutoscalersGet
regionAutoscalersGet pRagProject_ pRagAutoscaler_ pRagRegion_ =
RegionAutoscalersGet'
{ _ragProject = pRagProject_
, _ragAutoscaler = pRagAutoscaler_
, _ragRegion = pRagRegion_
}
ragProject :: Lens' RegionAutoscalersGet Text
ragProject
= lens _ragProject (\ s a -> s{_ragProject = a})
ragAutoscaler :: Lens' RegionAutoscalersGet Text
ragAutoscaler
= lens _ragAutoscaler
(\ s a -> s{_ragAutoscaler = a})
ragRegion :: Lens' RegionAutoscalersGet Text
ragRegion
= lens _ragRegion (\ s a -> s{_ragRegion = a})
instance GoogleRequest RegionAutoscalersGet where
type Rs RegionAutoscalersGet = Autoscaler
type Scopes RegionAutoscalersGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute",
"https://www.googleapis.com/auth/compute.readonly"]
requestClient RegionAutoscalersGet'{..}
= go _ragProject _ragRegion _ragAutoscaler
(Just AltJSON)
computeService
where go
= buildClient
(Proxy :: Proxy RegionAutoscalersGetResource)
mempty