We have a requirement to remove the user from all cloud groups (not on-premises AD managed groups) in the Azure Entra application account when the user leaves the organization.
We are using the direct Azure Active Directory connector to connect to Azure AD tenant.
When we try to remove these cloud groups, we are receiving the below 403 error:
Error: Response Code - 403 Error - Insufficient privileges to complete the operation
We are provided with all the permissions that are necessary to perform this action but still receiving the same error.
The permissions that are provided to our service account are:
Microsoft graph API permissions:-
GroupMember.ReadWrite.All (Application)
Group.ReadWrite.All (Application)
Service account’s permission:-
Groups Administrator
User Administrator
Can someone please check on this and let me know if any other permissions need to be assigned or something else can be done here.