This repository contains a stash plugin package for yt-dlp.
See yt-dlp plugins for more details.
Requires yt-dlp as well as stashapp-tools.
You can install this package with pip:
python3 -m pip install -U https://github.com/schmoaaaaah/yt-dlp-stash/archive/master.zip
python3 -m pip install yt-dlp-stash
See installing yt-dlp plugins for the other methods this plugin package can be installed.
To use this plugin, you must have a stash server running and add following to your yt-dlp command:
--use-postprocessor Stash:scheme="http"\;host="stash"\;port="9999"\;apikey="example_key"\;when=after_video
The apikey is optional and can be left out if you dont have authentication enabled.
--use-postprocessor Stash:scheme="http"\;host="stash"\;port="9999"\;when=after_video
name | default | required | description |
---|---|---|---|
scheme | http | x | scheme at which stash is available. either http or https |
host | localhost | x | fqdn of the stash instance |
port | 9999 | x | port on which stash is accessable |
apikey | api key which should be used | ||
sessioncookie | sessioncookie which should be used | ||
searchpathoverride | override the relative path for the search in stash | ||
when | when postprocessor is called |
if api key and sessioncookie are provided api key is preferred.
if you set the searchpathoverride the relative path of the downloaded file will be overriden when interacting with stash.
so if you define yt-dlp -o ./media/video.mp4
and set searchpathoverride to /mnt/nas
then stash will look for /mnt/nas/media/video.mp4
.
special case
/
:
if you defineyt-dlp -o ./media/video.mp4
and set searchpathoverride to/
then stash will look for/media/video.mp4
.
by default the Processor expects the same path for the media in stash as it is downloaded.
You might need to change after_video
to playlist
if you are downloading a playlist.
I haven't tested this yet.
See the Plugin Development section of the yt-dlp wiki.