AZURE AD GRAPH API - Domain Based Filtering Not Working , Returns All Users

Dev User 1 Reputation point
2020-06-22T13:42:08.44+00:00

Hello. I want to filter users based on domains. I tried to do so in the following manner using Azure AD Graph API:

https://graph.windows.net/\<domain-name>/users

The issue I am facing is that I have 2 domains with 2 users each, but whichever domain I try to query on, it returns all the users regardless.

So, for example, if 2 domains are: abcd.com and xyz.com, then:

https://graph.windows.net/abcd.com/users

https://graph.windows.net/xyz.com/users

Both these urls return the same set of users.

Can anyone help in understanding the issue here?

OR

Let me know another way to filter users on domains?

Thank you. :)

Microsoft Security | Microsoft Entra | Microsoft Entra ID
0 comments No comments

1 answer

Sort by: Most helpful
  1. Saurabh Sharma 23,866 Reputation points Microsoft Employee Moderator
    2020-06-22T23:49:25.607+00:00

    @DevUser-4116 Sorry, unfortunately this is not possible in Azure AD Graph API or in the new Microsoft Graph API.
    Also, it is recommended to use Microsoft Graph API instead as there are no further enhancements planned for Azure AD Graph API's.
    I suggest you please provide this as a feedback at Microsoft Graph Feature Requests site for community to upvote and products team to consider this in future releases of Microsoft Graph.

    Was this answer helpful?


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.