{-# 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.Orderreturns.Get
(
OrderreturnsGetResource
, orderreturnsGet
, OrderreturnsGet
, oggMerchantId
, oggReturnId
) where
import Network.Google.Prelude
import Network.Google.ShoppingContent.Types
type OrderreturnsGetResource =
"content" :>
"v2.1" :>
Capture "merchantId" (Textual Word64) :>
"orderreturns" :>
Capture "returnId" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] MerchantOrderReturn
data OrderreturnsGet = OrderreturnsGet'
{ _oggMerchantId :: !(Textual Word64)
, _oggReturnId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
orderreturnsGet
:: Word64
-> Text
-> OrderreturnsGet
orderreturnsGet pOggMerchantId_ pOggReturnId_ =
OrderreturnsGet'
{ _oggMerchantId = _Coerce # pOggMerchantId_
, _oggReturnId = pOggReturnId_
}
oggMerchantId :: Lens' OrderreturnsGet Word64
oggMerchantId
= lens _oggMerchantId
(\ s a -> s{_oggMerchantId = a})
. _Coerce
oggReturnId :: Lens' OrderreturnsGet Text
oggReturnId
= lens _oggReturnId (\ s a -> s{_oggReturnId = a})
instance GoogleRequest OrderreturnsGet where
type Rs OrderreturnsGet = MerchantOrderReturn
type Scopes OrderreturnsGet =
'["https://www.googleapis.com/auth/content"]
requestClient OrderreturnsGet'{..}
= go _oggMerchantId _oggReturnId (Just AltJSON)
shoppingContentService
where go
= buildClient
(Proxy :: Proxy OrderreturnsGetResource)
mempty