{-# 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.InstanceGroupManagers.SetInstanceTemplate
(
InstanceGroupManagersSetInstanceTemplateResource
, instanceGroupManagersSetInstanceTemplate
, InstanceGroupManagersSetInstanceTemplate
, igmsitRequestId
, igmsitProject
, igmsitInstanceGroupManager
, igmsitZone
, igmsitPayload
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type InstanceGroupManagersSetInstanceTemplateResource
=
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"zones" :>
Capture "zone" Text :>
"instanceGroupManagers" :>
Capture "instanceGroupManager" Text :>
"setInstanceTemplate" :>
QueryParam "requestId" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON]
InstanceGroupManagersSetInstanceTemplateRequest
:> Post '[JSON] Operation
data InstanceGroupManagersSetInstanceTemplate = InstanceGroupManagersSetInstanceTemplate'
{ _igmsitRequestId :: !(Maybe Text)
, _igmsitProject :: !Text
, _igmsitInstanceGroupManager :: !Text
, _igmsitZone :: !Text
, _igmsitPayload :: !InstanceGroupManagersSetInstanceTemplateRequest
} deriving (Eq,Show,Data,Typeable,Generic)
instanceGroupManagersSetInstanceTemplate
:: Text
-> Text
-> Text
-> InstanceGroupManagersSetInstanceTemplateRequest
-> InstanceGroupManagersSetInstanceTemplate
instanceGroupManagersSetInstanceTemplate pIgmsitProject_ pIgmsitInstanceGroupManager_ pIgmsitZone_ pIgmsitPayload_ =
InstanceGroupManagersSetInstanceTemplate'
{ _igmsitRequestId = Nothing
, _igmsitProject = pIgmsitProject_
, _igmsitInstanceGroupManager = pIgmsitInstanceGroupManager_
, _igmsitZone = pIgmsitZone_
, _igmsitPayload = pIgmsitPayload_
}
igmsitRequestId :: Lens' InstanceGroupManagersSetInstanceTemplate (Maybe Text)
igmsitRequestId
= lens _igmsitRequestId
(\ s a -> s{_igmsitRequestId = a})
igmsitProject :: Lens' InstanceGroupManagersSetInstanceTemplate Text
igmsitProject
= lens _igmsitProject
(\ s a -> s{_igmsitProject = a})
igmsitInstanceGroupManager :: Lens' InstanceGroupManagersSetInstanceTemplate Text
igmsitInstanceGroupManager
= lens _igmsitInstanceGroupManager
(\ s a -> s{_igmsitInstanceGroupManager = a})
igmsitZone :: Lens' InstanceGroupManagersSetInstanceTemplate Text
igmsitZone
= lens _igmsitZone (\ s a -> s{_igmsitZone = a})
igmsitPayload :: Lens' InstanceGroupManagersSetInstanceTemplate InstanceGroupManagersSetInstanceTemplateRequest
igmsitPayload
= lens _igmsitPayload
(\ s a -> s{_igmsitPayload = a})
instance GoogleRequest
InstanceGroupManagersSetInstanceTemplate where
type Rs InstanceGroupManagersSetInstanceTemplate =
Operation
type Scopes InstanceGroupManagersSetInstanceTemplate
=
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute"]
requestClient
InstanceGroupManagersSetInstanceTemplate'{..}
= go _igmsitProject _igmsitZone
_igmsitInstanceGroupManager
_igmsitRequestId
(Just AltJSON)
_igmsitPayload
computeService
where go
= buildClient
(Proxy ::
Proxy
InstanceGroupManagersSetInstanceTemplateResource)
mempty