XF2 [8WR] XenRio 2 (Streams) PRO

XF2 [8WR] XenRio 2 (Streams) PRO [Paid] 2.3.0.5

No permission to buy ($40.00)
@Jaxel

Approval queue has issues. Queue message in moderator panel just says...


Stream channel:

https://youtube.com/watch?v=


it doesn't link to the actual channel submitted by the user.

Error in admin cp...

  • XF\PrintableException: Job XF\Job\ApprovalQueueProcess: An error occurred while connecting with YouTube. Please try again later.
  • src/addons/EWR/Rio/Api/YouTube.php:74
  • Generated by: Unknown account
  • Jan 17, 2026 at 8:27 PM

Stack trace​

#0 [internal function]: EWR\Rio\Api\YouTube::dumpChannel(Object(EWR\Rio\Entity\Service), Array, false)
#1 src/addons/EWR/Rio/Repository/Channel.php(93): call_user_func_array(Array, Array)
#2 src/addons/EWR/Rio/ApprovalQueue/Queue.php(23): EWR\Rio\Repository\Channel->scrapeChannel('https://youtube...', 9)
#3 src/XF/ApprovalQueue/AbstractHandler.php(201): EWR\Rio\ApprovalQueue\Queue->actionApprove(Object(EWR\Rio\Entity\Queue))
#4 src/XF/Job/ApprovalQueueProcess.php(71): XF\ApprovalQueue\AbstractHandler->performAction('approve', Object(EWR\Rio\Entity\Queue))
#5 src/XF.php(906): XF\Job\ApprovalQueueProcess->XF\Job\{closure}()
#6 src/XF/Job/ApprovalQueueProcess.php(57): XF::asVisitor(Object(Andrew\ModeratorPanel\XF\Entity\User), Object(Closure))
#7 src/XF/Job/Manager.php(275): XF\Job\ApprovalQueueProcess->run(8)
#8 src/XF/Job/Manager.php(205): XF\Job\Manager->runJobInternal(Array, 8)
#9 src/XF/Job/Manager.php(121): XF\Job\Manager->runJobEntry(Array, 8)
#10 job.php(25): XF\Job\Manager->runByIds(Array, 8)
#11 {main}

Request state​

array(4) {
["url"] => string(8) "/job.php"
["referrer"] => string(38) "https://website.com/approval-queue/"
["_GET"] => array(0) {
}
["_POST"] => array(0) {
}
}



8WAY.webp
 
Last edited:
Hey all, can anyone help please?

Ive added youtube and have that working with no issues

My problem is with twitch, added the api keys and added channels, it shows the channels available and chat which is working, but i get no video stream, i can click the twitch link and go to twitch and watch with no issue

thanks in advance if anyone knows the issue

>>> Found the issue to be brave browser and related to twitch block the browser as it blocks adverts
 
Last edited:
Hey @Jaxel I modified YouTube.php for my personal use to add game-specific stream matching for YouTube. Since YouTube deprecated their Freebase topic IDs, there's no way to match streams to specific games like Twitch and Kick can. The spelling field only accepts broad categories like "Gaming" which doesn't help when you want separate categories for different games.

My modification adds a "t:" prefix for the YouTube spelling field with the format t:SearchQuery|keyword1,keyword2,keyword3. The search query before the pipe is what gets sent to the YouTube API, and the keywords after it are used to verify and distribute results to the correct game. For example:

  • FF7: t:Final Fantasy|Final Fantasy VII,FF7,FFVII
  • FF8: t:Final Fantasy|Final Fantasy VIII,FF8,FFVIII
  • FF8R: t:Final Fantasy|Final Fantasy VIII Remastered,FF8 Remastered,FFVIII Remastered
  • FF9: t:Final Fantasy|Final Fantasy IX,FF9,FFIX
  • FFX: t:Final Fantasy|FFX,FF10,Final Fantasy X ,Final Fantasy X/X-2,Final Fantasy 10,Final Fantasy X HD

The key feature is that all games sharing the same search query use ONE YouTube API call. So all your Final Fantasy games only hit the API once, and the results get distributed to the correct game based on keyword matching against the stream title and description. This keeps API usage low.

It also includes a 1-hour cache using XenForo's simpleCache to stay within YouTube's free API quota (10,000 units/day). With this approach you can have multiple franchise groups (Final Fantasy, Resident Evil, etc.) each only costing one API call per hour.

Additionally, manually added YouTube channels now get categorized into the correct game using the same keyword matching, so a channel streaming Tomb Raider won't incorrectly appear under Final Fantasy VII.

Everything is backward compatible, no database changes, and the original category-based matching still works. If you're interested I can share the modified file. Happy to contribute it if it's useful for a future update.

1773194441868.webp
1773196992256.webp
 
Last edited:
Great job! Would make YouTube usable for those who need game filtering. Maybe Jaxel can have a look and implement it =)
 
