Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save darrenjrobinson/9a5b899261db80814741e3e697a10c0e to your computer and use it in GitHub Desktop.
Save darrenjrobinson/9a5b899261db80814741e3e697a10c0e to your computer and use it in GitHub Desktop.
Remove the visibility of IdentityNow Applications from users. Associated Blog Post can be found here https://blog.darrenjrobinson.com/managing-sailpoint-identitynow-applications-via-api-with-powershell/
$time = [int][double]::Parse((Get-Date -UFormat %s))
$appListURI = "https://$($orgName).api.identitynow.com/cc/api/app/list?filter=org&_dc=$($time)"
$appList = Invoke-RestMethod -Uri $appListURI -Method Get -WebSession $IDN
$appUpdateURI = "https://$($orgName).api.identitynow.com/cc/api/app/update"
# Turn off App Visibility in Request Centre
$appBody = @{
"launchpadEnabled" = $false ;
"provisionRequestEnabled" = $false ;
"appCenterEnabled" = $false
}
$body = $appBody | ConvertTo-Json
if ($appList) {
foreach ($app in $appList) {
write-host -ForegroundColor Green "Disabling App: $($app.name)"
try {
$updateResponse = Invoke-RestMethod -Uri "$($appUpdateURI)/$($app.id)" -Method POST -Body $body -WebSession $IDN
}
catch {
write-host -ForegroundColor Red "Failed to update app $($app.name)"
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment