{-# 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.Container.Projects.Locations.Clusters.NodePools.Rollback
(
ProjectsLocationsClustersNodePoolsRollbackResource
, projectsLocationsClustersNodePoolsRollback
, ProjectsLocationsClustersNodePoolsRollback
, plcnprXgafv
, plcnprUploadProtocol
, plcnprAccessToken
, plcnprUploadType
, plcnprPayload
, plcnprName
, plcnprCallback
) where
import Network.Google.Container.Types
import Network.Google.Prelude
type ProjectsLocationsClustersNodePoolsRollbackResource
=
"v1" :>
CaptureMode "name" "rollback" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] RollbackNodePoolUpgradeRequest :>
Post '[JSON] Operation
data ProjectsLocationsClustersNodePoolsRollback = ProjectsLocationsClustersNodePoolsRollback'
{ _plcnprXgafv :: !(Maybe Xgafv)
, _plcnprUploadProtocol :: !(Maybe Text)
, _plcnprAccessToken :: !(Maybe Text)
, _plcnprUploadType :: !(Maybe Text)
, _plcnprPayload :: !RollbackNodePoolUpgradeRequest
, _plcnprName :: !Text
, _plcnprCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsLocationsClustersNodePoolsRollback
:: RollbackNodePoolUpgradeRequest
-> Text
-> ProjectsLocationsClustersNodePoolsRollback
projectsLocationsClustersNodePoolsRollback pPlcnprPayload_ pPlcnprName_ =
ProjectsLocationsClustersNodePoolsRollback'
{ _plcnprXgafv = Nothing
, _plcnprUploadProtocol = Nothing
, _plcnprAccessToken = Nothing
, _plcnprUploadType = Nothing
, _plcnprPayload = pPlcnprPayload_
, _plcnprName = pPlcnprName_
, _plcnprCallback = Nothing
}
plcnprXgafv :: Lens' ProjectsLocationsClustersNodePoolsRollback (Maybe Xgafv)
plcnprXgafv
= lens _plcnprXgafv (\ s a -> s{_plcnprXgafv = a})
plcnprUploadProtocol :: Lens' ProjectsLocationsClustersNodePoolsRollback (Maybe Text)
plcnprUploadProtocol
= lens _plcnprUploadProtocol
(\ s a -> s{_plcnprUploadProtocol = a})
plcnprAccessToken :: Lens' ProjectsLocationsClustersNodePoolsRollback (Maybe Text)
plcnprAccessToken
= lens _plcnprAccessToken
(\ s a -> s{_plcnprAccessToken = a})
plcnprUploadType :: Lens' ProjectsLocationsClustersNodePoolsRollback (Maybe Text)
plcnprUploadType
= lens _plcnprUploadType
(\ s a -> s{_plcnprUploadType = a})
plcnprPayload :: Lens' ProjectsLocationsClustersNodePoolsRollback RollbackNodePoolUpgradeRequest
plcnprPayload
= lens _plcnprPayload
(\ s a -> s{_plcnprPayload = a})
plcnprName :: Lens' ProjectsLocationsClustersNodePoolsRollback Text
plcnprName
= lens _plcnprName (\ s a -> s{_plcnprName = a})
plcnprCallback :: Lens' ProjectsLocationsClustersNodePoolsRollback (Maybe Text)
plcnprCallback
= lens _plcnprCallback
(\ s a -> s{_plcnprCallback = a})
instance GoogleRequest
ProjectsLocationsClustersNodePoolsRollback where
type Rs ProjectsLocationsClustersNodePoolsRollback =
Operation
type Scopes
ProjectsLocationsClustersNodePoolsRollback
= '["https://www.googleapis.com/auth/cloud-platform"]
requestClient
ProjectsLocationsClustersNodePoolsRollback'{..}
= go _plcnprName _plcnprXgafv _plcnprUploadProtocol
_plcnprAccessToken
_plcnprUploadType
_plcnprCallback
(Just AltJSON)
_plcnprPayload
containerService
where go
= buildClient
(Proxy ::
Proxy
ProjectsLocationsClustersNodePoolsRollbackResource)
mempty