Graph has no single endpoint to return all user profile photos. You have to call Get Profile Photo for each user.
So for any list of users, the profile photo can be constructed using https://graph.microsoft.com/v1.0/users/{user-id}/photo/$value
Can I get all profilephoto of all users inorganization along with user data in single query from Azure AD?
Dev
106
Reputation points
I am trying to retrieve all the users from the organisation which is working fine but I need to get the profile picture object as well along with the information of the user.
So I need to call api again for every user in order to get the profile picture or is there a way to get profilePhoto in the same "/users" get methods.
Thanks in advance
1 answer
Sort by: Most helpful
-
Danstan Onyango 3,726 Reputation points Microsoft Employee
2021-03-31T08:46:12.157+00:00