Post Man API Call - Cloud life cycle state

Hello All,

The API call is listing all the users from the sources,

{{baseUrl}}/accounts?filters=sourceId eq “appSourceID”&cloudLifecycleState=inactive

The requirement is to have to list all the users having cloud life cycle state as inactive from a specific source

Thanks,
Anirban

Hi @AllIT

I don’t think cloudLifecycleState is a filterable attribute on the accounts or identities API. I would use the search API for this use case:

POST https://<TENANT>.api.identitynow.com/v2026/search

{
  "indices": [
    "identities"
  ],
  "query": {
    "query": "attributes.cloudLifecycleState:\"inactive\""
  },
  "sort": [
    "name"
  ]
}

EDIT
Didn’t see your requirement for filtering on the source as well, this should work for that use case:

{
  "indices": [
    "identities"
  ],
  "query": {
    "query": "attributes.cloudLifecycleState:\"inactive\" AND source.name:\"SOURCENAMEHERE\""
  },
  "sort": [
    "name"
  ]
}

Hi @AllIT ,

Based on my understanding, cloudLifecycleState is an identity-level attribute and is not directly filterable at the account level. Since accounts are source-level objects, they cannot be filtered using cloudLifecycleState.You can only get accounts by using above API call.
As suggested by @trettkowski you can use Search API call to achieve your use case.

Thank you.