[8WR] Twitch Integration

Unmaintained [8WR] Twitch Integration 1.2.0

No permission to buy ($20.00)
The first version of this addon was released back when Twitch's v1 API was available. Back then, accounts were strictly identified by channel names (for instance, mine is "8wayrun"). With the release of Twitch's v5 API, channel names can no longer be used as provider keys for XenForo External Authorizations... instead we have account IDs. Because of this, the old provider keys will have to be wiped out. What does this mean? It means ALL current external-account links on your forum for Twitch will be deleted... users will be required to link their accounts again.

I'm sorry about this; but its gotta be done with Twitch deprecating their v3 API later this year. If you would like to read more about these Twitch changes, you can check their blog article here. Take note of the first line of the article where they literally admit that these changes will break integrations with all addons ever made for the platform.

Version 1.2.0 also includes OAuth Login functionality for Twitch. Originally, I decided against this because Twitch's account creation system was extremely easy to game. However, since the release of their v3 API, they implemented stronger account confirmation systems, including the ability to verify emails. With that in, I feel its finally time to add in this long requested feature.
There was one query I forgot to update to the new Twitch v5 API changes... this hotfix is for that. After uploading this hotfix, you must click the "Save Changes" button in the options settings for this addon in the admin CP. After doing that, then click the "Expunge and Rebuild All Twitch Upgrades" button.
  • Like
Reactions: chikarkas36
Twitch is changing their API yet again next year... I swear they go through these APIs like tissue paper. In v5 of their API, queries to the API will no longer accept channel names as endpoints... instead they will only be accepting channel IDs (you would think they would display your channel ID ANYWHERE on their website if they were doing this change).

Because of these changes, you will need to go into your admin CP and click "Save Changes" once on the options screen for this addon. This will automatically populate your channels list with their relevant channel IDs. The ID field for the channels list is "readonly" and thus can not be edited manually.
  • Fixed some minor bugs and phrasing.
More updates and fixes for the previous updates. Thank you for being patient with me, since I don't have two partnered channels on Twitch, I haven't been really able to test the functionality that well and didn't program around potential clashes... They should be worked out now.
  • There is now a button in the "options" screen that expunges all current Twitch upgrades and manually runs the cronjob. Use this function if you think there is an error in your upgrades database (caused by user error?).
  • This addon will no longer spam your user change logs each night when the cronjob is run automatically.
  • Fixed an issue where users get promoted to the wrong usergroup.
  • Fixes an issue where a user would only get one user upgrade at a time.
  • The XenRio integration option in added in 1.0.6 now has an option to turn it on/off in the admin CP. It is off by default.
  • The usergroup upgrade option is now a "per channel" option. Each channel defined in the admin CP can now upgrade to a different usergroup. Make sure to set this up!
  • BUG FIX: fixed an $options error introduced in 1.0.6.
  • Updated all API calls to prepare for the new Twitch API changes coming on August 8.
  • If you have XenRio installed, this mod will now automatically submit linked twitch channels to your stream library moderation queue.
  • Changed event listeners from switch-case statements, to XenForo's event hint system. This should provide a marginal boost to performance with larger forums.
  • The page at "account/twitch" has been removed. The contents of it have been moved to XF's new "account/external-accounts" page.
  • There is now the ability to add MULTIPLE channels to the subscription checks. Now you can give users promotions based based on whether or not they have subscribed to any of a number of channels.