{-# 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.Monitoring.Projects.UptimeCheckConfigs.Get
(
ProjectsUptimeCheckConfigsGetResource
, projectsUptimeCheckConfigsGet
, ProjectsUptimeCheckConfigsGet
, puccgXgafv
, puccgUploadProtocol
, puccgAccessToken
, puccgUploadType
, puccgName
, puccgCallback
) where
import Network.Google.Monitoring.Types
import Network.Google.Prelude
type ProjectsUptimeCheckConfigsGetResource =
"v3" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] UptimeCheckConfig
data ProjectsUptimeCheckConfigsGet = ProjectsUptimeCheckConfigsGet'
{ _puccgXgafv :: !(Maybe Xgafv)
, _puccgUploadProtocol :: !(Maybe Text)
, _puccgAccessToken :: !(Maybe Text)
, _puccgUploadType :: !(Maybe Text)
, _puccgName :: !Text
, _puccgCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsUptimeCheckConfigsGet
:: Text
-> ProjectsUptimeCheckConfigsGet
projectsUptimeCheckConfigsGet pPuccgName_ =
ProjectsUptimeCheckConfigsGet'
{ _puccgXgafv = Nothing
, _puccgUploadProtocol = Nothing
, _puccgAccessToken = Nothing
, _puccgUploadType = Nothing
, _puccgName = pPuccgName_
, _puccgCallback = Nothing
}
puccgXgafv :: Lens' ProjectsUptimeCheckConfigsGet (Maybe Xgafv)
puccgXgafv
= lens _puccgXgafv (\ s a -> s{_puccgXgafv = a})
puccgUploadProtocol :: Lens' ProjectsUptimeCheckConfigsGet (Maybe Text)
puccgUploadProtocol
= lens _puccgUploadProtocol
(\ s a -> s{_puccgUploadProtocol = a})
puccgAccessToken :: Lens' ProjectsUptimeCheckConfigsGet (Maybe Text)
puccgAccessToken
= lens _puccgAccessToken
(\ s a -> s{_puccgAccessToken = a})
puccgUploadType :: Lens' ProjectsUptimeCheckConfigsGet (Maybe Text)
puccgUploadType
= lens _puccgUploadType
(\ s a -> s{_puccgUploadType = a})
puccgName :: Lens' ProjectsUptimeCheckConfigsGet Text
puccgName
= lens _puccgName (\ s a -> s{_puccgName = a})
puccgCallback :: Lens' ProjectsUptimeCheckConfigsGet (Maybe Text)
puccgCallback
= lens _puccgCallback
(\ s a -> s{_puccgCallback = a})
instance GoogleRequest ProjectsUptimeCheckConfigsGet
where
type Rs ProjectsUptimeCheckConfigsGet =
UptimeCheckConfig
type Scopes ProjectsUptimeCheckConfigsGet =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/monitoring",
"https://www.googleapis.com/auth/monitoring.read"]
requestClient ProjectsUptimeCheckConfigsGet'{..}
= go _puccgName _puccgXgafv _puccgUploadProtocol
_puccgAccessToken
_puccgUploadType
_puccgCallback
(Just AltJSON)
monitoringService
where go
= buildClient
(Proxy ::
Proxy ProjectsUptimeCheckConfigsGetResource)
mempty