# ClinicalTrials.gov Search API: Studies by Condition & Drug (`lathewright/clinical-trials-search`) Actor

Returns clinical studies from the official ClinicalTrials.gov API v2 by condition, drug, sponsor, status, phase, location and update date: design, enrollment, dates, eligibility, outcomes and sites. No key. For biotech, CROs, investors and AI agents.

- **URL**: https://apify.com/lathewright/clinical-trials-search.md
- **Developed by:** [lathewright LLC](https://apify.com/lathewright) (community)
- **Categories:** Business, Automation, Other
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

$3.00 / 1,000 study founds

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

## ClinicalTrials.gov Search API: Studies by Condition & Drug

Search ClinicalTrials.gov by condition, intervention, sponsor, status, phase and location and get one clean row per study, for biotech analysts, CROs, patient advocates and AI agents. It costs $0.003 per study, so 100 studies cost $0.30.

Search the world's largest clinical trials registry by condition, intervention, keyword, sponsor, location, status, phase, study type and update date, and get one clean row per study: design, phases, enrollment, start and completion dates, sponsor and collaborators, conditions, interventions, eligibility, primary outcomes and site countries (optionally the full site list). Uses the official ClinicalTrials.gov API v2, no key needed.

Built and maintained by **Lathewright**. Lathewright is operated by AI systems under human ownership. A person reviews and approves everything we publish, send and sell. **$0.003 per study.**

### Who uses it

- **Biotech and pharma competitive intelligence**: every recruiting Phase 3 trial for a mechanism, weekly, into a sheet or Slack.
- **CROs and site networks**: find sponsors and trials starting near your sites.
- **Investors and analysts**: readout timelines (`primaryCompletionDate`) by company.
- **Patient advocates and clinicians**: recruiting trials for a condition near a city.
- **AI agents**: "Which Phase 3 GLP-1 trials in type 2 diabetes are recruiting, who sponsors them and when do they read out?"

### Example tasks

Paste any of these into the Input tab, or send the same JSON through the API. Prices are the per-result prices listed under Pricing.

#### 1. Recruiting semaglutide trials for type 2 diabetes

```json
{
  "condition": "type 2 diabetes",
  "intervention": "semaglutide",
  "statuses": ["RECRUITING"],
  "maxResults": 25
}
```

What comes back: One row per study with `nctId`, `title`, `status`, `phases`, `sponsor`, `enrollment`, `startDate`, `primaryCompletionDate` and `url`. Up to 25 rows, at most $0.075.

#### 2. Phase 3 studies from one sponsor, updated recently

```json
{
  "sponsor": "Pfizer",
  "phases": ["PHASE3"],
  "updatedSince": "2026-09-01",
  "maxResults": 50
}
```

What comes back: Phase 3 studies whose record changed on or after 1 September 2026, handy for a weekly monitor.

#### 3. Lung cancer studies near Boston with site lists

```json
{
  "condition": "lung cancer",
  "location": "Boston",
  "includeLocations": true,
  "maxResults": 10
}
```

What comes back: Each row also carries the full `locations` list.

### Input

```json
{
  "condition": "type 2 diabetes",
  "intervention": "semaglutide",
  "statuses": ["RECRUITING", "NOT_YET_RECRUITING"],
  "phases": ["PHASE3"],
  "studyType": "INTERVENTIONAL",
  "updatedSince": "2026-09-01",
  "includeLocations": false,
  "maxResults": 200
}
```

| Field | Notes |
|---|---|
| `condition`, `intervention`, `keywords`, `sponsor`, `location` | Free text; at least one is required |
| `statuses` | RECRUITING, NOT_YET_RECRUITING, ENROLLING_BY_INVITATION, ACTIVE_NOT_RECRUITING, COMPLETED, SUSPENDED, TERMINATED, WITHDRAWN, UNKNOWN |
| `phases` | EARLY_PHASE1, PHASE1, PHASE2, PHASE3, PHASE4, NA |
| `studyType` | INTERVENTIONAL or OBSERVATIONAL |
| `updatedSince` | YYYY-MM-DD; only records posted or updated since then |
| `includeLocations` | Add facility name, city, state, country and status per site |
| `maxResults` | Cap on studies |

### Output (one row per study)

```json
{
  "nctId": "NCT07564414",
  "title": "A Research Study to Look at How Two Different Doses of Semaglutide Work in People With Type 2 Diabetes",
  "status": "RECRUITING",
  "studyType": "INTERVENTIONAL",
  "phases": ["PHASE3"],
  "allocation": "RANDOMIZED",
  "masking": "DOUBLE",
  "conditions": ["Diabetes Mellitus, Type 2"],
  "interventions": [{ "type": "DRUG", "name": "Semaglutide" }],
  "sponsor": "Novo Nordisk A/S",
  "sponsorClass": "INDUSTRY",
  "enrollment": 2500,
  "startDate": "2026-05-21",
  "primaryCompletionDate": "2028-02-23",
  "eligibility": { "sex": "ALL", "minimumAge": "18 Years", "maximumAge": null, "healthyVolunteers": false, "criteria": "Inclusion Criteria: ..." },
  "primaryOutcomes": ["Change in HbA1c"],
  "locationsCount": 303,
  "locationCountries": ["United States", "Argentina", "Australia"],
  "hasResults": false,
  "url": "https://clinicaltrials.gov/study/NCT07564414"
}
```

### Pricing

| Event | Price |
|---|---|
| Study found (`study`) | $0.003 |

Plus Apify's start fee ($0.00005). 100 studies = $0.30. Studies filtered out by `phases` are never charged.

### How to use it

- **Console**: fill in the form, Start, export.
- **API**: `POST https://api.apify.com/v2/acts/lathewright~clinical-trials-search/run-sync-get-dataset-items?token=<token>`
- **n8n / Make / Zapier**: Apify node on a weekly schedule with `updatedSince` = last week → new or changed trials to your team.

### Use from an AI agent (MCP)

Add this Actor as a tool in Claude, Cursor, VS Code or any MCP client with `https://mcp.apify.com/?tools=lathewright/clinical-trials-search`. The Actor description is the tool description, and the input fields above are the tool parameters. Example prompts: "Recruiting Phase 2 or 3 trials for NSCLC with KRAS inhibitors", "What is Amgen running in obesity and when do the trials complete?".

### Data source and fair use

ClinicalTrials.gov API v2 (US National Library of Medicine), public domain, no key. The Actor sends at most two to three requests per second. Study contact names and emails are deliberately excluded; only organization-level sponsor and facility data is returned.

### FAQ

**Why do some trials show no sites?** Trials that are not yet recruiting often have no locations posted.

**Can I get results data?** `hasResults` tells you whether posted results exist; the `url` leads to the results tab. A results-extraction Actor is on the roadmap.

# Actor input Schema

## `condition` (type: `string`):

e.g. `type 2 diabetes`, `NSCLC`, `Alzheimer`.

## `intervention` (type: `string`):

e.g. `semaglutide`, `CAR-T`, `metformin`.

## `keywords` (type: `string`):

Free text searched across titles, summaries and keywords.

## `sponsor` (type: `string`):

e.g. `Novo Nordisk`, `National Cancer Institute`.

## `location` (type: `string`):

City, state or country, e.g. `Boston, Massachusetts` or `Germany`.

## `statuses` (type: `array`):

Any of RECRUITING, NOT_YET_RECRUITING, ENROLLING_BY_INVITATION, ACTIVE_NOT_RECRUITING, COMPLETED, SUSPENDED, TERMINATED, WITHDRAWN, UNKNOWN. Empty = all.

## `phases` (type: `array`):

Any of EARLY_PHASE1, PHASE1, PHASE2, PHASE3, PHASE4, NA. Empty = all.

## `studyType` (type: `string`):

INTERVENTIONAL, OBSERVATIONAL or empty for both.

## `updatedSince` (type: `string`):

Only studies whose record was posted/updated on or after this date. Great for weekly monitoring.

## `includeLocations` (type: `boolean`):

Add the list of facilities (name, city, state, country, status). No personal contact data is included.

## `maxResults` (type: `integer`):

Cap on studies returned.

## `compactOutput` (type: `boolean`):

Return only the key fields (smaller, cheaper for AI agents to read).

## Actor input object example

```json
{
  "condition": "type 2 diabetes",
  "intervention": "semaglutide",
  "includeLocations": false,
  "maxResults": 25,
  "compactOutput": false
}
```

# Actor output Schema

## `studies` (type: `string`):

One row per study.

# 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 = {
    "condition": "type 2 diabetes",
    "intervention": "semaglutide"
};

// Run the Actor and wait for it to finish
const run = await client.actor("lathewright/clinical-trials-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 = {
    "condition": "type 2 diabetes",
    "intervention": "semaglutide",
}

# Run the Actor and wait for it to finish
run = client.actor("lathewright/clinical-trials-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 '{
  "condition": "type 2 diabetes",
  "intervention": "semaglutide"
}' |
apify call lathewright/clinical-trials-search --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,lathewright/clinical-trials-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/pvu0SGYsn5gnANu85/builds/jSK5JEQKs7hpewUtS/openapi.json
