{-# 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.IAM.Projects.Roles.Get
(
ProjectsRolesGetResource
, projectsRolesGet
, ProjectsRolesGet
, prgXgafv
, prgUploadProtocol
, prgAccessToken
, prgUploadType
, prgName
, prgCallback
) where
import Network.Google.IAM.Types
import Network.Google.Prelude
type ProjectsRolesGetResource =
"v1" :>
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] Role
data ProjectsRolesGet = ProjectsRolesGet'
{ _prgXgafv :: !(Maybe Xgafv)
, _prgUploadProtocol :: !(Maybe Text)
, _prgAccessToken :: !(Maybe Text)
, _prgUploadType :: !(Maybe Text)
, _prgName :: !Text
, _prgCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsRolesGet
:: Text
-> ProjectsRolesGet
projectsRolesGet pPrgName_ =
ProjectsRolesGet'
{ _prgXgafv = Nothing
, _prgUploadProtocol = Nothing
, _prgAccessToken = Nothing
, _prgUploadType = Nothing
, _prgName = pPrgName_
, _prgCallback = Nothing
}
prgXgafv :: Lens' ProjectsRolesGet (Maybe Xgafv)
prgXgafv = lens _prgXgafv (\ s a -> s{_prgXgafv = a})
prgUploadProtocol :: Lens' ProjectsRolesGet (Maybe Text)
prgUploadProtocol
= lens _prgUploadProtocol
(\ s a -> s{_prgUploadProtocol = a})
prgAccessToken :: Lens' ProjectsRolesGet (Maybe Text)
prgAccessToken
= lens _prgAccessToken
(\ s a -> s{_prgAccessToken = a})
prgUploadType :: Lens' ProjectsRolesGet (Maybe Text)
prgUploadType
= lens _prgUploadType
(\ s a -> s{_prgUploadType = a})
prgName :: Lens' ProjectsRolesGet Text
prgName = lens _prgName (\ s a -> s{_prgName = a})
prgCallback :: Lens' ProjectsRolesGet (Maybe Text)
prgCallback
= lens _prgCallback (\ s a -> s{_prgCallback = a})
instance GoogleRequest ProjectsRolesGet where
type Rs ProjectsRolesGet = Role
type Scopes ProjectsRolesGet =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient ProjectsRolesGet'{..}
= go _prgName _prgXgafv _prgUploadProtocol
_prgAccessToken
_prgUploadType
_prgCallback
(Just AltJSON)
iAMService
where go
= buildClient
(Proxy :: Proxy ProjectsRolesGetResource)
mempty