# OpenAlex Works & Scholarly Literature Scraper (`plainkitbin/openalex-works`) Actor

Extract scholarly works and metadata from the open catalog OpenAlex as structured JSON. Not affiliated with OpenAlex or OurResearch.

- **URL**: https://apify.com/plainkitbin/openalex-works.md
- **Developed by:** [PlainKit bin](https://apify.com/plainkitbin) (community)
- **Categories:** AI, Developer tools
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.48 / 1,000 openalex work records

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

## OpenAlex Works & Scholarly Literature Scraper

The OpenAlex Scholarly Works Scraper enables researchers, academic developers, intelligence analysts, and data engineers to extract scholarly works, scientific publications, citations, and open-access metadata directly from the OpenAlex open catalog as clean structured JSON rows. Research tools, literature monitoring systems, citation dashboards, and AI retrieval-augmented generation pipelines require dependable access to global research records without building custom crawlers or managing bulk database snapshots. One single run retrieves targeted academic works matching your search terms and filters, delivering DOIs, publication years, author names, open access URLs, source venue titles, and citation counts ready for analysis.

The price is **$0.005** per delivered scholarly work row under the `FREE` plan tier on Apify Pay-Per-Event (event name: `openalex-work`).
This Actor is an independent open-data adapter and is not affiliated with OpenAlex or OurResearch.

### Introduction

Scholarly literature forms the foundation of modern technology, medicine, and academic discovery. OpenAlex indexes over 250 million scientific works under an open CC0 public domain dedication. This scraper connects directly to the OpenAlex REST API to provide clean, normalized records for:

- **Research tools and literature reviews:** Extract papers matching specific keywords, authors, or research themes.
- **Continuous literature monitoring:** Track new papers in rapidly developing fields like machine learning or biotechnology.
- **Citation dashboards and bibliometrics:** Monitor citation impact and publication velocity across institutions.
- **AI retrieval pipelines:** Feed structured metadata, titles, and open access full-text links into LLM context windows.

### Tutorial

#### Quick start

1. Enter a search query in the `search` input field (e.g. `graphene` or `quantum computing`).
2. Optionally specify publication year bounds (`publication_year_from` and `publication_year_to`) or toggle `open_access_only`.
3. Optionally set a citation threshold with `min_citations` (e.g. `10` for works with 10 or more citations) or select a specific `work_type` (e.g. `article`, `book`, `preprint`, `dataset`).
4. Set `max_items` to the desired number of works to retrieve (from 1 to 1000).
5. Click **Start** to run the Actor and view delivered results in the Apify dataset tab.

#### API key

Small runs may work without an API key because OpenAlex allows keyless requests that share an IP-level daily quota. However, adding your own free OpenAlex key makes runs far more reliable and provides a dedicated daily allowance. You can obtain a free key instantly at https://openalex.org/settings/api. Pass your key into the secret `api_key` input field. The key is used only for direct calls to api.openalex.org and is never recorded in output dataset rows, storage values, or execution logs.

### Pricing

This Actor operates exclusively on Apify Pay-Per-Event (PPE) pricing:

- Event name: `openalex-work`
- Pricing model: Apify Pay-Per-Event
- Tier prices:
  - FREE: $0.005 per event
  - BRONZE: $0.0045 per event
  - SILVER: $0.004 per event
  - GOLD: $0.003484 per event
  - PLATINUM: $0.003484 per event
  - DIAMOND: $0.003334 per event

Each row is pushed first and charged right after a successful push; a refused charge stops work and that row stays delivered and uncharged; a reached limit stops work after that row was charged; failed items are neither pushed nor charged.
Restart protection: if a run is resumed after a platform restart, previously delivered works are detected and never pushed or charged twice.

### Input and output examples

#### Input example

```json
{
  "search": "graphene",
  "publication_year_from": 2020,
  "publication_year_to": 2024,
  "open_access_only": true,
  "min_citations": 10,
  "work_type": "article",
  "max_items": 5
}
```

#### Output example

Each delivered item contains 11 standardized fields:

```json
{
  "cited_by_count": 15236,
  "doi": "https://doi.org/10.1103/physrevlett.97.187401",
  "first_author_name": "Andrea Carlo Ferrari",
  "id": "https://openalex.org/W2136334331",
  "is_oa": true,
  "oa_url": "https://arxiv.org/pdf/cond-mat/0606284",
  "publication_date": "2006-10-30",
  "publication_year": 2006,
  "source_name": "Physical Review Letters",
  "title": "Raman Spectrum of Graphene and Graphene Layers",
  "type": "article"
}
```

### Actor recommendations

For related automated intelligence and open data monitoring pipelines, consider pairing this Actor with:

- **PubMed Scraper:** For biomedical, life sciences, and clinical research monitoring.
- **SEC Filings Scraper:** For public company corporate disclosures and regulatory filings.
- **FDA Recalls Scraper:** For food, drug, and medical device enforcement monitoring.

### FAQ and support

#### Is the data permitted for commercial reuse?

Yes. OpenAlex bibliographic metadata is released under the Creative Commons CC0 Public Domain Dedication, permitting reuse, analysis, and integration without restriction.

#### What happens if the OpenAlex rate limit is reached?

If the daily OpenAlex budget is exhausted or a key is refused, the Actor ends gracefully with one uncharged status record instructing you to provide a free OpenAlex API key or try again later.

#### How can I get support?

For technical inquiries, bug reports, or compliance assistance, please contact the team at compliance@example.com.

# Actor input Schema

## `search` (type: `string`):

Free-text search query matching scholarly work titles, abstracts, or concepts.

## `publication_year_from` (type: `integer`):

Filter works published in or after this calendar year.

## `publication_year_to` (type: `integer`):

Filter works published in or before this calendar year.

## `open_access_only` (type: `boolean`):

When true, restrict results to open access works only.

## `min_citations` (type: `integer`):

Filter works with at least this many citations. Leave empty for no citation threshold.

## `work_type` (type: `string`):

Filter works by specific scholarly type (e.g. article, book, preprint, dataset). Leave empty for all types.

## `api_key` (type: `string`):

Optional personal OpenAlex API key. Raises rate limits and daily free quota.

## `max_items` (type: `integer`):

Maximum number of works to collect and output (1 to 1000).

## Actor input object example

```json
{
  "search": "graphene",
  "open_access_only": false,
  "work_type": "",
  "max_items": 10
}
```

# Actor output Schema

## `results` (type: `string`):

Dataset items produced by this run.

# 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 = {
    "search": "graphene",
    "max_items": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("plainkitbin/openalex-works").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 = {
    "search": "graphene",
    "max_items": 10,
}

# Run the Actor and wait for it to finish
run = client.actor("plainkitbin/openalex-works").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 '{
  "search": "graphene",
  "max_items": 10
}' |
apify call plainkitbin/openalex-works --silent --output-dataset

```

## MCP server setup

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

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/8Q31ygtxSnVbTfDhQ/builds/7MguOVyYVsl3Y3UwY/openapi.json
