So I am slowly getting the hang of using ajax requests under jquery , but I noticed that
GET requests (see code) seem to take ages (~50s) to update follower count etc .
Is this normal ? If so , how come follower alerts like Nightdevs register followers/subs almost instantly ?
Thanks for the help
Iām sure Night will correct me. But the Night follower updater, on a decent hit gets a nice chunk of followers to work thru (on the dropdown/popup) so by the time itās finished animating them all, a nice new stack is ready.
But Twitch advises that you shouldnāt be hitting more than once per minute on a given end point, as the end point is āstaticā for that minute and updates once per minute or so anyway. Fugi posts about the ācacheā here
Subscribers updates in real time as Night is polling Twitch chat for the āx has subscribedā message in chat.
I have seen the same behaviour you describe, (taking a minute to change) when polling the followers end point. Itās not a fault. Itās just how it works. And other trackers/larger channels just illusion quicker as large channels, get large stacks of new followers per minute, so a queue exists to process the stack.
This is essentially what is going on. As far as Iāve come to understand, Twitch now heavily caches the followers endpoint now due to the excessive use by alerters. Even so, my alerter polls once per 15 seconds. Itās possible that the longer caching is what is causing your alerts to show up slower.
I run a websocket TMI relay service that allows me to listen for new subscribers in chat. I donāt poll any endpoint for subscribers.