{-# 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.Compute.BackendServices.AddSignedURLKey
(
BackendServicesAddSignedURLKeyResource
, backendServicesAddSignedURLKey
, BackendServicesAddSignedURLKey
, bsasukRequestId
, bsasukProject
, bsasukPayload
, bsasukBackendService
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type BackendServicesAddSignedURLKeyResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"global" :>
"backendServices" :>
Capture "backendService" Text :>
"addSignedUrlKey" :>
QueryParam "requestId" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] SignedURLKey :>
Post '[JSON] Operation
data BackendServicesAddSignedURLKey = BackendServicesAddSignedURLKey'
{ _bsasukRequestId :: !(Maybe Text)
, _bsasukProject :: !Text
, _bsasukPayload :: !SignedURLKey
, _bsasukBackendService :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
backendServicesAddSignedURLKey
:: Text
-> SignedURLKey
-> Text
-> BackendServicesAddSignedURLKey
backendServicesAddSignedURLKey pBsasukProject_ pBsasukPayload_ pBsasukBackendService_ =
BackendServicesAddSignedURLKey'
{ _bsasukRequestId = Nothing
, _bsasukProject = pBsasukProject_
, _bsasukPayload = pBsasukPayload_
, _bsasukBackendService = pBsasukBackendService_
}
bsasukRequestId :: Lens' BackendServicesAddSignedURLKey (Maybe Text)
bsasukRequestId
= lens _bsasukRequestId
(\ s a -> s{_bsasukRequestId = a})
bsasukProject :: Lens' BackendServicesAddSignedURLKey Text
bsasukProject
= lens _bsasukProject
(\ s a -> s{_bsasukProject = a})
bsasukPayload :: Lens' BackendServicesAddSignedURLKey SignedURLKey
bsasukPayload
= lens _bsasukPayload
(\ s a -> s{_bsasukPayload = a})
bsasukBackendService :: Lens' BackendServicesAddSignedURLKey Text
bsasukBackendService
= lens _bsasukBackendService
(\ s a -> s{_bsasukBackendService = a})
instance GoogleRequest BackendServicesAddSignedURLKey
where
type Rs BackendServicesAddSignedURLKey = Operation
type Scopes BackendServicesAddSignedURLKey =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute"]
requestClient BackendServicesAddSignedURLKey'{..}
= go _bsasukProject _bsasukBackendService
_bsasukRequestId
(Just AltJSON)
_bsasukPayload
computeService
where go
= buildClient
(Proxy ::
Proxy BackendServicesAddSignedURLKeyResource)
mempty