{-# 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.Projects.Image.Redact
(
ProjectsImageRedactResource
, projectsImageRedact
, ProjectsImageRedact
, pirParent
, pirXgafv
, pirUploadProtocol
, pirAccessToken
, pirUploadType
, pirPayload
, pirCallback
) where
import Network.Google.DLP.Types
import Network.Google.Prelude
type ProjectsImageRedactResource =
"v2" :>
Capture "parent" Text :>
"image:redact" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] GooglePrivacyDlpV2RedactImageRequest
:> Post '[JSON] GooglePrivacyDlpV2RedactImageResponse
data ProjectsImageRedact = ProjectsImageRedact'
{ _pirParent :: !Text
, _pirXgafv :: !(Maybe Xgafv)
, _pirUploadProtocol :: !(Maybe Text)
, _pirAccessToken :: !(Maybe Text)
, _pirUploadType :: !(Maybe Text)
, _pirPayload :: !GooglePrivacyDlpV2RedactImageRequest
, _pirCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsImageRedact
:: Text
-> GooglePrivacyDlpV2RedactImageRequest
-> ProjectsImageRedact
projectsImageRedact pPirParent_ pPirPayload_ =
ProjectsImageRedact'
{ _pirParent = pPirParent_
, _pirXgafv = Nothing
, _pirUploadProtocol = Nothing
, _pirAccessToken = Nothing
, _pirUploadType = Nothing
, _pirPayload = pPirPayload_
, _pirCallback = Nothing
}
pirParent :: Lens' ProjectsImageRedact Text
pirParent
= lens _pirParent (\ s a -> s{_pirParent = a})
pirXgafv :: Lens' ProjectsImageRedact (Maybe Xgafv)
pirXgafv = lens _pirXgafv (\ s a -> s{_pirXgafv = a})
pirUploadProtocol :: Lens' ProjectsImageRedact (Maybe Text)
pirUploadProtocol
= lens _pirUploadProtocol
(\ s a -> s{_pirUploadProtocol = a})
pirAccessToken :: Lens' ProjectsImageRedact (Maybe Text)
pirAccessToken
= lens _pirAccessToken
(\ s a -> s{_pirAccessToken = a})
pirUploadType :: Lens' ProjectsImageRedact (Maybe Text)
pirUploadType
= lens _pirUploadType
(\ s a -> s{_pirUploadType = a})
pirPayload :: Lens' ProjectsImageRedact GooglePrivacyDlpV2RedactImageRequest
pirPayload
= lens _pirPayload (\ s a -> s{_pirPayload = a})
pirCallback :: Lens' ProjectsImageRedact (Maybe Text)
pirCallback
= lens _pirCallback (\ s a -> s{_pirCallback = a})
instance GoogleRequest ProjectsImageRedact where
type Rs ProjectsImageRedact =
GooglePrivacyDlpV2RedactImageResponse
type Scopes ProjectsImageRedact =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient ProjectsImageRedact'{..}
= go _pirParent _pirXgafv _pirUploadProtocol
_pirAccessToken
_pirUploadType
_pirCallback
(Just AltJSON)
_pirPayload
dLPService
where go
= buildClient
(Proxy :: Proxy ProjectsImageRedactResource)
mempty