{-# 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.FireStore.Projects.Databases.Documents.BatchGet
(
ProjectsDatabasesDocumentsBatchGetResource
, projectsDatabasesDocumentsBatchGet
, ProjectsDatabasesDocumentsBatchGet
, pddbgXgafv
, pddbgUploadProtocol
, pddbgDatabase
, pddbgAccessToken
, pddbgUploadType
, pddbgPayload
, pddbgCallback
) where
import Network.Google.FireStore.Types
import Network.Google.Prelude
type ProjectsDatabasesDocumentsBatchGetResource =
"v1" :>
Capture "database" Text :>
"documents:batchGet" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] BatchGetDocumentsRequest :>
Post '[JSON] BatchGetDocumentsResponse
data ProjectsDatabasesDocumentsBatchGet = ProjectsDatabasesDocumentsBatchGet'
{ _pddbgXgafv :: !(Maybe Xgafv)
, _pddbgUploadProtocol :: !(Maybe Text)
, _pddbgDatabase :: !Text
, _pddbgAccessToken :: !(Maybe Text)
, _pddbgUploadType :: !(Maybe Text)
, _pddbgPayload :: !BatchGetDocumentsRequest
, _pddbgCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsDatabasesDocumentsBatchGet
:: Text
-> BatchGetDocumentsRequest
-> ProjectsDatabasesDocumentsBatchGet
projectsDatabasesDocumentsBatchGet pPddbgDatabase_ pPddbgPayload_ =
ProjectsDatabasesDocumentsBatchGet'
{ _pddbgXgafv = Nothing
, _pddbgUploadProtocol = Nothing
, _pddbgDatabase = pPddbgDatabase_
, _pddbgAccessToken = Nothing
, _pddbgUploadType = Nothing
, _pddbgPayload = pPddbgPayload_
, _pddbgCallback = Nothing
}
pddbgXgafv :: Lens' ProjectsDatabasesDocumentsBatchGet (Maybe Xgafv)
pddbgXgafv
= lens _pddbgXgafv (\ s a -> s{_pddbgXgafv = a})
pddbgUploadProtocol :: Lens' ProjectsDatabasesDocumentsBatchGet (Maybe Text)
pddbgUploadProtocol
= lens _pddbgUploadProtocol
(\ s a -> s{_pddbgUploadProtocol = a})
pddbgDatabase :: Lens' ProjectsDatabasesDocumentsBatchGet Text
pddbgDatabase
= lens _pddbgDatabase
(\ s a -> s{_pddbgDatabase = a})
pddbgAccessToken :: Lens' ProjectsDatabasesDocumentsBatchGet (Maybe Text)
pddbgAccessToken
= lens _pddbgAccessToken
(\ s a -> s{_pddbgAccessToken = a})
pddbgUploadType :: Lens' ProjectsDatabasesDocumentsBatchGet (Maybe Text)
pddbgUploadType
= lens _pddbgUploadType
(\ s a -> s{_pddbgUploadType = a})
pddbgPayload :: Lens' ProjectsDatabasesDocumentsBatchGet BatchGetDocumentsRequest
pddbgPayload
= lens _pddbgPayload (\ s a -> s{_pddbgPayload = a})
pddbgCallback :: Lens' ProjectsDatabasesDocumentsBatchGet (Maybe Text)
pddbgCallback
= lens _pddbgCallback
(\ s a -> s{_pddbgCallback = a})
instance GoogleRequest
ProjectsDatabasesDocumentsBatchGet where
type Rs ProjectsDatabasesDocumentsBatchGet =
BatchGetDocumentsResponse
type Scopes ProjectsDatabasesDocumentsBatchGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/datastore"]
requestClient ProjectsDatabasesDocumentsBatchGet'{..}
= go _pddbgDatabase _pddbgXgafv _pddbgUploadProtocol
_pddbgAccessToken
_pddbgUploadType
_pddbgCallback
(Just AltJSON)
_pddbgPayload
fireStoreService
where go
= buildClient
(Proxy ::
Proxy ProjectsDatabasesDocumentsBatchGetResource)
mempty