{-# 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.Analytics.Management.AccountSummaries.List
(
ManagementAccountSummariesListResource
, managementAccountSummariesList
, ManagementAccountSummariesList
, maslStartIndex
, maslMaxResults
) where
import Network.Google.Analytics.Types
import Network.Google.Prelude
type ManagementAccountSummariesListResource =
"analytics" :>
"v3" :>
"management" :>
"accountSummaries" :>
QueryParam "start-index" (Textual Int32) :>
QueryParam "max-results" (Textual Int32) :>
QueryParam "alt" AltJSON :>
Get '[JSON] AccountSummaries
data ManagementAccountSummariesList = ManagementAccountSummariesList'
{ _maslStartIndex :: !(Maybe (Textual Int32))
, _maslMaxResults :: !(Maybe (Textual Int32))
} deriving (Eq,Show,Data,Typeable,Generic)
managementAccountSummariesList
:: ManagementAccountSummariesList
managementAccountSummariesList =
ManagementAccountSummariesList'
{ _maslStartIndex = Nothing
, _maslMaxResults = Nothing
}
maslStartIndex :: Lens' ManagementAccountSummariesList (Maybe Int32)
maslStartIndex
= lens _maslStartIndex
(\ s a -> s{_maslStartIndex = a})
. mapping _Coerce
maslMaxResults :: Lens' ManagementAccountSummariesList (Maybe Int32)
maslMaxResults
= lens _maslMaxResults
(\ s a -> s{_maslMaxResults = a})
. mapping _Coerce
instance GoogleRequest ManagementAccountSummariesList
where
type Rs ManagementAccountSummariesList =
AccountSummaries
type Scopes ManagementAccountSummariesList =
'["https://www.googleapis.com/auth/analytics.edit",
"https://www.googleapis.com/auth/analytics.readonly"]
requestClient ManagementAccountSummariesList'{..}
= go _maslStartIndex _maslMaxResults (Just AltJSON)
analyticsService
where go
= buildClient
(Proxy ::
Proxy ManagementAccountSummariesListResource)
mempty