{-# 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.Accounts.Claimwebsite
(
AccountsClaimwebsiteResource
, accountsClaimwebsite
, AccountsClaimwebsite
, acMerchantId
, acAccountId
, acOverwrite
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type AccountsClaimwebsiteResource =
"content" :>
"v2.1" :>
Capture "merchantId" (Textual Word64) :>
"accounts" :>
Capture "accountId" (Textual Word64) :>
"claimwebsite" :>
QueryParam "overwrite" Bool :>
QueryParam "alt" AltJSON :>
Post '[JSON] AccountsClaimWebsiteResponse
data AccountsClaimwebsite = AccountsClaimwebsite'
{ _acMerchantId :: !(Textual Word64)
, _acAccountId :: !(Textual Word64)
, _acOverwrite :: !(Maybe Bool)
} deriving (Eq,Show,Data,Typeable,Generic)
accountsClaimwebsite
:: Word64
-> Word64
-> AccountsClaimwebsite
accountsClaimwebsite pAcMerchantId_ pAcAccountId_ =
AccountsClaimwebsite'
{ _acMerchantId = _Coerce # pAcMerchantId_
, _acAccountId = _Coerce # pAcAccountId_
, _acOverwrite = Nothing
}
acMerchantId :: Lens' AccountsClaimwebsite Word64
acMerchantId
= lens _acMerchantId (\ s a -> s{_acMerchantId = a})
. _Coerce
acAccountId :: Lens' AccountsClaimwebsite Word64
acAccountId
= lens _acAccountId (\ s a -> s{_acAccountId = a}) .
_Coerce
acOverwrite :: Lens' AccountsClaimwebsite (Maybe Bool)
acOverwrite
= lens _acOverwrite (\ s a -> s{_acOverwrite = a})
instance GoogleRequest AccountsClaimwebsite where
type Rs AccountsClaimwebsite =
AccountsClaimWebsiteResponse
type Scopes AccountsClaimwebsite =
'["https://www.googleapis.com/auth/content"]
requestClient AccountsClaimwebsite'{..}
= go _acMerchantId _acAccountId _acOverwrite
(Just AltJSON)
shoppingContentService
where go
= buildClient
(Proxy :: Proxy AccountsClaimwebsiteResource)
mempty