{-# 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.Spanner.Projects.Instances.Databases.List
(
ProjectsInstancesDatabasesListResource
, projectsInstancesDatabasesList
, ProjectsInstancesDatabasesList
, pidlParent
, pidlXgafv
, pidlUploadProtocol
, pidlAccessToken
, pidlUploadType
, pidlPageToken
, pidlPageSize
, pidlCallback
) where
import Network.Google.Prelude
import Network.Google.Spanner.Types
type ProjectsInstancesDatabasesListResource =
"v1" :>
Capture "parent" Text :>
"databases" :>
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] ListDatabasesResponse
data ProjectsInstancesDatabasesList = ProjectsInstancesDatabasesList'
{ _pidlParent :: !Text
, _pidlXgafv :: !(Maybe Xgafv)
, _pidlUploadProtocol :: !(Maybe Text)
, _pidlAccessToken :: !(Maybe Text)
, _pidlUploadType :: !(Maybe Text)
, _pidlPageToken :: !(Maybe Text)
, _pidlPageSize :: !(Maybe (Textual Int32))
, _pidlCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsInstancesDatabasesList
:: Text
-> ProjectsInstancesDatabasesList
projectsInstancesDatabasesList pPidlParent_ =
ProjectsInstancesDatabasesList'
{ _pidlParent = pPidlParent_
, _pidlXgafv = Nothing
, _pidlUploadProtocol = Nothing
, _pidlAccessToken = Nothing
, _pidlUploadType = Nothing
, _pidlPageToken = Nothing
, _pidlPageSize = Nothing
, _pidlCallback = Nothing
}
pidlParent :: Lens' ProjectsInstancesDatabasesList Text
pidlParent
= lens _pidlParent (\ s a -> s{_pidlParent = a})
pidlXgafv :: Lens' ProjectsInstancesDatabasesList (Maybe Xgafv)
pidlXgafv
= lens _pidlXgafv (\ s a -> s{_pidlXgafv = a})
pidlUploadProtocol :: Lens' ProjectsInstancesDatabasesList (Maybe Text)
pidlUploadProtocol
= lens _pidlUploadProtocol
(\ s a -> s{_pidlUploadProtocol = a})
pidlAccessToken :: Lens' ProjectsInstancesDatabasesList (Maybe Text)
pidlAccessToken
= lens _pidlAccessToken
(\ s a -> s{_pidlAccessToken = a})
pidlUploadType :: Lens' ProjectsInstancesDatabasesList (Maybe Text)
pidlUploadType
= lens _pidlUploadType
(\ s a -> s{_pidlUploadType = a})
pidlPageToken :: Lens' ProjectsInstancesDatabasesList (Maybe Text)
pidlPageToken
= lens _pidlPageToken
(\ s a -> s{_pidlPageToken = a})
pidlPageSize :: Lens' ProjectsInstancesDatabasesList (Maybe Int32)
pidlPageSize
= lens _pidlPageSize (\ s a -> s{_pidlPageSize = a})
. mapping _Coerce
pidlCallback :: Lens' ProjectsInstancesDatabasesList (Maybe Text)
pidlCallback
= lens _pidlCallback (\ s a -> s{_pidlCallback = a})
instance GoogleRequest ProjectsInstancesDatabasesList
where
type Rs ProjectsInstancesDatabasesList =
ListDatabasesResponse
type Scopes ProjectsInstancesDatabasesList =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/spanner.admin"]
requestClient ProjectsInstancesDatabasesList'{..}
= go _pidlParent _pidlXgafv _pidlUploadProtocol
_pidlAccessToken
_pidlUploadType
_pidlPageToken
_pidlPageSize
_pidlCallback
(Just AltJSON)
spannerService
where go
= buildClient
(Proxy ::
Proxy ProjectsInstancesDatabasesListResource)
mempty