{-# 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.PubSub.Projects.Topics.Snapshots.List
(
ProjectsTopicsSnapshotsListResource
, projectsTopicsSnapshotsList
, ProjectsTopicsSnapshotsList
, ptsltXgafv
, ptsltUploadProtocol
, ptsltAccessToken
, ptsltUploadType
, ptsltTopic
, ptsltPageToken
, ptsltPageSize
, ptsltCallback
) where
import Network.Google.Prelude
import Network.Google.PubSub.Types
type ProjectsTopicsSnapshotsListResource =
"v1" :>
Capture "topic" Text :>
"snapshots" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "pageToken" Text :>
QueryParam "pageSize" (Textual Int32) :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] ListTopicSnapshotsResponse
data ProjectsTopicsSnapshotsList = ProjectsTopicsSnapshotsList'
{ _ptsltXgafv :: !(Maybe Xgafv)
, _ptsltUploadProtocol :: !(Maybe Text)
, _ptsltAccessToken :: !(Maybe Text)
, _ptsltUploadType :: !(Maybe Text)
, _ptsltTopic :: !Text
, _ptsltPageToken :: !(Maybe Text)
, _ptsltPageSize :: !(Maybe (Textual Int32))
, _ptsltCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsTopicsSnapshotsList
:: Text
-> ProjectsTopicsSnapshotsList
projectsTopicsSnapshotsList pPtsltTopic_ =
ProjectsTopicsSnapshotsList'
{ _ptsltXgafv = Nothing
, _ptsltUploadProtocol = Nothing
, _ptsltAccessToken = Nothing
, _ptsltUploadType = Nothing
, _ptsltTopic = pPtsltTopic_
, _ptsltPageToken = Nothing
, _ptsltPageSize = Nothing
, _ptsltCallback = Nothing
}
ptsltXgafv :: Lens' ProjectsTopicsSnapshotsList (Maybe Xgafv)
ptsltXgafv
= lens _ptsltXgafv (\ s a -> s{_ptsltXgafv = a})
ptsltUploadProtocol :: Lens' ProjectsTopicsSnapshotsList (Maybe Text)
ptsltUploadProtocol
= lens _ptsltUploadProtocol
(\ s a -> s{_ptsltUploadProtocol = a})
ptsltAccessToken :: Lens' ProjectsTopicsSnapshotsList (Maybe Text)
ptsltAccessToken
= lens _ptsltAccessToken
(\ s a -> s{_ptsltAccessToken = a})
ptsltUploadType :: Lens' ProjectsTopicsSnapshotsList (Maybe Text)
ptsltUploadType
= lens _ptsltUploadType
(\ s a -> s{_ptsltUploadType = a})
ptsltTopic :: Lens' ProjectsTopicsSnapshotsList Text
ptsltTopic
= lens _ptsltTopic (\ s a -> s{_ptsltTopic = a})
ptsltPageToken :: Lens' ProjectsTopicsSnapshotsList (Maybe Text)
ptsltPageToken
= lens _ptsltPageToken
(\ s a -> s{_ptsltPageToken = a})
ptsltPageSize :: Lens' ProjectsTopicsSnapshotsList (Maybe Int32)
ptsltPageSize
= lens _ptsltPageSize
(\ s a -> s{_ptsltPageSize = a})
. mapping _Coerce
ptsltCallback :: Lens' ProjectsTopicsSnapshotsList (Maybe Text)
ptsltCallback
= lens _ptsltCallback
(\ s a -> s{_ptsltCallback = a})
instance GoogleRequest ProjectsTopicsSnapshotsList
where
type Rs ProjectsTopicsSnapshotsList =
ListTopicSnapshotsResponse
type Scopes ProjectsTopicsSnapshotsList =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/pubsub"]
requestClient ProjectsTopicsSnapshotsList'{..}
= go _ptsltTopic _ptsltXgafv _ptsltUploadProtocol
_ptsltAccessToken
_ptsltUploadType
_ptsltPageToken
_ptsltPageSize
_ptsltCallback
(Just AltJSON)
pubSubService
where go
= buildClient
(Proxy :: Proxy ProjectsTopicsSnapshotsListResource)
mempty