{-# 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.RegionInstanceGroups.SetNamedPorts
(
RegionInstanceGroupsSetNamedPortsResource
, regionInstanceGroupsSetNamedPorts
, RegionInstanceGroupsSetNamedPorts
, rigsnpRequestId
, rigsnpProject
, rigsnpPayload
, rigsnpRegion
, rigsnpInstanceGroup
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type RegionInstanceGroupsSetNamedPortsResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"regions" :>
Capture "region" Text :>
"instanceGroups" :>
Capture "instanceGroup" Text :>
"setNamedPorts" :>
QueryParam "requestId" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON]
RegionInstanceGroupsSetNamedPortsRequest
:> Post '[JSON] Operation
data RegionInstanceGroupsSetNamedPorts = RegionInstanceGroupsSetNamedPorts'
{ _rigsnpRequestId :: !(Maybe Text)
, _rigsnpProject :: !Text
, _rigsnpPayload :: !RegionInstanceGroupsSetNamedPortsRequest
, _rigsnpRegion :: !Text
, _rigsnpInstanceGroup :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
regionInstanceGroupsSetNamedPorts
:: Text
-> RegionInstanceGroupsSetNamedPortsRequest
-> Text
-> Text
-> RegionInstanceGroupsSetNamedPorts
regionInstanceGroupsSetNamedPorts pRigsnpProject_ pRigsnpPayload_ pRigsnpRegion_ pRigsnpInstanceGroup_ =
RegionInstanceGroupsSetNamedPorts'
{ _rigsnpRequestId = Nothing
, _rigsnpProject = pRigsnpProject_
, _rigsnpPayload = pRigsnpPayload_
, _rigsnpRegion = pRigsnpRegion_
, _rigsnpInstanceGroup = pRigsnpInstanceGroup_
}
rigsnpRequestId :: Lens' RegionInstanceGroupsSetNamedPorts (Maybe Text)
rigsnpRequestId
= lens _rigsnpRequestId
(\ s a -> s{_rigsnpRequestId = a})
rigsnpProject :: Lens' RegionInstanceGroupsSetNamedPorts Text
rigsnpProject
= lens _rigsnpProject
(\ s a -> s{_rigsnpProject = a})
rigsnpPayload :: Lens' RegionInstanceGroupsSetNamedPorts RegionInstanceGroupsSetNamedPortsRequest
rigsnpPayload
= lens _rigsnpPayload
(\ s a -> s{_rigsnpPayload = a})
rigsnpRegion :: Lens' RegionInstanceGroupsSetNamedPorts Text
rigsnpRegion
= lens _rigsnpRegion (\ s a -> s{_rigsnpRegion = a})
rigsnpInstanceGroup :: Lens' RegionInstanceGroupsSetNamedPorts Text
rigsnpInstanceGroup
= lens _rigsnpInstanceGroup
(\ s a -> s{_rigsnpInstanceGroup = a})
instance GoogleRequest
RegionInstanceGroupsSetNamedPorts where
type Rs RegionInstanceGroupsSetNamedPorts = Operation
type Scopes RegionInstanceGroupsSetNamedPorts =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute"]
requestClient RegionInstanceGroupsSetNamedPorts'{..}
= go _rigsnpProject _rigsnpRegion
_rigsnpInstanceGroup
_rigsnpRequestId
(Just AltJSON)
_rigsnpPayload
computeService
where go
= buildClient
(Proxy ::
Proxy RegionInstanceGroupsSetNamedPortsResource)
mempty