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 Entra ID
Microsoft Entra ID
A Microsoft Entra identity service that provides identity management and access control capabilities. Replaces Azure Active Directory.
22,220 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Saurabh Sharma 23,816 Reputation points Microsoft Employee
    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.


Your answer

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