graph api update keeps throwing error during a few seconds for an invited guest user after creation

Simoes, Ruben Raposo 1 Reputation point
2022-07-29T13:57:08.737+00:00

graph api update keeps throwing error during a few seconds for an invited guest user after creation despiste working for a get operation.
Our workflow is the following:
1 - invite the user
2 - obtain the user id from the response payload
3 - use the id to do a get user
4 - update some data on the user
And sometimes the update fails with the following error despite the get user working correctly:
226203-errorgraphapi.png

Here is a code snippet:
226150-codesnippet.png

Microsoft Security | Microsoft Graph
{count} votes

1 answer

Sort by: Most helpful
  1. Vicky Kumar (Mindtree Consulting PVT LTD) 1,161 Reputation points Microsoft Employee
    2022-08-08T06:42:26.82+00:00

    This is a good practice to wait for some time while creating and updating, because object creating and object updating takes some time to reflect, so wait for a bit until the first process will successfully completed, we really recommend this to avoid unwanted failure.

    Hope this make sense

    Thanks

    1 person found this answer helpful.
    0 comments No comments

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.