{-# 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.DLP.Organizations.DeidentifyTemplates.Create
(
OrganizationsDeidentifyTemplatesCreateResource
, organizationsDeidentifyTemplatesCreate
, OrganizationsDeidentifyTemplatesCreate
, odtcParent
, odtcXgafv
, odtcUploadProtocol
, odtcAccessToken
, odtcUploadType
, odtcPayload
, odtcCallback
) where
import Network.Google.DLP.Types
import Network.Google.Prelude
type OrganizationsDeidentifyTemplatesCreateResource =
"v2" :>
Capture "parent" Text :>
"deidentifyTemplates" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON]
GooglePrivacyDlpV2CreateDeidentifyTemplateRequest
:> Post '[JSON] GooglePrivacyDlpV2DeidentifyTemplate
data OrganizationsDeidentifyTemplatesCreate = OrganizationsDeidentifyTemplatesCreate'
{ _odtcParent :: !Text
, _odtcXgafv :: !(Maybe Xgafv)
, _odtcUploadProtocol :: !(Maybe Text)
, _odtcAccessToken :: !(Maybe Text)
, _odtcUploadType :: !(Maybe Text)
, _odtcPayload :: !GooglePrivacyDlpV2CreateDeidentifyTemplateRequest
, _odtcCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
organizationsDeidentifyTemplatesCreate
:: Text
-> GooglePrivacyDlpV2CreateDeidentifyTemplateRequest
-> OrganizationsDeidentifyTemplatesCreate
organizationsDeidentifyTemplatesCreate pOdtcParent_ pOdtcPayload_ =
OrganizationsDeidentifyTemplatesCreate'
{ _odtcParent = pOdtcParent_
, _odtcXgafv = Nothing
, _odtcUploadProtocol = Nothing
, _odtcAccessToken = Nothing
, _odtcUploadType = Nothing
, _odtcPayload = pOdtcPayload_
, _odtcCallback = Nothing
}
odtcParent :: Lens' OrganizationsDeidentifyTemplatesCreate Text
odtcParent
= lens _odtcParent (\ s a -> s{_odtcParent = a})
odtcXgafv :: Lens' OrganizationsDeidentifyTemplatesCreate (Maybe Xgafv)
odtcXgafv
= lens _odtcXgafv (\ s a -> s{_odtcXgafv = a})
odtcUploadProtocol :: Lens' OrganizationsDeidentifyTemplatesCreate (Maybe Text)
odtcUploadProtocol
= lens _odtcUploadProtocol
(\ s a -> s{_odtcUploadProtocol = a})
odtcAccessToken :: Lens' OrganizationsDeidentifyTemplatesCreate (Maybe Text)
odtcAccessToken
= lens _odtcAccessToken
(\ s a -> s{_odtcAccessToken = a})
odtcUploadType :: Lens' OrganizationsDeidentifyTemplatesCreate (Maybe Text)
odtcUploadType
= lens _odtcUploadType
(\ s a -> s{_odtcUploadType = a})
odtcPayload :: Lens' OrganizationsDeidentifyTemplatesCreate GooglePrivacyDlpV2CreateDeidentifyTemplateRequest
odtcPayload
= lens _odtcPayload (\ s a -> s{_odtcPayload = a})
odtcCallback :: Lens' OrganizationsDeidentifyTemplatesCreate (Maybe Text)
odtcCallback
= lens _odtcCallback (\ s a -> s{_odtcCallback = a})
instance GoogleRequest
OrganizationsDeidentifyTemplatesCreate where
type Rs OrganizationsDeidentifyTemplatesCreate =
GooglePrivacyDlpV2DeidentifyTemplate
type Scopes OrganizationsDeidentifyTemplatesCreate =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient
OrganizationsDeidentifyTemplatesCreate'{..}
= go _odtcParent _odtcXgafv _odtcUploadProtocol
_odtcAccessToken
_odtcUploadType
_odtcCallback
(Just AltJSON)
_odtcPayload
dLPService
where go
= buildClient
(Proxy ::
Proxy OrganizationsDeidentifyTemplatesCreateResource)
mempty