# Polymarket Market Odds & Volume Scraper (`crawlyth-forge/polymarket-market-odds-and-volume-scraper`) Actor

Pull Polymarket prediction markets by keyword, event, category or condition ID, or browse trending and recently resolved markets, with outcome prices, volume, liquidity and resolution status.

- **URL**: https://apify.com/crawlyth-forge/polymarket-market-odds-and-volume-scraper.md
- **Developed by:** [crawlyth forge](https://apify.com/crawlyth-forge) (community)
- **Categories:** Automation, Developer tools, News
- **Features:** Limited permissions
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, 0 bookmarks
- **User rating**: No ratings yet

## Pricing

from $0.49 / 1,000 results

This Actor is paid per event and usage. You are charged both the fixed price for specific events and for Apify platform usage.
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?

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

## Polymarket Market Odds & Volume Scraper

Polymarket runs crypto-settled prediction markets on everything from elections to sports to crypto prices. This actor pulls market data five different ways: keyword search, trending by volume, a named event's markets, one exact market by condition ID, or recently resolved markets.

### What this actor does

- **Keyword search** across all Polymarket markets.
- **Trending** markets ranked by trading volume.
- **Event lookup** — markets grouped under a named event (e.g. an election or tournament).
- **Exact market fetch** by Polymarket condition ID.
- **Resolved markets** — already-settled markets for outcome tracking.
- **Filters**: category, minimum total volume, active-only, and resolved-only, applied on top of whichever mode you run.
- Fields a market doesn't carry (e.g. no `volume24hr` yet on a brand-new market) are left out of the record.

### Output per market

- `conditionId`, `marketSlug`, `question`, `description`
- `resolutionSource`, `image`
- `outcomes` — e.g. `["Yes", "No"]`
- `outcomePrices` — current probability for each outcome, in the same order as `outcomes`
- `volume`, `volume24hr`, `liquidity` — all in USD
- `startDate`, `endDate`
- `active`, `closed`, `resolved` — booleans, present only when Polymarket reports them explicitly
- `category`
- `recordType` — always `market`
- `scrapedAt`

### Input

| Field | Type | Default | Description |
|---|---|---|---|
| `mode` | string | `trending` | `search`, `trending`, `byEvent`, `byConditionId`, or `resolved` |
| `query` | string | – | Keyword (mode=`search`) or event name (mode=`byEvent`) |
| `conditionId` | string | – | Exact Polymarket condition ID (mode=`byConditionId`) |
| `category` | string | `all` | `all`, `Sports`, `Politics`, `Crypto`, `Science`, `Business`, `Entertainment`, `Pop Culture`, or `Other` |
| `minVolume` | number | – | Drop markets with total volume below this amount (USD) |
| `resolvedOnly` | boolean | `false` | Keep only resolved/closed markets |
| `activeOnly` | boolean | `true` | Keep only currently open markets |
| `maxItems` | integer | `5` | Maximum markets to return (1–1000) |

#### Example: trending political markets above $1M volume

```json
{
  "mode": "trending",
  "category": "Politics",
  "minVolume": 1000000,
  "maxItems": 50
}
```

#### Example: search for crypto-price markets

```json
{
  "mode": "search",
  "query": "bitcoin",
  "activeOnly": true,
  "maxItems": 30
}
```

#### Example: recently resolved sports markets

```json
{
  "mode": "resolved",
  "category": "Sports",
  "resolvedOnly": true,
  "maxItems": 50
}
```

#### Example: a single market by condition ID

```json
{
  "mode": "byConditionId",
  "conditionId": "0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcd"
}
```

### Use cases

- **Odds tracking** — poll `outcomePrices` for a market over time to chart implied probability.
- **Volume screening** — find the highest-volume markets in a category right now.
- **Event monitoring** — pull every market tied to one named event in a single run.
- **Resolution auditing** — collect `resolved` markets to check how outcomes actually settled.
- **Market research** — compare liquidity and volume across categories to spot where trading activity concentrates.

### FAQ

**Do I need a wallet or API key to use this?**
No — all modes read Polymarket's public market data; no wallet connection or API key is involved.

**What do `outcomePrices` values mean?**
Each value is the current market-implied probability (between 0 and 1) for the outcome at the same position in the `outcomes` array.

**Why is `volume24hr` missing from some markets?**
Polymarket only reports a 24-hour volume figure once a market has recent trading activity; very new or very illiquid markets may not have one yet.

**What's the difference between `active`, `closed`, and `resolved`?**
`active` means currently open for trading. `closed` means trading has stopped. `resolved` means Polymarket has published a final outcome. A market can be closed without being resolved yet.

**Can I combine `minVolume` with `category`?**
Yes, all filters (`category`, `minVolume`, `activeOnly`, `resolvedOnly`) apply together regardless of mode.

**How do I find a `conditionId`?**
Run `search` or `trending` first and read `conditionId` off any result, then use it directly in mode=`byConditionId` for a focused re-fetch.

**Is this affiliated with Polymarket?**
No. This is an independent, third-party actor built on Polymarket's publicly accessible market data.

# Actor input Schema

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

What to fetch from Polymarket.

## `query` (type: `string`):

Keyword to search for (mode=search or mode=byEvent).

## `conditionId` (type: `string`):

Polymarket condition ID of the specific market to fetch.

## `category` (type: `string`):

Filter markets by category tag.

## `minVolume` (type: `number`):

Filter out markets with total volume below this value.

## `resolvedOnly` (type: `boolean`):

Only include resolved/closed markets.

## `activeOnly` (type: `boolean`):

Only include currently active (open) markets.

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

Maximum number of markets to emit.

## Actor input object example

```json
{
  "mode": "trending",
  "query": "election",
  "category": "all",
  "resolvedOnly": false,
  "activeOnly": true,
  "maxItems": 5
}
```

# Actor output Schema

## `records` (type: `string`):

Dataset containing all scraped Polymarket markets.

# 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": "trending",
    "query": "election",
    "category": "all",
    "resolvedOnly": false,
    "activeOnly": true,
    "maxItems": 5
};

// Run the Actor and wait for it to finish
const run = await client.actor("crawlyth-forge/polymarket-market-odds-and-volume-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 = {
    "mode": "trending",
    "query": "election",
    "category": "all",
    "resolvedOnly": False,
    "activeOnly": True,
    "maxItems": 5,
}

# Run the Actor and wait for it to finish
run = client.actor("crawlyth-forge/polymarket-market-odds-and-volume-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 '{
  "mode": "trending",
  "query": "election",
  "category": "all",
  "resolvedOnly": false,
  "activeOnly": true,
  "maxItems": 5
}' |
apify call crawlyth-forge/polymarket-market-odds-and-volume-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "type": "http",
            "url": "https://mcp.apify.com/?tools=fetch-actor-details,crawlyth-forge/polymarket-market-odds-and-volume-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/jpGg7DQUjMMdR6ZJm/builds/ZR3HzIuNyWEHCUwuI/openapi.json
