{-# 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.Roles.QueryGrantableRoles
(
RolesQueryGrantableRolesResource
, rolesQueryGrantableRoles
, RolesQueryGrantableRoles
, rqgrXgafv
, rqgrUploadProtocol
, rqgrAccessToken
, rqgrUploadType
, rqgrPayload
, rqgrCallback
) where
import Network.Google.IAM.Types
import Network.Google.Prelude
type RolesQueryGrantableRolesResource =
"v1" :>
"roles:queryGrantableRoles" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] QueryGrantableRolesRequest :>
Post '[JSON] QueryGrantableRolesResponse
data RolesQueryGrantableRoles = RolesQueryGrantableRoles'
{ _rqgrXgafv :: !(Maybe Xgafv)
, _rqgrUploadProtocol :: !(Maybe Text)
, _rqgrAccessToken :: !(Maybe Text)
, _rqgrUploadType :: !(Maybe Text)
, _rqgrPayload :: !QueryGrantableRolesRequest
, _rqgrCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
rolesQueryGrantableRoles
:: QueryGrantableRolesRequest
-> RolesQueryGrantableRoles
rolesQueryGrantableRoles pRqgrPayload_ =
RolesQueryGrantableRoles'
{ _rqgrXgafv = Nothing
, _rqgrUploadProtocol = Nothing
, _rqgrAccessToken = Nothing
, _rqgrUploadType = Nothing
, _rqgrPayload = pRqgrPayload_
, _rqgrCallback = Nothing
}
rqgrXgafv :: Lens' RolesQueryGrantableRoles (Maybe Xgafv)
rqgrXgafv
= lens _rqgrXgafv (\ s a -> s{_rqgrXgafv = a})
rqgrUploadProtocol :: Lens' RolesQueryGrantableRoles (Maybe Text)
rqgrUploadProtocol
= lens _rqgrUploadProtocol
(\ s a -> s{_rqgrUploadProtocol = a})
rqgrAccessToken :: Lens' RolesQueryGrantableRoles (Maybe Text)
rqgrAccessToken
= lens _rqgrAccessToken
(\ s a -> s{_rqgrAccessToken = a})
rqgrUploadType :: Lens' RolesQueryGrantableRoles (Maybe Text)
rqgrUploadType
= lens _rqgrUploadType
(\ s a -> s{_rqgrUploadType = a})
rqgrPayload :: Lens' RolesQueryGrantableRoles QueryGrantableRolesRequest
rqgrPayload
= lens _rqgrPayload (\ s a -> s{_rqgrPayload = a})
rqgrCallback :: Lens' RolesQueryGrantableRoles (Maybe Text)
rqgrCallback
= lens _rqgrCallback (\ s a -> s{_rqgrCallback = a})
instance GoogleRequest RolesQueryGrantableRoles where
type Rs RolesQueryGrantableRoles =
QueryGrantableRolesResponse
type Scopes RolesQueryGrantableRoles =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient RolesQueryGrantableRoles'{..}
= go _rqgrXgafv _rqgrUploadProtocol _rqgrAccessToken
_rqgrUploadType
_rqgrCallback
(Just AltJSON)
_rqgrPayload
iAMService
where go
= buildClient
(Proxy :: Proxy RolesQueryGrantableRolesResource)
mempty