-
Notifications
You must be signed in to change notification settings - Fork 213
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
json export #134
Comments
Thanks for your interest in the project!
Actually, this already exists. You can use the GitHub UI to view Here's an example: https://github.com/mackorone/spotify-playlist-archive/blob/bbae5c6306c52b5867c2515ef88f92c3bbdf63e2/playlists/pretty/2dWfCGZguakRQagX7wM6Mi.json That said, the workflow is not very user-friendly. Many people are not familiar with the GitHub UI, it's tedious to scroll through commit history, and the "view at this point in the history" button is difficult to find. Thankfully, I think there's a better solution to your underlying question:
Spotify supports copy-paste for adding tracks to playlists. For example, you should be able to copy the URLs below and paste them into a playlist (using a keyboard shortcut, e.g.,
Which means that re-creating old versions of playlists is as easy as curating lists of track URLs. You're entirely correct that it's annoying to curate that information by hand. For now, the best solution is to use curl $URL | jq -r .tracks[].url However, an even better solution would be if https://spotifyplaylistarchive.com, which already makes it much easier to find old playlist versions, had a button for copying track URLs in one click. @maciejpedzich, what do you think about that? Is that something you'd be interested in implementing? |
thats a creative way. use a git repo as kind of a database. Another thing i´m not sure about. Are your archived playlists in the exact same track order they were at the snapshot date? |
Of course I would! It's been a couple months since my last commit, but this feature should be fairly easy to implement. While at it, I could also make it easier for users to obtain the correct playlist ID so as for the less Git-experienced users not to struggle with copying it manually as seen in PR #133. For the record, I'm not trying to shame that person for getting the wrong string - it's totally understandable, especially since it was their first time using Git and GitHub at all. The query string that Spotify appends when you copy the link from the share option menu didn't help either! |
Responding to @atopetiff:
Yea, that's the idea! See https://simonwillison.net/2020/Oct/9/git-scraping/
Interestingly, @maciejpedzich explored this idea when he built https://spotifyplaylistarchive.com/. I believe he decided to not implement the functionality at the time, given the complexity related to authentication that you mentioned.
Indeed! |
Responding to @maciejpedzich:
Nice! When you're done, let me know and I can add "how to restore a playlist" instructions to the
This would be great! Same as above, let me know when you're done and I'll update the |
Yeah, that's pretty close to what @mackorone has mentioned, and I've just wanted to elaborate on this one anwyay. So buckle up for a little development backstory! In May this year I started working on a prototype of this app called Arkivify, which was meant to serve the exact same purpose as The real issue wasn't the in-app implementation, but rather the way Spotify handles new OAuth apps. It initially restricts you to 20 signed up users, which you're also forced to add to an allowlist in order for them to be able to authorise your app in the first place. While it's possible to get a quota extension, this involves your app getting manually reviewed for quality control and compliance with the API's Terms of Service. Speaking of which, there's a teeny-tiny write-up in section 4.3.a.i of said ToS that would effectively put all my effort to waste. Fast forward to mid-June. Me and @mackorone had already emailed each other back-and-forth about the possibility of me migrating the data he had collected so far over to Arkivify's database, but after I'd discovered that pesky paragrah, I realised I had to change my strategy and essentially turn his Git repo into my web app's database/backend of sorts as you've noticed. And well... here we are today, with https://spotifyplaylistarchive.com up and running since July! EDIT: If I had a dollar for every time I wrote this year in my message, I would have three dollars. As Aloe Blacc once sang: https://open.spotify.com/track/3oUphdZVPyrsprZ8FgbmQS |
@mackorone, @atopetiff. I forgot to notify you yesterday (I think I pinged Mack though, but better safe than sorry). I opened a PR in the website's repo that introduces JSON export, among other features. You just need to click the Deploy preview link, choose any playlist's snapshot and click Export to JSON. |
Hey @atopetiff! I've just merged the aforementioned PR, and the changes are now live on https://spotifyplaylistarchive.com! All you need to do is to open up any playlist's snapshot and click Export to JSON (yes, I've mentioned it already, but doing it again wouldn't hurt I guess). @mackorone should add relevant instructions in |
Thanks for those improvements, @maciejpedzich! I just updated @atopetiff, let me know if you have any further questions. |
I found your project today. impressive.
would it be possible to export a specific state of a playlist to json with
really important is only the uri.
the reason is if you want to create a playlist from a specific state you need the uris. nobody clicks every link and a thats to playlist.
The text was updated successfully, but these errors were encountered: