Spotify Status Tweeter is a Python script that tweets the status of your Spotify account every hour, including the song name, album (if any), artist, as well as an attached URL link to the song track.
Simply download the source code and make sure that the required packages are installed from pip. Input your credentials in the secret.py
file, these can be created from the Twitter and Spotify Developer dashboards. Then, run tweetSpotifySong.py
and it should work -- if you are playing a song, it will tweet that along with the song information, if not, it'll tweet that you're not listening to Spotify at the moment.
When running the tweetSpotifySong.py
for the first time, you will be directed to a link (set in your Spotify Dev App) and you will need to input the authentication link back into the console.
I run these files on Heroku, so I use their scheduler add on to reduce my dyno hours (significantly). If you want to run this on your own machine, you can remove the comments from the scheduling code (sleep, schedule).
An example of this script in use is BenjaTheWorst's Twitter account. The script in use is a different version, it only tweets if the user is listening or not to replicate Discord's status for Spotify.