{-# 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.Dataproc.Projects.Locations.WorkflowTemplates.SetIAMPolicy
(
ProjectsLocationsWorkflowTemplatesSetIAMPolicyResource
, projectsLocationsWorkflowTemplatesSetIAMPolicy
, ProjectsLocationsWorkflowTemplatesSetIAMPolicy
, plwtsipXgafv
, plwtsipUploadProtocol
, plwtsipAccessToken
, plwtsipUploadType
, plwtsipPayload
, plwtsipResource
, plwtsipCallback
) where
import Network.Google.Dataproc.Types
import Network.Google.Prelude
type ProjectsLocationsWorkflowTemplatesSetIAMPolicyResource
=
"v1" :>
CaptureMode "resource" "setIamPolicy" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] SetIAMPolicyRequest :>
Post '[JSON] Policy
data ProjectsLocationsWorkflowTemplatesSetIAMPolicy = ProjectsLocationsWorkflowTemplatesSetIAMPolicy'
{ _plwtsipXgafv :: !(Maybe Xgafv)
, _plwtsipUploadProtocol :: !(Maybe Text)
, _plwtsipAccessToken :: !(Maybe Text)
, _plwtsipUploadType :: !(Maybe Text)
, _plwtsipPayload :: !SetIAMPolicyRequest
, _plwtsipResource :: !Text
, _plwtsipCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsLocationsWorkflowTemplatesSetIAMPolicy
:: SetIAMPolicyRequest
-> Text
-> ProjectsLocationsWorkflowTemplatesSetIAMPolicy
projectsLocationsWorkflowTemplatesSetIAMPolicy pPlwtsipPayload_ pPlwtsipResource_ =
ProjectsLocationsWorkflowTemplatesSetIAMPolicy'
{ _plwtsipXgafv = Nothing
, _plwtsipUploadProtocol = Nothing
, _plwtsipAccessToken = Nothing
, _plwtsipUploadType = Nothing
, _plwtsipPayload = pPlwtsipPayload_
, _plwtsipResource = pPlwtsipResource_
, _plwtsipCallback = Nothing
}
plwtsipXgafv :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy (Maybe Xgafv)
plwtsipXgafv
= lens _plwtsipXgafv (\ s a -> s{_plwtsipXgafv = a})
plwtsipUploadProtocol :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy (Maybe Text)
plwtsipUploadProtocol
= lens _plwtsipUploadProtocol
(\ s a -> s{_plwtsipUploadProtocol = a})
plwtsipAccessToken :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy (Maybe Text)
plwtsipAccessToken
= lens _plwtsipAccessToken
(\ s a -> s{_plwtsipAccessToken = a})
plwtsipUploadType :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy (Maybe Text)
plwtsipUploadType
= lens _plwtsipUploadType
(\ s a -> s{_plwtsipUploadType = a})
plwtsipPayload :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy SetIAMPolicyRequest
plwtsipPayload
= lens _plwtsipPayload
(\ s a -> s{_plwtsipPayload = a})
plwtsipResource :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy Text
plwtsipResource
= lens _plwtsipResource
(\ s a -> s{_plwtsipResource = a})
plwtsipCallback :: Lens' ProjectsLocationsWorkflowTemplatesSetIAMPolicy (Maybe Text)
plwtsipCallback
= lens _plwtsipCallback
(\ s a -> s{_plwtsipCallback = a})
instance GoogleRequest
ProjectsLocationsWorkflowTemplatesSetIAMPolicy where
type Rs
ProjectsLocationsWorkflowTemplatesSetIAMPolicy
= Policy
type Scopes
ProjectsLocationsWorkflowTemplatesSetIAMPolicy
= '["https://www.googleapis.com/auth/cloud-platform"]
requestClient
ProjectsLocationsWorkflowTemplatesSetIAMPolicy'{..}
= go _plwtsipResource _plwtsipXgafv
_plwtsipUploadProtocol
_plwtsipAccessToken
_plwtsipUploadType
_plwtsipCallback
(Just AltJSON)
_plwtsipPayload
dataprocService
where go
= buildClient
(Proxy ::
Proxy
ProjectsLocationsWorkflowTemplatesSetIAMPolicyResource)
mempty