# OpenSanctions Entities Scraper (`parseforge/opensanctions-entities-scraper`) Actor

Streams public OpenSanctions entities for AML/KYC screening. Filter sanctions, PEPs, companies, vessels, and watchlists by dataset, topic, schema, country, or name.

- **URL**: https://apify.com/parseforge/opensanctions-entities-scraper.md
- **Developed by:** [ParseForge](https://apify.com/parseforge) (community)
- **Categories:** Business, Automation, Other
- **Stats:** 5 total users, 2 monthly users, 100.0% runs succeeded, 1 bookmarks
- **User rating**: No ratings yet

## Pricing

from $22.50 / 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.
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)

### OpenSanctions Entities Scraper

**Stream sanctioned entities, PEPs, and persons of interest from OpenSanctions, filtered by list, country, or risk topic.** Each record returns the canonical name, aliases, addresses, and identifiers in a flat, machine-readable row. Export to CSV, JSON, Excel, or XML.

OpenSanctions consolidates global sanctions lists, PEP registries, and wanted databases into one open dataset. This Actor reads that public data directly, letting you pull targeted entities without building your own ETL pipeline. Filter by source list, entity type, country, or risk topic, and get a clean, deduplicated record for each match.

| Who uses it | What they scrape OpenSanctions for |
|---|---|
| Compliance officers | Build a local watchlist of sanctioned individuals and entities for a specific jurisdiction. |
| Financial crime investigators | Pull the latest PEPs and their close associates for enhanced due diligence. |
| Supply chain risk managers | Check for debarred suppliers and companies linked to forced labor or trafficking. |
| OSINT researchers | Collect all entities linked to a specific oligarch or intelligence officer network. |

### What it does

This Actor collects entities from the OpenSanctions API and returns each one as a flat row with its name, aliases, identifiers, and risk topics.

- 📋 **Source list filter:** Restrict results to a single authority, such as the US OFAC SDN List, the EU Financial Sanctions File, or the INTERPOL Red Notices.
- 🏷️ **Risk topic filter:** Pull only entities flagged for sanctions, PEP roles, terrorism, cybercrime, trafficking, or frozen assets.
- 🌐 **Country filter:** Limit the dataset to entities tied to a specific country using its ISO 3166-1 alpha-2 code.
- 🔍 **Name search:** Find a specific person or organization by canonical name or alias, using a case-insensitive substring or a fuzzy match that ignores diacritics and punctuation.
- 📊 **Compact output:** Cap the number of aliases per entity to keep payloads small, as some records carry hundreds of transliteration variants.

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

### What you can do with OpenSanctions data

**🛡️ Sanctions screening list generation.**

A compliance team runs the Actor weekly with the 'sanctions' dataset and a country filter for 'ru' to update their internal screening tool with the latest Russian sanctions targets.

**👤 PEP and RCA identification.**

A financial crime analyst pulls all entities with the 'role.pep' and 'role.rca' topics to identify politically exposed persons and their close associates during client onboarding.

**🚢 Maritime and aviation asset tracing.**

An investigator filters by the 'Vessel' or 'Airplane' schema to collect sanctioned transport assets and their registered owners for a network analysis.

**🏢 Debarment and exclusion checks.**

A procurement officer extracts entities from the 'debarment' dataset to verify that a new vendor is not on the World Bank or US SAM exclusion lists.

### Why choose this scraper

| | What you get |
|---|---|
| **No API key or registration** | Reads the public OpenSanctions bulk data, so you skip the official API's rate limits and authentication. |
| **Fixed, flat schema** | Every entity, whether a person, vessel, or company, lands in your dataset with the same predictable columns. |
| **Targeted extraction** | Pull only the entities you need by combining source list, topic, country, and name filters in a single run. |

### How it compares

This Actor focuses on targeted extraction from the core OpenSanctions API, while the alternative combines OpenSanctions with other registries and adds a screening mode.

| Feature | ParseForge | PEP Screening - OpenSanctions + Wikidata + National Registries |
|---|---|---|
| Direct OpenSanctions API extraction | Yes | Yes |
| Filter by specific source list (e.g., US OFAC SDN) | Yes | Not listed |
| Filter by risk topic (e.g., cybercrime, trafficking) | Yes | Not listed |
| Fuzzy name matching against aliases | Yes | Yes |
| Combined Wikidata and national registry data | No | Yes |
| Built-in batch screening mode | No | Yes |

### Configure the run

Drive the Actor from a dataset collection, a specific source list, a country code, a risk topic, and a name query, alone or together, and filters run as each entity is read so only matches reach your dataset. The Input tab lists every parameter.

A first run with the defaults:

```json
{
 "maxItems": 10
}
```

A larger pull:

```json
{
 "maxItems": 200
}
```

### Pricing

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

