# StoryGraph Book Scraper: Ratings, Moods (`maximedupre/storygraph`) Actor

Get StoryGraph book data from keyword searches or book links. Each row has the title, author, community rating, moods, pace, reader questions, content warnings and edition details. Filter by minimum rating or return only new books since your last run.

- **URL**: https://apify.com/maximedupre/storygraph.md
- **Developed by:** [Maxime Dupré](https://apify.com/maximedupre) (community)
- **Categories:** Other, Education, Automation
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.70 / 1,000 books

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.
Since this Actor supports Apify Store discounts, the price gets lower the higher subscription plan you have.

Learn more: https://docs.apify.com/actors/running/actors-in-store.md#pay-per-event

## What's an Apify Actor?

An Actor is a serverless cloud program that runs on the Apify platform. It has two run modes.
In Batch mode, an Actor accepts a well-defined JSON input, performs an action which can take anything from a few seconds to a few hours,
and optionally produces a well-defined JSON output, datasets with results, or files in key-value store.
In Standby mode, an Actor provides a web server which can be used as a website, API, or an MCP server.

Apify vocabulary and the platform model are defined once, in the agent quickstart at https://apify.com/agents.md.

## How to integrate an Actor?

If asked about integration, you help developers integrate Actors into their projects.
You adapt to their stack and deliver integrations that are safe, well-documented, and production-ready.

Do not guess an integration path. Every one of them is in the agent quickstart at https://apify.com/agents.md: the Apify MCP server, Agent Skills with the Apify CLI, the JavaScript and Python clients, the REST API, and the account-free path for an agent with no human to sign in. It also carries the rule on stating cost before the first paid run.

For examples already wired to this Actor's own input schema, see the [API](#api) section below.

Each client library has reference documentation the quickstart does not restate: [JavaScript/TypeScript](https://docs.apify.com/api/client/js/docs.md) (`npm install apify-client`) and [Python](https://docs.apify.com/api/client/python/docs.md) (`pip install apify-client`).

# README

### 📚 StoryGraph Book Scraper: Ratings, Moods, Pace and Content Warnings

Book bloggers, readers, librarians, and data builders can use this Actor to turn StoryGraph into clean dataset rows. Search by title, author, or series, or paste StoryGraph book links. Each book comes back with its catalog details, community rating, moods, pace, reader questions, and content warnings. Run it once, or run it again later to find only new books.

- Search a title, author, or series and collect every matching book.
- Build a reading list of books with a community rating of 4.0 or higher.
- Compare moods and pace across books to find a fast, dark, or lighthearted read.
- Check content warnings by severity before you recommend or buy a book.
- Track a search over time and return only the books that are new since the last run.

#### 🎭 StoryGraph book data in every row

Each dataset row is one StoryGraph book.

- **Catalog details:** title, author, description, cover image, page count, format, first publication year, and edition count.
- **Series:** the series name and the place of the book in it, when the book has a series.
- **Edition details:** ISBN, language, publisher, and edition publication date.
- **Community rating:** the StoryGraph average rating from 0 to 5 and the number of reviews or ratings behind it.
- **Moods:** the share of readers who tagged the book with each mood, such as adventurous, dark, tense, emotional, or funny.
- **Pace:** the share of readers who found the book fast, medium, or slow.
- **Reader questions:** community answers on plot or character driven, character development, loveable characters, diverse cast, and flawed characters.
- **Content warnings:** reader-submitted warnings grouped as graphic, moderate, and minor.

A field is left out of a row when the StoryGraph page has no value for it.

#### ▶️ Start a StoryGraph book run

1. Add one or more **Search queries**, or paste **Book links**, or use both.
2. Set **Maximum books** to cap the run. Leave it empty or use 0 to get all available books.
3. Optional: set a **Minimum rating** or turn on **Only new books since last run**.
4. Start the run, then open the dataset to view, download, or connect the rows.

If you add no search query and no valid book link, the run does nothing and shows a message that asks you to add one.

#### ⚙️ Input

**Input fields**

| Field | Type | What it does |
| --- | --- | --- |
| `searchQueries` | array of strings | Titles, authors, or series to search on StoryGraph. Each entry is one search. Repeated entries run once. The form pre-fills `fantasy`, but the field has no default value. |
| `bookUrls` | array of links | Full StoryGraph book links, such as `https://app.thestorygraph.com/books/<book-id>`. Use them with or without search queries. A link that is not a StoryGraph book link is skipped with a warning. A book found by both a search and a link is saved once. |
| `maxItems` | integer | Stops the run after this many books. The minimum is 0. Leave it empty or use 0 to get all available books. The form pre-fills 10, but the field has no default value. |
| `minRating` | number | Keeps only books with a StoryGraph community average rating at or above this value, from 0 to 5. Leave it empty to keep all books. Books that fail the filter are not saved and are not charged. |
| `onlyNewBooks` | boolean | When on, returns only books that were not in the previous run with the same search queries and book links. The Actor remembers the books it has seen between runs. The default is `false`, which returns all matching books. |

**Example input**

```json
{
  "searchQueries": [
    "fantasy"
  ],
  "maxItems": 10,
  "onlyNewBooks": false
}
```

#### 🧾 Output

**Output fields**

Every row has this shape. Fields marked as optional are left out when StoryGraph has no value for the book.

| Field | Type | What it does |
| --- | --- | --- |
| `url` | string | Link to the book page on StoryGraph. |
| `title` | string | Title of the book. |
| `author` | string | Name of the book author. |
| `description` | string | Description of the book. |
| `coverImageUrl` | string | Link to the book cover image. |
| `pageCount` | integer | Number of pages in the book. |
| `format` | string | Format of the book, such as paperback or ebook. |
| `firstPublicationYear` | integer | Year the book was first published. |
| `editionCount` | integer | Number of editions of the book on StoryGraph. |
| `series.name` | string | Name of the series. Optional. |
| `series.position` | string | Place of the book in the series, as StoryGraph shows it. Optional. |
| `isbn` | string | ISBN of the edition. |
| `language` | string | Language of the edition. |
| `publisher` | string | Publisher of the edition. |
| `editionPublicationDate` | string | Date the edition was published, as StoryGraph shows it. |
| `averageRating` | number | StoryGraph community average rating, from 0 to 5. |
| `reviewCount` | integer | Number of reviews or ratings behind the average rating. |
| `moods` | array of objects | Share of readers who tagged the book with each mood. |
| `moods[].mood` | string | Mood name, such as adventurous, dark, tense, emotional, or funny. |
| `moods[].percentage` | number | Percentage of readers who chose this mood. |
| `pace.fast` | number | Percentage of readers who found the book fast paced. |
| `pace.medium` | number | Percentage of readers who found the book medium paced. |
| `pace.slow` | number | Percentage of readers who found the book slow paced. |
| `readerQuestions` | array of objects | Community answers to questions about the book. Optional. |
| `readerQuestions[].question` | string | The question readers answered. |
| `readerQuestions[].answers` | array of objects | The answers and the share of readers who gave each one. |
| `readerQuestions[].answers[].answer` | string | The answer option. |
| `readerQuestions[].answers[].percentage` | number | Percentage of readers who gave this answer. |
| `contentWarnings.graphic` | array of strings | Graphic content warnings submitted by readers. Optional. |
| `contentWarnings.moderate` | array of strings | Moderate content warnings submitted by readers. Optional. |
| `contentWarnings.minor` | array of strings | Minor content warnings submitted by readers. Optional. |

**Example book**

This row comes from a real run. This book has no series, reader questions, or content warnings on StoryGraph, so those fields are not in the row.

```json
{
  "url": "https://app.thestorygraph.com/books/ab737e82-11de-4f0c-8ba8-397669d51880",
  "title": "The Tough Guide to Fantasyland",
  "author": "Diana Wynne Jones",
  "description": "The definitive edition of a cult classic by the legendary Diana Wynne Jones.Imagine that all fantasy novels--the ones featuring dragons, knights, wizards, and magic--are set in the same place. That place is called Fantasyland. The Tough Guide to Fantasyland is your travel guide, a handbook to everything you might find: Evil, the Dark Lord, Stew, Boots (but not Socks), and what passes for Economics and Ecology. Both a hilarious send-up of the cliches of the genre and an indispensable guide for writers, The Tough Guide to Fantasyland has been nearly impossible to find for years. Now this cult classic is back, and readers can experience Diana Wynne Jones at her very best: incisive, funny, and wildly imaginative. This is the definitive edition of The Tough Guide, featuring a new map, an entirely new design, and additional material written for it by Diana Wynne Jones.World Fantasy Award FinalistA Hugo Award Finalist (Nonfiction)",
  "coverImageUrl": "https://cdn.thestorygraph.com/bke43p1deydd3tltsjnim138koq1",
  "pageCount": 234,
  "firstPublicationYear": 1996,
  "editionCount": 9,
  "isbn": "9780142407226",
  "format": "Paperback",
  "language": "English",
  "publisher": "Firebird",
  "editionPublicationDate": "05 Oct 2006",
  "averageRating": 3.89,
  "reviewCount": 990,
  "moods": [
    {
      "mood": "funny",
      "percentage": 100
    },
    {
      "mood": "lighthearted",
      "percentage": 54
    },
    {
      "mood": "informative",
      "percentage": 37
    },
    {
      "mood": "adventurous",
      "percentage": 27
    },
    {
      "mood": "reflective",
      "percentage": 8
    },
    {
      "mood": "relaxing",
      "percentage": 5
    },
    {
      "mood": "challenging",
      "percentage": 2
    },
    {
      "mood": "dark",
      "percentage": 2
    },
    {
      "mood": "inspiring",
      "percentage": 2
    }
  ],
  "pace": {
    "fast": 53,
    "medium": 17,
    "slow": 28
  }
}
```

#### 💳 Pricing

This Actor uses pay per event pricing.

- **Run start:** a one-time charge of $0.005 each time a run starts.
- **Book:** a charge for each book saved to your dataset. The price depends on your Apify plan: $0.0036 on Free, $0.0032 on Bronze, $0.00295 on Silver, and $0.0027 on Gold, Platinum, and Diamond.

You pay only for books that are saved. Books skipped by the minimum rating filter, books skipped by the new books filter, and links that cannot be read are not charged. A run with no results only pays the run start charge.

#### 🔌 Integrations

Send StoryGraph book rows to your tools with Apify integrations, schedules, webhooks, and the Apify API. You can export the dataset as JSON, CSV, Excel, or HTML. Schedule a run with **Only new books since last run** on to watch a search over time.

https://www.youtube.com/watch?v=bNACk1_S_6w\&list=PLObrtcm1Kw6MUrlLNDbK9QRg8VDJg0gOW\&index=4

#### ❓ FAQ

##### Does it need a StoryGraph login?

No. The Actor reads public StoryGraph book pages and does not ask for your StoryGraph account.

##### Can I get content warnings for a book?

Yes. When readers have submitted warnings, the row has `contentWarnings` grouped as graphic, moderate, and minor. A book with no warnings has no `contentWarnings` field.

##### How do I get only new books each time?

Turn on **Only new books since last run** and keep the same search queries and book links. The first run returns all matching books. Later runs return only books that were not in the previous run for that same input.

##### How does the minimum rating filter work?

The Actor reads each book, then keeps it only if its average rating is at or above your value. A book with no average rating is dropped when you set a minimum rating.

##### What happens when a search finds nothing?

The Actor logs that no books were found for that query and moves on to the next one. You are not charged for that query.

##### Can I mix searches and book links?

Yes. Add both fields in one run. A book that appears in a search and in your links is saved once.

##### How many books can I collect?

Set **Maximum books** to the number you want. Leave it empty or use 0 to continue until all search pages and links are done.

### 📝 Changelog

**v0.0** (19-11-2026)

- Initial release.

### 🆘 Support

For issues, questions, or feature requests, [file a ticket](https://console.apify.com/actors/maximedupre~storygraph/issues) and I'll fix or implement it in less than 24h 🫡

### 🔗 Related Actors

- [Goodreads Scraper](https://apify.com/maximedupre/goodreads-scraper): collect Goodreads book ratings, ISBNs, and details to compare with StoryGraph rows.
- [StoryGraph Book Scraper — Ratings, Moods, Pace & Monitor](https://apify.com/scrapersdelight/storygraph-scraper): compare another StoryGraph scraper when you want a second source for book ratings and moods.
- [StoryGraph Books Scraper: Ratings, Moods, Content Warnings](https://apify.com/getascraper/storygraph-books-scraper): cross-check content warnings for books you track.
- [ISBN Lookup & Decoder API - Book Editions by Title or Author](https://apify.com/s-r/isbn-decoder): match an ISBN from your StoryGraph rows to more edition data.
- [Douban Book Ratings Scraper](https://apify.com/mrdoe/douban-book-ratings-scraper): add Douban ratings and vote counts to compare with StoryGraph ratings.

**Made with ❤️ by Maxime Dupré**

# Actor input Schema

## `searchQueries` (type: `array`):

Titles, authors, or series to search on StoryGraph. Each entry is one search.

## `bookUrls` (type: `array`):

Full StoryGraph book links, for example `https://app.thestorygraph.com/books/<book-id>`. Use this with or without search queries.

## `maxItems` (type: `integer`):

Stop after this many books. Leave empty or use 0 to get all available books.

## `minRating` (type: `number`):

Keep only books with a StoryGraph community average rating at or above this value, from 0 to 5. Leave empty to keep all books.

## `onlyNewBooks` (type: `boolean`):

Return only books that were not in the previous run with the same search queries and book links. The Actor remembers the books it has seen between runs. Turn this off to get all matching books.

## Actor input object example

```json
{
  "searchQueries": [
    "fantasy"
  ],
  "maxItems": 10,
  "onlyNewBooks": false
}
```

# Actor output Schema

## `books` (type: `string`):

The books found on StoryGraph.

# API

You can run this Actor programmatically using our API. Below are code examples in JavaScript, Python, and CLI, as well as the OpenAPI specification and MCP server setup.

## JavaScript example

```javascript
import { ApifyClient } from 'apify-client';

// Initialize the ApifyClient with your Apify API token
// Replace the '<YOUR_API_TOKEN>' with your token
const client = new ApifyClient({
    token: '<YOUR_API_TOKEN>',
});

// Prepare Actor input
const input = {
    "searchQueries": [
        "fantasy"
    ],
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("maximedupre/storygraph").call(input);

// Fetch and print Actor results from the run's dataset (if any)
console.log('Results from dataset');
console.log(`💾 Check your data here: https://console.apify.com/storage/datasets/${run.defaultDatasetId}`);
const { items } = await client.dataset(run.defaultDatasetId).listItems();
items.forEach((item) => {
    console.dir(item);
});

// 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/js/docs

```

## Python example

```python
from apify_client import ApifyClient

# Initialize the ApifyClient with your Apify API token
# Replace '<YOUR_API_TOKEN>' with your token.
client = ApifyClient("<YOUR_API_TOKEN>")

# Prepare the Actor input
run_input = {
    "searchQueries": ["fantasy"],
    "maxItems": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("maximedupre/storygraph").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print(f"💾 Check your data here: https://console.apify.com/storage/datasets/{run.default_dataset_id}")
for item in client.dataset(run.default_dataset_id).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{
  "searchQueries": [
    "fantasy"
  ],
  "maxItems": 10
}' |
apify call maximedupre/storygraph --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,maximedupre/storygraph"
        }
    }
}
```

The hosted server signs you in with OAuth on first connect, so no API token belongs in this config. Clients without OAuth support can send an `Authorization: Bearer <APIFY_API_TOKEN>` header instead, using a token from API & Integrations in Apify Console (https://console.apify.com/settings/integrations).

## OpenAPI specification

Download the OpenAPI definition: https://api.apify.com/v2/actors/eONtWZQ1gtEqr4OBF/builds/pzvCCZFToobkvnbI7/openapi.json
