{-# 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.CustomDimensions.List
(
ManagementCustomDimensionsListResource
, managementCustomDimensionsList
, ManagementCustomDimensionsList
, mcdlWebPropertyId
, mcdlAccountId
, mcdlStartIndex
, mcdlMaxResults
) where
import Network.Google.Analytics.Types
import Network.Google.Prelude
type ManagementCustomDimensionsListResource =
"analytics" :>
"v3" :>
"management" :>
"accounts" :>
Capture "accountId" Text :>
"webproperties" :>
Capture "webPropertyId" Text :>
"customDimensions" :>
QueryParam "start-index" (Textual Int32) :>
QueryParam "max-results" (Textual Int32) :>
QueryParam "alt" AltJSON :>
Get '[JSON] CustomDimensions
data ManagementCustomDimensionsList = ManagementCustomDimensionsList'
{ _mcdlWebPropertyId :: !Text
, _mcdlAccountId :: !Text
, _mcdlStartIndex :: !(Maybe (Textual Int32))
, _mcdlMaxResults :: !(Maybe (Textual Int32))
} deriving (Eq,Show,Data,Typeable,Generic)
managementCustomDimensionsList
:: Text
-> Text
-> ManagementCustomDimensionsList
managementCustomDimensionsList pMcdlWebPropertyId_ pMcdlAccountId_ =
ManagementCustomDimensionsList'
{ _mcdlWebPropertyId = pMcdlWebPropertyId_
, _mcdlAccountId = pMcdlAccountId_
, _mcdlStartIndex = Nothing
, _mcdlMaxResults = Nothing
}
mcdlWebPropertyId :: Lens' ManagementCustomDimensionsList Text
mcdlWebPropertyId
= lens _mcdlWebPropertyId
(\ s a -> s{_mcdlWebPropertyId = a})
mcdlAccountId :: Lens' ManagementCustomDimensionsList Text
mcdlAccountId
= lens _mcdlAccountId
(\ s a -> s{_mcdlAccountId = a})
mcdlStartIndex :: Lens' ManagementCustomDimensionsList (Maybe Int32)
mcdlStartIndex
= lens _mcdlStartIndex
(\ s a -> s{_mcdlStartIndex = a})
. mapping _Coerce
mcdlMaxResults :: Lens' ManagementCustomDimensionsList (Maybe Int32)
mcdlMaxResults
= lens _mcdlMaxResults
(\ s a -> s{_mcdlMaxResults = a})
. mapping _Coerce
instance GoogleRequest ManagementCustomDimensionsList
where
type Rs ManagementCustomDimensionsList =
CustomDimensions
type Scopes ManagementCustomDimensionsList =
'["https://www.googleapis.com/auth/analytics",
"https://www.googleapis.com/auth/analytics.readonly"]
requestClient ManagementCustomDimensionsList'{..}
= go _mcdlAccountId _mcdlWebPropertyId
_mcdlStartIndex
_mcdlMaxResults
(Just AltJSON)
analyticsService
where go
= buildClient
(Proxy ::
Proxy ManagementCustomDimensionsListResource)
mempty