{
  "openapi": "3.0.1",
  "info": {
    "title": "Flashscore Tennis Scraper - Live Scores, Stats, H2H",
    "description": "Tennis data from Flashscore: live scores, schedule and results for ATP, WTA, Challenger, ITF and Davis Cup, with round, rankings, match statistics, point-by-point and head-to-head in every row. Fast, no proxy. Export to Excel, CSV, JSON or API.",
    "version": "0.1",
    "x-build-id": "3aTrEg78E6Jrd6qSi"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/pshivam~flashscore-tennis-scraper/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-pshivam-flashscore-tennis-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/pshivam~flashscore-tennis-scraper/runs": {
      "post": {
        "operationId": "runs-sync-pshivam-flashscore-tennis-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/pshivam~flashscore-tennis-scraper/run-sync": {
      "post": {
        "operationId": "run-sync-pshivam-flashscore-tennis-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": [
              "schedule",
              "live",
              "match"
            ],
            "type": "string",
            "description": "Schedule: every match of the chosen days, upcoming, live and finished. Live: only the matches in play right now. Matches by id: full detail for the match ids or URLs you give.",
            "default": "schedule"
          },
          "daysBack": {
            "title": "Days back",
            "minimum": 0,
            "maximum": 7,
            "type": "integer",
            "description": "Schedule mode: also get this many days before today (finished matches). At most 7.",
            "default": 0
          },
          "daysAhead": {
            "title": "Days ahead",
            "minimum": 0,
            "maximum": 7,
            "type": "integer",
            "description": "Schedule mode: also get this many days after today (upcoming matches). At most 7.",
            "default": 0
          },
          "dates": {
            "title": "Or exact days",
            "type": "array",
            "description": "Schedule mode: days like 2026-11-07, up to 7 days back and 7 days ahead of today. Added to the days above.",
            "items": {
              "type": "string"
            }
          },
          "tours": {
            "title": "Only these tours",
            "type": "array",
            "description": "Keep only these tours. Leave empty for every tour. Grand Slams are listed under ATP and WTA.",
            "items": {
              "type": "string",
              "enum": [
                "atp",
                "wta",
                "challenger",
                "itf",
                "davis_cup",
                "bjk_cup",
                "united_cup",
                "exhibition",
                "other"
              ]
            }
          },
          "matchType": {
            "title": "Singles or doubles",
            "enum": [
              "any",
              "singles",
              "doubles"
            ],
            "type": "string",
            "description": "Keep only singles or only doubles matches.",
            "default": "any"
          },
          "status": {
            "title": "Match status",
            "enum": [
              "any",
              "scheduled",
              "live",
              "finished"
            ],
            "type": "string",
            "description": "Keep only scheduled (not started), live or finished matches. Live mode always means live.",
            "default": "any"
          },
          "players": {
            "title": "Only these players",
            "type": "array",
            "description": "Keep matches where one of the players has one of these names (part of a name is enough: Djokovic, Swiatek).",
            "items": {
              "type": "string"
            }
          },
          "tournaments": {
            "title": "Only these tournaments",
            "type": "array",
            "description": "Keep matches of tournaments whose name or tour contains one of these words (Paris, Challenger, Wimbledon).",
            "items": {
              "type": "string"
            }
          },
          "matchIds": {
            "title": "Match ids or URLs",
            "type": "array",
            "description": "For 'Matches by id': Flashscore match ids (6yDYuIT9) or match URLs (https://www.flashscore.com/match/6yDYuIT9/).",
            "items": {
              "type": "string"
            }
          },
          "includeMatchInfo": {
            "title": "Add round and rankings",
            "type": "boolean",
            "description": "Open the match page for the round (Quarter-finals), both players' ranking and full names. On by default for 'Matches by id', off for lists (one more request per match)."
          },
          "includeStatistics": {
            "title": "Add match statistics",
            "type": "boolean",
            "description": "Aces, double faults, serve and return points, break points and more, for the match and for each set. On by default for 'Matches by id', off for lists."
          },
          "includePointByPoint": {
            "title": "Add point-by-point",
            "type": "boolean",
            "description": "Every game of every set: who served, who won, the points played and the break points. On by default for 'Matches by id', off for lists."
          },
          "includeHeadToHead": {
            "title": "Add head-to-head",
            "type": "boolean",
            "description": "Both players' last 10 matches and their previous meetings. On by default for 'Matches by id', off for lists."
          },
          "onlyNew": {
            "title": "Only new matches",
            "type": "boolean",
            "description": "Skip matches that earlier runs of this same search already returned, so you never get or pay for the same match twice. The first run works as usual and remembers what it returned, in your key-value store 'flashscore-tennis-scraper-only-new'.",
            "default": false
          },
          "maxItems": {
            "title": "Maximum matches",
            "minimum": 1,
            "type": "integer",
            "description": "Stop after this many matches. You are charged per match.",
            "default": 100
          },
          "maxConcurrency": {
            "title": "Max parallel requests",
            "minimum": 1,
            "maximum": 16,
            "type": "integer",
            "description": "Requests at the same time (the scraper never sends more than 20 a second). More helps runs with detail blocks.",
            "default": 8
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}