A simple API for downloading music/audio from YouTube using NYouTubeDL.
This was originally developed as a way to download music for transfer to my plex server.
The songs are downloaded to a folder called "Songs", and are organized by artist and album ,
Songs/Test Artist/Test Album/Song.mp4.
Each song will have be tagged with the artist, album, and song title as well.
As of now, it is up to the user to properly use the program and populate
all fields on the main webpage.
sudo curl -L https://yt-dl.org/downloads/latest/youtube-dl -o /usr/bin/youtube-dl
sudo chmod a+rx /usr/bin/youtube-dlgit clone https://github.com/GT3CH1/YouTubeMusicDownloader-Apicd YouTubeMusicDownloader-Api
dotnet builddotnet ./YouTubeDownloader/bin/Debug/net6.0/YouTubeDownloader.dllNavigate to the URL that is shown in your terminal when you start the application.
At the top of the webpage, there is four fields you will have to input.
Once you have filled out the fields, click the "Add Song" button. The song is stored in a database, and is ready to be downloaded. Please see the "Downloading a Song" section for more information.
POST /api/Song/Add
{
"Url": "https://www.youtube.com/watch?v=some-url",
"Title": "Test Video",
"Artist": "Test Artist",
"Album": "Test Album"
}POST /api/Song/AddList
[
{
"Url": "https://www.youtube.com/watch?v=some-url",
"Title": "Test Video",
"Artist": "Test Artist",
"Album": "Test Album"
},
{
"Url": "https://www.youtube.com/watch?v=some-url",
"Title": "Test Video",
"Artist": "Test Artist",
"Album": "Test Album"
}
]GET /api/Song/GetListGET /api/Song/Get/{id}DELETE /api/Song/Delete/{id}DELETE /api/Song/DeleteAllPUT /api/Song/Edit/{id}
{
"Url": "https://www.youtube.com/watch?v=some-url",
"Title": "Test Video",
"Artist": "Test Artist",
"Album": "Test Album",
}GET /api/Song/Download/{id}GET /api/Song/DownloadAllIf you run into any bugs, or would like to request/add a feature, please open an issue on the GitHub repository. Any and all help is appreciated.