# Open Targets Platform Scraper (`parseforge/open-targets-platform-scraper`) Actor

Scrapes targets, diseases, and drugs from the Open Targets Platform GraphQL API. Returns flattened rows with evidence, tractability, and known drug associations.

- **URL**: https://apify.com/parseforge/open-targets-platform-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** Education, Business, Other
- **Stats:** 2 total users, 1 monthly users, 89.7% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $3.75 / 1,000 result items

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?

Actors are web data automations that power AI and operations. They run on the Apify platform to scrape websites, process data, connect APIs, and automate workflows.
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.
Actors are written with capital "A".

## 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.
The best way to integrate Actors is as follows.

- **AI agents and MCP clients** — the [Apify MCP server](https://docs.apify.com/integrations/mcp.md) at `https://mcp.apify.com` (remote, streamable HTTP, OAuth on first use).
- **Agentic workflows and local Actor development** — [Agent Skills](https://apify.com/.well-known/agent-skills/index.json) with the [Apify CLI](https://docs.apify.com/cli/docs.md): `npm install -g apify-cli`, then `apify login`.
- **JavaScript/TypeScript projects** — the official [JS/TS client](https://docs.apify.com/api/client/js/docs.md): `npm install apify-client`.
- **Python projects** — the official [Python client](https://docs.apify.com/api/client/python/docs.md): `pip install apify-client`.
- **Any other language** — the [REST API](https://docs.apify.com/api/v2.md).

For usage examples, see the [API](#api) section below.

For more details, see Apify documentation as [Markdown index](https://docs.apify.com/llms.txt) and [Markdown full-text](https://docs.apify.com/llms-full.txt).

# README

[![ParseForge](https://raw.githubusercontent.com/ParseForge/apify-assets/main/banner.jpg)](https://apify.com/parseforge?fpr=vmoqkp)

### Open Targets Platform Scraper

**Scrape drug targets, diseases, and drug data from the Open Targets Platform, up to a million records per run.** Every entity comes with its associated evidence, known drugs, tractability scores, and safety information. Export to CSV, JSON, Excel, or XML.

The Open Targets Platform integrates public datasets to help researchers identify and prioritize drug targets. Manually searching for targets, diseases, or drugs and compiling their associated data is slow and error-prone. This scraper reads the public GraphQL API directly, letting you pull structured records for any target, disease, or drug by search term or known ID, filtered to exactly what you need.

| Who uses it | What they scrape Open Targets Platform for |
|---|---|
| Bioinformaticians | Pulling target-disease association data for computational drug repurposing pipelines. |
| Drug discovery researchers | Compiling tractability and safety profiles for a list of gene targets of interest. |
| Pharma competitive intelligence analysts | Monitoring known drugs and mechanisms of action associated with a disease area. |
| Academic research groups | Gathering the evidence base for a systematic review of a gene-disease relationship. |

### What it does

This Actor collects Open Targets Platform entities (targets, diseases, or drugs) by free-text search or known identifier and returns each one as a flat row.

- 🎯 **Target, disease, or drug search:** scrape by free-text query (e.g. 'BRAF', 'melanoma') or paste a list of known Ensembl, EFO, or ChEMBL IDs.
- 📊 **Structured evidence data:** each row includes associated diseases, known drugs, tractability assessments, and safety liabilities.
- 📄 **Flat-row output:** complex nested data is flattened into a consistent schema ready for analysis in pandas, R, or Excel.

Results export to CSV, JSON, Excel, or XML, or straight from the API.

### What you can do with Open Targets Platform data

**🧬 Prioritize drug targets for a disease.**

A computational biologist scrapes all targets associated with an EFO disease ID to rank them by tractability and genetic evidence scores.

**💊 Audit known drugs for a gene target.**

A portfolio manager pulls the known drugs and mechanisms of action for a list of Ensembl gene IDs to assess the competitive landscape.

**📋 Build a target-disease evidence matrix.**

A bioinformatician scrapes targets by a disease search term to create a structured dataset of association scores for a machine learning model.

**🔬 Gather safety and tractability profiles.**

A drug discovery scientist pulls safety liabilities and tractability buckets for a set of candidate targets to inform lead selection.

### Why choose this scraper

|  | What you get |
|---|---|
| **No API key or registration** | Reads the public GraphQL endpoint directly with no app setup or OAuth flow. |
| **Flattened nested data** | Complex associations are returned as simple columns, not deeply nested JSON. |
| **Bulk ID processing** | Paste a list of Ensembl, EFO, or ChEMBL IDs to pull data for hundreds of entities in one run. |

### How it compares

This Actor is purpose-built for the Open Targets Platform's structured biomedical data, while the competitors below are general-purpose scrapers for different sources.

| Feature | ParseForge | Google Maps Scraper | Web Scraper |
|---|---|---|---|
| Open Targets Platform data | Yes | Not listed | Not listed |
| Target, disease, and drug entities | Yes | Not listed | Not listed |
| Tractability and safety data | Yes | Not listed | Not listed |
| Search by Ensembl, EFO, or ChEMBL ID | Yes | Not listed | Not listed |
| No API key required | Yes | Not listed | Not listed |

### Configure the run

Drive the Actor from a free-text search or a list of known identifiers for your chosen entity type, and set a maximum number of results to cap the run. The Input tab lists every parameter.

A first run with the defaults:

```json
{
  "maxItems": 10,
  "entityType": "target"
}
```

A larger pull:

```json
{
  "maxItems": 200,
  "entityType": "target"
}
```

### Pricing

Pay-per-result: **$0.005 per result** collected. You pay only for the results written to your dataset.

| Results collected | Approximate cost |
|---|---|
| 100 results | $0.50 |
| 1,000 results | $5.00 |
| 10,000 results | $50.00 |

New Apify accounts start with $5 in free credit.

### Free users

Free-plan runs return up to 10 results as a preview. [Upgrade your Apify plan](https://console.apify.com/sign-up?fpr=vmoqkp) to collect up to 1,000,000 results per run.

### Run it

1. [Create a free Apify account with $5 in credit](https://console.apify.com/sign-up?fpr=vmoqkp).
2. Open the [Open Targets Platform Scraper](https://apify.com/parseforge/open-targets-platform-scraper?fpr=vmoqkp).
3. Set your inputs and any filters, then click **Start**.
4. Export the results as CSV, Excel, JSON, or XML from the **Dataset** tab.

Run it programmatically through the [Apify API](https://docs.apify.com/api/v2) (`run-sync-get-dataset-items`) or the [ApifyClient](https://docs.apify.com/api/client/js) for JavaScript and Python.

### Use with AI agents (MCP)

Give an AI agent live access to Open Targets Platform through the Model Context Protocol. Add the Actor to Claude, Cursor, or any MCP client:

```bash
claude mcp add --transport http apify "https://mcp.apify.com/?tools=parseforge/open-targets-platform-scraper"
```

Then prompt it in plain language to run the scraper and read back the results.

### Troubleshooting

**Why am I getting no results for my search?**

Check that your search term matches the selected entity type. A gene symbol will not return results if the entity type is set to 'Disease'. Try the exact recommended ID format (e.g. ENSG..., EFO\_..., CHEMBL...).

**The run finished but my dataset is empty.**

Verify that you provided either a search query or a list of IDs. If both are empty, the Actor has no input to process. Also confirm the maxItems is set to a number greater than zero.

**I pasted a list of IDs but only got one result.**

Ensure each ID is on its own line in the string list input field. A comma-separated list on one line will be treated as a single, invalid ID.

**The output has too many columns and is hard to read.**

The Actor flattens nested API responses into a wide row. Use the 'Fields' tab in the Apify dataset viewer to hide columns you do not need, or load the CSV into pandas and select your columns of interest.

**I got a timeout error on a large run.**

The public GraphQL API can be slow for very complex queries. Try reducing maxItems and running multiple smaller batches, or increase the Actor's timeout setting in the run options.

### FAQ

| Question | Answer |
|---|---|
| Do I need an API key to scrape Open Targets? | No. This Actor reads the public Open Targets Platform GraphQL API directly. No registration, API key, or OAuth flow is required. |
| What entity types can I scrape? | You can scrape targets (genes, by Ensembl ID), diseases (by EFO or MONDO ID), and drugs (by ChEMBL ID). Select the entity type in the input, then provide a search term or a list of IDs. |
| Can I search by gene name instead of an Ensembl ID? | Yes. Use the free-text search field with a gene symbol like 'BRAF' or 'TP53'. The scraper will resolve the search and return matching target records. |
| What data comes back for a target? | Each target row includes associated diseases, known drugs, tractability assessments, safety liabilities, and genetic evidence scores, all flattened into a single record. |
| How do I scrape multiple specific targets at once? | Set the entity type to 'Target' and paste your list of Ensembl IDs into the Target IDs field. The Actor will fetch each one in sequence. |
| Can I scrape all targets for a disease? | Yes. Set the entity type to 'Target' and use the disease name or EFO ID as your search query. The results will include all targets associated with that disease. |
| What output formats are supported? | You can export your dataset to CSV, JSON, Excel, or XML from the Apify dataset tab. |
| Is there a rate limit? | The Actor respects the public API's response times. For very large pulls, increase the maxItems and the run will process them sequentially. |
| Can I scrape drug information? | Yes. Set the entity type to 'Drug' and search by drug name (e.g. 'pembrolizumab') or provide a list of ChEMBL IDs. |
| What is a tractability assessment? | Open Targets provides tractability buckets (e.g. small molecule, antibody) predicting how druggable a target is. This data is included in the output for each target. |

### Related actors

Browse the full [ParseForge collection](https://apify.com/parseforge?fpr=vmoqkp) for more scrapers.

🆘 **Need help?** Email parseforge@protonmail.com with your run ID, your input, and what you expected.

⚠️ **Disclaimer.** This Actor is unofficial and is not affiliated with, endorsed by, or sponsored by Open Targets. It collects only publicly available data. You are responsible for using the collected data in compliance with the source's terms of service and applicable data-protection laws, including GDPR, CCPA, and PIPL. Do not use it to collect personal data unlawfully.

# Actor input Schema

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

How many results to collect per run.

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

Which Open Targets entity to scrape.

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

Free-text search across the selected entity type. Examples: 'BRAF', 'melanoma', 'pembrolizumab'.

## `targetIds` (type: `array`):

Ensembl gene IDs (e.g. ENSG00000157764). Used when entityType is 'target'.

## `diseaseIds` (type: `array`):

EFO or MONDO identifiers (e.g. EFO\_0000756). Used when entityType is 'disease'.

## `drugIds` (type: `array`):

ChEMBL drug identifiers (e.g. CHEMBL1201585). Used when entityType is 'drug'.

## Actor input object example

```json
{
  "maxItems": 10,
  "entityType": "target"
}
```

# Actor output Schema

## `overview` (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 = {
    "maxItems": 10,
    "entityType": "target"
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/open-targets-platform-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 = {
    "maxItems": 10,
    "entityType": "target",
}

# Run the Actor and wait for it to finish
run = client.actor("parseforge/open-targets-platform-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 '{
  "maxItems": 10,
  "entityType": "target"
}' |
apify call parseforge/open-targets-platform-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parseforge/open-targets-platform-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/JF5JHBylhvZs4jiT6/builds/TGl51xlIbfUMfgK7q/openapi.json
