Disabled/Blocked Users not getting added as member to teams using graph api

Legion Squad 1 Reputation point
2022-11-17T09:28:44.923+00:00

Disabled/Blocked Users not getting added as member to teams using this graph api https://learn.microsoft.com/en-us/graph/api/team-post-members?view=graph-rest-1.0&tabs=http and getting error message

innerError":{"message":"User 'd7bc3af8-e652-4969-b917-c15a27b8e499' does not exist.","code":"ItemNotFound","innerError":{},"date":"2022-11-09T09:54:58","request-id":"cecea30e-e5e8-44ee-b0f8-57977169e9bd","client-request-id":"cecea30e-e5e8-44ee-b0f8-57977169e9bd"}

So wanted to know is this something not allowed by Azure only and any specific reason for the same. Or is there any alternative to resolve this.

Azure Active Directory
Azure Active Directory
An Azure enterprise identity service that provides single sign-on and multi-factor authentication.
14,665 questions
Microsoft Graph Teamwork API
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Vasil Michev 70,806 Reputation points MVP
    2022-11-17T09:40:56.507+00:00

    That's by design, disabled users cannot use Teams and are automatically removed from any team they're a member of. The behavior is detailed for example here: https://learn.microsoft.com/en-us/microsoftteams/troubleshoot/channels/logon-reenabled-user-not-see-previous-joined-teams
    It's a poor design, I know, but try convincing Microsoft of the same...

    0 comments No comments