
ArvS.21281 (Customer) asked a question.
It appears when I use pagination as defined in API documentation for event log retrieval, the response is disregarding my date range and providing data for a default range of about one week. I am wondering if I have syntax or sequencing of parameters wrong. Also, noticing that the link to "next" page found in header response is dropping the date range specified. Here is sample:
Thank you for any insights/guidance provided.

Hi @ArvS.21281 (Customer) , Thank you for reaching out to the Okta Community!
Just to clarify, the Events API should be deprecated as per the following documentation:
https://support.okta.com/help/s/article/FAQ-Events-API-End-of-Life
https://developer.okta.com/docs/concepts/events-api-migration/
That being said, judging by the sample provided you are using the System Log API.
The "q" parameter is not required and for time frames you need to use the "since" and "until" parameters as per de above documentation.
Example:
/api/v1/logs?filter=event_type+eq+%22user.authentication.sso%22+and+target.type+eq+%22AppInstance%22+and+target.id+eq+%220oa3xdb0yoHyzocqH697%22&since=2023-02-01T00%3A00%3A00%2B00%3A00&until=2023-04-04T23%3A59%3A59%2B00%3A00
*Extra notes: - make sure to change the above time frames to suit your needs (I just use those to confirm things in my org)
- the target.type+eq+%22AppInstance%22 filter might also be redundant if you specify the exact app ID under target.id+eq+... , but you might need to confirm that on your end depending on your requirements.
If my answer helped, remember to mark it as best to increase its visibility for other members of the Okta Community who might have the same questions as you.
Hope my answer helps!
--------------------------------
Community members help others by clicking Like or Select as Best on responses. Try it today.