Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Manage SailPoint IdentityNow Governance Group Membership. Associated Blog Post can be found here
# ID of the Governance Group that we just created
# Get GROUP MEMBERS to add
$query = "darren"
$govGroupMembers = Invoke-RestMethod -Method GET -Uri "$($SearchURI)limit=$($searchLimit)&query=$($query)" -Headers @{Authorization = "Basic $($encodedAuth)" }
$govGroupMembers = $govGroupMembers | Sort-Object | Select-Object -Property id -Unique
# Add members
foreach ($member in $govGroupMembers){
$add += $
$govGroupsMembers =@{
add = $add
remove = $remove
$govGroupsMembersBody = $govGroupsMembers | ConvertTo-Json
# GovernanceGroup Update URI
$govGroupMembersURI = "https://$($orgName)$($"
# Update Goverance Group
Invoke-RestMethod -Uri $govGroupMembersURI -Method POST -Body $govGroupsMembersBody -Headers @{Authorization = "Basic $($encodedAuth)"; "content-type" = "application/json"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment