{
  "openapi": "3.0.1",
  "info": {
    "title": "Polymarket Scraper: Track Prediction Markets by Category",
    "description": "Scrape Polymarket prediction markets by category, keyword, min volume, liquidity, and price move. Returns deduped JSON with question, outcomes, prices, 24h volume, and end date. Uses the official Polymarket Gamma API.",
    "version": "0.1",
    "x-build-id": "rqLcB1dzb78HrRajk"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapemint~polymarket-market-monitor/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapemint-polymarket-market-monitor",
        "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/scrapemint~polymarket-market-monitor/runs": {
      "post": {
        "operationId": "runs-sync-scrapemint-polymarket-market-monitor",
        "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/scrapemint~polymarket-market-monitor/run-sync": {
      "post": {
        "operationId": "run-sync-scrapemint-polymarket-market-monitor",
        "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": {
          "searchQueries": {
            "title": "Keyword search (title or description)",
            "type": "array",
            "description": "Only keep markets whose question or description contains any of these keywords. Case insensitive. Leave empty to keep everything the API returned.",
            "items": {
              "type": "string"
            }
          },
          "categories": {
            "title": "Category shortcut",
            "type": "array",
            "description": "Shortcut for top level Polymarket categories. Options: politics, crypto, sports, technology, music, entertainment, elections, basketball, football, blockchain. Internally resolves to tag IDs. Combine with tagIds below.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "tagIds": {
            "title": "Tag IDs (advanced)",
            "type": "array",
            "description": "Raw Polymarket tag IDs if you need a tag outside the category shortcuts. Example: 180 for Israel, 169 for Javier Milei. Browse tags at gamma-api.polymarket.com/tags.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "itemType": {
            "title": "Item type",
            "enum": [
              "markets",
              "events"
            ],
            "type": "string",
            "description": "Markets returns one row per individual market (question + outcomes). Events returns one row per event group (a basket of related markets, like 'Who will win the 2028 election').",
            "default": "markets"
          },
          "status": {
            "title": "Status",
            "enum": [
              "active",
              "closed",
              "all"
            ],
            "type": "string",
            "description": "Active is the default. Closed returns resolved markets. All returns both.",
            "default": "active"
          },
          "minVolume24h": {
            "title": "Minimum 24h volume (USD)",
            "minimum": 0,
            "maximum": 100000000,
            "type": "integer",
            "description": "Drop markets with less than this much volume in the last 24 hours. Useful when you only want liquid, actively traded markets.",
            "default": 0
          },
          "minLiquidity": {
            "title": "Minimum liquidity (USD)",
            "minimum": 0,
            "maximum": 100000000,
            "type": "integer",
            "description": "Drop markets with less than this much resting liquidity on the CLOB. Filters thin books.",
            "default": 0
          },
          "minTotalVolume": {
            "title": "Minimum total volume (USD)",
            "minimum": 0,
            "maximum": 1000000000,
            "type": "integer",
            "description": "Drop markets with less than this much lifetime traded volume. Filters toy markets.",
            "default": 0
          },
          "minPriceChangePct": {
            "title": "Minimum price move (%)",
            "minimum": 0,
            "maximum": 100,
            "type": "integer",
            "description": "Only keep markets whose 1 week or 1 month price has moved by at least this many percentage points (absolute value). Set to 0 to disable. Example: 10 returns only markets that moved 10+ points. Applies to markets, not events.",
            "default": 0
          },
          "minutesUntilEnd": {
            "title": "Minimum minutes until end",
            "minimum": 0,
            "maximum": 525600,
            "type": "integer",
            "description": "Drop markets ending sooner than this many minutes from now. Set to 0 to keep everything. Useful to exclude markets too close to resolution for your strategy.",
            "default": 0
          },
          "sortBy": {
            "title": "Sort",
            "enum": [
              "volume24hr",
              "liquidity",
              "endDate",
              "startDate",
              "volumeNum"
            ],
            "type": "string",
            "description": "Sort markets before filtering. volume24hr ranks by last 24 hours traded. liquidity ranks by depth. endDate ranks by closest to resolution. startDate returns newest first.",
            "default": "volume24hr"
          },
          "maxItemsPerSource": {
            "title": "Max items per tag or run",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "Per tag cap on items processed. Polymarket Gamma returns up to 100 per page; the actor paginates.",
            "default": 100
          },
          "maxItemsTotal": {
            "title": "Maximum items per run",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Hard cap on items pushed to the dataset per run. Controls total cost.",
            "default": 200
          },
          "dedupe": {
            "title": "Deduplicate across runs",
            "type": "boolean",
            "description": "Skip market IDs pushed on previous runs. Stored in the key value store under SEEN_IDS. Turn off to snapshot every run, useful when tracking price moves over time.",
            "default": true
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify proxy settings. The Polymarket Gamma API is public and does not IP rate limit aggressively, so proxy is rarely needed."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}