# IP Risk Checker – Tor Exit, Datacenter & Cloud IP Detection (`gazidev/ip-risk-checker`) Actor

Screen thousands of IPv4/IPv6 addresses for fraud and abuse signals: Tor exit node or relay, datacenter/cloud/hosting network (AWS, Google, Azure, Hetzner, OVH...), bogon/private, ASN and AS name, plus a 0-100 risk score with reasons. $0.30 per 1,000 IPs.

- **URL**: https://apify.com/gazidev/ip-risk-checker.md
- **Developed by:** [Cemal Atakli](https://apify.com/gazidev) (community)
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.30 / 1,000 ip checkeds

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

## IP Risk Checker – Tor Exit Node, Datacenter & Cloud IP Detection in Bulk

Screen **thousands of IPv4 and IPv6 addresses in one run** for the most common fraud and abuse signals and get one row per IP:

- **Tor exit node** (and Tor relay), from the official Tor Metrics exit list and relay list, refreshed every run
- **Datacenter / cloud / hosting / CDN network**: AWS, Google Cloud, Microsoft Azure, Oracle Cloud, DigitalOcean, Linode, Vultr, Hetzner, OVHcloud, Scaleway, Contabo, Leaseweb, Alibaba, Tencent, Cloudflare, Akamai, Fastly and about 40 more, plus a heuristic for other hosting companies
- **Bogon / private / reserved** addresses (private, loopback, CGNAT, documentation, multicast...)
- **ASN and AS organisation**
- a simple **risk score from 0 to 100**, a risk level and plain-English **reasons**

You don't need an API key. **$0.30 per 1,000 IPs.** Invalid, duplicate and bogon/private addresses are free.

### What you can use it for

- **Sign-up and checkout fraud screening**: real customers rarely browse from AWS, Hetzner or a Tor exit. Flag those sign-ups for review or extra verification.
- **Ad-click and affiliate fraud**: find clicks and installs coming from datacenter networks and Tor.
- **Log triage**: paste nginx, Apache, SSH or firewall logs and see at once which IPs are Tor exits or cloud servers (bots, scanners, scrapers).
- **Allow/deny lists**: decide which networks to rate-limit, challenge or block.
- **Data cleaning**: separate public addresses from private, CGNAT and other non-routable ones before further processing.
- **Chaining**: feed IPs from another Actor's dataset, for example a log parser or our Bulk DNS Lookup.

### How this differs from our other IP listings

| Actor | What it gives you |
|---|---|
| **IP Risk Checker** (this one) | Risk flags only: Tor exit/relay, datacenter/cloud/hosting/CDN, bogon, ASN, risk score. Fast and cheap for screening. |
| [Bulk IP Lookup](https://apify.com/gazidev/bulk-ip-lookup) | Geolocation (country, city, lat/lon), ASN/ISP, reverse DNS and RDAP network owner + abuse e-mail. It has **no** Tor or hosting flags. |
| [Email Blacklist Checker](https://apify.com/gazidev/email-blacklist-checker) | DNSBL/RBL blacklist status of mail servers and IPs. |
| [Bulk DNS Lookup](https://apify.com/gazidev/bulk-dns-lookup) | A, AAAA, MX, TXT and other DNS records for domains. |

Use this Actor to screen, then Bulk IP Lookup for location and owner details on the IPs you care about.

### What it does not do (please read)

- **It is not a VPN or residential-proxy detector.** Commercial VPNs and residential proxy networks are not identified unless they run on a datacenter network we flag. No free, commercially licensed VPN list exists, so we don't pretend to have one.
- **Datacenter detection is by ASN (network owner)**, not by each provider's published range file. The result says which provider owns the network (`cloudProvider`), not the cloud region or service.
- `isDatacenter` for Google (AS15169) and Cloudflare also covers their public services such as 8.8.8.8 and 1.1.1.1, and Cloudflare/Akamai/Fastly are tagged `cdn` with a lower score because their addresses are often proxies or WARP/Private Relay egress.
- No blacklist/spam reputation. For that, use our Email Blacklist Checker.
- The risk score is a simple, transparent rule (see below), not a machine-learning fraud score. Use it as a signal, not as a verdict.

### Input

| Field | What it does |
|---|---|
| `ips` | List of IPv4/IPv6 addresses. `1.2.3.4:443` and `[2001:db8::1]:443` work (the port is ignored). |
| `text` | Paste anything (CSV, access logs, firewall exports). Every IP address found in it is checked. |
| `datasetId` + `datasetField` | Read IPs from an Apify dataset (picker). The field can be a dot path (`client.ip`) or a list of IPs. |
| `includeAsn` | ASN lookup + datacenter/cloud detection (default on). Off = Tor and bogon checks only. |
| `includeInvalid` | Free error rows for values that are not IPs (default on). |
| `maxIps` | Cap on unique public IPs checked (default 100,000; 0 = no limit). |

```json
{
  "ips": ["3.5.140.2", "34.35.0.10", "1.1.1.1", "8.8.8.8", "185.220.101.33", "192.168.1.10"]
}
```

Logs pasted as text:

```json
{
  "text": "Nov 21 10:00:01 sshd[1]: Failed password for root from 185.220.101.170 port 4242\n5.9.0.1 - - [21/Nov/2026:10:00:02 +0000] \"GET /wp-login.php HTTP/1.1\" 404"
}
```

### Output

One row per unique IP:

```json
{
  "input": "185.220.101.33",
  "ip": "185.220.101.33",
  "version": 4,
  "ipType": "public",
  "isPublic": true,
  "isBogon": false,
  "isPrivate": false,
  "isTorExit": true,
  "isTorRelay": true,
  "isDatacenter": false,
  "isHostingAsn": false,
  "cloudProvider": null,
  "hostingCategory": null,
  "hostingMatch": null,
  "asn": 60729,
  "asOrganization": "Stiftung Erneuerbare Freiheit",
  "asNetwork": "185.220.101.0/24",
  "riskScore": 75,
  "riskLevel": "very high",
  "reasons": ["Tor exit node (traffic from this IP is anonymised)"],
  "listsUpdatedAt": {"torExitList": "2026-11-21-11-10-12", "torRelays": "2026-11-21 10:00:00", "dbipAsn": "2026-11"},
  "sources": "Tor exit list & relays: Tor Metrics (CollecTor, Onionoo), CC0 1.0 | ASN: IP to ASN Lite by DB-IP (https://db-ip.com), CC BY 4.0 | hosting ASN list & risk score: ip-risk-checker",
  "checkedAt": "2026-11-21T12:10:13+00:00"
}
```

A cloud IP looks like this (shortened): `"ip": "3.5.140.2", "isDatacenter": true, "cloudProvider": "AWS", "hostingCategory": "cloud", "hostingMatch": "curated-asn", "asn": 16509, "riskScore": 50, "riskLevel": "high"`.

- `hostingCategory`: `cloud`, `hosting` or `cdn`.
- `hostingMatch`: `curated-asn` (the AS is on our list of about 75 cloud/hosting/CDN networks) or `as-name-keyword` (the AS name contains words like "hosting", "datacenter", "server", "VPS" or "cloud"; less certain, `cloudProvider` stays empty).
- Bogon/private/reserved addresses get a free row with `isBogon: true`, `ipType` (`private`, `loopback`, `link-local`, `multicast`, `shared (CGNAT)`, `documentation/benchmark`, `reserved`) and `riskLevel: "not routable"`.
- Invalid values get a free row with `error`.

The run summary (counts, list timestamps, source errors, duration) is saved as `OUTPUT` in the default key-value store. Export to CSV, Excel or JSON from the Output tab.

#### Risk score

| Signal | Points |
|---|---|
| Tor exit node | +75 |
| Tor relay that is not an exit | +25 |
| Cloud or hosting network (curated list) | +50 |
| CDN/edge network (Cloudflare, Akamai, Fastly) | +30 |
| AS name looks like a hosting company | +35 |

The total is capped at 100. Level: `low` < 20, `medium` 20-49, `high` 50-74, `very high` ≥ 75. A home or mobile ISP address with no Tor signal scores 0.

### Pricing (pay per event)

| Event | Price | Charged when |
|---|---|---|
| `ip-checked` | $0.0003 ($0.30 / 1,000) | A public IP was checked and saved |
| Actor start | $0.00005 | Once per run |

Invalid values, duplicates and bogon/private addresses are free. If a data source can't be downloaded, the affected rows are marked `incomplete: true` and are **not charged**. If no source can be loaded, the run fails with nothing charged. If you set a maximum charge for the run, the Actor stops cleanly when it is reached (`stoppedAtMaxCharge` in `OUTPUT`).

How it compares with similar Store Actors (prices as listed on 21 November 2026):

| Actor | Price per 1,000 IPs |
|---|---|
| **This Actor** | **$0.30** |
| scrapemint (IP lookup with flags) | $1.00 |
| yadroo/ip-intel | $3.00 + $0.005 per run |
| kawsar/vpn-datacenter-ip-detector | $4.00 |

### Speed

All checks are in-memory lookups after the lists are downloaded. The 6-IP default input takes about 3-5 seconds. Each run downloads the current Tor exit list (about 0.5 MB) and relay list (about 1.4 MB). The DB-IP ASN database (about 5 MB) is downloaded once a month and cached in your account's key-value store `ip-risk-checker-cache`.

### Data sources and licences

- **Tor exit list and relay list**: [Tor Metrics](https://metrics.torproject.org/) (CollecTor exit lists and Onionoo). Tor Metrics data is released under **CC0 1.0** (no copyright).
- **ASN and AS organisation**: [IP to ASN Lite by DB-IP](https://db-ip.com), **CC BY 4.0**. Attribution: *IP Geolocation by DB-IP* (also in every row's `sources` field).
- **Datacenter/cloud ASN list and the risk score**: our own compilation of public AS numbers, checked against the DB-IP AS names.
- **Bogon/private/reserved**: Python's `ipaddress` module (IANA special-purpose address registries).

We deliberately do not use third-party data whose terms forbid use in a paid product.

### FAQ

**Does it detect VPNs?** Only VPN servers hosted in a datacenter network we flag (most commercial VPNs rent servers from hosters like M247, Leaseweb or Datacamp, so many are caught as `hosting`). It can't recognise residential proxies.

**How fresh is the Tor data?** The exit list is the latest hourly CollecTor file, and the relay list is the latest Onionoo snapshot, both downloaded at the start of every run. `listsUpdatedAt` shows the timestamps.

**Does it check IPv6?** Yes. IPv6 Tor relays and exits (relays with the Exit flag) and IPv6 ASN data are covered.

**Do you contact the IPs?** No. Nothing is sent to the addresses you check. All lookups are local.

**Can I check CIDR ranges?** No. Enter single addresses.

### Use with AI agents (Apify MCP)

This Actor works as a tool in the [Apify MCP server](https://mcp.apify.com/). An AI agent can call it with a list of IPs and get structured risk flags back, for example: "check these 200 sign-up IPs and list the ones from Tor or cloud providers". The flat JSON output with `riskScore` and `reasons` is easy for agents to filter and explain.

# Actor input Schema

## `ips` (type: `array`):

IPv4 and/or IPv6 addresses, one per line. `1.2.3.4:443` and `[2001:db8::1]:443` are accepted (the port is ignored). CIDR ranges are not expanded.

## `text` (type: `string`):

Every IP address found in the text is checked (other words are ignored). Handy for access logs, sign-up exports and ad-click logs.

## `datasetId` (type: `string`):

Optional: a dataset (e.g. the output of another Actor run) that contains IP addresses.

## `datasetField` (type: `string`):

Field name in that dataset (dot path like `client.ip` works; a list of IPs in one field also works).

## `includeAsn` (type: `boolean`):

Look up the ASN and AS organisation (DB-IP Lite) and flag datacenter, cloud, hosting and CDN networks. Turn off for a Tor-only check (same price).

## `includeInvalid` (type: `boolean`):

Adds a free row with an error for every value in *IP addresses* / the dataset that is not a valid IP.

## `maxIps` (type: `integer`):

Stop after this many unique public IPs (0 = no limit). Bogon/private, duplicate and invalid entries are free and not counted.

## Actor input object example

```json
{
  "ips": [
    "3.5.140.2",
    "34.35.0.10",
    "1.1.1.1",
    "8.8.8.8",
    "185.220.101.33",
    "192.168.1.10"
  ],
  "datasetField": "ip",
  "includeAsn": true,
  "includeInvalid": true,
  "maxIps": 100000
}
```

# Actor output Schema

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

No description

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

No description

## `summary` (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 = {
    "ips": [
        "3.5.140.2",
        "34.35.0.10",
        "1.1.1.1",
        "8.8.8.8",
        "185.220.101.33",
        "192.168.1.10"
    ]
};

// Run the Actor and wait for it to finish
const run = await client.actor("gazidev/ip-risk-checker").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 = { "ips": [
        "3.5.140.2",
        "34.35.0.10",
        "1.1.1.1",
        "8.8.8.8",
        "185.220.101.33",
        "192.168.1.10",
    ] }

# Run the Actor and wait for it to finish
run = client.actor("gazidev/ip-risk-checker").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 '{
  "ips": [
    "3.5.140.2",
    "34.35.0.10",
    "1.1.1.1",
    "8.8.8.8",
    "185.220.101.33",
    "192.168.1.10"
  ]
}' |
apify call gazidev/ip-risk-checker --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,gazidev/ip-risk-checker"
        }
    }
}
```

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/TSJqhL8h7xKIgBMnL/builds/t5NMBCfpMhRWzda5q/openapi.json
