{-# 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.Zones.Clusters.NodePools.Create
(
ProjectsZonesClustersNodePoolsCreateResource
, projectsZonesClustersNodePoolsCreate
, ProjectsZonesClustersNodePoolsCreate
, pzcnpcXgafv
, pzcnpcUploadProtocol
, pzcnpcAccessToken
, pzcnpcUploadType
, pzcnpcZone
, pzcnpcPayload
, pzcnpcClusterId
, pzcnpcProjectId
, pzcnpcCallback
) where
import Network.Google.Container.Types
import Network.Google.Prelude
type ProjectsZonesClustersNodePoolsCreateResource =
"v1" :>
"projects" :>
Capture "projectId" Text :>
"zones" :>
Capture "zone" Text :>
"clusters" :>
Capture "clusterId" Text :>
"nodePools" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] CreateNodePoolRequest :>
Post '[JSON] Operation
data ProjectsZonesClustersNodePoolsCreate = ProjectsZonesClustersNodePoolsCreate'
{ _pzcnpcXgafv :: !(Maybe Xgafv)
, _pzcnpcUploadProtocol :: !(Maybe Text)
, _pzcnpcAccessToken :: !(Maybe Text)
, _pzcnpcUploadType :: !(Maybe Text)
, _pzcnpcZone :: !Text
, _pzcnpcPayload :: !CreateNodePoolRequest
, _pzcnpcClusterId :: !Text
, _pzcnpcProjectId :: !Text
, _pzcnpcCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsZonesClustersNodePoolsCreate
:: Text
-> CreateNodePoolRequest
-> Text
-> Text
-> ProjectsZonesClustersNodePoolsCreate
projectsZonesClustersNodePoolsCreate pPzcnpcZone_ pPzcnpcPayload_ pPzcnpcClusterId_ pPzcnpcProjectId_ =
ProjectsZonesClustersNodePoolsCreate'
{ _pzcnpcXgafv = Nothing
, _pzcnpcUploadProtocol = Nothing
, _pzcnpcAccessToken = Nothing
, _pzcnpcUploadType = Nothing
, _pzcnpcZone = pPzcnpcZone_
, _pzcnpcPayload = pPzcnpcPayload_
, _pzcnpcClusterId = pPzcnpcClusterId_
, _pzcnpcProjectId = pPzcnpcProjectId_
, _pzcnpcCallback = Nothing
}
pzcnpcXgafv :: Lens' ProjectsZonesClustersNodePoolsCreate (Maybe Xgafv)
pzcnpcXgafv
= lens _pzcnpcXgafv (\ s a -> s{_pzcnpcXgafv = a})
pzcnpcUploadProtocol :: Lens' ProjectsZonesClustersNodePoolsCreate (Maybe Text)
pzcnpcUploadProtocol
= lens _pzcnpcUploadProtocol
(\ s a -> s{_pzcnpcUploadProtocol = a})
pzcnpcAccessToken :: Lens' ProjectsZonesClustersNodePoolsCreate (Maybe Text)
pzcnpcAccessToken
= lens _pzcnpcAccessToken
(\ s a -> s{_pzcnpcAccessToken = a})
pzcnpcUploadType :: Lens' ProjectsZonesClustersNodePoolsCreate (Maybe Text)
pzcnpcUploadType
= lens _pzcnpcUploadType
(\ s a -> s{_pzcnpcUploadType = a})
pzcnpcZone :: Lens' ProjectsZonesClustersNodePoolsCreate Text
pzcnpcZone
= lens _pzcnpcZone (\ s a -> s{_pzcnpcZone = a})
pzcnpcPayload :: Lens' ProjectsZonesClustersNodePoolsCreate CreateNodePoolRequest
pzcnpcPayload
= lens _pzcnpcPayload
(\ s a -> s{_pzcnpcPayload = a})
pzcnpcClusterId :: Lens' ProjectsZonesClustersNodePoolsCreate Text
pzcnpcClusterId
= lens _pzcnpcClusterId
(\ s a -> s{_pzcnpcClusterId = a})
pzcnpcProjectId :: Lens' ProjectsZonesClustersNodePoolsCreate Text
pzcnpcProjectId
= lens _pzcnpcProjectId
(\ s a -> s{_pzcnpcProjectId = a})
pzcnpcCallback :: Lens' ProjectsZonesClustersNodePoolsCreate (Maybe Text)
pzcnpcCallback
= lens _pzcnpcCallback
(\ s a -> s{_pzcnpcCallback = a})
instance GoogleRequest
ProjectsZonesClustersNodePoolsCreate where
type Rs ProjectsZonesClustersNodePoolsCreate =
Operation
type Scopes ProjectsZonesClustersNodePoolsCreate =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient
ProjectsZonesClustersNodePoolsCreate'{..}
= go _pzcnpcProjectId _pzcnpcZone _pzcnpcClusterId
_pzcnpcXgafv
_pzcnpcUploadProtocol
_pzcnpcAccessToken
_pzcnpcUploadType
_pzcnpcCallback
(Just AltJSON)
_pzcnpcPayload
containerService
where go
= buildClient
(Proxy ::
Proxy ProjectsZonesClustersNodePoolsCreateResource)
mempty