{-# 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.BigtableAdmin.Projects.Instances.Update
(
ProjectsInstancesUpdateResource
, projectsInstancesUpdate
, ProjectsInstancesUpdate
, piuXgafv
, piuUploadProtocol
, piuAccessToken
, piuUploadType
, piuPayload
, piuName
, piuCallback
) where
import Network.Google.BigtableAdmin.Types
import Network.Google.Prelude
type ProjectsInstancesUpdateResource =
"v2" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] Instance :> Put '[JSON] Instance
data ProjectsInstancesUpdate = ProjectsInstancesUpdate'
{ _piuXgafv :: !(Maybe Xgafv)
, _piuUploadProtocol :: !(Maybe Text)
, _piuAccessToken :: !(Maybe Text)
, _piuUploadType :: !(Maybe Text)
, _piuPayload :: !Instance
, _piuName :: !Text
, _piuCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsInstancesUpdate
:: Instance
-> Text
-> ProjectsInstancesUpdate
projectsInstancesUpdate pPiuPayload_ pPiuName_ =
ProjectsInstancesUpdate'
{ _piuXgafv = Nothing
, _piuUploadProtocol = Nothing
, _piuAccessToken = Nothing
, _piuUploadType = Nothing
, _piuPayload = pPiuPayload_
, _piuName = pPiuName_
, _piuCallback = Nothing
}
piuXgafv :: Lens' ProjectsInstancesUpdate (Maybe Xgafv)
piuXgafv = lens _piuXgafv (\ s a -> s{_piuXgafv = a})
piuUploadProtocol :: Lens' ProjectsInstancesUpdate (Maybe Text)
piuUploadProtocol
= lens _piuUploadProtocol
(\ s a -> s{_piuUploadProtocol = a})
piuAccessToken :: Lens' ProjectsInstancesUpdate (Maybe Text)
piuAccessToken
= lens _piuAccessToken
(\ s a -> s{_piuAccessToken = a})
piuUploadType :: Lens' ProjectsInstancesUpdate (Maybe Text)
piuUploadType
= lens _piuUploadType
(\ s a -> s{_piuUploadType = a})
piuPayload :: Lens' ProjectsInstancesUpdate Instance
piuPayload
= lens _piuPayload (\ s a -> s{_piuPayload = a})
piuName :: Lens' ProjectsInstancesUpdate Text
piuName = lens _piuName (\ s a -> s{_piuName = a})
piuCallback :: Lens' ProjectsInstancesUpdate (Maybe Text)
piuCallback
= lens _piuCallback (\ s a -> s{_piuCallback = a})
instance GoogleRequest ProjectsInstancesUpdate where
type Rs ProjectsInstancesUpdate = Instance
type Scopes ProjectsInstancesUpdate =
'["https://www.googleapis.com/auth/bigtable.admin",
"https://www.googleapis.com/auth/bigtable.admin.cluster",
"https://www.googleapis.com/auth/bigtable.admin.instance",
"https://www.googleapis.com/auth/cloud-bigtable.admin",
"https://www.googleapis.com/auth/cloud-bigtable.admin.cluster",
"https://www.googleapis.com/auth/cloud-platform"]
requestClient ProjectsInstancesUpdate'{..}
= go _piuName _piuXgafv _piuUploadProtocol
_piuAccessToken
_piuUploadType
_piuCallback
(Just AltJSON)
_piuPayload
bigtableAdminService
where go
= buildClient
(Proxy :: Proxy ProjectsInstancesUpdateResource)
mempty