{-# 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.Firewalls.Get
(
FirewallsGetResource
, firewallsGet
, FirewallsGet
, fgProject
, fgFirewall
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type FirewallsGetResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"global" :>
"firewalls" :>
Capture "firewall" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Firewall
data FirewallsGet = FirewallsGet'
{ _fgProject :: !Text
, _fgFirewall :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
firewallsGet
:: Text
-> Text
-> FirewallsGet
firewallsGet pFgProject_ pFgFirewall_ =
FirewallsGet'
{ _fgProject = pFgProject_
, _fgFirewall = pFgFirewall_
}
fgProject :: Lens' FirewallsGet Text
fgProject
= lens _fgProject (\ s a -> s{_fgProject = a})
fgFirewall :: Lens' FirewallsGet Text
fgFirewall
= lens _fgFirewall (\ s a -> s{_fgFirewall = a})
instance GoogleRequest FirewallsGet where
type Rs FirewallsGet = Firewall
type Scopes FirewallsGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute",
"https://www.googleapis.com/auth/compute.readonly"]
requestClient FirewallsGet'{..}
= go _fgProject _fgFirewall (Just AltJSON)
computeService
where go
= buildClient (Proxy :: Proxy FirewallsGetResource)
mempty