{-# 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.Products.Custombatch
(
ProductsCustombatchResource
, productsCustombatch
, ProductsCustombatch
, pcPayload
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type ProductsCustombatchResource =
"content" :>
"v2.1" :>
"products" :>
"batch" :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] ProductsCustomBatchRequest :>
Post '[JSON] ProductsCustomBatchResponse
newtype ProductsCustombatch = ProductsCustombatch'
{ _pcPayload :: ProductsCustomBatchRequest
} deriving (Eq,Show,Data,Typeable,Generic)
productsCustombatch
:: ProductsCustomBatchRequest
-> ProductsCustombatch
productsCustombatch pPcPayload_ =
ProductsCustombatch'
{ _pcPayload = pPcPayload_
}
pcPayload :: Lens' ProductsCustombatch ProductsCustomBatchRequest
pcPayload
= lens _pcPayload (\ s a -> s{_pcPayload = a})
instance GoogleRequest ProductsCustombatch where
type Rs ProductsCustombatch =
ProductsCustomBatchResponse
type Scopes ProductsCustombatch =
'["https://www.googleapis.com/auth/content"]
requestClient ProductsCustombatch'{..}
= go (Just AltJSON) _pcPayload shoppingContentService
where go
= buildClient
(Proxy :: Proxy ProductsCustombatchResource)
mempty