Problem with polling API

I’m building an Android app which polls Twitch API resources to get stream’s online status, viewer and follower counts, followers list to notify user on changes. It polls each resource every 5 seconds by default.
The problem came when I did new follower notification. I was comparing recieved follower list with one from previous request and extracting new follower. The next response from API was without the new follower and the next with triggering notification again. So I worked around it, made an another check.
Now I made notification for stream’s online status by polling “” same way. Sometimes I get multiple online/offline notifications while channel goes online only once. It is not consistent though.
I’m asking if it’s known behavior? Maybe I’m polling to often? Or maybe Twitch is caching data in some strange way while it’s under load?
Did not found any mentions of this problem by search.

My guess would be that the requests are being handled by different servers which might have slightly different data cached.

That doesn’t help me but thanks for reply anyway.

Increasing your polling interval or keeping track of what followers have already been alerted (also prevents follow/unfollow spam) is probably your best options.

I am confirming inconsistent behavior where the API reports that live streams are offline, or at the least, the requested live stream list randomly comes back empty. I confirmed this by manually checking and refreshing a stream list with streams known to be online.

Like this, except with actually online streams:,two,three,four,five

Do that, refresh it a good handful of times – 10 … 20 maybe… and it will randomly come back empty, like this:

I ended up compensating for this on my end by making sure more than one check has passed before calling it offline, but I’d guess this is the same issue OP was having. This has been happening for a long time, and still today.