{-# 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.DeploymentManager.Resources.Get
(
ResourcesGetResource
, resourcesGet
, ResourcesGet
, rgProject
, rgResource
, rgDeployment
) where
import Network.Google.DeploymentManager.Types
import Network.Google.Prelude
type ResourcesGetResource =
"deploymentmanager" :>
"v2" :>
"projects" :>
Capture "project" Text :>
"global" :>
"deployments" :>
Capture "deployment" Text :>
"resources" :>
Capture "resource" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Resource
data ResourcesGet = ResourcesGet'
{ _rgProject :: !Text
, _rgResource :: !Text
, _rgDeployment :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
resourcesGet
:: Text
-> Text
-> Text
-> ResourcesGet
resourcesGet pRgProject_ pRgResource_ pRgDeployment_ =
ResourcesGet'
{ _rgProject = pRgProject_
, _rgResource = pRgResource_
, _rgDeployment = pRgDeployment_
}
rgProject :: Lens' ResourcesGet Text
rgProject
= lens _rgProject (\ s a -> s{_rgProject = a})
rgResource :: Lens' ResourcesGet Text
rgResource
= lens _rgResource (\ s a -> s{_rgResource = a})
rgDeployment :: Lens' ResourcesGet Text
rgDeployment
= lens _rgDeployment (\ s a -> s{_rgDeployment = a})
instance GoogleRequest ResourcesGet where
type Rs ResourcesGet = Resource
type Scopes ResourcesGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/cloud-platform.read-only",
"https://www.googleapis.com/auth/ndev.cloudman",
"https://www.googleapis.com/auth/ndev.cloudman.readonly"]
requestClient ResourcesGet'{..}
= go _rgProject _rgDeployment _rgResource
(Just AltJSON)
deploymentManagerService
where go
= buildClient (Proxy :: Proxy ResourcesGetResource)
mempty