According to the API specs for get-task-status-list, CLOUD_ACCOUNT_AGGREGATION is not a valid type to filter on. The valid values are QUARTZ, QUEUED_TASK and QPOC.
You would need to filter on the client side (which is fine since you’re using PowerShell) for the uniqueName property containing “Cloud Account Aggregation”
If you desire to have more than 90 rolling days of data in your report, I would suggest not using the task status API as the retention period is only 90 days
If you do not need the level of detail contained in the task-status API (accounts scanned, accounts created/updated/deleted), you can instead use the search-post API and search through events instead. You won’t get as much detail but you’ll have far more history available. It just depends on what you want.
Search Query
name:"Aggregate Source Account Failed" OR name:"Aggregate Source Account Passed"
If you are making a direct API call instead of using invoke-paginate with the PowerShell SDK, you’re only going to get 250 results, which could explain why you are missing data.
As I mentioned in my previous reply, you have to paginate through the results to get them all.
Like many of the SailPoint APIs, this endpoint only returns the first 250 records, even if there are more than 250 records that would have been returned by this query.
In order to retrieve all the records, you must make multiple queries returning 250 pages of results at a time, also known as paginating. You do this through the use of the query parameters limit and offset.
You can see how many result would be returned through the use of the count query parameter
count
boolean
If true it will populate the X-Total-Count response header with the number of results that would be returned if limit and offset were ignored.
Look and see how many results would be returned via this method. If it is more than 250, you have to paginate.
The reason I provided a script using the PowerShell SDK is there are built in methods like Invoke-Paginate to take care of this for you, which means you have to write much less code