{-# 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.Analytics.Management.RemarketingAudience.Patch
(
ManagementRemarketingAudiencePatchResource
, managementRemarketingAudiencePatch
, ManagementRemarketingAudiencePatch
, mrapWebPropertyId
, mrapPayload
, mrapAccountId
, mrapRemarketingAudienceId
) where
import Network.Google.Analytics.Types
import Network.Google.Prelude
type ManagementRemarketingAudiencePatchResource =
"analytics" :>
"v3" :>
"management" :>
"accounts" :>
Capture "accountId" Text :>
"webproperties" :>
Capture "webPropertyId" Text :>
"remarketingAudiences" :>
Capture "remarketingAudienceId" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] RemarketingAudience :>
Patch '[JSON] RemarketingAudience
data ManagementRemarketingAudiencePatch = ManagementRemarketingAudiencePatch'
{ _mrapWebPropertyId :: !Text
, _mrapPayload :: !RemarketingAudience
, _mrapAccountId :: !Text
, _mrapRemarketingAudienceId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
managementRemarketingAudiencePatch
:: Text
-> RemarketingAudience
-> Text
-> Text
-> ManagementRemarketingAudiencePatch
managementRemarketingAudiencePatch pMrapWebPropertyId_ pMrapPayload_ pMrapAccountId_ pMrapRemarketingAudienceId_ =
ManagementRemarketingAudiencePatch'
{ _mrapWebPropertyId = pMrapWebPropertyId_
, _mrapPayload = pMrapPayload_
, _mrapAccountId = pMrapAccountId_
, _mrapRemarketingAudienceId = pMrapRemarketingAudienceId_
}
mrapWebPropertyId :: Lens' ManagementRemarketingAudiencePatch Text
mrapWebPropertyId
= lens _mrapWebPropertyId
(\ s a -> s{_mrapWebPropertyId = a})
mrapPayload :: Lens' ManagementRemarketingAudiencePatch RemarketingAudience
mrapPayload
= lens _mrapPayload (\ s a -> s{_mrapPayload = a})
mrapAccountId :: Lens' ManagementRemarketingAudiencePatch Text
mrapAccountId
= lens _mrapAccountId
(\ s a -> s{_mrapAccountId = a})
mrapRemarketingAudienceId :: Lens' ManagementRemarketingAudiencePatch Text
mrapRemarketingAudienceId
= lens _mrapRemarketingAudienceId
(\ s a -> s{_mrapRemarketingAudienceId = a})
instance GoogleRequest
ManagementRemarketingAudiencePatch where
type Rs ManagementRemarketingAudiencePatch =
RemarketingAudience
type Scopes ManagementRemarketingAudiencePatch =
'["https://www.googleapis.com/auth/analytics.edit"]
requestClient ManagementRemarketingAudiencePatch'{..}
= go _mrapAccountId _mrapWebPropertyId
_mrapRemarketingAudienceId
(Just AltJSON)
_mrapPayload
analyticsService
where go
= buildClient
(Proxy ::
Proxy ManagementRemarketingAudiencePatchResource)
mempty