Skip to content

Instantly share code, notes, and snippets.

@darrenjrobinson
Last active March 13, 2019 02:51
Show Gist options
  • Save darrenjrobinson/76036faad118d316dce4b9f27a633b2e to your computer and use it in GitHub Desktop.
Save darrenjrobinson/76036faad118d316dce4b9f27a633b2e to your computer and use it in GitHub Desktop.
Search SailPoint IdentityNow Identities using PowerShell and oAuth Token. Associated Blog Post https://blog.darrenjrobinson.com/using-sailpoint-identitynow-v3-apis-with-powershell/
# Search Limit
$searchLimit = '100'
# Search Identities URI
$searchURI = "https://$($orgName).api.identitynow.com/v2/search/identities?"
# Query for Users on a Source
$query = '@accounts(Active Directory)'
# Search Accounts
$Accounts = Invoke-RestMethod -Method Get -Uri "$($searchURI)limit=$($searchLimit)&query=$($query)" -Headers @{Authorization = "Bearer $($Global:v3Token.access_token)"}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment