# OpenAlex Research Papers, Authors & Institutions Export (`kingly_contest_7cb/openalex-scraper`) Actor

Search OpenAlex, the open catalog of 300M+ scholarly works, and export works, authors, institutions, journals or topics as clean JSON: DOI, authors with ORCID and affiliations, citations, open access links, topics and abstracts. No API key needed to start; add your free key for big exports.

- **URL**: https://apify.com/kingly_contest_7cb/openalex-scraper.md
- **Developed by:** [Carina Hatton](https://apify.com/kingly_contest_7cb) (community)
- **Categories:** AI, Developer tools, Lead generation
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $1.00 / 1,000 records

This Actor is paid per event. You are not charged for the Apify platform usage, but only a fixed price for specific events.

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 Research Papers, Authors & Institutions Export

OpenAlex is the big open catalog of scholarly research: hundreds of millions of papers, books and datasets, plus the people, institutions, journals and topics around them. It has a great API, but turning its nested JSON into something you can drop in a spreadsheet or a pipeline takes a bit of work. This Actor does that part for you.

Give it a search, a few filters, or a list of DOIs, and you get back one clean record per item: title, DOI, year, journal, every author with their ORCID and affiliations, citation counts, open access status with a link to the free copy, topics, and (if you want) the abstract as readable text.

### What you can export

| Pick | You get |
|---|---|
| **Works** | Papers, preprints, books, datasets. DOI, title, date, type, venue, authors + ORCID + institutions, citations, FWCI, OA status and URL, PDF link, topics, concepts, keywords, referenced works count, retraction flag, optional abstract |
| **Authors** | Name, ORCID, works and citation counts, h-index, i10-index, last known institutions, top topics |
| **Institutions** | Name, ROR, country, type, homepage, works and citations, h-index, top topics |
| **Sources** | Journals, repositories, conferences. ISSN, publisher, OA and DOAJ flags, APC, works and citations, h-index |
| **Topics** | Name, description, keywords, subfield / field / domain, works and citations |

### Filters

- **Search query**: full-text search. For works OpenAlex looks at titles, abstracts and full text; for everything else, names.
- **Publication year range** (works).
- **Open access only** (works and journals).
- **Institutions**: OpenAlex IDs like `I136199984`, ROR links like `https://ror.org/03vek6s52`, or plain names. Names get looked up and the match is written to the log, so check it. IDs are the safe bet.
- **Author ORCID iDs**: works by those people, or their author records.
- **DOI list**: pull exact works. Any format works (`10.1234/abc`, `https://doi.org/10.1234/abc`, `doi:10.1234/abc`).
- **Extra filter**: if you know OpenAlex's filter syntax, add anything else here (e.g. `type:article,language:en`).

Sort by relevance, most cited, newest, oldest, most works, or name. Set **Max records** so you don't accidentally pull a million rows.

### Do I need an OpenAlex API key?

No, not to get started. Leave the key field empty and the Actor runs on OpenAlex's free keyless allowance, which is fine for trying it out and for small exports.

The catch: the keyless allowance is small ($0.10 of OpenAlex usage a day) and it's shared by everyone calling from the same IP address, which on a cloud platform can include other people. Keyless runs are also capped at 10,000 results per query. If the shared allowance runs out mid-run, the Actor stops with a clear message and keeps whatever it already saved. It doesn't try to get around OpenAlex's limits (no proxy rotation or similar).

For anything regular or bigger, add your own key. It's free: sign up at [openalex.org](https://openalex.org) and copy your key from [openalex.org/settings/api](https://openalex.org/settings/api) into the **OpenAlex API key** field. The field is marked secret, so Apify stores it encrypted and the Actor only ever sends it to OpenAlex (in a header, never in a URL or the logs). With a key you get your own daily allowance (around $1 of API usage per day at the time of writing, which goes a long way: a page of 100 filtered works costs $0.0001 and a page of search results $0.001), fast cursor paging, and no 10,000-result ceiling.

**Your OpenAlex usage is separate from what you pay on Apify.** Anything OpenAlex charges for going over the free allowance is between you and OpenAlex.

### Example input

```json
{
  "apiKey": "your-openalex-key (optional)",
  "entityType": "works",
  "searchQuery": "large language models",
  "yearFrom": 2022,
  "yearTo": 2024,
  "openAccessOnly": true,
  "sort": "cited_by_count",
  "includeAbstract": true,
  "maxItems": 500
}
```

### Example output (one work, trimmed)

```json
{
  "entityType": "work",
  "id": "W4396721167",
  "doi": "10.1038/s41586-024-07487-w",
  "doiUrl": "https://doi.org/10.1038/s41586-024-07487-w",
  "title": "Accurate structure prediction of biomolecular interactions with AlphaFold 3",
  "publicationDate": "2024-05-08",
  "publicationYear": 2024,
  "type": "article",
  "venue": {"id": "S137773608", "name": "Nature", "type": "journal", "issnL": "0028-0836", "publisher": "Nature Portfolio"},
  "authors": [
    {
      "name": "Josh Abramson",
      "orcid": "https://orcid.org/0009-0000-3496-6952",
      "position": "first",
      "institutions": [{"id": "I4210090411", "name": "Google DeepMind (United Kingdom)", "ror": "https://ror.org/00971b260", "countryCode": "GB"}]
    }
  ],
  "authorCount": 48,
  "citedByCount": 15805,
  "isOpenAccess": true,
  "oaStatus": "hybrid",
  "oaUrl": "https://doi.org/10.1038/s41586-024-07487-w",
  "primaryTopic": {"id": "T10044", "name": "Protein Structure and Dynamics", "field": "Biochemistry, Genetics and Molecular Biology"},
  "referencedWorksCount": 71,
  "abstract": "The introduction of AlphaFold 2 has spurred a revolution in modelling the structure of proteins..."
}
```

A `RUN_SUMMARY` record in the key-value store shows the exact OpenAlex query URLs, how many results matched, how many were saved, and how much OpenAlex usage the run spent.

### A few things to know

- **Abstracts.** OpenAlex stores abstracts as a word index instead of plain text. The Actor puts the words back in order, so the text is readable, though now and then the spacing or punctuation is a little off. Plenty of works have no abstract at all because publishers don't share them.
- **Counts change.** Citation counts and topics update as OpenAlex reprocesses its data, so two runs a month apart won't match exactly.
- **Odd records at the top.** OpenAlex counts things like a journal's front matter or a whole conference series as "works" (type `paratext`), and some of them have huge citation counts, so they can show up first when sorting by citations. Add `is_paratext:false` (or `type:article`) in the extra filter to drop them.
- **Duplicates.** Each OpenAlex ID is saved once per run.

### Pricing

Pay per event: a tiny charge when the run starts plus about **$0.001 per record** saved. 1,000 works costs about $1. Set a max charge on the run if you want a hard cap; the Actor stops cleanly when it's reached.

### Data source and credit

All data comes from [OpenAlex](https://openalex.org), built by the nonprofit OurResearch. OpenAlex data is released under [CC0](https://creativecommons.org/publicdomain/zero/1.0/), so you can use it however you like, but please credit OpenAlex when you publish something built on it. This Actor isn't made, endorsed or supported by OpenAlex or OurResearch; it's an independent tool that calls their public API under their [terms](https://openalex.org/OpenAlex_termsofservice.pdf).

# Actor input Schema

## `apiKey` (type: `string`):

Optional. Leave empty to run on OpenAlex's free keyless allowance, which is small, shared per IP address and capped at 10,000 results per query. For bigger or regular exports, paste your own free key from openalex.org/settings/api. It's stored encrypted and only sent to OpenAlex.

## `entityType` (type: `string`):

The kind of OpenAlex record to return.

## `searchQuery` (type: `string`):

Full-text search. For works it looks at titles, abstracts and full text; for the other types, names. Leave empty to list by filters only.

## `yearFrom` (type: `integer`):

Works only.

## `yearTo` (type: `integer`):

Works only. Inclusive.

## `openAccessOnly` (type: `boolean`):

Works: only open access works. Sources: only open access journals.

## `institutions` (type: `array`):

OpenAlex IDs (I136199984), ROR IDs (https://ror.org/03vek6s52) or names. Names are looked up and the best match is logged, so IDs are safer. Applies to works (author affiliations), authors (affiliations) and institutions.

## `authorOrcids` (type: `array`):

e.g. 0000-0003-1613-5981. Works by these authors, or the author records themselves.

## `dois` (type: `array`):

Look up specific works by DOI (10.7717/peerj.4375 or https://doi.org/...). Works only.

## `additionalFilter` (type: `string`):

Raw OpenAlex filter syntax added to the query, e.g. type:article,language:en. See the OpenAlex docs for all filters.

## `sort` (type: `string`):

Leave empty for OpenAlex's default order (relevance when searching).

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

Stop after this many records. 0 = no limit (be careful: some queries match millions).

## `includeAbstract` (type: `boolean`):

Works only. Rebuilds the abstract text from OpenAlex's inverted index. Not every work has one.

## Actor input object example

```json
{
  "entityType": "works",
  "searchQuery": "large language models",
  "openAccessOnly": false,
  "maxItems": 50,
  "includeAbstract": false
}
```

# Actor output Schema

## `records` (type: `string`):

No description

## `summary` (type: `string`):

No description

# 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 = {
    "searchQuery": "large language models",
    "maxItems": 50
};

// Run the Actor and wait for it to finish
const run = await client.actor("kingly_contest_7cb/openalex-scraper").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 = {
    "searchQuery": "large language models",
    "maxItems": 50,
}

# Run the Actor and wait for it to finish
run = client.actor("kingly_contest_7cb/openalex-scraper").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 '{
  "searchQuery": "large language models",
  "maxItems": 50
}' |
apify call kingly_contest_7cb/openalex-scraper --silent --output-dataset

```

## MCP server setup

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

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/TxU3URHNoK0rzVdBO/builds/JAgscYhN737owID3F/openapi.json
