It uses Spotify API (Spotipy) to get the data. Then it finds the names of tracks and searches them on YouTube. With this, it gets a link to a YouTube video, where the library pytube is used for downloading .mp3 files. There are many factors that some tracks wouldn't work like the song is not on YouTube under the name, that it is on Spotify. In my case, it worked every time, when I tried it.
Have fun :) Also my first Repo.
Working on it:)
If you want to try the code => Install these libraries
pip install pytube
pip install yt_dlp
pip install spotipy
pip install re
Also don't forget the API key for Spotipy from "https://developer.spotify.com/dashboard"
To get the API keys, you need to create an app, add the details, and select "Web API" and "Save". Now go to the settings of the App and you will see both API keys.
