# Kalshi Market Monitor (`automatic/kalshi-market-monitor`) Actor

Monitor live Kalshi prediction markets in one run: yes/no prices, bid-ask spreads, volume, liquidity and open interest, plus close dates and market status. Filter by status, series or event prefix and a creation window. Every run returns a fresh full-board snapshot; no account is needed.

- **URL**: https://apify.com/automatic/kalshi-market-monitor.md
- **Developed by:** [Philip Kirkbride](https://apify.com/automatic) (community)
- **Features:** Limited permissions
- **Stats:** 1 total users, 0 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.40 / 1,000 market records

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

## Kalshi Market Monitor

Collect live Kalshi prediction markets in one run: yes/no bids and asks, last
price, an indicative probability, volume, 24-hour volume, liquidity, open
interest, open and close times and market status, one record per market.
Filter by status, series (for example `KXBTCD`, the Bitcoin price ladder) or
event prefix. Built for traders, analysts and bot builders who schedule runs
and pipe the JSON into dashboards, alerts or models. No Kalshi account or API
key is needed.

Data only, not financial advice.

### Use cases

- **Market boards:** a fresh snapshot of one market family (crypto ladders,
  sports games, economics) for a dashboard, refreshed on a schedule.
- **Price and probability tracking:** store snapshots and chart how a
  market's midpoint and volume move toward its close.
- **Cross-venue comparison:** map Kalshi tickers to Polymarket markets with
  `crossVenueMap` and compare the two venues side by side.
- **Bots and models:** feed bids, asks and open interest into your own
  pricing or alerting logic.

### Quick start

For a clean board, pick a series. This returns the open Bitcoin price ladder:

```json
{"seriesTicker": "KXBTCD", "status": "open", "lookbackHours": 0, "maxMarkets": 200}
```

Clicking **Start** with the prefilled form (or an empty input `{}`) returns up
to 200 open markets created in the last 7 days, newest-updated first, across
all of Kalshi, each with its event title. Auto-generated multi-leg combo
markets, which make up most of Kalshi's all-markets board and see little or no
trading, are left out unless you turn on `includeCombos`.

### Input

| Name | Type | Default | What it does |
| --- | --- | --- | --- |
| `status` | string | `open` | `open`, `unopened`, `closed`, `settled`, or `all` (every status). |
| `seriesTicker` | string | empty | Exact series ticker, for example `KXBTCD` (Bitcoin) or `KXETHD` (Ethereum). |
| `eventTickerPrefix` | string | empty | Keep only markets whose event ticker starts with this prefix (case-insensitive). |
| `includeCombos` | boolean | `false` | Include multi-leg combo markets when neither `seriesTicker` nor `eventTickerPrefix` is set. Series and prefix runs return exactly the markets they name either way. |
| `lookbackHours` | integer | `168` | Keep only markets created within this many hours (0–336). `0` turns the window off. Markets without a published creation time are skipped while the window is on. |
| `pageSize` | integer | `100` | Markets requested per page (1–1,000). |
| `maxMarkets` | integer | `200` | Maximum records returned after filters (1–2,000). |
| `maxPages` | integer | `6` | Maximum pages read per run (1–30). |
| `crossVenueMap` | object | `{}` | Optional map of Kalshi market or event ticker to a Polymarket slug or condition ID (up to 500 entries). Matching rows carry a `crossVenue` object. |
| `telegramChatId` | string | empty | Chat for an optional digest (cross-venue pairs and markets at or above `alertMinUsd`). Needs a `TELEGRAM_BOT_TOKEN` secret environment variable, so it suits your own copy of the Actor. |
| `alertMinUsd` | number | `1000` | Markets with total volume at or above this USD value go into the digest; cross-venue pairs always do. |
| `requestDelaySecs` | number | `0.25` | Pause between pages (0–10 seconds). |

A misspelt input field stops the run with an error that names it.

### Output

One dataset record per market: `recordKey`, `source`, `kind`, `collectedAt`,
`sourceUrl`, `ticker`, `eventTicker`, `eventTitle`, `question`, `status`,
`active`, `closed`, `openTime`, `closeTime`, `createdTime`, `endDate` (same as
`closeTime`), `lastPrice`, `yesBid`, `yesAsk`, `noBid`, `noAsk`,
`yesProbability`, `noProbability`, `probabilitySource`, `outcomes`, `volume`,
`volume24h`, `liquidity`, `openInterest`, `crossVenue`.

- Prices are in dollars per $1 contract. `yesAsk`/`noAsk` are the displayed
  buy quotes and `yesBid`/`noBid` the displayed sell quotes.
- `yesProbability` is an indicative mark, not an executable quote: the
  midpoint of a real two-sided Yes quote (`probabilitySource:
  bid_ask_midpoint`), otherwise the last trade when the market has traded
  (`last_trade`), otherwise `null`. A never-traded market's 0/1 placeholder
  quotes are kept as displayed but never turned into a 0% or 100%
  probability. `noProbability` is `1 - yesProbability`.
- `eventTitle` is the title of the market's event (for example the game or
  the date of a price ladder) and `question` the market's own title. Titles
  are filled for the first 100 events of a run, in output order; markets
  beyond that, or whose event can't be read, have `eventTitle: null`.
- Values Kalshi doesn't publish (for example `liquidity`) are `null`, never
  guessed.

The run summary (key-value store `OUTPUT`) reports coverage counters
(including how many combo markets were left out and how many records got an
event title), the digest result and any warnings.

### Output example

A real record from a run filtered to the NBA game series (`KXNBAGAME`),
collected 2026-11-08, with `eventTitle` as Kalshi publishes it for this
event:

```json
{"recordKey":"kalshi:market:KXNBAGAME-26NOV11OKCPOR-POR","source":"kalshi","kind":"market","collectedAt":"2026-11-08T22:12:41.348692+00:00","sourceUrl":"https://kalshi.com/markets/KXNBAGAME-26NOV11OKCPOR-POR","ticker":"KXNBAGAME-26NOV11OKCPOR-POR","eventTicker":"KXNBAGAME-26NOV11OKCPOR","eventTitle":"Oklahoma City vs Portland","question":"Portland wins","status":"active","active":true,"closed":false,"openTime":"2026-11-08T03:06:34.769286Z","closeTime":"2026-11-14T03:00:00Z","createdTime":"2026-11-08T03:02:08.069006Z","endDate":"2026-11-14T03:00:00Z","lastPrice":0.53,"yesBid":0.47,"yesAsk":0.54,"noBid":0.46,"noAsk":0.53,"yesProbability":0.505,"noProbability":0.495,"probabilitySource":"bid_ask_midpoint","outcomes":[{"side":"yes","outcome":"Yes — Portland","price":0.53,"bid":0.47,"ask":0.54},{"side":"no","outcome":"No — Portland","price":null,"bid":0.46,"ask":0.53}],"volume":57.82,"volume24h":57.82,"liquidity":null,"openInterest":57.82,"crossVenue":null}
```

### Pricing

- **$0.0004 per market record** ($0.40 per 1,000 markets).
- **$0.00005 per run start.** The run-start event is charged per GB of
  memory; the default 512 MB run is one start event.

Worked cost: the default 200-market board costs about **$0.08**; the maximum
2,000-market run about **$0.80**. Runs that match no markets add no record
charge.

### Scheduling and monitoring

- Schedule a series-scoped run (for example every 15 minutes or every hour)
  and key your history on `recordKey` plus `collectedAt` to chart a market's
  prices over time.
- Use `lookbackHours` to watch for newly listed markets in a series: a short
  window on a frequent schedule returns only markets created recently.

### FAQ

**How fresh is the data?** Each run reads the live Kalshi board at run time;
nothing is cached between runs.

**How many markets can I collect?** Up to 2,000 per run (`maxMarkets`) across
up to 30 pages (`maxPages`). Raise `pageSize` to read more per page.

**Can I get settled results?** Yes: set `status` to `settled` or `closed`
together with a `seriesTicker`.

**Does it include order-book depth or trade history?** No. It returns the
displayed best bid/ask, last price and volume per market.

**Export formats?** JSON, CSV, Excel, XML or RSS from the dataset, or read it
through the Apify API in your own pipeline.

### Limits

