{-# 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.Logging.Organizations.Exclusions.Patch
(
OrganizationsExclusionsPatchResource
, organizationsExclusionsPatch
, OrganizationsExclusionsPatch
, oepXgafv
, oepUploadProtocol
, oepUpdateMask
, oepAccessToken
, oepUploadType
, oepPayload
, oepName
, oepCallback
) where
import Network.Google.Logging.Types
import Network.Google.Prelude
type OrganizationsExclusionsPatchResource =
"v2" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "updateMask" GFieldMask :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] LogExclusion :>
Patch '[JSON] LogExclusion
data OrganizationsExclusionsPatch = OrganizationsExclusionsPatch'
{ _oepXgafv :: !(Maybe Xgafv)
, _oepUploadProtocol :: !(Maybe Text)
, _oepUpdateMask :: !(Maybe GFieldMask)
, _oepAccessToken :: !(Maybe Text)
, _oepUploadType :: !(Maybe Text)
, _oepPayload :: !LogExclusion
, _oepName :: !Text
, _oepCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
organizationsExclusionsPatch
:: LogExclusion
-> Text
-> OrganizationsExclusionsPatch
organizationsExclusionsPatch pOepPayload_ pOepName_ =
OrganizationsExclusionsPatch'
{ _oepXgafv = Nothing
, _oepUploadProtocol = Nothing
, _oepUpdateMask = Nothing
, _oepAccessToken = Nothing
, _oepUploadType = Nothing
, _oepPayload = pOepPayload_
, _oepName = pOepName_
, _oepCallback = Nothing
}
oepXgafv :: Lens' OrganizationsExclusionsPatch (Maybe Xgafv)
oepXgafv = lens _oepXgafv (\ s a -> s{_oepXgafv = a})
oepUploadProtocol :: Lens' OrganizationsExclusionsPatch (Maybe Text)
oepUploadProtocol
= lens _oepUploadProtocol
(\ s a -> s{_oepUploadProtocol = a})
oepUpdateMask :: Lens' OrganizationsExclusionsPatch (Maybe GFieldMask)
oepUpdateMask
= lens _oepUpdateMask
(\ s a -> s{_oepUpdateMask = a})
oepAccessToken :: Lens' OrganizationsExclusionsPatch (Maybe Text)
oepAccessToken
= lens _oepAccessToken
(\ s a -> s{_oepAccessToken = a})
oepUploadType :: Lens' OrganizationsExclusionsPatch (Maybe Text)
oepUploadType
= lens _oepUploadType
(\ s a -> s{_oepUploadType = a})
oepPayload :: Lens' OrganizationsExclusionsPatch LogExclusion
oepPayload
= lens _oepPayload (\ s a -> s{_oepPayload = a})
oepName :: Lens' OrganizationsExclusionsPatch Text
oepName = lens _oepName (\ s a -> s{_oepName = a})
oepCallback :: Lens' OrganizationsExclusionsPatch (Maybe Text)
oepCallback
= lens _oepCallback (\ s a -> s{_oepCallback = a})
instance GoogleRequest OrganizationsExclusionsPatch
where
type Rs OrganizationsExclusionsPatch = LogExclusion
type Scopes OrganizationsExclusionsPatch =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/logging.admin"]
requestClient OrganizationsExclusionsPatch'{..}
= go _oepName _oepXgafv _oepUploadProtocol
_oepUpdateMask
_oepAccessToken
_oepUploadType
_oepCallback
(Just AltJSON)
_oepPayload
loggingService
where go
= buildClient
(Proxy :: Proxy OrganizationsExclusionsPatchResource)
mempty