So you guys made this flow
but it does not work on nested security groups (so basic!!!)
ok, I thought.. let's do it myself.
all I need to do to make a recursive or loop that will check the @OData.type value for a group, if its a group, populate the members of that group and add them to an array of people
but, it's so complicated to make basic things inflow such as appending an array inside an array
why so complicated?
why there are composed, but not delete/remove function
The only way I've found to do those kinds of recursion actions is to put the lookup and extraction of users into a child flow that returns an array of users. Then when you find a nested group you can call the child flow to process it. If the child flow finds a nested group it can call another instance. But I agree recursion isn't easy in Power Automate. in general writing recurrence functions isn't easy in any computer system.
Hi,
I know 365 groups cant be nested.
Im trying to copy all the members of security groups to 365 group
The problem is when the security group have other group inside.
So if you could share a flow that does this, it woold be appricated, i know its possible
Office 365 groups can't be nested, so that may be one of the issues you are having. But if you explain the issue you are having with the array I will try to help. The easiest way to do that is to
1) Initialize a variable of type array
2) in a Loop Append a value to the array using JSON formatting. You can copy an individual JSON record for a person and then substitute the values from dynamic content fairly easily.
Michael E. Gernaey
497
Super User 2025 Season 1
David_MA
436
Super User 2025 Season 1
Riyaz_riz11
244
Super User 2025 Season 1