{
  "openapi": "3.0.1",
  "info": {
    "title": "Sports API - Live Scores, Stats & Odds (Soccer, NBA, NHL, NFL)",
    "description": "Live scores, results and fixtures for soccer, basketball, hockey, American football, baseball, handball and volleyball: statistics, goals and cards, lineups, odds from every bookmaker, head-to-head, league tables and team schedules. Ask by date, league or team; no ids needed.",
    "version": "0.1",
    "x-build-id": "DtVWPzQhWkqhQkmDt"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/akhil_rajesh~sports-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-akhil_rajesh-sports-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/akhil_rajesh~sports-scraper/runs": {
      "post": {
        "operationId": "runs-sync-akhil_rajesh-sports-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/akhil_rajesh~sports-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-akhil_rajesh-sports-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": {
          "mode": {
            "title": "What to get",
            "enum": [
              "matches",
              "competitions",
              "standings",
              "teams"
            ],
            "type": "string",
            "description": "Matches: matches by day (7 days back or forward), live now, or by link. Competitions: every result and fixture of a league or cup season, back many seasons. Standings: league tables, with groups, conferences and divisions. Teams: a team's latest results and next fixtures.",
            "default": "matches"
          },
          "sports": {
            "title": "Sports",
            "type": "array",
            "description": "Which sports to read. Competition and team names are looked up in these sports first; a name only another sport has (NBA with soccer chosen) is read too, and the run says so. Tennis has its own Actor (akhil_rajesh/tennis-scraper).",
            "items": {
              "type": "string",
              "enum": [
                "soccer",
                "basketball",
                "hockey",
                "american-football",
                "baseball",
                "handball",
                "volleyball"
              ],
              "enumTitles": [
                "Soccer (football)",
                "Basketball",
                "Ice hockey",
                "American football",
                "Baseball",
                "Handball",
                "Volleyball"
              ]
            },
            "default": [
              "soccer"
            ]
          },
          "date": {
            "title": "Date",
            "type": "string",
            "description": "Matches mode: 'today', 'yesterday', 'tomorrow' or a date such as 2026-10-05 (UTC). Up to 7 days back or forward.",
            "default": "today"
          },
          "days": {
            "title": "Number of days",
            "minimum": 1,
            "maximum": 15,
            "type": "integer",
            "description": "Matches mode: how many days from the date. 3 with date 'yesterday' reads yesterday, today and tomorrow.",
            "default": 1
          },
          "status": {
            "title": "Match status",
            "type": "array",
            "description": "Keep only live, finished or scheduled matches. Empty keeps all. 'Live' alone reads what's being played now, whatever the date says. In Competitions and Teams modes, 'finished' gives results only and 'scheduled' fixtures only.",
            "items": {
              "type": "string",
              "enum": [
                "live",
                "finished",
                "scheduled"
              ],
              "enumTitles": [
                "Live now",
                "Finished",
                "Scheduled"
              ]
            },
            "default": []
          },
          "competitions": {
            "title": "Competitions",
            "type": "array",
            "description": "Matches mode: keep only these competitions. Competitions and Standings modes: the competitions to read. Use the name as Flashscore writes it ('Premier League', 'LaLiga', 'NBA', 'Champions League'), with the country when the name exists in several ('England: Championship'), a country alone ('Spain') for all its competitions in Matches mode, or a Flashscore competition link. A link to one season ('…/premier-league-2024-2025/') reads that season.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "teams": {
            "title": "Teams",
            "type": "array",
            "description": "Matches and Competitions modes: keep only matches of these teams. Teams mode: the teams to look up. A team name ('Arsenal', 'Lakers', 'Real Madrid') or a Flashscore team link; a name never matches a women's, youth or reserve side unless you write it ('Arsenal W', 'Real Madrid B').",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "matchUrls": {
            "title": "Match links",
            "type": "array",
            "description": "Matches mode: exact matches by Flashscore match link or 8-character match id, of any date and status. When given, the date and filters are not used.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "includeStatistics": {
            "title": "Match statistics",
            "type": "boolean",
            "description": "Each sport's statistics for the whole match and each period: soccer's expected goals, possession, shots, passes and saves; basketball's shooting, rebounds and assists; hockey's shots on goal and power plays; yards and first downs; hits and home runs. Most professional leagues have them.",
            "default": false
          },
          "includeEvents": {
            "title": "Match events",
            "type": "boolean",
            "description": "What happened, in order: goals with scorer, assists and the score after each, cards, substitutions, hockey penalties, touchdowns and field goals, shoot-out attempts. Basketball, baseball, handball and volleyball list period scores only.",
            "default": false
          },
          "includeLineups": {
            "title": "Lineups and missing players",
            "type": "boolean",
            "description": "Formations, starting players and substitutes with shirt numbers, captains, goalkeepers and player ratings, the coaches, and injured or suspended players.",
            "default": false
          },
          "includeOdds": {
            "title": "Odds",
            "type": "boolean",
            "description": "The match-winner odds from every bookmaker Flashscore lists, with the opening price: the average, the best and each bookmaker's price (1X2 in soccer, handball and hockey, the money line elsewhere). For finished matches the price is the closing one.",
            "default": false
          },
          "includeAllOddsMarkets": {
            "title": "All odds markets",
            "type": "boolean",
            "description": "Also over/under, both teams to score, double chance, draw no bet, handicaps, correct score, half time/full time and odd/even, per bookmaker and period. Turns Odds on.",
            "default": false
          },
          "includeHeadToHead": {
            "title": "Head-to-head and form",
            "type": "boolean",
            "description": "Past meetings of the two teams, and each team's last 10 matches with results, counting only what came before this match.",
            "default": false
          },
          "seasons": {
            "title": "Seasons",
            "type": "array",
            "description": "Competitions and Standings modes: seasons to read, written 2024/2025 or, for leagues played in one year, 2025. Empty reads the current season, with its fixtures.",
            "default": [],
            "items": {
              "type": "string"
            }
          },
          "standingsTables": {
            "title": "Tables",
            "type": "array",
            "description": "Standings mode: which tables to read.",
            "items": {
              "type": "string",
              "enum": [
                "overall",
                "home",
                "away",
                "form"
              ],
              "enumTitles": [
                "Overall",
                "Home matches",
                "Away matches",
                "Form (last matches)"
              ]
            },
            "default": [
              "overall"
            ]
          },
          "maxMatchesPerTeam": {
            "title": "Matches per team",
            "minimum": 0,
            "maximum": 500,
            "type": "integer",
            "description": "Teams mode: how many of each team's matches to add, half latest results and half next fixtures (up to about 40 of each are available). 0 returns the team row only.",
            "default": 20
          },
          "onlyChanges": {
            "title": "Only new or changed matches",
            "type": "boolean",
            "description": "For scheduled runs: output only matches that are new since the last run of the same search, or whose status, score, red cards or odds changed. Unchanged matches are not output or charged. Max results caps what each run outputs; the rest come in the next runs. Each search keeps its own history.",
            "default": false
          },
          "historyName": {
            "title": "History name",
            "type": "string",
            "description": "Optional. Name of the store that remembers earlier runs. Empty gives each search its own; set the same name on several schedules to share one."
          },
          "maxResults": {
            "title": "Max results",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "The most matches to return (standings rows per table in Standings mode, where a table split into conferences, divisions or groups is cut only between them). It is shared among the sports, competitions or teams asked for. When a day has more, each sport's best-known competitions come first (World Cup, Champions League, the big leagues, NBA, NHL, NFL, MLB...), then live matches, then by start time; a competition's season gives its latest results first, then its next fixtures.",
            "default": 100
          },
          "proxy": {
            "title": "Proxy",
            "type": "object",
            "description": "Optional. The sources answer ordinary requests, so no proxy is needed. Residential proxies aren't used."
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}