[PR #79] [MERGED] feat: add twitch vod/clip support #1007

Closed
opened 2025-11-09 10:03:56 -06:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/imputnet/cobalt/pull/79
Author: @Snazzah
Created: 2/4/2023
Status: Merged
Merged: 9/16/2023
Merged by: @wukko

Base: currentHead: feat/twitch


📝 Commits (8)

📊 Changes

9 files changed (+186 additions, -10 deletions)

View changed files

📝 README.md (+1 -0)
📝 src/modules/processing/hostOverrides.js (+8 -0)
📝 src/modules/processing/match.js (+8 -0)
📝 src/modules/processing/matchActionDecider.js (+1 -1)
src/modules/processing/services/twitch.js (+76 -0)
📝 src/modules/processing/servicesConfig.json (+7 -1)
📝 src/modules/processing/servicesPatternTesters.js (+6 -4)
📝 src/modules/sub/utils.js (+49 -3)
📝 src/test/tests.json (+30 -1)

📄 Description

I've tried out adding twitch support to this, it's a bit weird since I've had to change some stuff with the utils:

  • Added tld option to services so TLDs other than .com work (this should really be able to be set for each pattern though)
  • streamLiveRender() allows to just take one stream and an extra flag for m3u8 URLs so FFmpeg can take a m3u8 file and convert it to something else properly

Clips and VODs videos work, but requesting audio only from VODs and clips do not work at the moment. Not sure what combination of args will make that work but I couldn't get that bit working well.

You can test with these links:

Not sure what to show if the streamer was banned, so I just used the ErrorEmptyDownload error.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/imputnet/cobalt/pull/79 **Author:** [@Snazzah](https://github.com/Snazzah) **Created:** 2/4/2023 **Status:** ✅ Merged **Merged:** 9/16/2023 **Merged by:** [@wukko](https://github.com/wukko) **Base:** `current` ← **Head:** `feat/twitch` --- ### 📝 Commits (8) - [`fa7af1b`](https://github.com/imputnet/cobalt/commit/fa7af1bf444e3a473118ca5243380f32863d24cb) feat: add twitch vod/clip support - [`c8d0eb8`](https://github.com/imputnet/cobalt/commit/c8d0eb862cb00b6255776ae5cd7054db9b4dd951) chore: update readme - [`8551243`](https://github.com/imputnet/cobalt/commit/8551243207a798346c4c90434dd7f497d07de01c) Merge branch 'current' into feat/twitch - [`ff9d487`](https://github.com/imputnet/cobalt/commit/ff9d48740d77949905e39697893cae5cb73cc210) Merge branch 'current' into feat/twitch - [`ad9b6eb`](https://github.com/imputnet/cobalt/commit/ad9b6ebdd38f5a8711621f09dd6cb5c0b6d4e8ee) twitch clean up - [`f7247b8`](https://github.com/imputnet/cobalt/commit/f7247b87f0088c1c62b83e55750dbf7c8aac1c4d) fix wording - [`ad8a9c4`](https://github.com/imputnet/cobalt/commit/ad8a9c454d1cca12552822beee7a057f84294cee) remove vods - [`e0af5ef`](https://github.com/imputnet/cobalt/commit/e0af5ef1cf5eea1668cf524251fb168013081fbb) one more fix ### 📊 Changes **9 files changed** (+186 additions, -10 deletions) <details> <summary>View changed files</summary> 📝 `README.md` (+1 -0) 📝 `src/modules/processing/hostOverrides.js` (+8 -0) 📝 `src/modules/processing/match.js` (+8 -0) 📝 `src/modules/processing/matchActionDecider.js` (+1 -1) ➕ `src/modules/processing/services/twitch.js` (+76 -0) 📝 `src/modules/processing/servicesConfig.json` (+7 -1) 📝 `src/modules/processing/servicesPatternTesters.js` (+6 -4) 📝 `src/modules/sub/utils.js` (+49 -3) 📝 `src/test/tests.json` (+30 -1) </details> ### 📄 Description I've tried out adding twitch support to this, it's a bit weird since I've had to change some stuff with the utils: - Added `tld` option to services so TLDs other than `.com` work (this should really be able to be set for each pattern though) - `streamLiveRender()` allows to just take one stream and an extra flag for m3u8 URLs so FFmpeg can take a m3u8 file and convert it to something else properly Clips and VODs videos work, but requesting audio only from VODs and clips **do not work at the moment**. Not sure what combination of args will make that work but I couldn't get that bit working well. You can test with these links: - https://clips.twitch.tv/EnthusiasticBrainyTrollOMGScoots-190YbTxz136jR5bQ - https://www.twitch.tv/watchmeforever/clip/ArtsyMotionlessPartridgeAMPTropPunch-_lNDhyQAMonFN4I2 - https://www.twitch.tv/rtgame/clip/TubularInventiveSardineCorgiDerp-PM47mJQQ2vsL5B5G - https://www.twitch.tv/videos/1315890970 Not sure what to show if the streamer was banned, so I just used the `ErrorEmptyDownload` error. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2025-11-09 10:03:56 -06:00
Sign in to join this conversation.