After looking through @AxlRose's code, I realized it's not viable for various reasons. Though I did discover a better solution in the process.

As for the reasons why it doesn't work, firstly just doing a query for something like Starcraft would produce hundreds of erroneous results, because it searches all fields: titles, descriptions, etc. Changing the query to t:Starcraft limits the search specifically to searching only the tags field. This greatly reduces the results, but still has many errors. Many people will simply flood their videos will hundreds of extra tags specifically to abuse this very search system, and many people don't even bother tagging their videos in the first place.

The second issue with this method is it uses the YouTube API's search query system. When YouTube deprecated their Freebase topic system, they also changed the way API limits work. They added weight values to various types of searches. Searching directly for videos cost 3 points, and each additional piece of information adds another point. So pinging the API for video information usually costs about 4 points on average (it's not exact, because you can group queries together to reduce API calls). The more channels you have, and the more results you get, and the more points your query will cost.

However, with broad search queries, as the one that @AxlRose is using, YouTube's base cost is not 3 points, but 100. If you are scraping for streams every 10 minutes, then you are spending a minimum of 600 points per hour. If your daily limit on the YouTube API is 3,000 credits, then you'll only be able to scrape for a maximum of 5 hours in a day before you get rate limited out. I myself have a credit limit of 15,000, but that's because I'm grandfathered in.

This is why we don't ping the YouTube API with base search queries and instead use a simple http fetch and pull the actual HTML from a page and parse through that using preg_matches. It doesn't ping the API at all and doesn't have a credit cost. Only after parsing through the matches, do we start pinging the YouTube API for exact video matches at 4 points on average. This is also why fetching from YouTube is a constantly moving target, as they change the construction of their website.

As for the better solution... I have discovered that YouTube started creating auto-generated "channels" for games, such as:

We can scrape these channels, using similar methods. So the "spelling" for Starcraft would be: channel/UCkeZMocgb7uHpndXTYWWqAw. I am currently testing this new solution on my dev site and hope to release by the end of the week.
 
After looking through @AxlRose's code, I realized it's not viable for various reasons. Though I did discover a better solution in the process.

As for the reasons why it doesn't work, firstly just doing a query for something like Starcraft would produce hundreds of erroneous results, because it searches all fields: titles, descriptions, etc. Changing the query to t:Starcraft limits the search specifically to searching only the tags field. This greatly reduces the results, but still has many errors. Many people will simply flood their videos will hundreds of extra tags specifically to abuse this very search system, and many people don't even bother tagging their videos in the first place.

The second issue with this method is it uses the YouTube API's search query system. When YouTube deprecated their Freebase topic system, they also changed the way API limits work. They added weight values to various types of searches. Searching directly for videos cost 3 points, and each additional piece of information adds another point. So pinging the API for video information usually costs about 4 points on average (it's not exact, because you can group queries together to reduce API calls). The more channels you have, and the more results you get, and the more points your query will cost.

However, with broad search queries, as the one that @AxlRose is using, YouTube's base cost is not 3 points, but 100. If you are scraping for streams every 10 minutes, then you are spending a minimum of 600 points per hour. If your daily limit on the YouTube API is 3,000 credits, then you'll only be able to scrape for a maximum of 5 hours in a day before you get rate limited out. I myself have a credit limit of 15,000, but that's because I'm grandfathered in.

This is why we don't ping the YouTube API with base search queries and instead use a simple http fetch and pull the actual HTML from a page and parse through that using preg_matches. It doesn't ping the API at all and doesn't have a credit cost. Only after parsing through the matches, do we start pinging the YouTube API for exact video matches at 4 points on average. This is also why fetching from YouTube is a constantly moving target, as they change the construction of their website.

As for the better solution... I have discovered that YouTube started creating auto-generated "channels" for games, such as:

We can scrape these channels, using similar methods. So the "spelling" for Starcraft would be: channel/UCkeZMocgb7uHpndXTYWWqAw. I am currently testing this new solution on my dev site and hope to release by the end of the week.
That's a way better approach honestly. The auto-generated game channels solve the core problem cleanly without burning through API credits on search queries. I knew the search cost was high which is why I added the caching and query grouping, but 100 credits per search vs scraping a channel page at zero cost isn't even a comparison.

The keyword matching against titles/descriptions was the best I could come up with at the time since the Freebase deprecation left a pretty big gap, but yeah the false positive issue is real. Looking forward to testing the channel-based solution when it drops.
 
Jaxel updated XF2 [8WR] XenRio 2 (Streams) PRO with a new update entry:

2.3.0.5 - CHANGELOG

  • YouTube game scrapping is now back! Since YouTube deprecated their Freebase topic system, game spellings were lost. YouTube has since started creating "auto-generated" channels which automatically list streams and videos on certain topics. Putting in the URL of one of these auto-generated channels as a spelling for a game, will allow the scraping of these channels. Below are several examples:

Read the rest of this update entry...
 
Back
Top Bottom