{-# 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.Directory.OrgUnits.Delete
(
OrgUnitsDeleteResource
, orgUnitsDelete
, OrgUnitsDelete
, oudOrgUnitPath
, oudCustomerId
) where
import Network.Google.Directory.Types
import Network.Google.Prelude
type OrgUnitsDeleteResource =
"admin" :>
"directory" :>
"v1" :>
"customer" :>
Capture "customerId" Text :>
"orgunits" :>
Captures "orgUnitPath" Text :>
QueryParam "alt" AltJSON :> Delete '[JSON] ()
data OrgUnitsDelete = OrgUnitsDelete'
{ _oudOrgUnitPath :: ![Text]
, _oudCustomerId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
orgUnitsDelete
:: [Text]
-> Text
-> OrgUnitsDelete
orgUnitsDelete pOudOrgUnitPath_ pOudCustomerId_ =
OrgUnitsDelete'
{ _oudOrgUnitPath = _Coerce # pOudOrgUnitPath_
, _oudCustomerId = pOudCustomerId_
}
oudOrgUnitPath :: Lens' OrgUnitsDelete [Text]
oudOrgUnitPath
= lens _oudOrgUnitPath
(\ s a -> s{_oudOrgUnitPath = a})
. _Coerce
oudCustomerId :: Lens' OrgUnitsDelete Text
oudCustomerId
= lens _oudCustomerId
(\ s a -> s{_oudCustomerId = a})
instance GoogleRequest OrgUnitsDelete where
type Rs OrgUnitsDelete = ()
type Scopes OrgUnitsDelete =
'["https://www.googleapis.com/auth/admin.directory.orgunit"]
requestClient OrgUnitsDelete'{..}
= go _oudCustomerId _oudOrgUnitPath (Just AltJSON)
directoryService
where go
= buildClient (Proxy :: Proxy OrgUnitsDeleteResource)
mempty