{-# 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.AccessContextManager.AccessPolicies.Get
(
AccessPoliciesGetResource
, accessPoliciesGet
, AccessPoliciesGet
, apgXgafv
, apgUploadProtocol
, apgAccessToken
, apgUploadType
, apgName
, apgCallback
) where
import Network.Google.AccessContextManager.Types
import Network.Google.Prelude
type AccessPoliciesGetResource =
"v1beta" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] AccessPolicy
data AccessPoliciesGet = AccessPoliciesGet'
{ _apgXgafv :: !(Maybe Xgafv)
, _apgUploadProtocol :: !(Maybe Text)
, _apgAccessToken :: !(Maybe Text)
, _apgUploadType :: !(Maybe Text)
, _apgName :: !Text
, _apgCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
accessPoliciesGet
:: Text
-> AccessPoliciesGet
accessPoliciesGet pApgName_ =
AccessPoliciesGet'
{ _apgXgafv = Nothing
, _apgUploadProtocol = Nothing
, _apgAccessToken = Nothing
, _apgUploadType = Nothing
, _apgName = pApgName_
, _apgCallback = Nothing
}
apgXgafv :: Lens' AccessPoliciesGet (Maybe Xgafv)
apgXgafv = lens _apgXgafv (\ s a -> s{_apgXgafv = a})
apgUploadProtocol :: Lens' AccessPoliciesGet (Maybe Text)
apgUploadProtocol
= lens _apgUploadProtocol
(\ s a -> s{_apgUploadProtocol = a})
apgAccessToken :: Lens' AccessPoliciesGet (Maybe Text)
apgAccessToken
= lens _apgAccessToken
(\ s a -> s{_apgAccessToken = a})
apgUploadType :: Lens' AccessPoliciesGet (Maybe Text)
apgUploadType
= lens _apgUploadType
(\ s a -> s{_apgUploadType = a})
apgName :: Lens' AccessPoliciesGet Text
apgName = lens _apgName (\ s a -> s{_apgName = a})
apgCallback :: Lens' AccessPoliciesGet (Maybe Text)
apgCallback
= lens _apgCallback (\ s a -> s{_apgCallback = a})
instance GoogleRequest AccessPoliciesGet where
type Rs AccessPoliciesGet = AccessPolicy
type Scopes AccessPoliciesGet =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient AccessPoliciesGet'{..}
= go _apgName _apgXgafv _apgUploadProtocol
_apgAccessToken
_apgUploadType
_apgCallback
(Just AltJSON)
accessContextManagerService
where go
= buildClient
(Proxy :: Proxy AccessPoliciesGetResource)
mempty