GetQueriesAlertsV2 shows wrong count when compared to console #1153
-
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 5 replies
-
Hi @Ni-ka-sH thanks for the question! It looks to me like this comes down to differences in the filtering when using the UI vs. the API. Let me show an example. When I load up the new endpoint detection experience I see the below: 19,652 total results. This is without any filtering. One item of note however is that the UI hides hidden items and this cannot be changed. Another change to keep in mind is that the timestamp filters are not exactly the same in the UI so you may see slightly different results in the UI based on this. As far as the pagination you need to specify an offset to get to the next page which works something like this.
From your query above you'll need to provide the Let us know with any questions on this |
Beta Was this translation helpful? Give feedback.
HI @Ni-ka-sH
Few items on the pagination, this API returns a maximum of 10000 records. The Limit + Offset must always be less than 10k records.
To get around this limitation I reccomend using a filter to reduce the total count below 10000. Based on your environment there may be a few different options for this filter, timestamp is a good bet as you can use a rolling window.
For my usage I used a created_timestamp and the polling logic goes something like this
Make an initial call with no filter and limit 10000. Additionally sort the records using created_timestamp.asc which will return records sorted in ascending order by when they were last seen.
For each page of 10000 use the get_alerts…