{-# 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.SQL.BackupRuns.Delete
(
BackupRunsDeleteResource
, backupRunsDelete
, BackupRunsDelete
, brdProject
, brdId
, brdInstance
) where
import Network.Google.Prelude
import Network.Google.SQLAdmin.Types
type BackupRunsDeleteResource =
"sql" :>
"v1beta4" :>
"projects" :>
Capture "project" Text :>
"instances" :>
Capture "instance" Text :>
"backupRuns" :>
Capture "id" (Textual Int64) :>
QueryParam "alt" AltJSON :> Delete '[JSON] Operation
data BackupRunsDelete = BackupRunsDelete'
{ _brdProject :: !Text
, _brdId :: !(Textual Int64)
, _brdInstance :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
backupRunsDelete
:: Text
-> Int64
-> Text
-> BackupRunsDelete
backupRunsDelete pBrdProject_ pBrdId_ pBrdInstance_ =
BackupRunsDelete'
{ _brdProject = pBrdProject_
, _brdId = _Coerce # pBrdId_
, _brdInstance = pBrdInstance_
}
brdProject :: Lens' BackupRunsDelete Text
brdProject
= lens _brdProject (\ s a -> s{_brdProject = a})
brdId :: Lens' BackupRunsDelete Int64
brdId
= lens _brdId (\ s a -> s{_brdId = a}) . _Coerce
brdInstance :: Lens' BackupRunsDelete Text
brdInstance
= lens _brdInstance (\ s a -> s{_brdInstance = a})
instance GoogleRequest BackupRunsDelete where
type Rs BackupRunsDelete = Operation
type Scopes BackupRunsDelete =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/sqlservice.admin"]
requestClient BackupRunsDelete'{..}
= go _brdProject _brdInstance _brdId (Just AltJSON)
sQLAdminService
where go
= buildClient
(Proxy :: Proxy BackupRunsDeleteResource)
mempty