{-# 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.AdSenseHost.Accounts.AdClients.List
(
AccountsAdClientsListResource
, accountsAdClientsList
, AccountsAdClientsList
, aaclAccountId
, aaclPageToken
, aaclMaxResults
) where
import Network.Google.AdSenseHost.Types
import Network.Google.Prelude
type AccountsAdClientsListResource =
"adsensehost" :>
"v4.1" :>
"accounts" :>
Capture "accountId" Text :>
"adclients" :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" (Textual Word32) :>
QueryParam "alt" AltJSON :> Get '[JSON] AdClients
data AccountsAdClientsList = AccountsAdClientsList'
{ _aaclAccountId :: !Text
, _aaclPageToken :: !(Maybe Text)
, _aaclMaxResults :: !(Maybe (Textual Word32))
} deriving (Eq,Show,Data,Typeable,Generic)
accountsAdClientsList
:: Text
-> AccountsAdClientsList
accountsAdClientsList pAaclAccountId_ =
AccountsAdClientsList'
{ _aaclAccountId = pAaclAccountId_
, _aaclPageToken = Nothing
, _aaclMaxResults = Nothing
}
aaclAccountId :: Lens' AccountsAdClientsList Text
aaclAccountId
= lens _aaclAccountId
(\ s a -> s{_aaclAccountId = a})
aaclPageToken :: Lens' AccountsAdClientsList (Maybe Text)
aaclPageToken
= lens _aaclPageToken
(\ s a -> s{_aaclPageToken = a})
aaclMaxResults :: Lens' AccountsAdClientsList (Maybe Word32)
aaclMaxResults
= lens _aaclMaxResults
(\ s a -> s{_aaclMaxResults = a})
. mapping _Coerce
instance GoogleRequest AccountsAdClientsList where
type Rs AccountsAdClientsList = AdClients
type Scopes AccountsAdClientsList =
'["https://www.googleapis.com/auth/adsensehost"]
requestClient AccountsAdClientsList'{..}
= go _aaclAccountId _aaclPageToken _aaclMaxResults
(Just AltJSON)
adSenseHostService
where go
= buildClient
(Proxy :: Proxy AccountsAdClientsListResource)
mempty