{-# 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.ServiceAccounts.Keys.Get
(
ProjectsServiceAccountsKeysGetResource
, projectsServiceAccountsKeysGet
, ProjectsServiceAccountsKeysGet
, psakgXgafv
, psakgUploadProtocol
, psakgAccessToken
, psakgUploadType
, psakgName
, psakgPublicKeyType
, psakgCallback
) where
import Network.Google.IAM.Types
import Network.Google.Prelude
type ProjectsServiceAccountsKeysGetResource =
"v1" :>
Capture "name" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "publicKeyType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] ServiceAccountKey
data ProjectsServiceAccountsKeysGet = ProjectsServiceAccountsKeysGet'
{ _psakgXgafv :: !(Maybe Xgafv)
, _psakgUploadProtocol :: !(Maybe Text)
, _psakgAccessToken :: !(Maybe Text)
, _psakgUploadType :: !(Maybe Text)
, _psakgName :: !Text
, _psakgPublicKeyType :: !(Maybe Text)
, _psakgCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
projectsServiceAccountsKeysGet
:: Text
-> ProjectsServiceAccountsKeysGet
projectsServiceAccountsKeysGet pPsakgName_ =
ProjectsServiceAccountsKeysGet'
{ _psakgXgafv = Nothing
, _psakgUploadProtocol = Nothing
, _psakgAccessToken = Nothing
, _psakgUploadType = Nothing
, _psakgName = pPsakgName_
, _psakgPublicKeyType = Nothing
, _psakgCallback = Nothing
}
psakgXgafv :: Lens' ProjectsServiceAccountsKeysGet (Maybe Xgafv)
psakgXgafv
= lens _psakgXgafv (\ s a -> s{_psakgXgafv = a})
psakgUploadProtocol :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
psakgUploadProtocol
= lens _psakgUploadProtocol
(\ s a -> s{_psakgUploadProtocol = a})
psakgAccessToken :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
psakgAccessToken
= lens _psakgAccessToken
(\ s a -> s{_psakgAccessToken = a})
psakgUploadType :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
psakgUploadType
= lens _psakgUploadType
(\ s a -> s{_psakgUploadType = a})
psakgName :: Lens' ProjectsServiceAccountsKeysGet Text
psakgName
= lens _psakgName (\ s a -> s{_psakgName = a})
psakgPublicKeyType :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
psakgPublicKeyType
= lens _psakgPublicKeyType
(\ s a -> s{_psakgPublicKeyType = a})
psakgCallback :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
psakgCallback
= lens _psakgCallback
(\ s a -> s{_psakgCallback = a})
instance GoogleRequest ProjectsServiceAccountsKeysGet
where
type Rs ProjectsServiceAccountsKeysGet =
ServiceAccountKey
type Scopes ProjectsServiceAccountsKeysGet =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient ProjectsServiceAccountsKeysGet'{..}
= go _psakgName _psakgXgafv _psakgUploadProtocol
_psakgAccessToken
_psakgUploadType
_psakgPublicKeyType
_psakgCallback
(Just AltJSON)
iAMService
where go
= buildClient
(Proxy ::
Proxy ProjectsServiceAccountsKeysGetResource)
mempty