{-# 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.AndroidDeviceProvisioning.Customers.Configurations.Patch
(
CustomersConfigurationsPatchResource
, customersConfigurationsPatch
, CustomersConfigurationsPatch
, ccpXgafv
, ccpUploadProtocol
, ccpUpdateMask
, ccpAccessToken
, ccpUploadType
, ccpPayload
, ccpName
, ccpCallback
) where
import Network.Google.AndroidDeviceProvisioning.Types
import Network.Google.Prelude
type CustomersConfigurationsPatchResource =
"v1" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "updateMask" GFieldMask :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] Configuration :>
Patch '[JSON] Configuration
data CustomersConfigurationsPatch = CustomersConfigurationsPatch'
{ _ccpXgafv :: !(Maybe Xgafv)
, _ccpUploadProtocol :: !(Maybe Text)
, _ccpUpdateMask :: !(Maybe GFieldMask)
, _ccpAccessToken :: !(Maybe Text)
, _ccpUploadType :: !(Maybe Text)
, _ccpPayload :: !Configuration
, _ccpName :: !Text
, _ccpCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
customersConfigurationsPatch
:: Configuration
-> Text
-> CustomersConfigurationsPatch
customersConfigurationsPatch pCcpPayload_ pCcpName_ =
CustomersConfigurationsPatch'
{ _ccpXgafv = Nothing
, _ccpUploadProtocol = Nothing
, _ccpUpdateMask = Nothing
, _ccpAccessToken = Nothing
, _ccpUploadType = Nothing
, _ccpPayload = pCcpPayload_
, _ccpName = pCcpName_
, _ccpCallback = Nothing
}
ccpXgafv :: Lens' CustomersConfigurationsPatch (Maybe Xgafv)
ccpXgafv = lens _ccpXgafv (\ s a -> s{_ccpXgafv = a})
ccpUploadProtocol :: Lens' CustomersConfigurationsPatch (Maybe Text)
ccpUploadProtocol
= lens _ccpUploadProtocol
(\ s a -> s{_ccpUploadProtocol = a})
ccpUpdateMask :: Lens' CustomersConfigurationsPatch (Maybe GFieldMask)
ccpUpdateMask
= lens _ccpUpdateMask
(\ s a -> s{_ccpUpdateMask = a})
ccpAccessToken :: Lens' CustomersConfigurationsPatch (Maybe Text)
ccpAccessToken
= lens _ccpAccessToken
(\ s a -> s{_ccpAccessToken = a})
ccpUploadType :: Lens' CustomersConfigurationsPatch (Maybe Text)
ccpUploadType
= lens _ccpUploadType
(\ s a -> s{_ccpUploadType = a})
ccpPayload :: Lens' CustomersConfigurationsPatch Configuration
ccpPayload
= lens _ccpPayload (\ s a -> s{_ccpPayload = a})
ccpName :: Lens' CustomersConfigurationsPatch Text
ccpName = lens _ccpName (\ s a -> s{_ccpName = a})
ccpCallback :: Lens' CustomersConfigurationsPatch (Maybe Text)
ccpCallback
= lens _ccpCallback (\ s a -> s{_ccpCallback = a})
instance GoogleRequest CustomersConfigurationsPatch
where
type Rs CustomersConfigurationsPatch = Configuration
type Scopes CustomersConfigurationsPatch = '[]
requestClient CustomersConfigurationsPatch'{..}
= go _ccpName _ccpXgafv _ccpUploadProtocol
_ccpUpdateMask
_ccpAccessToken
_ccpUploadType
_ccpCallback
(Just AltJSON)
_ccpPayload
androidDeviceProvisioningService
where go
= buildClient
(Proxy :: Proxy CustomersConfigurationsPatchResource)
mempty