README
Why
- Auto install the latest
hrtube-youtube-dl
version available. - Executes any command in a efficient way.
- Intuitive interface.
Install
$ npm install @hrtube/youtube-dl --save
Usage
const youtubedl = require('@hrtube/youtube-dl')
youtubedl('https://example.com', {
dumpJson: true,
noWarnings: true,
noCallHome: true,
noCheckCertificate: true,
preferFreeFormats: true,
youtubeSkipDashManifest: true,
referer: 'https://example.com'
})
.then(output => console.log(output))
It's equivalent to:
$ youtube-dl https://example.com --dump-json --no-warnings --no-call-home --no-check-certificate --prefer-free-formats --youtube-skip-dash-manifest --referer=https://example.com
API
YOUTUBE_DL_DIR
It determines the folder where to put the binary file.
The default folder is bin
.
YOUTUBE_DL_FILENAME
It determines the binary filename.
The default binary file could be youtube-dl
or youtube-dl.exe
, depending of the YOUTUBE_DL_PLATFORM
value.
YOUTUBE_DL_PLATFORM
It determines the architecture of the machine that will use the youtube-dl
binary.
The default value will computed from process.platform
, being 'unix'
or 'win32'
.
Original License
GitHub microlink.io