{-# 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.Routers.GetRouterStatus
(
RoutersGetRouterStatusResource
, routersGetRouterStatus
, RoutersGetRouterStatus
, rgrsProject
, rgrsRouter
, rgrsRegion
) where
import Network.Google.Compute.Types
import Network.Google.Prelude
type RoutersGetRouterStatusResource =
"compute" :>
"v1" :>
"projects" :>
Capture "project" Text :>
"regions" :>
Capture "region" Text :>
"routers" :>
Capture "router" Text :>
"getRouterStatus" :>
QueryParam "alt" AltJSON :>
Get '[JSON] RouterStatusResponse
data RoutersGetRouterStatus = RoutersGetRouterStatus'
{ _rgrsProject :: !Text
, _rgrsRouter :: !Text
, _rgrsRegion :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
routersGetRouterStatus
:: Text
-> Text
-> Text
-> RoutersGetRouterStatus
routersGetRouterStatus pRgrsProject_ pRgrsRouter_ pRgrsRegion_ =
RoutersGetRouterStatus'
{ _rgrsProject = pRgrsProject_
, _rgrsRouter = pRgrsRouter_
, _rgrsRegion = pRgrsRegion_
}
rgrsProject :: Lens' RoutersGetRouterStatus Text
rgrsProject
= lens _rgrsProject (\ s a -> s{_rgrsProject = a})
rgrsRouter :: Lens' RoutersGetRouterStatus Text
rgrsRouter
= lens _rgrsRouter (\ s a -> s{_rgrsRouter = a})
rgrsRegion :: Lens' RoutersGetRouterStatus Text
rgrsRegion
= lens _rgrsRegion (\ s a -> s{_rgrsRegion = a})
instance GoogleRequest RoutersGetRouterStatus where
type Rs RoutersGetRouterStatus = RouterStatusResponse
type Scopes RoutersGetRouterStatus =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/compute",
"https://www.googleapis.com/auth/compute.readonly"]
requestClient RoutersGetRouterStatus'{..}
= go _rgrsProject _rgrsRegion _rgrsRouter
(Just AltJSON)
computeService
where go
= buildClient
(Proxy :: Proxy RoutersGetRouterStatusResource)
mempty