- Public market data only; no trading, account data or fills.
- No historical price candles; build history by scheduling runs.
- The all-markets board mixes every category; filter by series or event
  prefix for a focused board.
- Event titles are filled for up to 100 events per run.

For support, contact Apify support and include the Actor run ID.

# Actor input Schema

## `status` (type: `string`):

Status filter, one of unopened | open | closed | settled. 'all' or empty includes every status.

## `seriesTicker` (type: `string`):

Exact Kalshi series ticker, for example KXBTCD (the whole Bitcoin price ladder) or KXETHD (Ethereum). Narrow a run to one market family. Empty disables.

## `eventTickerPrefix` (type: `string`):

Keep only markets whose event ticker starts with this prefix, case-insensitive. Empty disables.

## `includeCombos` (type: `boolean`):

Kalshi's all-markets board is dominated by auto-generated multi-leg combo markets with little or no trading. When neither a series ticker nor an event prefix is set, they are left out unless this is on. Series and event-prefix runs return exactly the markets they name either way.

## `lookbackHours` (type: `integer`):

Keep only markets created within this many hours (0..336; 0 disables the window). A market without a published creation time is skipped while the window is on.

## `pageSize` (type: `integer`):

Rows requested per page (1..1000).

## `maxMarkets` (type: `integer`):

Maximum market records returned after filters.

## `maxPages` (type: `integer`):

Maximum pages fetched per run.

## `crossVenueMap` (type: `object`):

Optional map of Kalshi market ticker OR event ticker -> Polymarket slug/conditionId (string -> string, up to 500 entries). Matching rows carry a crossVenue object (venue, matchedKey, polymarketId) — the join surface for the PK x Kalshi arb monitor. Both key forms are tried, market ticker first.

## `telegramChatId` (type: `string`):

Optional Telegram chat id for the digest (cross-venue pairs and markets with volume at or above alertMinUsd). Requires a Telegram bot to be configured. A failed or skipped send is a warning, never a failed run.

## `alertMinUsd` (type: `number`):

Markets with total volume at or above this USD value go into the Telegram digest (when configured); cross-venue pairs are always alerted regardless of volume.

## `requestDelaySecs` (type: `number`):

Pause between requests.

## Actor input object example

```json
{
  "status": "open",
  "seriesTicker": "",
  "eventTickerPrefix": "",
  "includeCombos": false,
  "lookbackHours": 168,
  "pageSize": 100,
  "maxMarkets": 200,
  "maxPages": 6,
  "crossVenueMap": {},
  "telegramChatId": "",
  "alertMinUsd": 1000,
  "requestDelaySecs": 0.25
}
```

# Actor output Schema

## `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 = {
    "status": "open",
    "seriesTicker": "",
    "eventTickerPrefix": "",
    "lookbackHours": 168,
    "pageSize": 100,
    "maxMarkets": 200,
    "maxPages": 6,
    "crossVenueMap": {},
    "telegramChatId": "",
    "alertMinUsd": 1000,
    "requestDelaySecs": 0.25
};

// Run the Actor and wait for it to finish
const run = await client.actor("automatic/kalshi-market-monitor").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 = {
    "status": "open",
    "seriesTicker": "",
    "eventTickerPrefix": "",
    "lookbackHours": 168,
    "pageSize": 100,
    "maxMarkets": 200,
    "maxPages": 6,
    "crossVenueMap": {},
    "telegramChatId": "",
    "alertMinUsd": 1000,
    "requestDelaySecs": 0.25,
}

# Run the Actor and wait for it to finish
run = client.actor("automatic/kalshi-market-monitor").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 '{
  "status": "open",
  "seriesTicker": "",
  "eventTickerPrefix": "",
  "lookbackHours": 168,
  "pageSize": 100,
  "maxMarkets": 200,
  "maxPages": 6,
  "crossVenueMap": {},
  "telegramChatId": "",
  "alertMinUsd": 1000,
  "requestDelaySecs": 0.25
}' |
apify call automatic/kalshi-market-monitor --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,automatic/kalshi-market-monitor"
        }
    }
}
```

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/fU0h3aQA1hZs7dZ1Q/builds/I0X5j7kF5FY4jFwYM/openapi.json
