Skip to main content

Resolved: Add User to Group and Check If already Exists | Power Automate | Office 365 Groups Connector

The context of this blog post is to add the AD Users into Office 365 Groups using Power Automate Flow.

For one requirement, when I was trying to implement I experienced the below error and thought this post would be helpful for someone in future encountering the same issue and would save some R&D time.

Error: One or more added object references already exist for the following modified properties: 'members'

Understanding the above error: When a user is already present in the group and we try to add him again using the 'Add member to group' Action of the Office 365 Groups connector we will get the above error.

Resolution:

We can check beforehand if the User is present in the target 'Office 365 Group' or not and add if not already present.

How To:,

Below is a snapshot of Power Automate flow should be self-explanatory

Use the 'List Group Members' to check if the user already exists and apply a filter to check for the existence of the required user record. If we don't find the user in the retrieved List then 'Add member to group'



Comments