Other media embeds

Started by snow, Sep 04, 2025, 04:54 AM

Previous topic - Next topic

snow

If we can embed YouTube, why not Bandcamp or Soundcloud?

Bandcamp

I can't find any docs on it, so here's my learnings so far (if anybody knows docs for this, let me know):

https://bandcamp.com/EmbeddedPlayer/v=2/track=$TRACK_ID/album=$ALBUM_ID/size=large/tracklist=false/artwork=small/

v: always 2? doesn't seem necessary, but also doesn't hurt?
artwork: none, small, large
track, album: track/album id (not the name). if track is provided, album isn't required, but it doesn't hurt
size: small, medium, large. there's a matrix of what combination of size and artwork are supported (an unsupported combination creates a messed-up embed)
tracklist: boolean. does what it says on the tin. only useful if album is set (if only track, it shows a tracklist with only one track)

Soundcloud

https://w.soundcloud.com/player/?url=https%3A//api.soundcloud.com/tracks/2136879759&color=%23ff5500&auto_play=false&hide_related=false&show_comments=true&show_user=true&show_reposts=false&show_teaser=true

This is a weird one. Seems like we can scrape the oembed tag, thankfully.