{-# 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.DoubleClickSearch.Conversion.UpdateAvailability
(
ConversionUpdateAvailabilityResource
, conversionUpdateAvailability
, ConversionUpdateAvailability
, cuaPayload
) where
import Network.Google.DoubleClickSearch.Types
import Network.Google.Prelude
type ConversionUpdateAvailabilityResource =
"doubleclicksearch" :>
"v2" :>
"conversion" :>
"updateAvailability" :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] UpdateAvailabilityRequest :>
Post '[JSON] UpdateAvailabilityResponse
newtype ConversionUpdateAvailability = ConversionUpdateAvailability'
{ _cuaPayload :: UpdateAvailabilityRequest
} deriving (Eq,Show,Data,Typeable,Generic)
conversionUpdateAvailability
:: UpdateAvailabilityRequest
-> ConversionUpdateAvailability
conversionUpdateAvailability pCuaPayload_ =
ConversionUpdateAvailability'
{ _cuaPayload = pCuaPayload_
}
cuaPayload :: Lens' ConversionUpdateAvailability UpdateAvailabilityRequest
cuaPayload
= lens _cuaPayload (\ s a -> s{_cuaPayload = a})
instance GoogleRequest ConversionUpdateAvailability
where
type Rs ConversionUpdateAvailability =
UpdateAvailabilityResponse
type Scopes ConversionUpdateAvailability =
'["https://www.googleapis.com/auth/doubleclicksearch"]
requestClient ConversionUpdateAvailability'{..}
= go (Just AltJSON) _cuaPayload
doubleClickSearchService
where go
= buildClient
(Proxy :: Proxy ConversionUpdateAvailabilityResource)
mempty