# arXiv Papers Scraper (`jonboyd544/arxiv-papers-scraper`) Actor

Search arXiv through its official API by keyword, category and submission date. Returns title, abstract, authors, categories, dates, DOI, journal reference and PDF links, newest first.

- **URL**: https://apify.com/jonboyd544/arxiv-papers-scraper.md
- **Developed by:** [Jonathan Boyd](https://apify.com/jonboyd544) (community)
- **Categories:** AI, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$2.00 / 1,000 results

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

## arXiv Papers Scraper

Search arXiv through its official API by keyword, category and submission date. Returns title, abstract, authors, categories, dates, DOI, journal reference and PDF links, newest first.

Uses only official/public data endpoints, paces requests to respect the source's rate limits, retries transient errors, removes duplicates and returns clean, flat, consistently typed JSON, CSV or Excel.

### Use cases

- Track new AI/ML, physics or math research daily
- Build literature-review and RAG datasets
- Analyse publication trends by category

### Input

| Field | Type | Description | Default |
|---|---|---|---|
| `query` | string | Keywords or arXiv syntax: ti:, au:, abs:, all:, AND/OR/ANDNOT. Plain phrases are searched in all fields. | — |
| `categories` | array | arXiv categories, e.g. cs.CL, cs.LG, stat.ML, astro-ph. | \[] |
| `submittedFrom` | string | Earliest submission date. Format: YYYY-MM-DD. | — |
| `submittedTo` | string | Latest submission date. Format: YYYY-MM-DD. | — |
| `sortBy` | string | Ordering field. | "submittedDate" |
| `sortOrder` | string | descending = newest first. | "descending" |
| `maxItems` | integer | Maximum number of results to save (and pay for). The run stops as soon as this many unique results are saved. | 100 |

Example input:

```json
{
  "query": "large language model",
  "categories": [
    "cs.CL"
  ],
  "maxItems": 20
}
```

### Output

Each result is one flat record with these fields (missing values are `null`, lists are `[]`):

| Field | Type |
|---|---|
| `arxivId` | string |
| `version` | integer |
| `title` | string |
| `abstract` | string |
| `authors` | array |
| `firstAuthor` | string |
| `authorCount` | integer |
| `primaryCategory` | string |
| `categories` | array |
| `published` | string |
| `updated` | string |
| `doi` | string |
| `journalRef` | string |
| `comment` | string |
| `url` | string |
| `pdfUrl` | string |

Example result:

```json
{
  "arxivId": "2610.40627",
  "version": 1,
  "title": "ShallowDefend: Harnessing Shallow Safety Alignment for Multi-Turn Defender",
  "abstract": "Safety alignment has enabled large language models to reliably refuse harmful requests directly, yet the same request distributed across a multi-turn conversation still succeeds far too often. This brittleness has a mechanistic root: Alignment is shallow, with safety behavior concentrated in a model's first few output tokens, and existing defenses inherit the weakness, supervising the surface form of the response without ever giving the model an explicit safety decision to learn. We take the opposite view of shallowness: if a short span determines the trajectory of an entire response, that span is the highest-leverage place to intervene, and the defender can occupy it first. We propose Assess $\\to$ Decide $\\to$ Respond, a framework in which the defender assesses the user's intent, commits to an explicit, parseable safety decision, and only then generates a reply conditioned on it, with the commitment trained by reinforcement learning at the payload turn. Because the decision is a token span, the reward can be a rule: a self-verified reward checks the committed label against the conversation's known nature, requiring no judge and no annotation, while the same format also supports an LLM-as-judge reward over a graded decision space with safe redirection. Across two model families and fourteen benchmarks spanning safety, utility, and helpfulness, our defenders achieve the strongest multi-turn safety in a controlled comparison, maintaining their lead in safety while preserving utility at a modest cost to helpfulness. A per-token KL analysis and interventional probes confirm why this works: training concentrates its effect on the brief deliberation that sets a response's trajectory, and the decision committed there is a causal control point. The very shallowness attackers exploit becomes the mechanism of defense.",
  "authors": [
    "Qiyao Ma",
    "Xiaodong Liu",
    "Weiwei Yang",
    "Mingqian Feng",
    "Chengquan Guo",
    "Jialin Song",
    "Carolyn Buractaon",
    "Zhe Zhao",
    "Junshan Zhang",
    "Sandeep Atluri",
    "Christopher White",
    "Jianfeng Gao"
  ],
  "firstAuthor": "Qiyao Ma",
  "authorCount": 12,
  "primaryCategory": "cs.CL",
  "categories": [
    "cs.CL"
  ],
  "published": "2026-10-29T17:56:53Z",
  "updated": "2026-10-29T17:56:53Z",
  "doi": null,
  "journalRef": null,
  "comment": null,
  "url": "https://arxiv.org/abs/2610.40627",
  "pdfUrl": "https://arxiv.org/pdf/2610.40627v1"
}
```

The **Overview** dataset view shows the key columns as a table; export everything as JSON, CSV, Excel or via API.

### Pricing

Pay per result: you are charged one `result` event for each saved record (suggested $1.00 per 1,000 results), plus nothing for duplicates, failed requests or empty runs. The run stops automatically at your **Max results** setting or at the maximum total charge you set for the run, whichever comes first.

### FAQ

**Is this legal / allowed?** It reads publicly available data from official public sources and follows their published rate limits. Check the source's terms for your use case.

**Why did I get fewer results than Max results?** Your filters matched fewer records, or the source caps how many it returns (see Limitations).

**What happens on errors?** Transient errors (timeouts, rate limits, 5xx) are retried with exponential backoff. Invalid input stops the run immediately with a message explaining what to fix.

**Can I schedule it?** Yes, use Apify Schedules; duplicates within a run are removed automatically.

### Limitations

- arXiv asks for at most one request every 3 seconds, so large runs take time (about 200 papers per 3 s).
- arXiv caps a single query at 30,000 results.
- Results depend on the public source; if it is down, the actor retries with backoff and then fails with a clear message (you are not charged for results that were not saved).

# Actor input Schema

## `query` (type: `string`):

Keywords or arXiv syntax: ti:, au:, abs:, all:, AND/OR/ANDNOT. Plain phrases are searched in all fields.

## `categories` (type: `array`):

arXiv categories, e.g. cs.CL, cs.LG, stat.ML, astro-ph.

## `submittedFrom` (type: `string`):

Earliest submission date. Format: YYYY-MM-DD.

## `submittedTo` (type: `string`):

Latest submission date. Format: YYYY-MM-DD.

## `sortBy` (type: `string`):

Ordering field.

## `sortOrder` (type: `string`):

descending = newest first.

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

Maximum number of results to save (and pay for). The run stops as soon as this many unique results are saved.

## Actor input object example

```json
{
  "query": "large language model",
  "categories": [
    "cs.CL"
  ],
  "sortBy": "submittedDate",
  "sortOrder": "descending",
  "maxItems": 100
}
```

# Actor output Schema

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

All scraped results (overview table view)

# 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 = {
    "query": "large language model",
    "categories": [
        "cs.CL"
    ],
    "maxItems": 100
};

// Run the Actor and wait for it to finish
const run = await client.actor("jonboyd544/arxiv-papers-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 = {
    "query": "large language model",
    "categories": ["cs.CL"],
    "maxItems": 100,
}

# Run the Actor and wait for it to finish
run = client.actor("jonboyd544/arxiv-papers-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 '{
  "query": "large language model",
  "categories": [
    "cs.CL"
  ],
  "maxItems": 100
}' |
apify call jonboyd544/arxiv-papers-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,jonboyd544/arxiv-papers-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/CpeeCq7BPsgQW1c30/builds/2Zs1ptDvZRigftODY/openapi.json
