{
  "openapi": "3.0.1",
  "info": {
    "title": "Tennis Match Tracker: Results, Form, H2H & Stats",
    "description": "Tennis results, fixtures and live matches across ATP, WTA, Challenger and ITF. Every match comes with both players' recent form, surface record, head-to-head and serve and return statistics, measured before the match started. No API key, no proxy.",
    "version": "0.1",
    "x-build-id": "M7yuCEvU9qfzOqSPh"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/precious_bathmat~tennis-match-tracker/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-precious_bathmat-tennis-match-tracker",
        "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/precious_bathmat~tennis-match-tracker/runs": {
      "post": {
        "operationId": "runs-sync-precious_bathmat-tennis-match-tracker",
        "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/precious_bathmat~tennis-match-tracker/run-sync": {
      "post": {
        "operationId": "run-sync-precious_bathmat-tennis-match-tracker",
        "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": {
          "categories": {
            "title": "Tours and events",
            "type": "array",
            "description": "Which levels of tennis to include. Singles and doubles are separate choices.",
            "items": {
              "type": "string",
              "enum": [
                "atp-singles",
                "wta-singles",
                "atp-doubles",
                "wta-doubles",
                "challenger-men-singles",
                "challenger-women-singles",
                "challenger-men-doubles",
                "challenger-women-doubles",
                "itf-men-singles",
                "itf-women-singles",
                "itf-men-doubles",
                "itf-women-doubles",
                "teams",
                "other"
              ],
              "enumTitles": [
                "ATP singles",
                "WTA singles",
                "ATP doubles",
                "WTA doubles",
                "Challenger men's singles",
                "Challenger women's singles",
                "Challenger men's doubles",
                "Challenger women's doubles",
                "ITF men's singles",
                "ITF women's singles",
                "ITF men's doubles",
                "ITF women's doubles",
                "Team events (Davis Cup, Billie Jean King Cup, Laver Cup)",
                "Everything else (juniors, exhibitions)"
              ]
            },
            "default": [
              "atp-singles",
              "wta-singles"
            ]
          },
          "daysBack": {
            "title": "Days back",
            "minimum": 0,
            "maximum": 7,
            "type": "integer",
            "description": "How many days of results to include before today (UTC). 0 means today only. Flashscore keeps seven.",
            "default": 1
          },
          "daysAhead": {
            "title": "Days ahead",
            "minimum": 0,
            "maximum": 7,
            "type": "integer",
            "description": "How many days of upcoming matches to include after today (UTC). Matches usually appear only once the order of play is published, so more than one or two days ahead is often thin.",
            "default": 1
          },
          "status": {
            "title": "Match status",
            "enum": [
              "all",
              "finished",
              "upcoming",
              "live"
            ],
            "type": "string",
            "description": "Completed matches include retirements and walkovers; each row says which.",
            "default": "all"
          },
          "players": {
            "title": "Players",
            "type": "array",
            "description": "Only matches involving these players. Surname is enough (\"Sinner\"), full names and accents are handled. Leave empty for every player.",
            "items": {
              "type": "string"
            }
          },
          "tournaments": {
            "title": "Tournaments",
            "type": "array",
            "description": "Only these tournaments, by any part of the name, e.g. \"Tokyo\" or \"Shanghai\". Leave empty for all.",
            "items": {
              "type": "string"
            }
          },
          "includeQualifying": {
            "title": "Include qualifying matches",
            "type": "boolean",
            "description": "Qualifying rounds are listed separately by Flashscore and each row is flagged.",
            "default": true
          },
          "includeForm": {
            "title": "Add form and head-to-head",
            "type": "boolean",
            "description": "Each player's recent record, record on this surface, streak, days since last match and matches in the last 14 days, plus their head-to-head. Measured before the match started. Charged as a match insight.",
            "default": true
          },
          "formMatches": {
            "title": "Form window (matches)",
            "minimum": 3,
            "maximum": 50,
            "type": "integer",
            "description": "How many previous completed matches the form figures use.",
            "default": 10
          },
          "includeStats": {
            "title": "Add match statistics",
            "type": "boolean",
            "description": "Aces, double faults, serve and return points won, break points and more, for matches that have been played. Many ITF matches have none.",
            "default": true
          },
          "maxMatches": {
            "title": "Maximum matches",
            "minimum": 1,
            "maximum": 5000,
            "type": "integer",
            "description": "Stops after this many matches, earliest first.",
            "default": 300
          }
        }
      },
      "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}