{
  "openapi": "3.0.1",
  "info": {
    "title": "Sports Betting Odds Scraper",
    "description": "Collects pre-match and live betting odds from many bookmakers for football, tennis, basketball and 20+ other sports from Flashscore's odds comparison, with opening odds and price movement, to compare prices and track how they move.",
    "version": "0.0",
    "x-build-id": "eV3MIZkufIU5rij9b"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/mina_safwat~sports-odds-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-mina_safwat-sports-odds-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/mina_safwat~sports-odds-scraper/runs": {
      "post": {
        "operationId": "runs-sync-mina_safwat-sports-odds-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/mina_safwat~sports-odds-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-mina_safwat-sports-odds-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": {
          "match_urls": {
            "title": "Match links",
            "type": "array",
            "description": "Flashscore match links, one per line, from flashscore.com or any of its country sites (flashscore.co.uk, flashscore.de, livesport.cz, diretta.it…). Open a match and copy the address bar: links ending in ?mid=… and older /match/<id>/ links both work, and so does the bare 8-character match id. Upcoming, live and finished matches all work (finished ones give the closing odds).",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "league_urls": {
            "title": "Competition links",
            "type": "array",
            "description": "Flashscore league or tournament pages, such as https://www.flashscore.com/football/england/premier-league/ or https://www.flashscore.com/basketball/usa/nba/. The Actor reads the competition's upcoming matches in kick-off order, up to \"Max events\" per link.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "sport": {
            "title": "Sport",
            "enum": [
              "football",
              "tennis",
              "basketball",
              "hockey",
              "american-football",
              "baseball",
              "handball",
              "rugby-union",
              "floorball",
              "bandy",
              "futsal",
              "volleyball",
              "cricket",
              "darts",
              "snooker",
              "boxing",
              "beach-volleyball",
              "aussie-rules",
              "rugby-league",
              "badminton",
              "water-polo",
              "field-hockey",
              "table-tennis",
              "beach-soccer",
              "mma",
              "esports"
            ],
            "type": "string",
            "description": "The sport whose matches to read for the day below.",
            "default": "football"
          },
          "day": {
            "title": "Day",
            "pattern": "^(today|tomorrow|yesterday|\\d{4}-\\d{2}-\\d{2})$",
            "type": "string",
            "description": "today, tomorrow, yesterday or a date such as 2026-10-12, up to 7 days either way. Days run midnight to midnight UTC. Matches still to be played (or in play) are read first, in kick-off order, then finished ones.",
            "default": "today"
          },
          "bookmaker_country": {
            "title": "Bookmakers licensed in",
            "enum": [
              "GB",
              "AO",
              "AT",
              "AZ",
              "BD",
              "BA",
              "BW-CE",
              "BN",
              "BG",
              "CM",
              "CA",
              "CA-ON",
              "TD",
              "CO",
              "CG",
              "CY",
              "CZ",
              "CD",
              "DK",
              "DO",
              "EC",
              "EE",
              "ET",
              "FI",
              "GM",
              "GE",
              "DE",
              "GH",
              "GR",
              "GN",
              "IN",
              "IE",
              "IT",
              "CI",
              "JP",
              "KE",
              "LA",
              "LV",
              "LR",
              "MW",
              "MY",
              "ML",
              "MX",
              "MN",
              "ME",
              "MA",
              "MZ",
              "NA",
              "NP",
              "NG",
              "MK",
              "NO",
              "PK",
              "PE",
              "PH",
              "PL",
              "RO",
              "RU",
              "SN",
              "RS",
              "SL",
              "SG",
              "SK",
              "SI",
              "ZA",
              "KR",
              "ES",
              "LK",
              "SE",
              "CH",
              "TW",
              "TJ",
              "TZ",
              "TH",
              "TN",
              "TR",
              "UG",
              "US-AZ",
              "US-CO",
              "US-CT",
              "US-DC",
              "US-IL",
              "US-IN",
              "US-IA",
              "US-KS",
              "US-KY",
              "US-LA",
              "US-MD",
              "US-MA",
              "US-MI",
              "US-NJ",
              "US-NY",
              "US-NC",
              "US-OH",
              "US-PA",
              "US-TN",
              "US-VT",
              "US-VA",
              "US-WA",
              "US-WV",
              "US-WY",
              "UZ",
              "VE",
              "ZM",
              "ZW",
              "INT"
            ],
            "type": "string",
            "description": "Flashscore shows the bookmakers licensed where its visitor is, so this picks the set: about 20 for the United Kingdom, a handful for most countries. In the US and Canada it goes by state or province. Countries where Flashscore switches its odds comparison off (France, the Netherlands, Australia and most US states) are not listed. International is the set shown to visitors from unlisted countries.",
            "default": "GB"
          },
          "markets": {
            "title": "Markets",
            "type": "array",
            "description": "Which betting markets to save. A sport only has some of them: football has 1X2 but no Home/Away, tennis and basketball the other way round. Each market adds a row per bookmaker (and per line), so fewer markets means fewer rows; left empty, the five main markets are read. Correct score adds 30 to 40 rows per bookmaker and match.",
            "items": {
              "type": "string",
              "enum": [
                "1x2",
                "home_away",
                "over_under",
                "asian_handicap",
                "both_teams_to_score",
                "double_chance",
                "draw_no_bet",
                "european_handicap",
                "to_qualify",
                "odd_even",
                "correct_score",
                "half_time_full_time",
                "next_goal"
              ],
              "enumTitles": [
                "1X2 (home / draw / away)",
                "Home/Away (moneyline, no draw)",
                "Over/Under (totals)",
                "Asian handicap (spread)",
                "Both teams to score",
                "Double chance",
                "Draw no bet",
                "European handicap",
                "To qualify",
                "Odd/Even total",
                "Correct score (one row per score)",
                "Half time/Full time (one row per result pair)",
                "Next goal (live only)"
              ]
            },
            "default": [
              "1x2",
              "home_away",
              "over_under",
              "asian_handicap",
              "both_teams_to_score"
            ]
          },
          "periods": {
            "title": "Periods",
            "type": "array",
            "description": "Which part of the match the odds are for. Full time also covers markets priced including overtime, such as the hockey and basketball moneyline.",
            "items": {
              "type": "string",
              "enum": [
                "full_time",
                "first_half",
                "second_half",
                "first_period",
                "first_quarter",
                "first_set",
                "second_set"
              ],
              "enumTitles": [
                "Full time (incl. overtime where priced so)",
                "1st half",
                "2nd half",
                "1st period",
                "1st quarter",
                "1st set",
                "2nd set"
              ]
            },
            "default": [
              "full_time"
            ]
          },
          "all_lines": {
            "title": "Every line (not only the main one)",
            "type": "boolean",
            "description": "Over/under and handicap markets come in many lines (0.5, 1.5, 2.5 goals…). Off: only each market's main line, the one quoted by the most bookmakers with the most even prices, so you get one comparable row per bookmaker. On: every line, often 5 to 10 times the rows.",
            "default": false
          },
          "include_live_odds": {
            "title": "Add live (in-play) odds",
            "type": "boolean",
            "description": "For matches in play when the run reaches them, also save each bookmaker's in-play prices (rows with odds_type live): about 20 more rows per live match with the default markets. Off by default. Pre-match odds (the closing prices, once a match has started) are saved either way.",
            "default": false
          },
          "max_events": {
            "title": "Max events",
            "minimum": 1,
            "maximum": 1000,
            "type": "integer",
            "description": "For each competition link and for the day: stop after this many matches with odds. Matches without odds are skipped and don't count. Match links are always all read.",
            "default": 20
          },
          "proxy_configuration": {
            "title": "Proxy",
            "type": "object",
            "description": "Leave this off: Flashscore answers the Actor directly, and if it ever refuses, the Actor retries through Apify's datacenter and then residential proxies on its own.",
            "default": {
              "useApifyProxy": false
            }
          }
        }
      },
      "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "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
                  },
                  "PROXY_UNBLOCKER_UNITS": {
                    "type": "integer",
                    "example": 0
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}