{-# 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.AndroidPublisher.Purchases.Voidedpurchases.List
(
PurchasesVoidedpurchasesListResource
, purchasesVoidedpurchasesList
, PurchasesVoidedpurchasesList
, pvlPackageName
, pvlStartTime
, pvlToken
, pvlEndTime
, pvlStartIndex
, pvlMaxResults
) where
import Network.Google.AndroidPublisher.Types
import Network.Google.Prelude
type PurchasesVoidedpurchasesListResource =
"androidpublisher" :>
"v3" :>
"applications" :>
Capture "packageName" Text :>
"purchases" :>
"voidedpurchases" :>
QueryParam "startTime" (Textual Int64) :>
QueryParam "token" Text :>
QueryParam "endTime" (Textual Int64) :>
QueryParam "startIndex" (Textual Word32) :>
QueryParam "maxResults" (Textual Word32) :>
QueryParam "alt" AltJSON :>
Get '[JSON] VoidedPurchasesListResponse
data PurchasesVoidedpurchasesList = PurchasesVoidedpurchasesList'
{ _pvlPackageName :: !Text
, _pvlStartTime :: !(Maybe (Textual Int64))
, _pvlToken :: !(Maybe Text)
, _pvlEndTime :: !(Maybe (Textual Int64))
, _pvlStartIndex :: !(Maybe (Textual Word32))
, _pvlMaxResults :: !(Maybe (Textual Word32))
} deriving (Eq,Show,Data,Typeable,Generic)
purchasesVoidedpurchasesList
:: Text
-> PurchasesVoidedpurchasesList
purchasesVoidedpurchasesList pPvlPackageName_ =
PurchasesVoidedpurchasesList'
{ _pvlPackageName = pPvlPackageName_
, _pvlStartTime = Nothing
, _pvlToken = Nothing
, _pvlEndTime = Nothing
, _pvlStartIndex = Nothing
, _pvlMaxResults = Nothing
}
pvlPackageName :: Lens' PurchasesVoidedpurchasesList Text
pvlPackageName
= lens _pvlPackageName
(\ s a -> s{_pvlPackageName = a})
pvlStartTime :: Lens' PurchasesVoidedpurchasesList (Maybe Int64)
pvlStartTime
= lens _pvlStartTime (\ s a -> s{_pvlStartTime = a})
. mapping _Coerce
pvlToken :: Lens' PurchasesVoidedpurchasesList (Maybe Text)
pvlToken = lens _pvlToken (\ s a -> s{_pvlToken = a})
pvlEndTime :: Lens' PurchasesVoidedpurchasesList (Maybe Int64)
pvlEndTime
= lens _pvlEndTime (\ s a -> s{_pvlEndTime = a}) .
mapping _Coerce
pvlStartIndex :: Lens' PurchasesVoidedpurchasesList (Maybe Word32)
pvlStartIndex
= lens _pvlStartIndex
(\ s a -> s{_pvlStartIndex = a})
. mapping _Coerce
pvlMaxResults :: Lens' PurchasesVoidedpurchasesList (Maybe Word32)
pvlMaxResults
= lens _pvlMaxResults
(\ s a -> s{_pvlMaxResults = a})
. mapping _Coerce
instance GoogleRequest PurchasesVoidedpurchasesList
where
type Rs PurchasesVoidedpurchasesList =
VoidedPurchasesListResponse
type Scopes PurchasesVoidedpurchasesList =
'["https://www.googleapis.com/auth/androidpublisher"]
requestClient PurchasesVoidedpurchasesList'{..}
= go _pvlPackageName _pvlStartTime _pvlToken
_pvlEndTime
_pvlStartIndex
_pvlMaxResults
(Just AltJSON)
androidPublisherService
where go
= buildClient
(Proxy :: Proxy PurchasesVoidedpurchasesListResource)
mempty