cobalt icon indicating copy to clipboard operation
cobalt copied to clipboard

req: add coub.com support w/ "audio + video" & "video + audio" modes

Open Gesugao-san opened this issue 9 months ago • 2 comments

service name

Coub.com

service description

hey team! :3

first, huge thanks for cobalt—it's been super reliable for grabbing publicly available content from all sorts of platforms. i'd love to suggest adding support for coub.com, which is:

  • completely publicly accessible (all content is available without logins)
  • free (no paywalls or premium content)
  • DRM-free (just good ol' web videos)

why coub needs love

  1. official download option? lol no - coub doesn't provide one
  2. third-party solutions? let me tell you a cautionary tale...

the rise and fall of mycoub.ru:
back in its golden era, mycoub.ru was perfect:

  • clean interface
  • direct "audio + video" downloads
  • no nonsense

then came the dark times:

  • first they removed the download buttons
  • then became an ad-infested extension pusher
  • their chrome extension:
    • lacks the merge modes we want
    • demands suspicious permissions
    • basically acts like spyware (tracking, ads, redirects)

now it's just a shell of its former self, and we're left without a good alternative.

what would be amazing

could cobalt add these optional download modes?

  1. audio + video - full audio first, then merge with video (classic mycoub style)
  2. video + audio - full video first, then overlay audio

this would be:

  • 100% within cobalt's scope (public, free, non-DRM content)
  • a safer alternative to shady extensions
  • a return to the golden age of coub downloads

plus, coub is still super popular for:

  • meme content
  • music snippets
  • creative looping videos

would be happy to help test or provide examples if needed! this would make the coub community so happy.

link samples

### link samples & regex
should recognize:
- regular: `https://coub.com/view/47tj88`
- shared: `https://coub.com/v/47tj88`
- mobile: `https://m.coub.com/view/47tj88`
- embed: `https://coub.com/embed/47tj88`
- stories: `https://coub.com/stories/5083967-bookmarki-ch-2` (extracts just 5083967)

optimized regex pattern:

^https?://(?:m\.)?coub\.com/(?:view|v|embed)/([a-z0-9]+)|stories/(\d+)


### key improvements
1. **clean story extraction** - only captures numeric ID after /stories/
2. **two capture groups**:
   - Group 1: video IDs (47tj88)
   - Group 2: story IDs (5083967)
3. **more efficient** - uses alternation instead of optional slug matching

### example matches:
- `https://coub.com/stories/5083967-bookmarki-ch-2` → 5083967
- `https://coub.com/view/47tj88` → 47tj88
- `https://m.coub.com/embed/abc123` → abc123

additional context

No response

Gesugao-san avatar Apr 04 '25 10:04 Gesugao-san

hey team :3

noticed a comment got deleted on apr 13 - just wanted to check:

  1. what was in it?
  2. any questions/concerns i should address about the coub feature?

want to make sure i'm following the ~vibes~ and guidelines properly. thanks for all the work you put into cobalt - it's honestly the least-painful downloader out there ✨

(p.s. no rush - just wanna help make this feature as cobalt-y as possible)

Gesugao-san avatar Jun 22 '25 18:06 Gesugao-san

i’m pretty sure that was a reply from a spam bot lol

the info in your issue is more than enough, we just didn’t have the opportunity to get to implementing coub support. you can make a PR, though!

wukko avatar Jun 23 '25 03:06 wukko