{-# 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.CloudSearch.Settings.Datasources.Delete
(
SettingsDatasourcesDeleteResource
, settingsDatasourcesDelete
, SettingsDatasourcesDelete
, sddXgafv
, sddUploadProtocol
, sddAccessToken
, sddUploadType
, sddName
, sddDebugOptionsEnableDebugging
, sddCallback
) where
import Network.Google.CloudSearch.Types
import Network.Google.Prelude
type SettingsDatasourcesDeleteResource =
"v1" :>
"settings" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "debugOptions.enableDebugging" Bool :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :> Delete '[JSON] Operation
data SettingsDatasourcesDelete = SettingsDatasourcesDelete'
{ _sddXgafv :: !(Maybe Xgafv)
, _sddUploadProtocol :: !(Maybe Text)
, _sddAccessToken :: !(Maybe Text)
, _sddUploadType :: !(Maybe Text)
, _sddName :: !Text
, _sddDebugOptionsEnableDebugging :: !(Maybe Bool)
, _sddCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
settingsDatasourcesDelete
:: Text
-> SettingsDatasourcesDelete
settingsDatasourcesDelete pSddName_ =
SettingsDatasourcesDelete'
{ _sddXgafv = Nothing
, _sddUploadProtocol = Nothing
, _sddAccessToken = Nothing
, _sddUploadType = Nothing
, _sddName = pSddName_
, _sddDebugOptionsEnableDebugging = Nothing
, _sddCallback = Nothing
}
sddXgafv :: Lens' SettingsDatasourcesDelete (Maybe Xgafv)
sddXgafv = lens _sddXgafv (\ s a -> s{_sddXgafv = a})
sddUploadProtocol :: Lens' SettingsDatasourcesDelete (Maybe Text)
sddUploadProtocol
= lens _sddUploadProtocol
(\ s a -> s{_sddUploadProtocol = a})
sddAccessToken :: Lens' SettingsDatasourcesDelete (Maybe Text)
sddAccessToken
= lens _sddAccessToken
(\ s a -> s{_sddAccessToken = a})
sddUploadType :: Lens' SettingsDatasourcesDelete (Maybe Text)
sddUploadType
= lens _sddUploadType
(\ s a -> s{_sddUploadType = a})
sddName :: Lens' SettingsDatasourcesDelete Text
sddName = lens _sddName (\ s a -> s{_sddName = a})
sddDebugOptionsEnableDebugging :: Lens' SettingsDatasourcesDelete (Maybe Bool)
sddDebugOptionsEnableDebugging
= lens _sddDebugOptionsEnableDebugging
(\ s a -> s{_sddDebugOptionsEnableDebugging = a})
sddCallback :: Lens' SettingsDatasourcesDelete (Maybe Text)
sddCallback
= lens _sddCallback (\ s a -> s{_sddCallback = a})
instance GoogleRequest SettingsDatasourcesDelete
where
type Rs SettingsDatasourcesDelete = Operation
type Scopes SettingsDatasourcesDelete =
'["https://www.googleapis.com/auth/cloud_search",
"https://www.googleapis.com/auth/cloud_search.settings",
"https://www.googleapis.com/auth/cloud_search.settings.indexing"]
requestClient SettingsDatasourcesDelete'{..}
= go _sddName _sddXgafv _sddUploadProtocol
_sddAccessToken
_sddUploadType
_sddDebugOptionsEnableDebugging
_sddCallback
(Just AltJSON)
cloudSearchService
where go
= buildClient
(Proxy :: Proxy SettingsDatasourcesDeleteResource)
mempty