packages icon indicating copy to clipboard operation
packages copied to clipboard

Make package index available as JSON.

Open hayleigh-dot-dev opened this issue 2 years ago • 1 comments

The packages site was recently updated to expose the sqlite database directly (super cool!), it'd be nice if all the package info was available as JSON too. I'd like to create a lustre tutorial for folks to follow along with that recreates the packages site just as a client app (no backend or anything) and it'd be super nice I could just point people to a /packages.json endpoint.

Elm's package site provides this sort of info at:

  • https://package.elm-lang.org/all-packages/
  • https://package.elm-lang.org/search.json

These kinds of tutorial projects historically use things like the reddit, twitter, or hackernews api, but I think it'd be kinda nice if we could keep it all "in-house" and use only gleamy things, if it's not too much work to add this :)

hayleigh-dot-dev avatar Sep 25 '23 17:09 hayleigh-dot-dev

What information would you be after? I don't think it's suitable to put the whole database as one JSON payload so we'd need more precise APIs.

The Elm endpoints there seem to offer a very small amount of the information for each package, but that seems like it wouldn't be useful to many people.

lpil avatar Sep 25 '23 17:09 lpil