Hexalyse's Blog As long as you don't choose, everything remains possible.
Posts with the tag python:

How to listen along a Last.fm user on Spotify

tl;dr “I dont want to read your article, I want to download the code” : Skip to this section of the article for the link to the Github repository.

Lately I started using Last.fm a bit more thoroughly. For those who don’t know what Last.fm is, it’s a webstite that allows you to “scrobble” (log) every song you listen to.
It’s cool because then you can have cool stats about your listening habits, but also discover new artists related to what you like (Spotify largely copied what Last.fm was doing, with the artist/album/song radio and “daily mix” playlists).

The idea

I was browsing the website and looking at what my friends were listening to, when suddenly I thought that it would be cool to be able to listen to what another user is listening to, at the same time. It’s a cool way to discover new music while relying on someone’s tastes isntead of the Spotify algorithms, that unfortunately often brings you the same songs that you already know too well.

I started googling, but unfortunately didn’t find anything remotely close to what I was trying to do, except a very old website called “overhere” that apparently did the same thing, but is now long dead.

So I knew I had to do it myself.

Python version of the Ask.fm API

In the previous articles How I reverse-engineered the Ask.fm API – Part 1 and Part 2 we saw how I proceeded to analyze and reverse engineer the Ask FM API so I could automate some tasks.

How I reverse-engineered the Ask.fm API – Part 2

In the second part, we’ll take a look at the requests we intercepted thanks to Fiddler, and see if Aks.fm implemented some sort of security (tokens, checksums, etc)

How I reverse-engineered the Ask.fm API – Part 1

In this first post, we’ll see how I managed to reverse engineer the Ask.fm API. In a subsequent post, I might give the (ugly) code I came up with, which implements some of the API features I needed for various bots and scripts.