{-# 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.Content.LiaSettings.Update
(
LiaSettingsUpdateResource
, liaSettingsUpdate
, LiaSettingsUpdate
, lsuMerchantId
, lsuPayload
, lsuAccountId
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type LiaSettingsUpdateResource =
"content" :>
"v2.1" :>
Capture "merchantId" (Textual Word64) :>
"liasettings" :>
Capture "accountId" (Textual Word64) :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] LiaSettings :>
Put '[JSON] LiaSettings
data LiaSettingsUpdate = LiaSettingsUpdate'
{ _lsuMerchantId :: !(Textual Word64)
, _lsuPayload :: !LiaSettings
, _lsuAccountId :: !(Textual Word64)
} deriving (Eq,Show,Data,Typeable,Generic)
liaSettingsUpdate
:: Word64
-> LiaSettings
-> Word64
-> LiaSettingsUpdate
liaSettingsUpdate pLsuMerchantId_ pLsuPayload_ pLsuAccountId_ =
LiaSettingsUpdate'
{ _lsuMerchantId = _Coerce # pLsuMerchantId_
, _lsuPayload = pLsuPayload_
, _lsuAccountId = _Coerce # pLsuAccountId_
}
lsuMerchantId :: Lens' LiaSettingsUpdate Word64
lsuMerchantId
= lens _lsuMerchantId
(\ s a -> s{_lsuMerchantId = a})
. _Coerce
lsuPayload :: Lens' LiaSettingsUpdate LiaSettings
lsuPayload
= lens _lsuPayload (\ s a -> s{_lsuPayload = a})
lsuAccountId :: Lens' LiaSettingsUpdate Word64
lsuAccountId
= lens _lsuAccountId (\ s a -> s{_lsuAccountId = a})
. _Coerce
instance GoogleRequest LiaSettingsUpdate where
type Rs LiaSettingsUpdate = LiaSettings
type Scopes LiaSettingsUpdate =
'["https://www.googleapis.com/auth/content"]
requestClient LiaSettingsUpdate'{..}
= go _lsuMerchantId _lsuAccountId (Just AltJSON)
_lsuPayload
shoppingContentService
where go
= buildClient
(Proxy :: Proxy LiaSettingsUpdateResource)
mempty