{-# 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.Directory.Resources.Features.Get
(
ResourcesFeaturesGetResource
, resourcesFeaturesGet
, ResourcesFeaturesGet
, rfgCustomer
, rfgFeatureKey
) where
import Network.Google.Directory.Types
import Network.Google.Prelude
type ResourcesFeaturesGetResource =
"admin" :>
"directory" :>
"v1" :>
"customer" :>
Capture "customer" Text :>
"resources" :>
"features" :>
Capture "featureKey" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Feature
data ResourcesFeaturesGet = ResourcesFeaturesGet'
{ _rfgCustomer :: !Text
, _rfgFeatureKey :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
resourcesFeaturesGet
:: Text
-> Text
-> ResourcesFeaturesGet
resourcesFeaturesGet pRfgCustomer_ pRfgFeatureKey_ =
ResourcesFeaturesGet'
{ _rfgCustomer = pRfgCustomer_
, _rfgFeatureKey = pRfgFeatureKey_
}
rfgCustomer :: Lens' ResourcesFeaturesGet Text
rfgCustomer
= lens _rfgCustomer (\ s a -> s{_rfgCustomer = a})
rfgFeatureKey :: Lens' ResourcesFeaturesGet Text
rfgFeatureKey
= lens _rfgFeatureKey
(\ s a -> s{_rfgFeatureKey = a})
instance GoogleRequest ResourcesFeaturesGet where
type Rs ResourcesFeaturesGet = Feature
type Scopes ResourcesFeaturesGet =
'["https://www.googleapis.com/auth/admin.directory.resource.calendar",
"https://www.googleapis.com/auth/admin.directory.resource.calendar.readonly"]
requestClient ResourcesFeaturesGet'{..}
= go _rfgCustomer _rfgFeatureKey (Just AltJSON)
directoryService
where go
= buildClient
(Proxy :: Proxy ResourcesFeaturesGetResource)
mempty