Recent searches


No recent searches

Search API returning tickets with out of date status values

Answered


Posted Sep 05, 2022

Hello, I am creating and modifying tickets via the REST api, then performing searches using the search API as well.

A frequent use case is setting the status to "solved", then soon after searching tickets based on subject string and status:open, and I'll receive back tickets that just should have been set to status:solved.  Is this expected behavior?  Is there a lag on some API operations, such as modifying status, and the search API getting returning those updated results?  If I wait and indeterminate time, say 1 minute, and search I get expected results based on recent status modifications.


0

4

4 comments

As added info here, when I make a new ticket via the API, and search soon after it also doesn't return expected results.  And again, if I wait a minute or so it does.

0


This is expected behaviour, it threw me off the first time too. The search API seems to use cached results and I think data can be anywhere up to 5 mins out of date from my experience.

You may be better off using the incremental export API to get the data you need and then filtering it.

1


Hi :) We face the same issue :( What are the safe intervals to run API requests to make sure they will return all the data? Making calls every 3 minutes results in data loss from time to time, which is bad... We deal with a lot of API and no other tool has similar issues, no idea why Zendesk has done it in such a bad way :(

0


image avatar

Greg Katechis

Zendesk Developer Advocacy

Hi Jacek! 

 

If your situation is similar to the others above, the delay can take up to a couple of minutes, due to indexing and propagation via search functionalities. If you want to call the ticket directly, you should get fairly instant results, but any search feature will need time to index.

0


Please sign in to leave a comment.

Didn't find what you're looking for?

New post