# Kalshi Polymarket Arb Radar (`jovian_zabra_nk5/kalshi-polymarket-arb-radar`) Actor

Cross-venue arbitrage scanner for Kalshi and Polymarket: fuzzy-matched binary markets with fee-inclusive bid/ask edges and risk flags, or watchlist mode for user-supplied exact pairs. No login, no proxies. Agent/MCP-friendly JSON.

- **URL**: https://apify.com/jovian_zabra_nk5/kalshi-polymarket-arb-radar.md
- **Developed by:** [dev bro](https://apify.com/jovian_zabra_nk5) (community)
- **Categories:** Developer tools, AI, Agents
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.00 / 1,000 arb pair reports

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

## Prediction Market Arbitrage Radar (Kalshi ↔ Polymarket)

Scan **Kalshi** and **Polymarket** simultaneously and report cross-venue matched pairs with an
**actionable, fee-inclusive edge** — or feed it your own known pairs via `manualPairs` and let it
price them for you every run.

### What you get

One dataset record per matched pair:

- **`edgeCents`** — riskless lock-in edge in cents after Kalshi taker fees
  (0.07 × P × (1−P) per side). Polymarket charges no taker fee, so it is not added.
- **`strategy`** — which legs to buy: `PM-YES/K-NO` (Polymarket YES + Kalshi NO) or
  `K-YES/PM-NO` (Kalshi YES + Polymarket NO), computed from live **asks**, not last prices.
- Full quotes on both sides: yes bid/ask, Kalshi no-ask, spreads, 24h volumes, end times, URLs.
- **`similarity`** + **`matchMethod`** (`fuzzy`, `h2h`, `manual`) so you can judge match quality.
- **`riskFlags`** — honest warnings: `end-date-gap-Nd` (resolution dates differ), `wide-*-spread`,
  `predicate-mismatch`-style guards already exclude false pairs upstream.

### Two modes

1. **`scan`** (default) — fuzzy-matches open binary markets across venues with strict guards
   (predicate signature, year consistency, exact team-token match for head-to-head markets).
   Filter with `minEdgeCents`, `minSimilarity`, `minVolume24hUsd`.
2. **`watchlist`** — supply exact `[{"kalshiTicker":"KX...","polymarketSlug":"will-..."}]` pairs;
   the Actor re-prices them every run. This is the reliable way to monitor markets you already
   know are the same event.

### Why a radar, not a geyser

True cross-venue edges are **transient** — they appear when news hits one venue first and close
within minutes. Today's scan may return one +0.4c pair or none; the value is running this on a
schedule (or after news) and catching the moment. Zero-result runs are honest runs, and cost you
only the run price. If you need guaranteed hits, use `watchlist` with pairs you track yourself.

### Fees & assumptions

- Kalshi fee model: 0.07 × P × (1−P) per contract, applied to each Kalshi leg. Polymarket: 0.
- Edges use displayed asks; real fill depends on book depth at execution time.
- End-date gaps > 7 days are flagged: same question, different resolution dates ⇒ not a true arb.

### Use cases

- Automated news-driven edge alerts (schedule the Actor hourly/daily).
- Monitoring your own Kalshi↔Polymarket pair book via `watchlist`.
- Research datasets of cross-venue spreads over time.

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `mode` | string | `scan` | `scan` or `watchlist` |
| `minEdgeCents` | number | `0` | Report threshold (fee-inclusive edge in cents) |
| `minSimilarity` | number | `0.55` | Fuzzy match threshold in scan mode |
| `minVolume24hUsd` | number | `200` | Liquidity filter per venue |
| `maxKalshiEvents` | integer | `1500` | Kalshi events to paginate |
| `maxPolymarketMarkets` | integer | `300` | PM pool size (top by 24h volume) |
| `maxResults` | integer | `100` | Cap on pair reports |
| `manualPairs` | array | `[]` | Exact pairs for watchlist mode |

### Output

Dataset of pair reports, sorted by edge descending. See the Overview table view in the Console,
or consume the JSON directly (`edgeCents`, `strategy`, quotes, `riskFlags`, URLs). MCP/agent-ready:
machine-readable fields, no scraping artifacts.

### Sources

Official public endpoints only: `trade-api/v2` (Kalshi), `gamma-api.polymarket.com`. No login,
no cookies, no proxies, no browser.

# Actor input Schema

## `mode` (type: `string`):

scan = fuzzy cross-venue matching with guards, watchlist = monitor exact pairs you supply via manualPairs.

## `minEdgeCents` (type: `number`):

Only report pairs whose fee-inclusive edge is at least this many cents. 0 reports everything matched.

## `minSimilarity` (type: `number`):

Threshold (0-1) for fuzzy question matching in scan mode. Higher = fewer false matches, fewer results.

## `minVolume24hUsd` (type: `number`):

Skip markets below this 24h volume on either venue (liquidity filter).

## `maxKalshiEvents` (type: `integer`):

How many open Kalshi events (with nested markets) to paginate before matching.

## `maxPolymarketMarkets` (type: `integer`):

Top Polymarket markets by 24h volume to include in the scan pool.

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

Cap on output pair reports (each is one billable result).

## `manualPairs` (type: `array`):

Exact pairs to monitor: \[{"kalshiTicker": "KX...", "polymarketSlug": "will-..."}]. Ignored in scan mode.

## Actor input object example

```json
{
  "mode": "scan",
  "minEdgeCents": 0,
  "minSimilarity": 0.55,
  "minVolume24hUsd": 200,
  "maxKalshiEvents": 1500,
  "maxPolymarketMarkets": 300,
  "maxResults": 100,
  "manualPairs": []
}
```

# Actor output Schema

## `pairs` (type: `string`):

Matched Kalshi/Polymarket pairs sorted by edge, with actionable strategy, fees included, and risk flags for end-date gaps and wide spreads.

# 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 = {
    "mode": "scan",
    "minEdgeCents": 0,
    "minSimilarity": 0.55,
    "minVolume24hUsd": 200,
    "maxKalshiEvents": 1500,
    "maxPolymarketMarkets": 300,
    "maxResults": 100,
    "manualPairs": []
};

// Run the Actor and wait for it to finish
const run = await client.actor("jovian_zabra_nk5/kalshi-polymarket-arb-radar").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 = {
    "mode": "scan",
    "minEdgeCents": 0,
    "minSimilarity": 0.55,
    "minVolume24hUsd": 200,
    "maxKalshiEvents": 1500,
    "maxPolymarketMarkets": 300,
    "maxResults": 100,
    "manualPairs": [],
}

# Run the Actor and wait for it to finish
run = client.actor("jovian_zabra_nk5/kalshi-polymarket-arb-radar").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 '{
  "mode": "scan",
  "minEdgeCents": 0,
  "minSimilarity": 0.55,
  "minVolume24hUsd": 200,
  "maxKalshiEvents": 1500,
  "maxPolymarketMarkets": 300,
  "maxResults": 100,
  "manualPairs": []
}' |
apify call jovian_zabra_nk5/kalshi-polymarket-arb-radar --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,jovian_zabra_nk5/kalshi-polymarket-arb-radar"
        }
    }
}
```

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/cRcthhGZDNmiVygbe/builds/yX85LONN50IKc6RUy/openapi.json
