{-# 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.AdSense.Accounts.Payments.List
(
AccountsPaymentsListResource
, accountsPaymentsList
, AccountsPaymentsList
, aplAccountId
) where
import Network.Google.AdSense.Types
import Network.Google.Prelude
type AccountsPaymentsListResource =
"adsense" :>
"v1.4" :>
"accounts" :>
Capture "accountId" Text :>
"payments" :>
QueryParam "alt" AltJSON :> Get '[JSON] Payments
newtype AccountsPaymentsList = AccountsPaymentsList'
{ _aplAccountId :: Text
} deriving (Eq,Show,Data,Typeable,Generic)
accountsPaymentsList
:: Text
-> AccountsPaymentsList
accountsPaymentsList pAplAccountId_ =
AccountsPaymentsList'
{ _aplAccountId = pAplAccountId_
}
aplAccountId :: Lens' AccountsPaymentsList Text
aplAccountId
= lens _aplAccountId (\ s a -> s{_aplAccountId = a})
instance GoogleRequest AccountsPaymentsList where
type Rs AccountsPaymentsList = Payments
type Scopes AccountsPaymentsList =
'["https://www.googleapis.com/auth/adsense",
"https://www.googleapis.com/auth/adsense.readonly"]
requestClient AccountsPaymentsList'{..}
= go _aplAccountId (Just AltJSON) adSenseService
where go
= buildClient
(Proxy :: Proxy AccountsPaymentsListResource)
mempty