{-# 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.DLP.Projects.JobTriggers.Patch
(
ProjectsJobTriggersPatchResource
, projectsJobTriggersPatch
, ProjectsJobTriggersPatch
, pjtpXgafv
, pjtpUploadProtocol
, pjtpAccessToken
, pjtpUploadType
, pjtpPayload
, pjtpName
, pjtpCallback
) where
import Network.Google.DLP.Types
import Network.Google.Prelude
type ProjectsJobTriggersPatchResource =
"v2" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON]
GooglePrivacyDlpV2UpdateJobTriggerRequest
:> Patch '[JSON] GooglePrivacyDlpV2JobTrigger
data ProjectsJobTriggersPatch = ProjectsJobTriggersPatch'
{ _pjtpXgafv :: !(Maybe Xgafv)
, _pjtpUploadProtocol :: !(Maybe Text)
, _pjtpAccessToken :: !(Maybe Text)
, _pjtpUploadType :: !(Maybe Text)
, _pjtpPayload :: !GooglePrivacyDlpV2UpdateJobTriggerRequest
, _pjtpName :: !Text
, _pjtpCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsJobTriggersPatch
:: GooglePrivacyDlpV2UpdateJobTriggerRequest
-> Text
-> ProjectsJobTriggersPatch
projectsJobTriggersPatch pPjtpPayload_ pPjtpName_ =
ProjectsJobTriggersPatch'
{ _pjtpXgafv = Nothing
, _pjtpUploadProtocol = Nothing
, _pjtpAccessToken = Nothing
, _pjtpUploadType = Nothing
, _pjtpPayload = pPjtpPayload_
, _pjtpName = pPjtpName_
, _pjtpCallback = Nothing
}
pjtpXgafv :: Lens' ProjectsJobTriggersPatch (Maybe Xgafv)
pjtpXgafv
= lens _pjtpXgafv (\ s a -> s{_pjtpXgafv = a})
pjtpUploadProtocol :: Lens' ProjectsJobTriggersPatch (Maybe Text)
pjtpUploadProtocol
= lens _pjtpUploadProtocol
(\ s a -> s{_pjtpUploadProtocol = a})
pjtpAccessToken :: Lens' ProjectsJobTriggersPatch (Maybe Text)
pjtpAccessToken
= lens _pjtpAccessToken
(\ s a -> s{_pjtpAccessToken = a})
pjtpUploadType :: Lens' ProjectsJobTriggersPatch (Maybe Text)
pjtpUploadType
= lens _pjtpUploadType
(\ s a -> s{_pjtpUploadType = a})
pjtpPayload :: Lens' ProjectsJobTriggersPatch GooglePrivacyDlpV2UpdateJobTriggerRequest
pjtpPayload
= lens _pjtpPayload (\ s a -> s{_pjtpPayload = a})
pjtpName :: Lens' ProjectsJobTriggersPatch Text
pjtpName = lens _pjtpName (\ s a -> s{_pjtpName = a})
pjtpCallback :: Lens' ProjectsJobTriggersPatch (Maybe Text)
pjtpCallback
= lens _pjtpCallback (\ s a -> s{_pjtpCallback = a})
instance GoogleRequest ProjectsJobTriggersPatch where
type Rs ProjectsJobTriggersPatch =
GooglePrivacyDlpV2JobTrigger
type Scopes ProjectsJobTriggersPatch =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient ProjectsJobTriggersPatch'{..}
= go _pjtpName _pjtpXgafv _pjtpUploadProtocol
_pjtpAccessToken
_pjtpUploadType
_pjtpCallback
(Just AltJSON)
_pjtpPayload
dLPService
where go
= buildClient
(Proxy :: Proxy ProjectsJobTriggersPatchResource)
mempty