{-# 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.DFAReporting.FloodlightActivityGroups.Patch
(
FloodlightActivityGroupsPatchResource
, floodlightActivityGroupsPatch
, FloodlightActivityGroupsPatch
, fagpProFileId
, fagpPayload
, fagpId
) where
import Network.Google.DFAReporting.Types
import Network.Google.Prelude
type FloodlightActivityGroupsPatchResource =
"dfareporting" :>
"v3.2" :>
"userprofiles" :>
Capture "profileId" (Textual Int64) :>
"floodlightActivityGroups" :>
QueryParam "id" (Textual Int64) :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] FloodlightActivityGroup :>
Patch '[JSON] FloodlightActivityGroup
data FloodlightActivityGroupsPatch = FloodlightActivityGroupsPatch'
{ _fagpProFileId :: !(Textual Int64)
, _fagpPayload :: !FloodlightActivityGroup
, _fagpId :: !(Textual Int64)
} deriving (Eq,Show,Data,Typeable,Generic)
floodlightActivityGroupsPatch
:: Int64
-> FloodlightActivityGroup
-> Int64
-> FloodlightActivityGroupsPatch
floodlightActivityGroupsPatch pFagpProFileId_ pFagpPayload_ pFagpId_ =
FloodlightActivityGroupsPatch'
{ _fagpProFileId = _Coerce # pFagpProFileId_
, _fagpPayload = pFagpPayload_
, _fagpId = _Coerce # pFagpId_
}
fagpProFileId :: Lens' FloodlightActivityGroupsPatch Int64
fagpProFileId
= lens _fagpProFileId
(\ s a -> s{_fagpProFileId = a})
. _Coerce
fagpPayload :: Lens' FloodlightActivityGroupsPatch FloodlightActivityGroup
fagpPayload
= lens _fagpPayload (\ s a -> s{_fagpPayload = a})
fagpId :: Lens' FloodlightActivityGroupsPatch Int64
fagpId
= lens _fagpId (\ s a -> s{_fagpId = a}) . _Coerce
instance GoogleRequest FloodlightActivityGroupsPatch
where
type Rs FloodlightActivityGroupsPatch =
FloodlightActivityGroup
type Scopes FloodlightActivityGroupsPatch =
'["https://www.googleapis.com/auth/dfatrafficking"]
requestClient FloodlightActivityGroupsPatch'{..}
= go _fagpProFileId (Just _fagpId) (Just AltJSON)
_fagpPayload
dFAReportingService
where go
= buildClient
(Proxy ::
Proxy FloodlightActivityGroupsPatchResource)
mempty