{
  "openapi": "3.0.1",
  "info": {
    "title": "Polymarket Leaderboard Scraper – Top Wallets, PnL",
    "description": "Polymarket leaderboard scraper and unofficial API: export top traders and smart-money wallet rankings (PnL, ROI, win rate) to CSV/JSON, no login.",
    "version": "1.0",
    "x-build-id": "OGKEBsPMVcIExt17r"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/logiover~polymarket-top-wallets-leaderboard/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-logiover-polymarket-top-wallets-leaderboard",
        "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-top-wallets-leaderboard/runs": {
      "post": {
        "operationId": "runs-sync-logiover-polymarket-top-wallets-leaderboard",
        "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-top-wallets-leaderboard/run-sync": {
      "post": {
        "operationId": "run-sync-logiover-polymarket-top-wallets-leaderboard",
        "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": {
          "intervals": {
            "title": "Lookback Intervals",
            "uniqueItems": true,
            "type": "array",
            "description": "Lookback windows for ranking. `1d` = past 24h, `7d` = past week, `30d` = past 30 days, `all` = all-time leaderboard.",
            "items": {
              "type": "string",
              "enum": [
                "1d",
                "7d",
                "30d",
                "all"
              ],
              "enumTitles": [
                "24 hours",
                "7 days",
                "30 days",
                "All time"
              ]
            },
            "default": [
              "1d",
              "7d",
              "30d",
              "all"
            ]
          },
          "includeSmartWallet": {
            "title": "Include Smart-Wallet Top 200",
            "type": "boolean",
            "description": "Fetch the overall smart-wallet leaderboard (~200 wallets per interval).",
            "default": true
          },
          "categories": {
            "title": "Category IDs (top100 leaderboards)",
            "type": "array",
            "description": "Polymarket category IDs to also fetch the top-100 leaderboard for. Common: 1 = Sports, 2 = Politics, 21 = Crypto, 100265 = Trump-tagged. Each category × interval is a separate call.",
            "default": [
              "1",
              "2",
              "21",
              "100265",
              "126",
              "78",
              "309"
            ],
            "items": {
              "type": "string"
            }
          },
          "includeWalletOverview": {
            "title": "Include Per-Wallet 24h Overview",
            "type": "boolean",
            "description": "For each unique wallet returned by the leaderboard calls, also fetch the per-wallet `/pf/api/v1/wallet/{addr}/overview` endpoint with wallet age, total value, 24h profit, 24h buys / sells, etc.",
            "default": false
          },
          "maxOverviewLookups": {
            "title": "Max Overview Lookups",
            "minimum": 0,
            "type": "integer",
            "description": "Cap on per-wallet overview calls when `includeWalletOverview` is ON. Higher = more rows; 0 = lookup every unique wallet.",
            "default": 5000
          },
          "minPnl": {
            "title": "Minimum PnL (USD)",
            "type": "number",
            "description": "Drop wallets whose leaderboard PnL is below this.",
            "default": 0
          },
          "minRoi": {
            "title": "Minimum ROI (0-1)",
            "type": "number",
            "description": "Drop wallets whose ROI is below this (e.g. 0.05 = 5%).",
            "default": 0
          },
          "minWinRate": {
            "title": "Minimum Win Rate (0-1)",
            "type": "number",
            "description": "Drop rows with a win rate below this (0-1). E.g. 0.5 = 50%.",
            "default": 0
          },
          "minVolumeUsd": {
            "title": "Minimum Volume (USD)",
            "type": "number",
            "description": "Drop rows whose USD volume is below this threshold. Default 0 = no filter.",
            "default": 0
          },
          "minTxs": {
            "title": "Minimum Transactions",
            "type": "integer",
            "description": "Drop rows with fewer transactions than this — filters out lucky one-shot wallets.",
            "default": 0
          },
          "tagFilter": {
            "title": "Tag Filter",
            "type": "array",
            "description": "Keep only wallets carrying these tags (e.g. `smart_money`, `top100_21`). Empty = all.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "deduplicate": {
            "title": "Deduplicate Wallets",
            "type": "boolean",
            "description": "When ON, a wallet returned by multiple (interval, category) calls is emitted once with the merged `appearedIn` list.",
            "default": false
          },
          "useProxy": {
            "title": "Use Apify Proxy",
            "type": "boolean",
            "description": "Route requests through Apify Proxy. Leave OFF (recommended): the direct datacenter origin passes the future.news Cloudflare check, while the residential proxy upstream is currently rejected (UPSTREAM504). Only turn ON if you hit rate limits, and then prefer the default datacenter group.",
            "default": false
          },
          "proxyConfiguration": {
            "title": "Proxy Configuration",
            "type": "object",
            "description": "Apify Proxy configuration, used only when 'Use Apify Proxy' is ON. The default datacenter group works best against future.news; the residential group is currently blocked upstream.",
            "default": {
              "useApifyProxy": true
            }
          },
          "maxConcurrency": {
            "title": "Max Concurrent Requests",
            "minimum": 1,
            "maximum": 20,
            "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": 5
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}