| Results collected | Approximate cost |
|---|---|
| 100 results | $3.00 |
| 1,000 results | $30.00 |
| 10,000 results | $300.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 [OpenSanctions Entities Scraper](https://apify.com/parseforge/opensanctions-entities-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 OpenSanctions 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/opensanctions-entities-scraper"
```

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

### Troubleshooting

**Why am I getting no results?**

Check that your filters are not too restrictive. A specific name query combined with a narrow topic and a single source list might return zero matches. Try broadening one filter at a time.

**The run is taking a long time.**

Pulling the full 'default' collection with a high maxItems value can take a while. Use a more specific dataset collection or a lower entity limit to speed up the run.

**I am missing aliases for some entities.**

Check the 'Max Aliases per Entity' setting. If it is set too low, the Actor truncates the aliases array. Increase the cap to capture more name variants.

**The country filter is not working as expected.**

Ensure you are using the correct lowercase ISO 3166-1 alpha-2 code. For example, use 'gb' for the United Kingdom, not 'uk'.

### FAQ

| Question | Answer |
|---|---|
| What is the difference between the 'sanctions' and 'default' dataset collections? | The 'sanctions' collection is a consolidated list of all global sanctions. The 'default' collection is the full union of all datasets, including sanctions, PEPs, crime, and debarment lists. |
| How does the fuzzy name match work? | The fuzzy match strips diacritics, punctuation, and standardizes casing before comparing the query to the entity's canonical name and all aliases. It catches transliteration variants and minor spelling differences. |
| Can I pull entities from only one specific sanctions list, like the US OFAC SDN? | Yes. Use the 'Specific Source List' filter and select 'US OFAC SDN List' to restrict the output to entities from that single authority. |
| Does this Actor include relatives and close associates of sanctioned persons? | Yes. When you select the 'Linked to sanctioned entity' or 'Relative or Close Associate (RCA)' topic, the Actor returns entities that OpenSanctions has flagged with those relationships. |
| What entity types can I filter by? | You can filter by Person, Organization, Company, Legal Entity, Vessel, Airplane, Position, or Crypto Wallet. Leave the filter empty to get all types. |
| How do I filter by country? | Enter the lowercase two-letter ISO 3166-1 alpha-2 code, such as 'ir' for Iran or 'kp' for North Korea, in the Country field. |
| Is the data updated live? | The Actor reads from the public OpenSanctions API, which is refreshed daily from its upstream sources. Each run pulls the latest available data. |
| Can I search for a specific person by name? | Yes. Enter a name in the 'Entity name' field and choose a substring or fuzzy match mode to find a specific individual or organization across all aliases. |
| What is the maximum number of entities I can collect in one run? | You can set the 'Maximum entities' input up to 1,000,000 per run. |
| Why would I cap the number of aliases per entity? | Some entities, particularly sanctioned individuals, have hundreds of transliteration variants. Capping aliases keeps each row compact and your dataset easier to process. |

### 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 OpenSanctions.org. 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

## `dataset` (type: `string`):

Which OpenSanctions collection to pull from. 'sanctions' is the consolidated global sanctions list; 'peps' covers politically-exposed persons; 'crime' covers wanted lists; 'default' is the full union of all collections.

## `schema` (type: `string`):

Restrict to a single entity type. Leave empty to include all types.

## `country` (type: `string`):

Filter to entities tied to a specific country (lowercase 2-letter code, e.g. 'ru', 'ir', 'kp', 'us'). Leave empty for all countries.

## `topic` (type: `string`):

Restrict to entities flagged with a specific risk topic. Leave empty for all topics.

## `nameQuery` (type: `string`):

Match on the canonical name or any alias. Substring match is case-insensitive; fuzzy match also strips diacritics, punctuation and casing variations. Leave empty to skip name filtering.

## `nameMatchMode` (type: `string`):

How to match the Name Filter against entity names and aliases.

## `datasetSource` (type: `string`):

Restrict to a single underlying source list. Leave empty for all sources within the chosen collection.

## `maxAliases` (type: `integer`):

Cap the aliases array per record to keep payloads compact. Some entities have hundreds of transliteration variants.

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

How many entities to collect per run.

## Actor input object example

```json
{
  "dataset": "sanctions",
  "schema": "",
  "country": "",
  "topic": "",
  "nameQuery": "",
  "nameMatchMode": "substring",
  "datasetSource": "",
  "maxAliases": 50,
  "maxItems": 10
}
```

# Actor output Schema

## `overview` (type: `string`):

Overview of scraped data

## `fullData` (type: `string`):

Complete dataset

# 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 = {
    "country": "",
    "nameQuery": "",
    "maxItems": 10
};

// Run the Actor and wait for it to finish
const run = await client.actor("parseforge/opensanctions-entities-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 = {
    "country": "",
    "nameQuery": "",
    "maxItems": 10,
}

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

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,parseforge/opensanctions-entities-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/XRZ4e6nTOtvQGCm9a/builds/E47yCGIVWyVWw0xOw/openapi.json
