{-# 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.ShippingSettings.Get
(
ShippingSettingsGetResource
, shippingSettingsGet
, ShippingSettingsGet
, shiMerchantId
, shiAccountId
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type ShippingSettingsGetResource =
"content" :>
"v2.1" :>
Capture "merchantId" (Textual Word64) :>
"shippingsettings" :>
Capture "accountId" (Textual Word64) :>
QueryParam "alt" AltJSON :>
Get '[JSON] ShippingSettings
data ShippingSettingsGet = ShippingSettingsGet'
{ _shiMerchantId :: !(Textual Word64)
, _shiAccountId :: !(Textual Word64)
} deriving (Eq,Show,Data,Typeable,Generic)
shippingSettingsGet
:: Word64
-> Word64
-> ShippingSettingsGet
shippingSettingsGet pShiMerchantId_ pShiAccountId_ =
ShippingSettingsGet'
{ _shiMerchantId = _Coerce # pShiMerchantId_
, _shiAccountId = _Coerce # pShiAccountId_
}
shiMerchantId :: Lens' ShippingSettingsGet Word64
shiMerchantId
= lens _shiMerchantId
(\ s a -> s{_shiMerchantId = a})
. _Coerce
shiAccountId :: Lens' ShippingSettingsGet Word64
shiAccountId
= lens _shiAccountId (\ s a -> s{_shiAccountId = a})
. _Coerce
instance GoogleRequest ShippingSettingsGet where
type Rs ShippingSettingsGet = ShippingSettings
type Scopes ShippingSettingsGet =
'["https://www.googleapis.com/auth/content"]
requestClient ShippingSettingsGet'{..}
= go _shiMerchantId _shiAccountId (Just AltJSON)
shoppingContentService
where go
= buildClient
(Proxy :: Proxy ShippingSettingsGetResource)
mempty