Spotify will always be Spotify

Don’t build an empire on a shaky foundation

Long story short, I built a Chrome extension that assumed that Spotify wouldn’t change any major parts of their web player UI. Stupid, right?

The past

Queuebit used to be a Chrome extension that counted up the length of a queue from Spotify’s web player, built to assist me in managing the Spotify queue for the Rutgers Karaoke Club.

Old Spotify queue

The old Spotify queue, and where the Queuebit extension used to live

Alas, Spotify moved the Queue from a main-page element off to the sidebar. With less space, the queue no longer includes the length of each song on the queue. Because my extension read the numbers off of the page, it could no longer function.

New sidebar

The new Spotify sidebar, where the queue is now located

The present

With another stroke of luck (genius?), I had previously experimented with Spotify’s developer API to try and get my recently played songs in a list. Even though I learned that the API limits the recently-played list to 50 songs, this side project left me with a working example of authenticating with Spotify’s OAuth2 system, which made setting up the next version of Queuebit much easier.

Queuebit is now a standalone website that is both a step up, and also somewhat of a step down from the Chrome extension. The chrome extension counted up the songs you put in your queue and displayed the time that the whole queue would end. The standalone website displays the starting time, finishing time, duration, and minutes/seconds until the song will begin, but does not update as frequently, and cannot tell the difference between songs explicitly queued and songs placed in the queue by Spotify’s “Next Up” system.

New Queuebit

The new Queuebit website, showing the current song, the next song, and the time until the next song starts

(Spotify’s public API doesn’t differentiate between the two, so I can’t either. I intend to figure out how the internal API works, but that’s for another time.)

Either way, the website is hosted, but still unavailable for public use, because it is currently classified as a “development” project, which means that only whitelisted Spotify users can use it.

The future

I’ve submitted an application to Spotify to get it approved for public use, but I’m not holding my breath. I may post the code on GitHub once I’ve removed the Spotify API keys.

An update!

Spotify accepted my application on June 18th, 2024! The tool is available to use by any spotify (premium) user at queuebit.vercel.app!

However, I never did fix the authentication flow. It logs in perfectly fine, but after a half-hour or so, the token expires and you have to re-sign in. It’s a quick “Allow Spotify to connect to Queuebit” page, but I really should have fixed it before sending it off for review.

I’ll have to fix the authentication flow, but one thing that I don’t think will ever get fixed is the hard limit on 20 songs reported from the queue. I could ask for an extension to this limit, but it’d probably be shot down, as the reason the queue API is capped is specifically to stop 3rd-party apps from being used in these non-consumer fashions. (Would a bar start using Spotify if api-driven queue management could extend past 20 songs?)