# Book Reader Stats API
> Live reader-community stats for books from Open Library (the Internet Archive's open book catalog) — no key, nothing stored. This is the reading-community view of a book: how readers rate it and how many want to read, are reading or have already read it, distinct from the plain book-catalog and reading-trends APIs in the catalogue — this is the community-engagement layer, not the bibliographic record. The book endpoint returns a title's reader stats: the average rating, the full 1-5 star distribution, and the reading-log counts (want-to-read, currently-reading, already-read), with its authors, first-published year and subjects. The search endpoint searches books and returns each match with its rating and want-to-read count, so you can find a work and its Open Library id. The author endpoint returns an author's profile — work count, top work and dates. Build reading dashboards, book-recommendation widgets, "most wanted" charts and community-sentiment tools on top of real Open Library data. Look up a book by its Open Library work id (work=OL27448W) or by title (title=the hobbit); reading-log counts come from the community's bookshelves.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/bookstats-api/..."
```

## Pricing
- **Free** (Free) — 25,000 calls/Mo, 3 req/s
- **Starter** ($5/Mo) — 330,000 calls/Mo, 10 req/s
- **Pro** ($14/Mo) — 1,400,000 calls/Mo, 25 req/s
- **Scale** ($33/Mo) — 5,000,000 calls/Mo, 55 req/s

## Endpoints

### Book

#### `GET /v1/book` — A book reader stats — ratings and reading-log

**Parameters:**
- `work` (query, optional, string) — Open Library work id Example: `OL27448W`
- `title` (query, optional, string) — Book title (resolved via search) Example: `the hobbit`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bookstats-api/v1/book?work=OL27448W&title=the+hobbit"
```

### Search

#### `GET /v1/search` — Search books with ratings and want-to-read

**Parameters:**
- `q` (query, required, string) — Search query Example: `dune`
- `limit` (query, optional, string) — Max results (default 10, max 25) Example: `10`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bookstats-api/v1/search?q=dune&limit=10"
```

### Author

#### `GET /v1/author` — An author profile — work count, top work

**Parameters:**
- `author` (query, required, string) — Author name Example: `brandon sanderson`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bookstats-api/v1/author?author=brandon+sanderson"
```

### Meta

#### `GET /v1/meta` — Service metadata

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/bookstats-api/v1/meta"
```


---
Marketplace page: https://www.oanor.com/api/bookstats-api
OpenAPI spec: https://www.oanor.com/api/bookstats-api/openapi.json
