youtube-mp3-converter
A simple node module to download youtube videos and convert them to mp3s.
A simple wrapper around the ytdl and ffmped library, which provides a nice and easy to use api to convert youtube links into mp3s.
Attention
Downloading videos or their respective audio from youtube, is in direct breach with their Policy.
Using this module on other videos than your own, may lead to youtube sueing you.
Before you start
This module depends on the ffmpeg library. Make sure you have ffmpeg installed. If not see here for installation details.
Install
npm install youtube-mp3-converter
Run Tests
npm run test
Basic Usage
const youtubeMp3Converter = require('youtube-mp3-converter')
const convertLinkToMp3 = youtubeMp3Converter(pathToSaveFiles)
const pathToMp3 = await convertLinkToMp3('https://www.youtube.com/watch?v=_cyND_1y1k0')
Usage Options
const youtubeMp3Converter = require('youtube-mp3-converter')
const convertLinkToMp3 = youtubeMp3Converter(pathToSaveFiles)
const pathToMp3 = await convertLinkToMp3('https://www.youtube.com/watch?v=_cyND_1y1k0', {
startTime: "00:00:10",
duration: 20,
title: 'fooo'
})
TODOS
This module is currently lacking some serious tests. If you wanna extend that, please be my guest.