{-# 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.CollectionGroups.Indexes.Create
(
ProjectsDatabasesCollectionGroupsIndexesCreateResource
, projectsDatabasesCollectionGroupsIndexesCreate
, ProjectsDatabasesCollectionGroupsIndexesCreate
, pdcgicParent
, pdcgicXgafv
, pdcgicUploadProtocol
, pdcgicAccessToken
, pdcgicUploadType
, pdcgicPayload
, pdcgicCallback
) where
import Network.Google.FireStore.Types
import Network.Google.Prelude
type ProjectsDatabasesCollectionGroupsIndexesCreateResource
=
"v1" :>
Capture "parent" Text :>
"indexes" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] GoogleFirestoreAdminV1Index :>
Post '[JSON] GoogleLongrunningOperation
data ProjectsDatabasesCollectionGroupsIndexesCreate = ProjectsDatabasesCollectionGroupsIndexesCreate'
{ _pdcgicParent :: !Text
, _pdcgicXgafv :: !(Maybe Xgafv)
, _pdcgicUploadProtocol :: !(Maybe Text)
, _pdcgicAccessToken :: !(Maybe Text)
, _pdcgicUploadType :: !(Maybe Text)
, _pdcgicPayload :: !GoogleFirestoreAdminV1Index
, _pdcgicCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsDatabasesCollectionGroupsIndexesCreate
:: Text
-> GoogleFirestoreAdminV1Index
-> ProjectsDatabasesCollectionGroupsIndexesCreate
projectsDatabasesCollectionGroupsIndexesCreate pPdcgicParent_ pPdcgicPayload_ =
ProjectsDatabasesCollectionGroupsIndexesCreate'
{ _pdcgicParent = pPdcgicParent_
, _pdcgicXgafv = Nothing
, _pdcgicUploadProtocol = Nothing
, _pdcgicAccessToken = Nothing
, _pdcgicUploadType = Nothing
, _pdcgicPayload = pPdcgicPayload_
, _pdcgicCallback = Nothing
}
pdcgicParent :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate Text
pdcgicParent
= lens _pdcgicParent (\ s a -> s{_pdcgicParent = a})
pdcgicXgafv :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate (Maybe Xgafv)
pdcgicXgafv
= lens _pdcgicXgafv (\ s a -> s{_pdcgicXgafv = a})
pdcgicUploadProtocol :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate (Maybe Text)
pdcgicUploadProtocol
= lens _pdcgicUploadProtocol
(\ s a -> s{_pdcgicUploadProtocol = a})
pdcgicAccessToken :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate (Maybe Text)
pdcgicAccessToken
= lens _pdcgicAccessToken
(\ s a -> s{_pdcgicAccessToken = a})
pdcgicUploadType :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate (Maybe Text)
pdcgicUploadType
= lens _pdcgicUploadType
(\ s a -> s{_pdcgicUploadType = a})
pdcgicPayload :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate GoogleFirestoreAdminV1Index
pdcgicPayload
= lens _pdcgicPayload
(\ s a -> s{_pdcgicPayload = a})
pdcgicCallback :: Lens' ProjectsDatabasesCollectionGroupsIndexesCreate (Maybe Text)
pdcgicCallback
= lens _pdcgicCallback
(\ s a -> s{_pdcgicCallback = a})
instance GoogleRequest
ProjectsDatabasesCollectionGroupsIndexesCreate where
type Rs
ProjectsDatabasesCollectionGroupsIndexesCreate
= GoogleLongrunningOperation
type Scopes
ProjectsDatabasesCollectionGroupsIndexesCreate
=
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/datastore"]
requestClient
ProjectsDatabasesCollectionGroupsIndexesCreate'{..}
= go _pdcgicParent _pdcgicXgafv _pdcgicUploadProtocol
_pdcgicAccessToken
_pdcgicUploadType
_pdcgicCallback
(Just AltJSON)
_pdcgicPayload
fireStoreService
where go
= buildClient
(Proxy ::
Proxy
ProjectsDatabasesCollectionGroupsIndexesCreateResource)
mempty