TLDR:
- Why is the /channels/(id)/subscriptions inconsistent for calculating subpoints compared to dashboard?
- Is there an endpoint giving me a more accurate number?
I tried to calculate subpoints (for unlocking emotes with the new tiers) to be used for unlocking different goals/events during an anniversary stream.
I used the https://api.twitch.tv/kraken/channels/(id)/subscriptions endpoint for this purpose. I started by only reading the unique last entry for each user, hence ignoring not older and not yet expired double subscription remaining after upgrading tiers, and then simply adding one point for 1000-sub 2 points for 2000 and 6 points for 3000.
This worked just fine at first, but the day before the stream the script was intended to be used for, we noticed that the dashboard was showing one less than this calculation ended up with, and I just manually corrected it. However, during the stream, while people were upgrading and subscribing, the number started to deviate even more, ending up with a 12 points gap between this calculation from the API compared to the dashboard, where the dashboard was showing more than this calculation from the channels/(id)/subscriptions endpoint.
Is there a preferred method to calculate this that I didn’t find, or is there any endpoint simply showing the correct number, matching the current one in the dashboard? And how come these numbers differ this much?