0

I am using the Microsoft Graph API in my ASP.NET MVC application. The issue occurs when removing the user from the group and again adding the same user to the same group.

I am getting an exception that a user already exists in the group. If I try after 10 seconds, then it is working fine.

The issue I have to wait for 10 seconds between removing and adding the user to the group.

Is there any solution for this delay, or after removing the user, is any refresh option available?

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
  • I don't think so. The same effect occurs also in the Azure portal. If you remove a member and refresh the list you see him again and after refreshing a few seconds later the user is really gone. All you can do, is retrying every second and handle the error code till it succeeded. – Oliver Jul 04 '23 at 17:34
  • Yeah, I am removing the user from the group, and after that, I am ensuring whether the user exists or not. If it exists, It will prevent Try adding the user again to the group. but after the 10-second latency, the user was removed. When I check whether the user exists or not, it indicates that the user does not exist. So that's why is there anyway to refresh it like what we do in the Azure portal, like that same anything available in the GRAPH API SDK? – madhavan_sof Jul 07 '23 at 06:11
  • As mentioned in the document there is a know delay of 10 seconds of the deletion:https://learn.microsoft.com/en-us/graph/known-issues#removing-a-group-owner-also-removes-the-user-as-a-group-member – Mehtab Siddique Jul 11 '23 at 09:55

0 Answers0