{-# 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.YouTubeReporting.Jobs.Reports.List
(
JobsReportsListResource
, jobsReportsList
, JobsReportsList
, jrlCreatedAfter
, jrlXgafv
, jrlJobId
, jrlUploadProtocol
, jrlAccessToken
, jrlUploadType
, jrlStartTimeAtOrAfter
, jrlStartTimeBefore
, jrlOnBehalfOfContentOwner
, jrlPageToken
, jrlPageSize
, jrlCallback
) where
import Network.Google.Prelude
import Network.Google.YouTubeReporting.Types
type JobsReportsListResource =
"v1" :>
"jobs" :>
Capture "jobId" Text :>
"reports" :>
QueryParam "createdAfter" DateTime' :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "startTimeAtOrAfter" DateTime' :>
QueryParam "startTimeBefore" DateTime' :>
QueryParam "onBehalfOfContentOwner" Text :>
QueryParam "pageToken" Text :>
QueryParam "pageSize" (Textual Int32) :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] ListReportsResponse
data JobsReportsList = JobsReportsList'
{ _jrlCreatedAfter :: !(Maybe DateTime')
, _jrlXgafv :: !(Maybe Xgafv)
, _jrlJobId :: !Text
, _jrlUploadProtocol :: !(Maybe Text)
, _jrlAccessToken :: !(Maybe Text)
, _jrlUploadType :: !(Maybe Text)
, _jrlStartTimeAtOrAfter :: !(Maybe DateTime')
, _jrlStartTimeBefore :: !(Maybe DateTime')
, _jrlOnBehalfOfContentOwner :: !(Maybe Text)
, _jrlPageToken :: !(Maybe Text)
, _jrlPageSize :: !(Maybe (Textual Int32))
, _jrlCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
jobsReportsList
:: Text
-> JobsReportsList
jobsReportsList pJrlJobId_ =
JobsReportsList'
{ _jrlCreatedAfter = Nothing
, _jrlXgafv = Nothing
, _jrlJobId = pJrlJobId_
, _jrlUploadProtocol = Nothing
, _jrlAccessToken = Nothing
, _jrlUploadType = Nothing
, _jrlStartTimeAtOrAfter = Nothing
, _jrlStartTimeBefore = Nothing
, _jrlOnBehalfOfContentOwner = Nothing
, _jrlPageToken = Nothing
, _jrlPageSize = Nothing
, _jrlCallback = Nothing
}
jrlCreatedAfter :: Lens' JobsReportsList (Maybe UTCTime)
jrlCreatedAfter
= lens _jrlCreatedAfter
(\ s a -> s{_jrlCreatedAfter = a})
. mapping _DateTime
jrlXgafv :: Lens' JobsReportsList (Maybe Xgafv)
jrlXgafv = lens _jrlXgafv (\ s a -> s{_jrlXgafv = a})
jrlJobId :: Lens' JobsReportsList Text
jrlJobId = lens _jrlJobId (\ s a -> s{_jrlJobId = a})
jrlUploadProtocol :: Lens' JobsReportsList (Maybe Text)
jrlUploadProtocol
= lens _jrlUploadProtocol
(\ s a -> s{_jrlUploadProtocol = a})
jrlAccessToken :: Lens' JobsReportsList (Maybe Text)
jrlAccessToken
= lens _jrlAccessToken
(\ s a -> s{_jrlAccessToken = a})
jrlUploadType :: Lens' JobsReportsList (Maybe Text)
jrlUploadType
= lens _jrlUploadType
(\ s a -> s{_jrlUploadType = a})
jrlStartTimeAtOrAfter :: Lens' JobsReportsList (Maybe UTCTime)
jrlStartTimeAtOrAfter
= lens _jrlStartTimeAtOrAfter
(\ s a -> s{_jrlStartTimeAtOrAfter = a})
. mapping _DateTime
jrlStartTimeBefore :: Lens' JobsReportsList (Maybe UTCTime)
jrlStartTimeBefore
= lens _jrlStartTimeBefore
(\ s a -> s{_jrlStartTimeBefore = a})
. mapping _DateTime
jrlOnBehalfOfContentOwner :: Lens' JobsReportsList (Maybe Text)
jrlOnBehalfOfContentOwner
= lens _jrlOnBehalfOfContentOwner
(\ s a -> s{_jrlOnBehalfOfContentOwner = a})
jrlPageToken :: Lens' JobsReportsList (Maybe Text)
jrlPageToken
= lens _jrlPageToken (\ s a -> s{_jrlPageToken = a})
jrlPageSize :: Lens' JobsReportsList (Maybe Int32)
jrlPageSize
= lens _jrlPageSize (\ s a -> s{_jrlPageSize = a}) .
mapping _Coerce
jrlCallback :: Lens' JobsReportsList (Maybe Text)
jrlCallback
= lens _jrlCallback (\ s a -> s{_jrlCallback = a})
instance GoogleRequest JobsReportsList where
type Rs JobsReportsList = ListReportsResponse
type Scopes JobsReportsList =
'["https://www.googleapis.com/auth/yt-analytics-monetary.readonly",
"https://www.googleapis.com/auth/yt-analytics.readonly"]
requestClient JobsReportsList'{..}
= go _jrlJobId _jrlCreatedAfter _jrlXgafv
_jrlUploadProtocol
_jrlAccessToken
_jrlUploadType
_jrlStartTimeAtOrAfter
_jrlStartTimeBefore
_jrlOnBehalfOfContentOwner
_jrlPageToken
_jrlPageSize
_jrlCallback
(Just AltJSON)
youTubeReportingService
where go
= buildClient
(Proxy :: Proxy JobsReportsListResource)
mempty