Skip to content

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

1 Commit
 
 
 
 
 
 
 
 

Repository files navigation

Open Library Scraper — Books, Authors, Subjects & ISBN Data

Apify Actor Run on Apify License: MIT

▶️ Run Open Library Scraper on Apify — no API key, no login, thousands of book records per run.

📄 This repository is documentation only. The scraper runs as a hosted Actor on the Apify platform — nothing to install, no code to maintain. Click Run on Apify above to start.


What is the Open Library Scraper?

The Open Library Scraper extracts structured book metadata from one of the largest open book catalogues in the world — over 20 million records. Run a full-text search, browse by subject / genre, search authors, look up trending titles, or fetch book detail by work ID — and pull back title, author names, ISBN, edition count, publishers, subjects, community ratings, language, and cover image URLs.

There is no API key, no login, and no rate-limit workaround. Leave the input empty and the Actor returns popular / trending books; add a query or subject and it paginates to thousands of book records in one run. Results export to CSV, Excel, JSON, or Google Sheets in a click — perfect for library catalogues, book-discovery apps, ISBN databases, and bibliographic research.

Use it to build a book metadata database, collect ISBNs and publishers for a catalogue, power a reading-recommendation engine with ratings and subjects, or compile author authority files — all without writing or maintaining a scraper.

What you get (output fields)

One structured row per book (or author, in author mode):

Field Description
key Open Library work/author key (e.g. /works/OL45804W)
title Full book title (or author name in author mode)
authors Comma-separated author names
firstPublishYear Year the work was first published
isbn Up to 5 ISBNs (ISBN-10 / ISBN-13)
editionCount Number of known editions (or works, in author mode)
publishers Comma-separated publisher names
subjects Comma-separated subjects / genres
ratingsAverage Community average rating (0–5)
ratingsCount Number of community ratings
language Comma-separated language codes (e.g. eng, fre)
coverUrl Cover image URL
openLibraryUrl Link to the Open Library page
description Work description (bookDetail mode)
mode Scraping mode that produced this row

Use cases

  • Book metadata database — bulk-collect titles, ISBNs, publishers, and subjects across a genre to build or refresh a catalogue.
  • Book-discovery app — pull cover URLs, first-publish years, and ratings to power a browse/search experience.
  • ISBN & edition lookup — resolve a set of works to their ISBNs and edition counts for inventory or cataloguing.
  • Reading-recommendation engine — mine subjects and community ratings to build genre-based or "if you liked X" recommendations.
  • Author authority files — search authors and capture work counts, top works, and subjects for library metadata.
  • Corpus / NLP research — assemble large bibliographic datasets (titles, subjects, descriptions) for classification or trend analysis.
  • Publisher & genre analysis — compare edition counts and ratings across publishers or subjects for market insight.

Quick start — 4 ways to run

1. Apify Console (no code)

  1. Open the Actor: apify.com/logiover/openlibrary-scraper.
  2. Click Try for free.
  3. Leave the input empty for trending/popular books, or set mode to search with a query (e.g. science fiction) and click Start.
  4. When the run finishes, open the Dataset tab and Export to CSV, Excel, or JSON.

2. Apify CLI

npm install -g apify-cli
apify login
apify call logiover/openlibrary-scraper --input '{
  "mode": "search",
  "query": "science fiction",
  "maxResults": 500
}'

3. API / cURL

curl -X POST "https://api.apify.com/v2/acts/logiover~openlibrary-scraper/run-sync-get-dataset-items?token=YOUR_TOKEN" \
  -H "Content-Type: application/json" \
  -d '{
    "mode": "search",
    "query": "artificial intelligence",
    "maxResults": 200
  }'

run-sync-get-dataset-items runs the Actor and returns dataset items directly. Get your token from Apify Console → Settings → Integrations.

4. Apify client (JavaScript & Python)

JavaScript

import { ApifyClient } from 'apify-client';

const client = new ApifyClient({ token: 'YOUR_TOKEN' });

const run = await client.actor('logiover/openlibrary-scraper').call({
  mode: 'search',
  query: 'science fiction',
  maxResults: 200,
});

const { items } = await client.dataset(run.defaultDatasetId).listItems();
console.log(items[0].title, '—', items[0].authors);

Python

from apify_client import ApifyClient

client = ApifyClient("YOUR_TOKEN")

run = client.actor("logiover/openlibrary-scraper").call(run_input={
    "mode": "search",
    "query": "science fiction",
    "maxResults": 200,
})

for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item["title"], item["authors"], item["ratingsAverage"])

More detailed examples live in examples/: CLI · API / cURL · JavaScript · Python.

Input

All inputs are optional — an empty input returns trending / popular books.

