{-# 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.Autoscalers.Get
(
AutoscalersGetResource
, autoscalersGet
, AutoscalersGet
, agProject
, agZone
, agAutoscaler
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type AutoscalersGetResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"zones" :>
Capture "zone" Text :>
"autoscalers" :>
Capture "autoscaler" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Autoscaler
data AutoscalersGet = AutoscalersGet'
{ _agProject :: !Text
, _agZone :: !Text
, _agAutoscaler :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
autoscalersGet
:: Text
-> Text
-> Text
-> AutoscalersGet
autoscalersGet pAgProject_ pAgZone_ pAgAutoscaler_ =
AutoscalersGet'
{ _agProject = pAgProject_
, _agZone = pAgZone_
, _agAutoscaler = pAgAutoscaler_
}
agProject :: Lens' AutoscalersGet Text
agProject
= lens _agProject (\ s a -> s{_agProject = a})
agZone :: Lens' AutoscalersGet Text
agZone = lens _agZone (\ s a -> s{_agZone = a})
agAutoscaler :: Lens' AutoscalersGet Text
agAutoscaler
= lens _agAutoscaler (\ s a -> s{_agAutoscaler = a})
instance GoogleRequest AutoscalersGet where
type Rs AutoscalersGet = Autoscaler
type Scopes AutoscalersGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute",
"https://www.googleapis.com/auth/compute.readonly"]
requestClient AutoscalersGet'{..}
= go _agProject _agZone _agAutoscaler (Just AltJSON)
computeService
where go
= buildClient (Proxy :: Proxy AutoscalersGetResource)
mempty