I once offered gRegor to write up a bookmarklet for turning Bookshop.org book pages into want-to-read (or currently-reading or finished-reading) posts on your own site with Micropub courtest of IndieBookClub.biz.

Then I lost my main computer’s SSD and my browser bookmarks!

Today I re-created it to make some posts on my site, so here it is!

javascript:(function()%7Bconst%20ld%20%3D%20JSON.parse(document.querySelector('script%5Btype%3D%22application%2Fld%2Bjson%22%5D').textContent)%3B%0Aconst%20p%20%3D%20new%20URLSearchParams(%7B%0Atitle%3A%20ld.name%2C%0Aauthors%3A%20ld.author%5B0%5D.name%2C%0Aisbn%3A%20ld.isbn%2C%0Atags%3A%20'books'%2C%0A'post-status'%3A%20'published'%0A%7D)%3B%0Adocument.location%20%3D%20'https%3A%2F%2Findiebookclub.biz%2Fnew%3F'%20%2B%20p.toString()%3B%7D)()

Here’s the original source for study or to edit to your enjoyment! (I enjoy Marek Gibney’s Bookmarklet Editor for this!)

const ld = JSON.parse(document.querySelector('script[type="application/ld+json"]').textContent);
const p = new URLSearchParams({
  title: ld.name,
  authors: ld.author[].name,
  isbn: ld.isbn,
  tags: 'books',
  'post-status': 'published'
});
document.location = 'https://indiebookclub.biz/new?' + p.toString();

What does this do?

Bookshop.org book pages have a <script> tag marked as a “JSON-encoded Linked Data island” (pejorative) also known as JSON data.

The bookmarklet finds and parses this then (quick and dirty) pulls out likely book title, ISBN, and author and combines these with another couple of options (I tag all my reading posts with “books” and I want the posts to be published by default). Those options are turned into URL query string parameters, as described in IndieBookClub.biz’ documentation and sends your browser over there, where IndieBookClub(dot biz) handles the rest!