{-# 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.Orders.Updatelineitemshippingdetails
(
OrdersUpdatelineitemshippingdetailsResource
, ordersUpdatelineitemshippingdetails
, OrdersUpdatelineitemshippingdetails
, ousMerchantId
, ousPayload
, ousOrderId
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type OrdersUpdatelineitemshippingdetailsResource =
"content" :>
"v2.1" :>
Capture "merchantId" (Textual Word64) :>
"orders" :>
Capture "orderId" Text :>
"updateLineItemShippingDetails" :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON]
OrdersUpdateLineItemShippingDetailsRequest
:>
Post '[JSON]
OrdersUpdateLineItemShippingDetailsResponse
data OrdersUpdatelineitemshippingdetails = OrdersUpdatelineitemshippingdetails'
{ _ousMerchantId :: !(Textual Word64)
, _ousPayload :: !OrdersUpdateLineItemShippingDetailsRequest
, _ousOrderId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
ordersUpdatelineitemshippingdetails
:: Word64
-> OrdersUpdateLineItemShippingDetailsRequest
-> Text
-> OrdersUpdatelineitemshippingdetails
ordersUpdatelineitemshippingdetails pOusMerchantId_ pOusPayload_ pOusOrderId_ =
OrdersUpdatelineitemshippingdetails'
{ _ousMerchantId = _Coerce # pOusMerchantId_
, _ousPayload = pOusPayload_
, _ousOrderId = pOusOrderId_
}
ousMerchantId :: Lens' OrdersUpdatelineitemshippingdetails Word64
ousMerchantId
= lens _ousMerchantId
(\ s a -> s{_ousMerchantId = a})
. _Coerce
ousPayload :: Lens' OrdersUpdatelineitemshippingdetails OrdersUpdateLineItemShippingDetailsRequest
ousPayload
= lens _ousPayload (\ s a -> s{_ousPayload = a})
ousOrderId :: Lens' OrdersUpdatelineitemshippingdetails Text
ousOrderId
= lens _ousOrderId (\ s a -> s{_ousOrderId = a})
instance GoogleRequest
OrdersUpdatelineitemshippingdetails where
type Rs OrdersUpdatelineitemshippingdetails =
OrdersUpdateLineItemShippingDetailsResponse
type Scopes OrdersUpdatelineitemshippingdetails =
'["https://www.googleapis.com/auth/content"]
requestClient
OrdersUpdatelineitemshippingdetails'{..}
= go _ousMerchantId _ousOrderId (Just AltJSON)
_ousPayload
shoppingContentService
where go
= buildClient
(Proxy ::
Proxy OrdersUpdatelineitemshippingdetailsResource)
mempty