{-# 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.BackendBuckets.Get
(
BackendBucketsGetResource
, backendBucketsGet
, BackendBucketsGet
, bbgBackendBucket
, bbgProject
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type BackendBucketsGetResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"global" :>
"backendBuckets" :>
Capture "backendBucket" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] BackendBucket
data BackendBucketsGet = BackendBucketsGet'
{ _bbgBackendBucket :: !Text
, _bbgProject :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
backendBucketsGet
:: Text
-> Text
-> BackendBucketsGet
backendBucketsGet pBbgBackendBucket_ pBbgProject_ =
BackendBucketsGet'
{ _bbgBackendBucket = pBbgBackendBucket_
, _bbgProject = pBbgProject_
}
bbgBackendBucket :: Lens' BackendBucketsGet Text
bbgBackendBucket
= lens _bbgBackendBucket
(\ s a -> s{_bbgBackendBucket = a})
bbgProject :: Lens' BackendBucketsGet Text
bbgProject
= lens _bbgProject (\ s a -> s{_bbgProject = a})
instance GoogleRequest BackendBucketsGet where
type Rs BackendBucketsGet = BackendBucket
type Scopes BackendBucketsGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute",
"https://www.googleapis.com/auth/compute.readonly"]
requestClient BackendBucketsGet'{..}
= go _bbgProject _bbgBackendBucket (Just AltJSON)
computeService
where go
= buildClient
(Proxy :: Proxy BackendBucketsGetResource)
mempty