Forum Discussion

Arulraj123's avatar
Arulraj123
Copper Contributor
Feb 19, 2020

Get the user role from Azure AD by Laravel azure ad oauth

I am trying to get the role form Azure AD by using metrogistics/laravel-azure-ad-oauth socialiate plugin.

I got the name and email and azure_id from the Azure. But I can't get the user role.

 

My callback url output below  

 

user: array:12 [
"@odata.context" => "https://graph.microsoft.com/v1.0/$metadata#users/$entity"
"businessPhones" => []
"displayName" => "Test4"
"givenName" => "Test4"
"jobTitle" => null
"mail" => null
"mobilePhone" => null
"officeLocation" => null
"preferredLanguage" => null
"surname" => null
"userPrincipalName" => "test4@xyz.com"
"id" => "xyz"
]

 

It is possible to get the role from Azure

No RepliesBe the first to reply

Resources