# PubMed Article Search (`snappytools/pubmed-article-search`) Actor

Type a PubMed search and get back the matching articles with titles, abstracts, authors, journal, year, PMID and DOI. This PubMed search tool calls the official NCBI E-utilities, so the results match what you see on pubmed.ncbi.nlm.nih.gov.

- **URL**: https://apify.com/snappytools/pubmed-article-search.md
- **Developed by:** [Snappy](https://apify.com/snappytools) (community)
- **Categories:** News
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$1.70 / 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

## PubMed Search API – Articles, Abstracts and PMIDs

PubMed search tool that returns titles, abstracts, journal, year, PMID and DOI for any query, straight from the official NCBI E-utilities.

You give it a list of search queries, written the same way you would type them into PubMed. You get back one row per query, holding the total number of matches and a list of the top articles. Each article has `pmid`, `title`, `abstract`, `authors`, `journal`, `year`, `doi` and a direct `url` to its PubMed page.

Bad or empty queries don't stop the run. Each one still gets its own row with a `status`, so you get one row back for every query you sent. Set it on a schedule with newest-first sorting to keep an eye on new papers.

### Why this one

- **Official source.** Every result comes from NCBI E-utilities, the public API behind PubMed, so it matches what you see on pubmed.ncbi.nlm.nih.gov.
- **Abstracts included.** Each article carries its abstract text, with section labels such as BACKGROUND kept in place.
- **One row per query.** Results line up with your input list, which makes matching and checking easy.
- **PubMed syntax works.** Field tags such as `[ti]` and `[pmid]` and AND/OR operators go to PubMed as written.
- **Pay per result.** $1.70 per 1,000 results, no start fee, and runs with no results cost nothing.

### Quick start

```json
{
  "queries": ["CRISPR sickle cell disease", "metformin[ti] AND aging", "long covid fatigue randomized controlled trial"],
  "maxResultsPerQuery": 5,
  "sort": "relevance"
}
```

This returns three rows, each with the five best-matching PubMed articles for that query. In a test run on 20 Nov 2026, "CRISPR sickle cell disease" matched 498 articles and "metformin\[ti] AND aging" matched 748.

### What you can use it for

| Who | What for |
| --- | --- |
| Medical writers | Pull abstracts and DOIs for a reference list in one go |
| Research analysts | Track new papers on a drug or condition every week |
| Pharma and biotech teams | Check published evidence for a target or compound |
| Students and librarians | Export PubMed search results for a literature review to CSV |
| Automation builders | Feed citations and abstracts into a pipeline |

### How to use it

1. Click **Try for free**.
2. In **Search queries**, add one query per line, for example `metformin[ti] AND aging`. Up to 50 queries per run.
3. Set **Max articles per query**, for example `10`. The range is 1 to 50.
4. Pick a **Sort order**: `relevance` (best match) or `pub_date` (newest first).
5. Click **Start**.

Tip: choose `pub_date` and set a weekly schedule to watch for new papers on a topic.

### What data you get

Each row is one query, and its `articles` list holds the matching papers.

| Field | What it is | Example |
| --- | --- | --- |
| `id` | Stable ID for the query | `q-3aa1a819287c` |
| `input` | The query you sent | `metformin[ti] AND aging` |
| `status` | Result of the query, such as `ok` | `ok` |
| `reason` | Note when status isn't ok | `null` |
| `totalCount` | Total PubMed matches for the query | `498` |
| `returnedCount` | Articles included in this row | `5` |
| `searchUrl` | The same search on PubMed | `https://pubmed.ncbi.nlm.nih.gov/?term=CRISPR%20sickle%20cell%20disease` |
| `articles[].pmid` | PubMed ID | `33283989` |
| `articles[].url` | PubMed page for the article | `https://pubmed.ncbi.nlm.nih.gov/33283989/` |
| `articles[].title` | Article title | `Metformin decelerates aging clock in male monkeys.` |
| `articles[].abstract` | Abstract text | `Sickle cell disease (SCD) is the most common monogenic blood disorder...` |
| `articles[].authors` | Author names | `[]` |
| `articles[].journal` | Journal title | `Cell metabolism` |
| `articles[].year` | Publication year | `2024` |
| `articles[].doi` | DOI when listed | `10.1056/NEJMoa2031054` |
| `checkedAt` | When the query ran (ISO 8601) | `2026-11-20T09:57:49.162Z` |
| `source` | Service used and its link | `NCBI E-utilities (PubMed)` |

### Pricing

| Event | Price |
| --- | --- |
| Result (each result written to the dataset) | $0.0017 |

| Run | Cost |
| --- | --- |
| 100 results | $0.17 |
| 1,000 results | $1.70 |
| 10,000 results | $17.00 |

There is no start fee, and runs with no results cost nothing.

### Good to know

- **Limits:** up to 50 queries per run and up to 50 articles per query.
- **Data source:** NCBI E-utilities, the official public API for PubMed.
- **Not included:** full-text articles and paywalled content. Some records have no abstract or DOI.
- **Authors:** the `authors` list came back empty in the test run, so don't rely on it yet.
- **Freshness:** results are live from PubMed at run time.
- **Not affiliated:** this tool isn't affiliated with or endorsed by NCBI, the NLM or the NIH.

### FAQ

**Is there a PubMed API?**
Yes, NCBI runs the free E-utilities API. This tool wraps it and gives you clean rows with abstracts.

**How do I export PubMed search results to Excel or CSV?**
Run your queries, then download the dataset as Excel or CSV from the Output tab.

**Can I use PubMed search tags like \[ti] or \[pmid]?**
Yes. Queries go to PubMed as written, so PubMed search syntax works.

**What happens if a query is empty or finds nothing?**
It still gets its own row with a `status` and a `reason`, so the run carries on.

### Getting the data out

Download results as Excel, CSV or JSON from the Output tab. Send them to Google Sheets, Slack, Zapier, Make or webhooks from the **Integrations** tab. Every run is also available through the Apify API, and you can run it on a timetable from **Schedules**.

### Questions or problems

Open an issue on the **Issues** tab and include the run link. I reply within one business day.

### Related tools

- [Public RSS Feed Monitor](https://apify.com/snappytools/rss-feed-monitor): watch RSS feeds for new items
- [Sitemap News Article Extractor](https://apify.com/snappytools/smart-sitemap-article-extractor): pull articles from a site's sitemap
- [Hacker News Search and Who-is-Hiring Extractor](https://apify.com/snappytools/hackernews-algolia-scraper): search Hacker News and export results

# Actor input Schema

## `queries` (type: `array`):

List of PubMed search queries, one per line, written exactly as you would type them into PubMed. Field tags work, for example: CRISPR sickle cell disease, metformin\[ti] AND aging, or 34567890\[pmid]. Up to 50 queries per run.

## `maxResultsPerQuery` (type: `integer`):

How many of the most relevant articles to return for each query, from 1 to 50. Example: 5.

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

How PubMed orders the matches before the top results are taken. Use relevance (best match) or pub_date (newest first).

## Actor input object example

```json
{
  "queries": [
    "CRISPR sickle cell disease",
    "metformin[ti] AND aging",
    "long covid fatigue randomized controlled trial"
  ],
  "maxResultsPerQuery": 5,
  "sort": "relevance"
}
```

# Actor output Schema

## `results` (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 = {
    "queries": [
        "CRISPR sickle cell disease",
        "metformin[ti] AND aging",
        "long covid fatigue randomized controlled trial"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("snappytools/pubmed-article-search").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 = { "queries": [
        "CRISPR sickle cell disease",
        "metformin[ti] AND aging",
        "long covid fatigue randomized controlled trial",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("snappytools/pubmed-article-search").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 '{
  "queries": [
    "CRISPR sickle cell disease",
    "metformin[ti] AND aging",
    "long covid fatigue randomized controlled trial"
  ]
}' |
apify call snappytools/pubmed-article-search --silent --output-dataset

```

## MCP server setup

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

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/0qVitqcGuDqr81ENX/builds/JQGUyZR2mrLXdUorS/openapi.json
