{-# 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.RequestgmbAccess
(
LiaSettingsRequestgmbAccessResource
, liaSettingsRequestgmbAccess
, LiaSettingsRequestgmbAccess
, lsraGmbEmail
, lsraMerchantId
, lsraAccountId
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type LiaSettingsRequestgmbAccessResource =
"content" :>
"v2.1" :>
Capture "merchantId" (Textual Word64) :>
"liasettings" :>
Capture "accountId" (Textual Word64) :>
"requestgmbaccess" :>
QueryParam "gmbEmail" Text :>
QueryParam "alt" AltJSON :>
Post '[JSON] LiaSettingsRequestGmbAccessResponse
data LiaSettingsRequestgmbAccess = LiaSettingsRequestgmbAccess'
{ _lsraGmbEmail :: !Text
, _lsraMerchantId :: !(Textual Word64)
, _lsraAccountId :: !(Textual Word64)
} deriving (Eq,Show,Data,Typeable,Generic)
liaSettingsRequestgmbAccess
:: Text
-> Word64
-> Word64
-> LiaSettingsRequestgmbAccess
liaSettingsRequestgmbAccess pLsraGmbEmail_ pLsraMerchantId_ pLsraAccountId_ =
LiaSettingsRequestgmbAccess'
{ _lsraGmbEmail = pLsraGmbEmail_
, _lsraMerchantId = _Coerce # pLsraMerchantId_
, _lsraAccountId = _Coerce # pLsraAccountId_
}
lsraGmbEmail :: Lens' LiaSettingsRequestgmbAccess Text
lsraGmbEmail
= lens _lsraGmbEmail (\ s a -> s{_lsraGmbEmail = a})
lsraMerchantId :: Lens' LiaSettingsRequestgmbAccess Word64
lsraMerchantId
= lens _lsraMerchantId
(\ s a -> s{_lsraMerchantId = a})
. _Coerce
lsraAccountId :: Lens' LiaSettingsRequestgmbAccess Word64
lsraAccountId
= lens _lsraAccountId
(\ s a -> s{_lsraAccountId = a})
. _Coerce
instance GoogleRequest LiaSettingsRequestgmbAccess
where
type Rs LiaSettingsRequestgmbAccess =
LiaSettingsRequestGmbAccessResponse
type Scopes LiaSettingsRequestgmbAccess =
'["https://www.googleapis.com/auth/content"]
requestClient LiaSettingsRequestgmbAccess'{..}
= go _lsraMerchantId _lsraAccountId
(Just _lsraGmbEmail)
(Just AltJSON)
shoppingContentService
where go
= buildClient
(Proxy :: Proxy LiaSettingsRequestgmbAccessResource)
mempty