{-# 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.Ml.Projects.Models.GetIAMPolicy
(
ProjectsModelsGetIAMPolicyResource
, projectsModelsGetIAMPolicy
, ProjectsModelsGetIAMPolicy
, pmgipXgafv
, pmgipUploadProtocol
, pmgipAccessToken
, pmgipUploadType
, pmgipResource
, pmgipCallback
) where
import Network.Google.MachineLearning.Types
import Network.Google.Prelude
type ProjectsModelsGetIAMPolicyResource =
"v1" :>
CaptureMode "resource" "getIamPolicy" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] GoogleIAMV1__Policy
data ProjectsModelsGetIAMPolicy = ProjectsModelsGetIAMPolicy'
{ _pmgipXgafv :: !(Maybe Xgafv)
, _pmgipUploadProtocol :: !(Maybe Text)
, _pmgipAccessToken :: !(Maybe Text)
, _pmgipUploadType :: !(Maybe Text)
, _pmgipResource :: !Text
, _pmgipCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsModelsGetIAMPolicy
:: Text
-> ProjectsModelsGetIAMPolicy
projectsModelsGetIAMPolicy pPmgipResource_ =
ProjectsModelsGetIAMPolicy'
{ _pmgipXgafv = Nothing
, _pmgipUploadProtocol = Nothing
, _pmgipAccessToken = Nothing
, _pmgipUploadType = Nothing
, _pmgipResource = pPmgipResource_
, _pmgipCallback = Nothing
}
pmgipXgafv :: Lens' ProjectsModelsGetIAMPolicy (Maybe Xgafv)
pmgipXgafv
= lens _pmgipXgafv (\ s a -> s{_pmgipXgafv = a})
pmgipUploadProtocol :: Lens' ProjectsModelsGetIAMPolicy (Maybe Text)
pmgipUploadProtocol
= lens _pmgipUploadProtocol
(\ s a -> s{_pmgipUploadProtocol = a})
pmgipAccessToken :: Lens' ProjectsModelsGetIAMPolicy (Maybe Text)
pmgipAccessToken
= lens _pmgipAccessToken
(\ s a -> s{_pmgipAccessToken = a})
pmgipUploadType :: Lens' ProjectsModelsGetIAMPolicy (Maybe Text)
pmgipUploadType
= lens _pmgipUploadType
(\ s a -> s{_pmgipUploadType = a})
pmgipResource :: Lens' ProjectsModelsGetIAMPolicy Text
pmgipResource
= lens _pmgipResource
(\ s a -> s{_pmgipResource = a})
pmgipCallback :: Lens' ProjectsModelsGetIAMPolicy (Maybe Text)
pmgipCallback
= lens _pmgipCallback
(\ s a -> s{_pmgipCallback = a})
instance GoogleRequest ProjectsModelsGetIAMPolicy
where
type Rs ProjectsModelsGetIAMPolicy =
GoogleIAMV1__Policy
type Scopes ProjectsModelsGetIAMPolicy =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient ProjectsModelsGetIAMPolicy'{..}
= go _pmgipResource _pmgipXgafv _pmgipUploadProtocol
_pmgipAccessToken
_pmgipUploadType
_pmgipCallback
(Just AltJSON)
machineLearningService
where go
= buildClient
(Proxy :: Proxy ProjectsModelsGetIAMPolicyResource)
mempty