meeb / bandcampsync

Downloads your Bandcamp purchases automatically
BSD 3-Clause "New" or "Revised" License
140 stars 7 forks source link

[Feature Request] Call endpoint if new media was downloaded succefully #19

Open Virusmater opened 5 months ago

Virusmater commented 5 months ago

I would like to have Jellyfin library refreshed if new media was downloaded successfully.

Their API is straightforward, just a single POST request. I think for Plex and other media servers have similar API. It would be nice to be able to pass the API endpoint as an environment variable.

meeb commented 5 months ago

I can see why this may be a wanted feature, however bandcampsync is a pretty small script. I don't really want to start adding in and support interfaces to whatever media servers people use. If I ended up supporting 2-3 media servers the media server interface code would be bigger than bandcampsync itself.

I may add in the ability to execute an arbitrary command if new music is downloaded, you can add in a curl command into a shell script or similar and execute that.

Virusmater commented 5 months ago

I totally do not expect support to whatever media server, just an extension point for curl after successful download will be more than enough

meeb commented 5 months ago

I'll see if I can pop this into the next release. I realise you weren't asking for general media server support but if I added Jellyfin support directly I'd have Plex requests pretty quickly as well 😄

tacerus commented 3 months ago

Hi, what about having the bandcampsync tool exit with a certain exit code if new media was downloaded?

Virusmater commented 3 months ago

It will not work for docker installation

amias-channer commented 1 month ago

making it hit a single url should be enough for most media services, they can work out what changed by looking at the disk so all it needs is to know its time to look again