# Librario, a book metadata API that aggregates G Books, ISBN…

TLDR: Librario is a book metadata API that aggregates data from Google Books, ISBNDB, and Hardcover into a single response, solving the problem of no single source having complete book information. It's currently pre-alpha, AGPL-licensed, and available to try now[0]. My wife and I have a personal l…

- **Page:** https://magpie.gallery/i/librario-a-book-metadata-api-that-aggregates-g-boo-8qhg
- **Type:** Link to an idea elsewhere
- **Category:** AI & dev
- **Runs on:** web
- **Tags:** api, books, metadata, open-source, aggregation

## Source

Web · jamesponddotco: Librario, a book metadata API that aggregates G Books, ISBNDB, and more

- **Original:** https://news.ycombinator.com/item?id=46571149

> TLDR: Librario is a book metadata API that aggregates data from Google Books, ISBNDB, and Hardcover into a single response, solving the problem of no single source having complete book information. It's currently pre-alpha, AGPL-licensed, and available to try now[0]. My wife and I have a personal library with around 1,800 books. I started working on a library management tool for us, but I quickly realized I needed a source of data for book information, and none of the solutions available provided all the data I needed. One might provide the series, the other might provide genres, and another might provide a good cover, but none provided everything. So I started working on Librario, a book metadata aggregation API written in Go. It fetches information about books from multiple sources (Google Books, ISBNDB, Hardcover. Working on Goodreads and Anna's Archive next.), merges everything, and saves it all to a PostgreSQL database for future lookups. The idea is that the database gets stronger over time as more books are queried. You can see an example response here[1], or try it yourself: curl -s -H 'Authorization: Bearer librario_ARbmrp1fjBpDywzhvrQcByA4sZ9pn7D5HEk0kmS34eqRcaujyt0enCZ' \ 'https://api.librario.dev/v1/book/9781328879943' | jq . This is pre-alpha and runs on a small VPS, so keep that in mind. I never hit the limits in the third-party services, so depending on how this post goes, I’ll or will not find out if the code handles that well. The merger is the heart of the service, and figuring out how to combine conflicting data from different sources was the hardest part. In the end I decided to use field-specific strategies which are quite naive, but work for now. Each extractor has a priority, and results are sorted by that priority before merging. But priority alone isn't enough, so different fields need different treatment. For example: - Titles use a scoring system. I penalize titles containing parentheses or brackets because sources sometimes shove subtitle

## Rules for reuse

- Build your own version: don't copy another product's code, look, icons, colours or copy.
- The original belongs to its author; Magpie only links to it.
- The original content's copyright belongs to its creator. Magpie doesn't download or re-upload it; we only show the link and the official preview.
