We have developed an MS Teams Tab app. One of its features allows users to set their MS Teams status directly from our app. We use the setUserPreferredPresence endpoint of the Microsoft Graph API to update the status. While this functionality generally works well, we have encountered an issue when a user sets their status to “Away” in MS Teams and remains inactive for more than 15-20 minutes. In this scenario, when we call the Graph API to update the status using setUserPreferredPresence, we receive a 200 OK response from Graph, but user’s status does not change in Teams.
Our API call to the Graph API looks like this: https://graph.microsoft.com/v1.0/users/${ids}/presence/setUserPreferredPresence. This works for other statuses but fails when trying to update from “Away.”
any help would be appreciated. Thanks