Our app uses the following link to obtain photos from the Graph API.
https://graph.microsoft.com/beta/users/USER_ID/photo/$value
and this was working well until recently. 3-4 days ago we noticed that guest users in our Azure AD no longer have access to any profile images in the system, and get the following error:
{
"error": {
"code": "UnknownError",
"message": "{\r\n \"errorCode\": \"ErrorAccessDeniedForUser\",\r\n \"message\": \"Exception of type 'Microsoft.Fast.Profile.Core.Exception.ProfileUnauthorizedException' was thrown.\",\r\n \"target\": null,\r\n \"details\": null,\r\n \"innerError\": null,\r\n \"instanceAnnotations\": []\r\n}",
"innerError": {
"date": "2021-12-21T14:25:36",
"request-id": "9684bb8a-c2d9-4ecc-a97c-e2ea683038d6",
"client-request-id": "9684bb8a-c2d9-4ecc-a97c-e2ea683038d6"
}
}
}
"Regular" users are still able to access the profile images, it is just the guest users who cannot.
We also tried the same with the new, non-beta endpoint
https://graph.microsoft.com/v1.0/users/USER_ID/photo/$value
But we get the same result. We know that this was working until recently but no longer does.