{-# 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.DFAReporting.UserRolePermissionGroups.Get
(
UserRolePermissionGroupsGetResource
, userRolePermissionGroupsGet
, UserRolePermissionGroupsGet
, urpggProFileId
, urpggId
) where
import Network.Google.DFAReporting.Types
import Network.Google.Prelude
type UserRolePermissionGroupsGetResource =
"dfareporting" :>
"v3.2" :>
"userprofiles" :>
Capture "profileId" (Textual Int64) :>
"userRolePermissionGroups" :>
Capture "id" (Textual Int64) :>
QueryParam "alt" AltJSON :>
Get '[JSON] UserRolePermissionGroup
data UserRolePermissionGroupsGet = UserRolePermissionGroupsGet'
{ _urpggProFileId :: !(Textual Int64)
, _urpggId :: !(Textual Int64)
} deriving (Eq,Show,Data,Typeable,Generic)
userRolePermissionGroupsGet
:: Int64
-> Int64
-> UserRolePermissionGroupsGet
userRolePermissionGroupsGet pUrpggProFileId_ pUrpggId_ =
UserRolePermissionGroupsGet'
{ _urpggProFileId = _Coerce # pUrpggProFileId_
, _urpggId = _Coerce # pUrpggId_
}
urpggProFileId :: Lens' UserRolePermissionGroupsGet Int64
urpggProFileId
= lens _urpggProFileId
(\ s a -> s{_urpggProFileId = a})
. _Coerce
urpggId :: Lens' UserRolePermissionGroupsGet Int64
urpggId
= lens _urpggId (\ s a -> s{_urpggId = a}) . _Coerce
instance GoogleRequest UserRolePermissionGroupsGet
where
type Rs UserRolePermissionGroupsGet =
UserRolePermissionGroup
type Scopes UserRolePermissionGroupsGet =
'["https://www.googleapis.com/auth/dfatrafficking"]
requestClient UserRolePermissionGroupsGet'{..}
= go _urpggProFileId _urpggId (Just AltJSON)
dFAReportingService
where go
= buildClient
(Proxy :: Proxy UserRolePermissionGroupsGetResource)
mempty