{-# 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.Compute.NodeGroups.AddNodes
(
NodeGroupsAddNodesResource
, nodeGroupsAddNodes
, NodeGroupsAddNodes
, nganRequestId
, nganNodeGroup
, nganProject
, nganZone
, nganPayload
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type NodeGroupsAddNodesResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"zones" :>
Capture "zone" Text :>
"nodeGroups" :>
Capture "nodeGroup" Text :>
"addNodes" :>
QueryParam "requestId" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] NodeGroupsAddNodesRequest :>
Post '[JSON] Operation
data NodeGroupsAddNodes = NodeGroupsAddNodes'
{ _nganRequestId :: !(Maybe Text)
, _nganNodeGroup :: !Text
, _nganProject :: !Text
, _nganZone :: !Text
, _nganPayload :: !NodeGroupsAddNodesRequest
} deriving (Eq,Show,Data,Typeable,Generic)
nodeGroupsAddNodes
:: Text
-> Text
-> Text
-> NodeGroupsAddNodesRequest
-> NodeGroupsAddNodes
nodeGroupsAddNodes pNganNodeGroup_ pNganProject_ pNganZone_ pNganPayload_ =
NodeGroupsAddNodes'
{ _nganRequestId = Nothing
, _nganNodeGroup = pNganNodeGroup_
, _nganProject = pNganProject_
, _nganZone = pNganZone_
, _nganPayload = pNganPayload_
}
nganRequestId :: Lens' NodeGroupsAddNodes (Maybe Text)
nganRequestId
= lens _nganRequestId
(\ s a -> s{_nganRequestId = a})
nganNodeGroup :: Lens' NodeGroupsAddNodes Text
nganNodeGroup
= lens _nganNodeGroup
(\ s a -> s{_nganNodeGroup = a})
nganProject :: Lens' NodeGroupsAddNodes Text
nganProject
= lens _nganProject (\ s a -> s{_nganProject = a})
nganZone :: Lens' NodeGroupsAddNodes Text
nganZone = lens _nganZone (\ s a -> s{_nganZone = a})
nganPayload :: Lens' NodeGroupsAddNodes NodeGroupsAddNodesRequest
nganPayload
= lens _nganPayload (\ s a -> s{_nganPayload = a})
instance GoogleRequest NodeGroupsAddNodes where
type Rs NodeGroupsAddNodes = Operation
type Scopes NodeGroupsAddNodes =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute"]
requestClient NodeGroupsAddNodes'{..}
= go _nganProject _nganZone _nganNodeGroup
_nganRequestId
(Just AltJSON)
_nganPayload
computeService
where go
= buildClient
(Proxy :: Proxy NodeGroupsAddNodesResource)
mempty