{-# 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.UnSampledReports.List
(
ManagementUnSampledReportsListResource
, managementUnSampledReportsList
, ManagementUnSampledReportsList
, musrlWebPropertyId
, musrlProFileId
, musrlAccountId
, musrlStartIndex
, musrlMaxResults
) where
import Network.Google.Analytics.Types
import Network.Google.Prelude
type ManagementUnSampledReportsListResource =
"analytics" :>
"v3" :>
"management" :>
"accounts" :>
Capture "accountId" Text :>
"webproperties" :>
Capture "webPropertyId" Text :>
"profiles" :>
Capture "profileId" Text :>
"unsampledReports" :>
QueryParam "start-index" (Textual Int32) :>
QueryParam "max-results" (Textual Int32) :>
QueryParam "alt" AltJSON :>
Get '[JSON] UnSampledReports
data ManagementUnSampledReportsList = ManagementUnSampledReportsList'
{ _musrlWebPropertyId :: !Text
, _musrlProFileId :: !Text
, _musrlAccountId :: !Text
, _musrlStartIndex :: !(Maybe (Textual Int32))
, _musrlMaxResults :: !(Maybe (Textual Int32))
} deriving (Eq,Show,Data,Typeable,Generic)
managementUnSampledReportsList
:: Text
-> Text
-> Text
-> ManagementUnSampledReportsList
managementUnSampledReportsList pMusrlWebPropertyId_ pMusrlProFileId_ pMusrlAccountId_ =
ManagementUnSampledReportsList'
{ _musrlWebPropertyId = pMusrlWebPropertyId_
, _musrlProFileId = pMusrlProFileId_
, _musrlAccountId = pMusrlAccountId_
, _musrlStartIndex = Nothing
, _musrlMaxResults = Nothing
}
musrlWebPropertyId :: Lens' ManagementUnSampledReportsList Text
musrlWebPropertyId
= lens _musrlWebPropertyId
(\ s a -> s{_musrlWebPropertyId = a})
musrlProFileId :: Lens' ManagementUnSampledReportsList Text
musrlProFileId
= lens _musrlProFileId
(\ s a -> s{_musrlProFileId = a})
musrlAccountId :: Lens' ManagementUnSampledReportsList Text
musrlAccountId
= lens _musrlAccountId
(\ s a -> s{_musrlAccountId = a})
musrlStartIndex :: Lens' ManagementUnSampledReportsList (Maybe Int32)
musrlStartIndex
= lens _musrlStartIndex
(\ s a -> s{_musrlStartIndex = a})
. mapping _Coerce
musrlMaxResults :: Lens' ManagementUnSampledReportsList (Maybe Int32)
musrlMaxResults
= lens _musrlMaxResults
(\ s a -> s{_musrlMaxResults = a})
. mapping _Coerce
instance GoogleRequest ManagementUnSampledReportsList
where
type Rs ManagementUnSampledReportsList =
UnSampledReports
type Scopes ManagementUnSampledReportsList =
'["https://www.googleapis.com/auth/analytics",
"https://www.googleapis.com/auth/analytics.edit",
"https://www.googleapis.com/auth/analytics.readonly"]
requestClient ManagementUnSampledReportsList'{..}
= go _musrlAccountId _musrlWebPropertyId
_musrlProFileId
_musrlStartIndex
_musrlMaxResults
(Just AltJSON)
analyticsService
where go
= buildClient
(Proxy ::
Proxy ManagementUnSampledReportsListResource)
mempty