{
  "openapi": "3.0.1",
  "info": {
    "title": "Sofascore Scraper: Match Stats, Player Ratings & Standings",
    "description": "Sofascore match data in analysis-ready rows: fixtures and results by date, league or team, match statistics with xG, one row per player per match with rating, standings, player season stats. No start fee, from $2 per 1,000 rows.",
    "version": "0.0",
    "x-build-id": "6EqBk6AX4OxEfiwxZ"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/scrapebench~sofascore-match-stats-player-ratings-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-scrapebench-sofascore-match-stats-player-ratings-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/scrapebench~sofascore-match-stats-player-ratings-scraper/runs": {
      "post": {
        "operationId": "runs-sync-scrapebench-sofascore-match-stats-player-ratings-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/scrapebench~sofascore-match-stats-player-ratings-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-scrapebench-sofascore-match-stats-player-ratings-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",
              "match_details",
              "standings",
              "player_stats",
              "search"
            ],
            "type": "string",
            "description": "matches: the matches of a date, the live matches, a league's round, or a team's last/next matches (one row per match). match_details: everything about the matches you list (statistics with xG, incidents, lineups, one row per player with rating). standings: a league table. player_stats: a player's profile and season statistics. search: find a league, team or player by name.",
            "default": "matches"
          },
          "sport": {
            "title": "Sport",
            "enum": [
              "football",
              "basketball",
              "tennis",
              "ice-hockey",
              "american-football",
              "baseball",
              "volleyball",
              "handball",
              "rugby",
              "cricket",
              "esports",
              "table-tennis",
              "futsal",
              "darts",
              "snooker",
              "motorsport",
              "mma"
            ],
            "type": "string",
            "description": "For matches by date or live. Football by default.",
            "default": "football"
          },
          "date": {
            "title": "Date",
            "type": "string",
            "description": "A day as YYYY-MM-DD, or today / yesterday / tomorrow (UTC). For matches mode. Leave empty with no league or team for today's matches."
          },
          "dates": {
            "title": "Dates",
            "type": "array",
            "description": "Several days (YYYY-MM-DD). Each day is one batch entry; maxResults applies per entry.",
            "items": {
              "type": "string"
            }
          },
          "liveOnly": {
            "title": "Live matches only",
            "type": "boolean",
            "description": "Matches mode: the matches in play right now for the sport, instead of a date.",
            "default": false
          },
          "league": {
            "title": "League",
            "type": "string",
            "description": "A league by name (Premier League, LaLiga, NBA, Champions League) or its Sofascore id / link. Matches mode: narrows a date to this league, or with no date lists the current round. Standings mode: the table."
          },
          "leagues": {
            "title": "Leagues",
            "type": "array",
            "description": "Several leagues, each one batch entry.",
            "items": {
              "type": "string"
            }
          },
          "season": {
            "title": "Season",
            "type": "string",
            "description": "Standings and player stats: a season as the site writes it (25/26, 2025) or its id. Empty = the current season."
          },
          "team": {
            "title": "Team",
            "type": "string",
            "description": "Matches mode: a team by name (Arsenal) or id / link; returns its recent and upcoming matches."
          },
          "teams": {
            "title": "Teams",
            "type": "array",
            "description": "Several teams, each one batch entry.",
            "items": {
              "type": "string"
            }
          },
          "match": {
            "title": "Match",
            "type": "string",
            "description": "Match details mode: a match link (any Sofascore match link, including plain /event/<id> links) or its numeric id."
          },
          "matches": {
            "title": "Matches",
            "type": "array",
            "description": "Several match links or ids, each one batch entry.",
            "items": {
              "type": "string"
            }
          },
          "player": {
            "title": "Player",
            "type": "string",
            "description": "Player stats mode: a player by name (Haaland), id or link."
          },
          "players": {
            "title": "Players",
            "type": "array",
            "description": "Several players, each one batch entry.",
            "items": {
              "type": "string"
            }
          },
          "query": {
            "title": "Search",
            "type": "string",
            "description": "Search mode: a name to look up (league, team or player)."
          },
          "queries": {
            "title": "Searches",
            "type": "array",
            "description": "Several names, each one batch entry.",
            "items": {
              "type": "string"
            }
          },
          "includeMatchStats": {
            "title": "Add match statistics to match rows",
            "type": "boolean",
            "description": "Matches mode: also return one match statistics row (xG, shots, possession by period, incidents, fan votes, head-to-head, displayed odds) per finished match. Charged per match. Always on in match details mode.",
            "default": false
          },
          "includePlayerRatings": {
            "title": "Add player ratings to match rows",
            "type": "boolean",
            "description": "Matches mode: also return one row per player per finished match (rating, minutes, goals, assists, xG, xA, passes...). Charged once per match, not per player. Always on in match details mode.",
            "default": false
          },
          "standingsView": {
            "title": "Standings view",
            "enum": [
              "total",
              "home",
              "away"
            ],
            "type": "string",
            "description": "total, home or away table.",
            "default": "total"
          },
          "maxResults": {
            "title": "Max matches / rows per entry",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Per entry (each date, league, team, match, player or search): at most this many matches (matches mode) or rows. A free notice says how many more there were.",
            "default": 100
          },
          "proxyConfiguration": {
            "title": "Proxy configuration",
            "type": "object",
            "description": "Apify residential proxy by default, which this actor needs. Change it only to supply your own residential proxies.",
            "default": {
              "useApifyProxy": true,
              "apifyProxyGroups": [
                "RESIDENTIAL"
              ]
            }
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}