Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Create SailPoint IdentityNow Governance Group. Associated Blog Post can be found here
$baseURI = "https://$($orgName)"
# Governance Group Owner
$query = "darrenrobinson_admin"
$Accounts = Invoke-RestMethod -Method GET -Uri "$($SearchURI)limit=$($searchLimit)&query=$($query)" -Headers @{Authorization = "Basic $($encodedAuth)" }
$GovGroupOwner = $Accounts[0]
$body = @{"name" = "Vendor - Darren J Robinson";
"displayName" = "Darren J Robinson";
"description" = "Darren J Robinson";
"owner" = @{"displayName" = $GovGroupOwner.displayName;
"emailAddress" = $;
"id" = $;
"name" = $
$body = $body | Convertto-json
$createGovGroup = Invoke-RestMethod -Method POST -Uri "$($baseURI)/v2/workgroups?&org=$($orgName)" -Headers @{Authorization = "Basic $($encodedAuth)"} -Body $body
if ($createGovGroup.memberCount.Equals(0)){
write-host -ForegroundColor Green "Created Governance Group"
} catch {
write-host -ForegroundColor Red "Problem creating Governance Group"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.