Input Type Description
mode select trending (default), search (full-text), subject (genre browse), author (author search), or bookDetail (by work ID)
query string Free-text query for books or authors (search/author modes)
title string Filter search results by title keyword (search mode)
author string Filter search results by author name (search mode)
subject dropdown Subject/genre to browse (subject mode) — pick a common one or type a slug like graphic_novels
sort dropdown Relevance (default), Rating, Reading-log popularity, Most editions, Oldest/Newest, Random (search mode)
trendingPeriod dropdown Now, Today, This week, This month, This year (trending mode)
workIds array of strings Open Library work IDs for bookDetail mode, e.g. OL45804W
maxResults integer Maximum results to return (1–5000). Default 200
proxyConfiguration proxy Apify Proxy configuration — automatic default works well

Modes at a glance: search for full-text queries (optionally filter by title/author and sort); subject to browse a genre; author to search authors and their catalogs; bookDetail to fetch descriptions and edition data for specific work IDs; trending for popular titles by time window.

Output

Realistic sample (a search result):

{
  "key": "/works/OL27258W",
  "title": "The Hitchhiker's Guide to the Galaxy",
  "authors": "Douglas Adams",
  "firstPublishYear": 1979,
  "isbn": "9780345391803, 0345391802, 9780330508117",
  "editionCount": 487,
  "publishers": "Pan Books, Del Rey Books, Harmony Books",
  "subjects": "Science fiction, Humorous fiction, Space, Adventure, Comedy",
  "ratingsAverage": 4.21,
  "ratingsCount": 188432,
  "language": "eng",
  "coverUrl": "https://covers.openlibrary.org/b/id/8267040-L.jpg",
  "openLibraryUrl": "https://openlibrary.org/works/OL27258W",
  "description": null,
  "mode": "search"
}

Because the catalogue is community-maintained, lesser-known books may lack ISBNs, ratings, or covers — those fields come back null. Descriptions are populated in bookDetail mode; use it for the most complete record on a specific work.

Integrations & automation

Run on a schedule and route records anywhere with Apify's built-in integrations — no glue code:

  • Schedules — run weekly to track new arrivals in a subject area or rating changes over time.
  • Webhooks — POST the finished dataset to your API or database on completion.
  • Google Sheets — sync every run into a spreadsheet for cataloguing or sharing.
  • Amazon S3 / storage — archive raw JSON for a growing book-metadata lake.
  • Zapier · Make · n8n · Pipedream — add books to Notion, Airtable, or a catalogue database; send Slack alerts.
  • Slack — get a run-complete message with a result count and sample record.

Export formats

One-click export from the Console or via the API:

  • CSV — spreadsheets, catalogue imports
  • JSON — apps and pipelines
  • JSONL — line-delimited streaming
  • Excel (XLSX) — analysts and reporting
  • XML — legacy systems and feeds

FAQ

How do I scrape Open Library without an API key?

Run this Actor — it's fully keyless and loginless. Open the Actor on Apify, click Try for free, and start with an empty input or a search query. No account on the data source, no key.

Is there an Open Library API alternative that exports to CSV/Excel?

Yes. This Actor is a no-code Open Library data export: results download as CSV, Excel, JSON, JSONL, or XML, or push to Google Sheets.

How do I search books by ISBN?

Use search mode and set query to isbn:9780345391803 (replace with your ISBN). ISBN queries are supported natively.

How do I browse a whole genre?

Set mode to subject and pick a subject (or type a slug with underscores, e.g. science_fiction, history, cookbooks). Raise maxResults to pull thousands of titles.

How many results can one run return?

Up to 5000 per run. Search paginates automatically, and subject browsing can surface thousands of titles per category.

What's the difference between a "work" and an "edition"?

A work is the canonical entry for a book (e.g. The Hobbit); an edition is a specific physical version (a given hardcover or paperback). The Actor returns work-level data by default; bookDetail mode also surfaces edition data such as ISBNs and publishers.

How do I get a book's description?

Use bookDetail mode with the work's ID in workIds (e.g. OL27258W). Search mode does not return descriptions.

Why are some fields null?

Coverage is community-driven, so lesser-known books may lack ISBNs, ratings, or covers. Ratings appear only once at least one user has rated a work. Use bookDetail mode for the fullest record on a specific title.

Can I get different cover image sizes?

Yes. The coverUrl returns a large image ending in -L.jpg; swap it for -M.jpg (medium) or -S.jpg (small) as needed.

Is it free?

The Actor runs on Apify. A free Apify account includes monthly usage credit, so small runs typically cost nothing. Pricing is pay-per-use — you only pay for the results you pull.

Can AI agents call this scraper?

Yes. Via the Apify MCP server, assistants like Claude or GPT can trigger the Actor as a tool and reason over the returned book records (e.g. "find 500 sci-fi books published after 2000 with their titles, authors, and average ratings").

Related actors

  • OpenAlex Scraper — scholarly works, authors, institutions, and journals with DOIs and citations.
  • Google Books Scraper — search Google Books for titles, authors, ISBNs, and descriptions.

📄 Documentation only — the Actor runs on the Apify platform, not from this repository. ▶️ Run it: https://apify.com/logiover/openlibrary-scraper

Released under the MIT License. © 2026 logiover.

About

Scrape Open Library by search, subject, or author — title, ISBN, ratings, cover, publisher, subjects, editions. No API key. Docs for the Apify Actor.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors