# Polymarket Events, Live Odds & AI Analysis Scraper (`logiover/polymarket-events-odds-ai-scraper`) Actor

Every active Polymarket event, sports match with live scores, AI betting analysis, and Twitter signal feed. Market-level data (outcomes, prices, volumes 5m/1h/6h/24h, liquidity, spreads), sports games (teams, scores, period, status), AI rationale, X sentiment, tweet → event impact map.

- **URL**: https://apify.com/logiover/polymarket-events-odds-ai-scraper.md
- **Developed by:** [Logiover](https://apify.com/logiover) (community)
- **Categories:** Automation, News, AI
- **Stats:** 2 total users, 1 monthly users, 100.0% runs succeeded, NaN bookmarks
- **User rating**: No ratings yet

## Pricing

from $2.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.

Learn more: https://docs.apify.com/platform/actors/running/actors-in-store#pay-per-event

## What's an Apify Actor?

Actors are a software tools running on the Apify platform, for all kinds of web data extraction and automation use cases.
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.

In JavaScript/TypeScript projects, use official [JavaScript/TypeScript client](https://docs.apify.com/api/client/js.md):

```bash
npm install apify-client
```

In Python projects, use official [Python client library](https://docs.apify.com/api/client/python.md):

```bash
pip install apify-client
```

In shell scripts, use [Apify CLI](https://docs.apify.com/cli/docs.md):

````bash
# MacOS / Linux
curl -fsSL https://apify.com/install-cli.sh | bash
# Windows
irm https://apify.com/install-cli.ps1 | iex
```bash

In AI frameworks, you might use the [Apify MCP server](https://docs.apify.com/platform/integrations/mcp.md).

If your project is in a different language, use 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

## Polymarket Events, Live Odds, Sports Scores, AI Analysis & Twitter Signal Scraper

**The most comprehensive Polymarket data extractor on Apify.** Scrape every active Polymarket event, every sports market with live scores, every AI-generated betting analysis, and the high-significance Twitter signal feed — **all in one actor**. Returns market-level data (condition IDs, outcomes, prices, volumes at 5m/1h/6h/24h/all, liquidity, spreads, end timestamps), sports game data (home/away teams, scores, periods, game status), AI analysis (betting recommendation, rationale, market context, key data, X sentiment), and Twitter activity (significance score, content, linked events / markets / probabilities).

> The Bloomberg terminal of prediction markets — every key dataset in one Apify run.

---

### 🚀 What this actor does

Polymarket is the dominant on-chain prediction market with billions in cumulative volume. future.news is a leading Polymarket data aggregator that exposes a clean API surface. This actor turns that into four pluggable feeds:

1. **`events_rank`** — every active event + series with markets, prices, outcome assets.
2. **`sports`** — sports markets with live game data (scores, period, game status, home/away teams with logos).
3. **`twitter_activity`** — paginated curated Twitter feed where each tweet is **tagged with the prediction-market events it affects** (with current probability + outcome).
4. **`ai_analysis`** — batch AI analysis for given event slugs: betting option, rationale, market analysis, key data, X sentiment.

You toggle which feeds and the actor emits everything into the dataset with a `_kind` discriminator. Use one feed for narrow runs (e.g. just `sports` for live odds) or all four for a comprehensive nightly export.

---

### 💡 Use cases

- **Polymarket trading dashboards** — power your own UI with live event + odds data.
- **Election forecasting tools** — pull political-event markets every minute, build a "real-time pollster" view.
- **Sports betting analytics** — live odds + live scores in a single export.
- **AI-driven trading bots** — feed the AI analysis output into a buy/no-buy decision pipeline.
- **News + market correlation** — Twitter activity feed shows which tweets are moving which markets.
- **Newsletter / Substack pre-game previews** — auto-generated from events + AI analysis.
- **Election bettors aggregator** — Like ElectionBettingOdds.com but live and structured.
- **Research datasets** — labelled Polymarket events × tweets × AI takes for ML.

---

### ⚙️ Input configuration

| Field | Type | Default | Description |
|-------|------|---------|-------------|
| `feeds` | `string[]` | `["events_rank","sports","twitter_activity"]` | Which feeds to fetch. |
| `explodeMarkets` | `boolean` | `true` | One row per market within an event. |
| `explodeAssets` | `boolean` | `false` | One row per outcome (Yes/No/team) within a market. |
| `twitterMaxItems` | `integer` | `100` | Cap on tweets in `twitter_activity` (paginated). |
| `minTwitterSignificance` | `integer` | `0` | Drop tweets below this significance (0-100). |
| `twitterCategories` | `string[]` | `[]` | Polymarket category IDs to keep in tweet feed. |
| `aiAnalysisSlugs` | `string[]` | `[]` | Event slugs to AI-analyze (auto-filled from `events_rank` when both feeds run). |
| `aiAnalysisType` | `integer` | `1` | AI analysis variant. |
| `minVolume24hUsd` | `number` | `0` | Drop low-volume events/markets. |
| `onlyLive` | `boolean` | `false` | Sports: keep only `live_status: true` games. |
| `useProxy` | `boolean` | `true` | |
| `proxyConfiguration` | `object` | residential | |
| `maxConcurrency` | `integer` | `3` | |

---

### 📦 Output rows

The dataset emits four row kinds distinguished by `_kind`:

#### 1. `event` (Polymarket event row — primary)
Identity: `eventSlug`, `eventTitle`, `eventTitleTrans`, `eventDescription`, `eventIcon`, `exchange`, `tagIds`.
Time: `endTimestamp`, `createdTimestamp`, `liveStartAt`, `liveStatus`, `status`.
Series: `seriesSlug`, `seriesRecurrence`, `maxChance`, `maxSpread`.
Resolution: `resolutionSource`, `liveStreamUrl`, `cryptoCurrentPrice`, `cryptoPriceToBeat`.
Aggregate volume: `volume5m`, `volume1h`, `volume6h`, `volume24h`, `volumeAll`, `liquidity`, `marketsCount`, `totalVolume`.

**When `explodeMarkets: true` (default)**, each event-market pair adds:
`marketId`, `marketQuestion`, `marketIcon`, `marketStatus`, `marketEndTimestamp`, `marketGroupItem`, `marketGroupItemTrans`, `marketResolutionSource`, `marketResolvedAssetId`, `marketLiveStartAt`, `marketSportsType`, `marketLine`, `marketGroupItemThreshold`, `marketRewardsDailyRate`, `marketRewardsMinSize`, `marketRewardsMaxSpread`, `marketRewardsAmount`, `marketEnableOrderBook`, `price`, `price5m`, `price1h`, `price6h`, `price24h`, `volume5m/1h/6h/24h/All`, `liquidity`, `spread`, `createdTimestamp`.

**When `explodeAssets: true`**, each outcome adds:
`outcome`, `outcomeTrans`, `outcomeChance`, `outcomeBestAsk`, `outcomeBestBid`, `outcomeTokenId`.

#### 2. `sports` (sports event — has all `event` fields plus)
`gameStatus`, `gameType`, `gameElapsed`, `gameEnded`, `gameClockStartAt`, `gameClockEndAt`, `gameEndAt`, `score`, `homeTeamName`/`Logo`/`Color`/`Abbr`, `awayTeamName`/`Logo`/`Color`/`Abbr`, `thesportsMatchId`.

#### 3. `series` (Polymarket series — meta-row for recurring events)
`seriesSlug`, `seriesTitle`, `seriesVolume5m/1h/6h/24h/All`, `currentEventSlug`, `currentEventTitle`, `currentEventStatus`, `currentEventEndAt`, `currentEventLiveStartAt`, `currentEventVolume24h`, `currentEventLiquidity`.

#### 4. `twitter_activity` (curated tweets affecting markets)
`tweetId`, `originTweetId`, `tweetUserId`, `tweetUserHandle`, `tweetUserName`, `tweetUserAvatar`, `tweetUserVerifiedType`, `tweetOriginUserHandle`, `tweetOriginUserName`, `tweetType`, `activityType`, `tweetText`, `tweetPhotos`, `tweetVideos`, `tweetThumbnails`, `tweetTimestamp`, `tweetSignificance`, `tweetCategory`, `tweetPlatform`, `tweetEvents[]` (each with `eventSlug`, `eventTitle`, `marketTitle`, `marketId`, `volume24h`, `probability`, `outcome`), `tweetUrl`.

#### 5. `ai_analysis` (AI betting analysis for an event)
`eventSlug`, `aiStatus`, `aiUpdatedAt`, `aiRawContent`, `aiBettingOption`, `aiBettingRationale`, `aiContextAnalysis`, `aiKeyDataEvidence`, `aiXSentiment`.

---

### 🧪 Example outputs

#### `sports` row
```json
{
  "_kind": "sports",
  "eventSlug": "atp-carabel-kecmano-2026-05-15",
  "eventTitle": "Valencia: Camilo Ugo Carabelli vs Miomir Kecmanovic",
  "homeTeamName": "Camilo Ugo Carabelli",
  "awayTeamName": "Miomir Kecmanovic",
  "homeTeamLogo": "https://polymarket-upload.s3.us-east-2.amazonaws.com/country-flags/arg.png",
  "score": "0-1",
  "period": "S1",
  "gameStatus": "in_progress",
  "gameType": "tennis",
  "marketId": "0x9439f1eaac30c73e9780a5eebedcd9b1a7a7a6d429cd15ebba69672b6877e757",
  "marketQuestion": "Camilo Ugo Carabelli vs Miomir Kecmanovic — Moneyline",
  "outcome": "Camilo Ugo Carabelli",
  "outcomePrice": 0.385,
  "outcomeBestAsk": 0.39,
  "outcomeBestBid": 0.38,
  "volume24h": 26600.28,
  "totalVolume": 26702.56,
  "scrapedAt": "2026-05-15T12:00:00.000Z"
}
````

#### `twitter_activity` row

```json
{
  "_kind": "twitter_activity",
  "tweetId": "2055259399174619490",
  "tweetUserHandle": "MOSSADil",
  "tweetUserName": "Mossad Commentary",
  "tweetUserVerifiedType": "blue",
  "tweetText": "NEW—President Trump says he may lift sanctions on Chinese companies buying Iranian oil…",
  "tweetTimestamp": "2026-05-15T12:10:00.293Z",
  "tweetSignificance": 95,
  "tweetCategory": ["2", "100265"],
  "tweetEvents": [
    {
      "eventSlug": "trump-xi-summit-what-will-china-announce-by-may-22",
      "eventTitle": "Trump-Xi Summit: What will China announce by May 22?",
      "marketTitle": "Boeing Aircraft Purchase",
      "marketId": "0xecbc...",
      "volume24h": 25698.89,
      "probability": 0.5,
      "outcome": "Yes"
    }
  ],
  "tweetUrl": "https://x.com/MOSSADil/status/2055259399174619490",
  "scrapedAt": "2026-05-15T12:10:00.000Z"
}
```

#### `ai_analysis` row

```json
{
  "_kind": "ai_analysis",
  "eventSlug": "trump-xi-summit-what-will-china-announce-by-may-22",
  "aiStatus": "SUCCESS",
  "aiUpdatedAt": "2026-05-15T07:13:19.000Z",
  "aiBettingOption": "Boeing Aircraft Purchase: Buy No",
  "aiBettingRationale": "Summit concluded May 15 without official Chinese announcements on Boeing purchases…",
  "aiContextAnalysis": "Trump-Xi summit in Beijing aimed to stabilize trade amid Iran war, Taiwan tensions…",
  "aiKeyDataEvidence": "Reuters: Pre-summit, US-China eyed tariff cuts on $30B non-sensitive imports…",
  "aiXSentiment": "Hype around Trump securing 200 Boeing jets, soybeans, oil/LNG buys, Iran help from Xi…"
}
```

***

### 🧰 Recipes

#### 1. Live odds dashboard (refresh every minute)

```json
{ "feeds": ["events_rank","sports"], "onlyLive": true }
```

Schedule every minute. Webhook each row → dashboard.

#### 2. AI-driven betting bot

```json
{
  "feeds": ["events_rank", "ai_analysis"],
  "explodeMarkets": true,
  "minVolume24hUsd": 1000,
  "aiAnalysisType": 1
}
```

events\_rank auto-feeds slugs into AI analysis. Combine `aiBettingOption` with current `price` to decide trades.

#### 3. Sports betting export

```json
{
  "feeds": ["sports"],
  "explodeMarkets": true,
  "explodeAssets": true,
  "onlyLive": true
}
```

#### 4. Politics tweet alerts (high-significance only)

```json
{
  "feeds": ["twitter_activity"],
  "twitterMaxItems": 200,
  "minTwitterSignificance": 70,
  "twitterCategories": ["2", "100265"]
}
```

Schedule every 5 minutes; webhook each significant tweet to Telegram.

#### 5. Daily Polymarket research bundle

```json
{
  "feeds": ["events_rank", "sports", "twitter_activity", "ai_analysis"],
  "twitterMaxItems": 500,
  "explodeMarkets": true,
  "explodeAssets": true
}
```

Comprehensive nightly export.

***

### 🛡️ Under the hood

- **Endpoints (future.news)** —
  - `POST /events/api/rank` `{ status, order_by, limit, max_end_timestamp, ... }`
  - `POST /events/api/sports/list` `{ require_all_tags, list_type, live_start_at_min/max, limit, ... }`
  - `GET /fds/api/v1/twitter/activity/list?limit=10&cursor=...`
  - `POST /events/api/ai-analysis/batch` `{ exchange, slugs[], type }`
- **Pagination** — Twitter activity uses base64-encoded cursor.
- **Auto-fill** — AI analysis auto-fills slugs from `events_rank` when both feeds run.
- **Auth** — none.
- **Proxy** — Apify Residential default.
- **Retries** — 5 attempts with exponential backoff on 403 / 429 / 5xx.

***

### ⚡ Performance

| Configuration | Rows | Time | Cost |
|--------------|------|------|------|
| events\_rank only | 200-1000 | ~30s | <$0.01 |
| events\_rank + sports + 100 tweets | 500-2000 | ~1-2 min | ~$0.04 |
| All feeds, full | 1000-5000 | ~5 min | ~$0.10 |

***

### 📅 Recommended schedules

- **Live odds feed** — every 1-5 minutes (`events_rank` + `sports`).
- **High-significance tweet alerts** — every 5-15 minutes (`twitter_activity`).
- **Daily AI bundle** — once per hour or daily (`ai_analysis`).

***

### ❓ FAQ

#### What's a Polymarket "event" vs "series"?

**Event** = a single resolvable market (e.g. "Will Trump announce X by May 22"). **Series** = a recurring sequence of events (e.g. "BTC Up or Down 5m" generates a new event every 5 minutes).

#### Why `_kind` rows?

Different kinds have different shapes — the discriminator lets you filter cleanly in your dataset.

#### What's `tweetSignificance`?

future.news's 0-100 score of how impactful a tweet is for prediction markets. 95+ tweets typically move odds.

#### How is AI analysis generated?

future.news runs an LLM (likely Grok / GPT-class) on event description, recent news, X sentiment, and produces a structured betting recommendation. Quality varies; treat as a research input, not financial advice.

#### Can I pass arbitrary event slugs to AI analysis?

Yes — set `aiAnalysisSlugs: ["slug-1", "slug-2"]` and skip `events_rank` if you want isolated AI calls.

#### How big is the events\_rank list?

Typically 50-200 active events at a time, plus 20-30 active series. Sports adds another ~50-100 live/upcoming games.

#### Can I get historical prices?

The actor returns current snapshots + 5m / 1h / 6h / 24h aggregates. For longer history, schedule daily and stitch.

#### What's `crypto_current_price` vs `crypto_price_to_beat`?

For crypto-asset events, the current asset price and the resolution threshold.

#### Are sports scores live?

Yes — `score`, `period`, `gameStatus`, `gameEnded` reflect live game state.

#### What's `tweetEvents[]`?

For each tweet, the list of Polymarket events the tweet is tagged as affecting — with current `probability` and `outcome`. Critical for "this tweet just moved that market" analysis.

#### What if AI analysis is missing for some slugs?

The endpoint sometimes returns `null` or no entry. The actor logs and continues; status field will be empty.

#### Does the actor cover non-Polymarket exchanges?

Currently the AI analysis endpoint is parameterized with `exchange: "polymarket"`. future.news may expose others later.

#### Can I run this in a tight loop?

Yes — recommended `pollIterations: 1` per run, scheduled every 1-5 minutes.

#### How fresh is the odds data?

future.news refreshes every ~10-30 seconds.

***

### 🔗 Related actors

- **Polymarket Top Wallets & PnL Leaderboard** — who's winning on Polymarket.
- **GMGN Trending Memecoin Scanner** — for the on-chain crypto side.
- **GMGN Smart Money Buy Signals** — live crypto whale buys.
- **GMGN Crypto KOL Twitter & Telegram Signal Feed** — crypto-specific KOL chatter.

***

### 🆘 Support

Bug? Want a new feed exposed? Open an issue on the actor's Apify page.

# Actor input Schema

## `feeds` (type: `array`):

Which feeds to fetch. `events_rank` = all active Polymarket events with markets/series. `sports` = sports markets with live scores. `twitter_activity` = curated tweet activity feed with event tags. `ai_analysis` = per-event AI betting analysis (requires event slugs).

## `explodeMarkets` (type: `boolean`):

When ON, each market within an event becomes its own row (one event with 5 markets → 5 rows). When OFF, markets are kept nested under the event row.

## `explodeAssets` (type: `boolean`):

When ON and markets are exploded, each market outcome (Yes/No, team A/B, etc.) becomes its own row.

## `twitterMaxItems` (type: `integer`):

Cap on twitter\_activity items (paginated via cursor, 10 per page). Higher = more rows but slower runs. 200 ≈ 1 minute; 2000 ≈ 10 minutes.

## `minTwitterSignificance` (type: `integer`):

Drop tweets with significance score below this (0-100). Higher = more impactful.

## `twitterCategories` (type: `array`):

Polymarket category IDs to keep in the Twitter activity feed. Empty = all.

## `aiAnalysisSlugs` (type: `array`):

Polymarket event slugs to run AI analysis on (e.g. `trump-xi-summit-what-will-china-announce-by-may-22`). Required when `feeds` includes `ai_analysis`. Auto-populated from `events_rank` when omitted and that feed is enabled.

## `aiAnalysisType` (type: `integer`):

AI analysis type ID. 1 is the standard betting-recommendation analysis.

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

Drop events / markets with 24h volume below this threshold.

## `onlyLive` (type: `boolean`):

Sports feed only: keep games where `live_status == true`.

## `useProxy` (type: `boolean`):

Route requests through Apify Proxy. Strongly recommended ON — residential proxy is the most reliable way to bypass Cloudflare rate limits.

## `proxyConfiguration` (type: `object`):

Apify Proxy configuration. Residential proxy group is recommended for the highest success rate against Cloudflare.

## `maxConcurrency` (type: `integer`):

Maximum number of API calls running in parallel. Higher = faster runs but more chance of hitting rate limits. 3-5 is safe.

## Actor input object example

```json
{
  "feeds": [
    "events_rank",
    "sports",
    "twitter_activity"
  ],
  "explodeMarkets": true,
  "explodeAssets": true,
  "twitterMaxItems": 200,
  "minTwitterSignificance": 0,
  "twitterCategories": [],
  "aiAnalysisSlugs": [],
  "aiAnalysisType": 1,
  "minVolume24hUsd": 0,
  "onlyLive": false,
  "useProxy": true,
  "proxyConfiguration": {
    "useApifyProxy": true,
    "apifyProxyGroups": [
      "RESIDENTIAL"
    ]
  },
  "maxConcurrency": 3
}
```

# Actor output Schema

## `_kind` (type: `string`):

event / sports / series / twitter\_activity / ai\_analysis

## `eventSlug` (type: `string`):

Polymarket event slug

## `eventTitle` (type: `string`):

Event question / title

## `eventIcon` (type: `string`):

Event icon URL

## `eventDescription` (type: `string`):

Event description

## `seriesSlug` (type: `string`):

Series slug (for recurring events)

## `seriesTitle` (type: `string`):

Series title

## `marketId` (type: `string`):

Polymarket condition\_id

## `marketQuestion` (type: `string`):

Market question text

## `marketGroupItem` (type: `string`):

Group item title (multi-outcome group)

## `outcome` (type: `string`):

Outcome name (Yes/No/team)

## `outcomePrice` (type: `string`):

Outcome price 0-1

## `outcomeBestAsk` (type: `string`):

Best ask

## `outcomeBestBid` (type: `string`):

Best bid

## `price` (type: `string`):

Market price

## `spread` (type: `string`):

Spread

## `liquidity` (type: `string`):

Pool liquidity

## `volume24h` (type: `string`):

24h volume

## `volumeAll` (type: `string`):

All-time volume

## `endTimestamp` (type: `string`):

ISO event end time

## `liveStatus` (type: `string`):

Live status

## `resolutionSource` (type: `string`):

Resolution source URL

## `homeTeamName` (type: `string`):

Home team name (sports rows)

## `homeTeamLogo` (type: `string`):

Home team logo

## `awayTeamName` (type: `string`):

Away team name

## `awayTeamLogo` (type: `string`):

Away team logo

## `score` (type: `string`):

Live game score

## `gameStatus` (type: `string`):

in\_progress / completed / etc.

## `gameType` (type: `string`):

tennis / soccer / etc.

## `tweetId` (type: `string`):

Tweet ID (twitter\_activity rows)

## `tweetUserHandle` (type: `string`):

Tweet author handle

## `tweetUserName` (type: `string`):

Tweet author display name

## `tweetText` (type: `string`):

Tweet content

## `tweetSignificance` (type: `string`):

future.news significance score 0-100

## `tweetCategory` (type: `string`):

Polymarket category IDs the tweet affects

## `tweetEvents` (type: `string`):

Events affected by the tweet (with probability + outcome)

## `tweetTimestamp` (type: `string`):

ISO tweet timestamp

## `tweetUrl` (type: `string`):

Direct tweet URL

## `aiStatus` (type: `string`):

AI analysis status (ai\_analysis rows)

## `aiBettingOption` (type: `string`):

AI recommended betting option

## `aiBettingRationale` (type: `string`):

Reasoning for the recommended bet

## `aiContextAnalysis` (type: `string`):

Market context analysis

## `aiKeyDataEvidence` (type: `string`):

Key data and media evidence

## `aiXSentiment` (type: `string`):

X / Twitter sentiment summary

## `aiUpdatedAt` (type: `string`):

AI analysis last update timestamp

## `scrapedAt` (type: `string`):

Scrape timestamp

# 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 = {};

// Run the Actor and wait for it to finish
const run = await client.actor("logiover/polymarket-events-odds-ai-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 = {}

# Run the Actor and wait for it to finish
run = client.actor("logiover/polymarket-events-odds-ai-scraper").call(run_input=run_input)

# Fetch and print Actor results from the run's dataset (if there are any)
print("💾 Check your data here: https://console.apify.com/storage/datasets/" + run["defaultDatasetId"])
for item in client.dataset(run["defaultDatasetId"]).iterate_items():
    print(item)

# 📚 Want to learn more 📖? Go to → https://docs.apify.com/api/client/python/docs/quick-start

```

## CLI example

```bash
echo '{}' |
apify call logiover/polymarket-events-odds-ai-scraper --silent --output-dataset

```

## MCP server setup

```json
{
    "mcpServers": {
        "apify": {
            "command": "npx",
            "args": [
                "mcp-remote",
                "https://mcp.apify.com/?tools=logiover/polymarket-events-odds-ai-scraper",
                "--header",
                "Authorization: Bearer <YOUR_API_TOKEN>"
            ]
        }
    }
}

```

## OpenAPI specification

```json
{
    "openapi": "3.0.1",
    "info": {
        "title": "Polymarket Events, Live Odds & AI Analysis Scraper",
        "description": "Every active Polymarket event, sports match with live scores, AI betting analysis, and Twitter signal feed. Market-level data (outcomes, prices, volumes 5m/1h/6h/24h, liquidity, spreads), sports games (teams, scores, period, status), AI rationale, X sentiment, tweet → event impact map.",
        "version": "1.0",
        "x-build-id": "XtL43LXWdgBdSikT2"
    },
    "servers": [
        {
            "url": "https://api.apify.com/v2"
        }
    ],
    "paths": {
        "/acts/logiover~polymarket-events-odds-ai-scraper/run-sync-get-dataset-items": {
            "post": {
                "operationId": "run-sync-get-dataset-items-logiover-polymarket-events-odds-ai-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for its completion, and returns Actor's dataset items in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        },
        "/acts/logiover~polymarket-events-odds-ai-scraper/runs": {
            "post": {
                "operationId": "runs-sync-logiover-polymarket-events-odds-ai-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor and returns information about the initiated run in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK",
                        "content": {
                            "application/json": {
                                "schema": {
                                    "$ref": "#/components/schemas/runsResponseSchema"
                                }
                            }
                        }
                    }
                }
            }
        },
        "/acts/logiover~polymarket-events-odds-ai-scraper/run-sync": {
            "post": {
                "operationId": "run-sync-logiover-polymarket-events-odds-ai-scraper",
                "x-openai-isConsequential": false,
                "summary": "Executes an Actor, waits for completion, and returns the OUTPUT from Key-value store in response.",
                "tags": [
                    "Run Actor"
                ],
                "requestBody": {
                    "required": true,
                    "content": {
                        "application/json": {
                            "schema": {
                                "$ref": "#/components/schemas/inputSchema"
                            }
                        }
                    }
                },
                "parameters": [
                    {
                        "name": "token",
                        "in": "query",
                        "required": true,
                        "schema": {
                            "type": "string"
                        },
                        "description": "Enter your Apify token here"
                    }
                ],
                "responses": {
                    "200": {
                        "description": "OK"
                    }
                }
            }
        }
    },
    "components": {
        "schemas": {
            "inputSchema": {
                "type": "object",
                "properties": {
                    "feeds": {
                        "title": "Feeds to Scrape",
                        "uniqueItems": true,
                        "type": "array",
                        "description": "Which feeds to fetch. `events_rank` = all active Polymarket events with markets/series. `sports` = sports markets with live scores. `twitter_activity` = curated tweet activity feed with event tags. `ai_analysis` = per-event AI betting analysis (requires event slugs).",
                        "items": {
                            "type": "string",
                            "enum": [
                                "events_rank",
                                "sports",
                                "twitter_activity",
                                "ai_analysis"
                            ],
                            "enumTitles": [
                                "Events / Series Rank",
                                "Sports List + Live Scores",
                                "Twitter Activity Feed",
                                "AI Analysis (batch)"
                            ]
                        },
                        "default": [
                            "events_rank",
                            "sports",
                            "twitter_activity"
                        ]
                    },
                    "explodeMarkets": {
                        "title": "Explode Markets (Events Mode)",
                        "type": "boolean",
                        "description": "When ON, each market within an event becomes its own row (one event with 5 markets → 5 rows). When OFF, markets are kept nested under the event row.",
                        "default": true
                    },
                    "explodeAssets": {
                        "title": "Explode Assets (Markets)",
                        "type": "boolean",
                        "description": "When ON and markets are exploded, each market outcome (Yes/No, team A/B, etc.) becomes its own row.",
                        "default": true
                    },
                    "twitterMaxItems": {
                        "title": "Twitter Max Items",
                        "minimum": 10,
                        "type": "integer",
                        "description": "Cap on twitter_activity items (paginated via cursor, 10 per page). Higher = more rows but slower runs. 200 ≈ 1 minute; 2000 ≈ 10 minutes.",
                        "default": 200
                    },
                    "minTwitterSignificance": {
                        "title": "Min Twitter Significance",
                        "minimum": 0,
                        "maximum": 100,
                        "type": "integer",
                        "description": "Drop tweets with significance score below this (0-100). Higher = more impactful.",
                        "default": 0
                    },
                    "twitterCategories": {
                        "title": "Twitter Category Filter",
                        "type": "array",
                        "description": "Polymarket category IDs to keep in the Twitter activity feed. Empty = all.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "aiAnalysisSlugs": {
                        "title": "AI Analysis Event Slugs",
                        "type": "array",
                        "description": "Polymarket event slugs to run AI analysis on (e.g. `trump-xi-summit-what-will-china-announce-by-may-22`). Required when `feeds` includes `ai_analysis`. Auto-populated from `events_rank` when omitted and that feed is enabled.",
                        "default": [],
                        "items": {
                            "type": "string"
                        }
                    },
                    "aiAnalysisType": {
                        "title": "AI Analysis Type",
                        "minimum": 1,
                        "maximum": 10,
                        "type": "integer",
                        "description": "AI analysis type ID. 1 is the standard betting-recommendation analysis.",
                        "default": 1
                    },
                    "minVolume24hUsd": {
                        "title": "Minimum 24h Volume (USD)",
                        "type": "number",
                        "description": "Drop events / markets with 24h volume below this threshold.",
                        "default": 0
                    },
                    "onlyLive": {
                        "title": "Only Live Sports Games",
                        "type": "boolean",
                        "description": "Sports feed only: keep games where `live_status == true`.",
                        "default": false
                    },
                    "useProxy": {
                        "title": "Use Apify Proxy",
                        "type": "boolean",
                        "description": "Route requests through Apify Proxy. Strongly recommended ON — residential proxy is the most reliable way to bypass Cloudflare rate limits.",
                        "default": true
                    },
                    "proxyConfiguration": {
                        "title": "Proxy Configuration",
                        "type": "object",
                        "description": "Apify Proxy configuration. Residential proxy group is recommended for the highest success rate against Cloudflare.",
                        "default": {
                            "useApifyProxy": true,
                            "apifyProxyGroups": [
                                "RESIDENTIAL"
                            ]
                        }
                    },
                    "maxConcurrency": {
                        "title": "Max Concurrent Requests",
                        "minimum": 1,
                        "maximum": 10,
                        "type": "integer",
                        "description": "Maximum number of API calls running in parallel. Higher = faster runs but more chance of hitting rate limits. 3-5 is safe.",
                        "default": 3
                    }
                }
            },
            "runsResponseSchema": {
                "type": "object",
                "properties": {
                    "data": {
                        "type": "object",
                        "properties": {
                            "id": {
                                "type": "string"
                            },
                            "actId": {
                                "type": "string"
                            },
                            "userId": {
                                "type": "string"
                            },
                            "startedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "finishedAt": {
                                "type": "string",
                                "format": "date-time",
                                "example": "2025-01-08T00:00:00.000Z"
                            },
                            "status": {
                                "type": "string",
                                "example": "READY"
                            },
                            "meta": {
                                "type": "object",
                                "properties": {
                                    "origin": {
                                        "type": "string",
                                        "example": "API"
                                    },
                                    "userAgent": {
                                        "type": "string"
                                    }
                                }
                            },
                            "stats": {
                                "type": "object",
                                "properties": {
                                    "inputBodyLen": {
                                        "type": "integer",
                                        "example": 2000
                                    },
                                    "rebootCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "restartCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "resurrectCount": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "computeUnits": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "options": {
                                "type": "object",
                                "properties": {
                                    "build": {
                                        "type": "string",
                                        "example": "latest"
                                    },
                                    "timeoutSecs": {
                                        "type": "integer",
                                        "example": 300
                                    },
                                    "memoryMbytes": {
                                        "type": "integer",
                                        "example": 1024
                                    },
                                    "diskMbytes": {
                                        "type": "integer",
                                        "example": 2048
                                    }
                                }
                            },
                            "buildId": {
                                "type": "string"
                            },
                            "defaultKeyValueStoreId": {
                                "type": "string"
                            },
                            "defaultDatasetId": {
                                "type": "string"
                            },
                            "defaultRequestQueueId": {
                                "type": "string"
                            },
                            "buildNumber": {
                                "type": "string",
                                "example": "1.0.0"
                            },
                            "containerUrl": {
                                "type": "string"
                            },
                            "usage": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "integer",
                                        "example": 1
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            },
                            "usageTotalUsd": {
                                "type": "number",
                                "example": 0.00005
                            },
                            "usageUsd": {
                                "type": "object",
                                "properties": {
                                    "ACTOR_COMPUTE_UNITS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATASET_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "KEY_VALUE_STORE_WRITES": {
                                        "type": "number",
                                        "example": 0.00005
                                    },
                                    "KEY_VALUE_STORE_LISTS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_READS": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "REQUEST_QUEUE_WRITES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_INTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "DATA_TRANSFER_EXTERNAL_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_RESIDENTIAL_TRANSFER_GBYTES": {
                                        "type": "integer",
                                        "example": 0
                                    },
                                    "PROXY_SERPS": {
                                        "type": "integer",
                                        "example": 0
                                    }
                                }
                            }
                        }
                    }
                }
            }
        }
    }
}
```
