How do I retrieve the employee id using django?

Elton Tan Jin Rong 1 Reputation point
2021-08-05T04:59:50.567+00:00

I am trying to retrieve the employee id from Azure AD using Django. I am able to retrieve the name, email etc. Do I need to add the parameters to retrieve the employee id?

These are my parameters in the picture below.
120694-microsoftteams-image.png

Microsoft Security | Microsoft Entra | Microsoft Entra ID
{count} votes

1 answer

Sort by: Most helpful
  1. Siva-kumar-selvaraj 15,736 Reputation points Volunteer Moderator
    2021-08-09T11:25:27.45+00:00

    Hello @Elton Tan Jin Rong ,

    Thanks for reaching out.

    Could you please confirm graph_url being used to get user details by django? If you are using V1.0 which is (https://graph.microsoft.com/v1.0) then you need to switch it to MS Graph beta endpoint https://graph.microsoft.com/beta/ because "employeeId" is only available in MS Graph beta endpoint as of today.

    You can check this from Microsoft Graph Explorer as shown below :
    121637-image.png

    Hope this helps.

    Reference: https://learn.microsoft.com/en-us/graph/tutorials/python?tutorial-step=3

    ------
    Please "Accept the answer" if the information helped you. This will help us and others in the community as well.

    1 person found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.