{
  "openapi": "3.0.1",
  "info": {
    "title": "Sports Injury Report API — NFL, NBA, MLB, NHL",
    "description": "Every injured player in NFL, NBA, MLB, NHL and WNBA as rows: status, body part, surgery, expected return date and the analyst note — joined to the games each team is about to play, so you see which side takes the field short-handed. No API key or login.",
    "version": "0.1",
    "x-build-id": "yQNKWC84V2m5ZIeQ9"
  },
  "servers": [
    {
      "url": "https://api.apify.com/v2"
    }
  ],
  "paths": {
    "/acts/lergassy~sports-injuries-api/run-sync-get-dataset-items": {
      "post": {
        "operationId": "run-sync-get-dataset-items-lergassy-sports-injuries-api",
        "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/lergassy~sports-injuries-api/runs": {
      "post": {
        "operationId": "runs-sync-lergassy-sports-injuries-api",
        "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/lergassy~sports-injuries-api/run-sync": {
      "post": {
        "operationId": "run-sync-lergassy-sports-injuries-api",
        "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": [
              "injuries",
              "teams",
              "games"
            ],
            "type": "string",
            "description": "<b>Injuries</b> — one row per injured player with the body part, the surgery and the expected return date. <b>Teams</b> — one row per team: how many are hurt, how many are actually out, and who. <b>Games</b> — the upcoming schedule with each side's injury load next to it, so you can see which team takes the field short-handed.",
            "default": "injuries"
          },
          "leagues": {
            "title": "🏆 Leagues",
            "type": "array",
            "description": "ESPN keeps injury lists for the North American leagues. Soccer and college basketball have none, so those are not offered.",
            "items": {
              "type": "string",
              "enum": [
                "nfl",
                "nba",
                "mlb",
                "nhl",
                "wnba",
                "ncaaf"
              ],
              "enumTitles": [
                "NFL",
                "NBA",
                "MLB",
                "NHL",
                "WNBA",
                "College football"
              ]
            },
            "default": [
              "nfl",
              "nba",
              "mlb",
              "nhl"
            ]
          },
          "outOnly": {
            "title": "🚫 Only players who will not play",
            "type": "boolean",
            "description": "Keeps Out, Injured Reserve, the IL lists and suspensions, and drops Questionable and Day-To-Day. This is usually what you want when the question is who is missing.",
            "default": false
          },
          "includeActive": {
            "title": "📰 Include ESPN’s notes about healthy players",
            "type": "boolean",
            "description": "ESPN’s feed also carries roster notes about players who are fine — depth-chart moves, contract news — under the status <b>Active</b>, with no injury and no return date. They are dropped by default so you are not paying for rows that are not injuries. Turn this on to get ESPN’s whole note feed.",
            "default": false
          },
          "statuses": {
            "title": "📋 Statuses",
            "type": "array",
            "description": "Exact statuses to keep, such as <code>Out</code>, <code>Questionable</code>, <code>Doubtful</code>, <code>Day-To-Day</code>, <code>Injured Reserve</code>. Leave empty for all of them.",
            "items": {
              "type": "string"
            }
          },
          "teams": {
            "title": "🏟️ Teams",
            "type": "array",
            "description": "Team names or abbreviations, such as <code>Kansas City Chiefs</code> or <code>KC</code>. Leave empty for every team.",
            "items": {
              "type": "string"
            }
          },
          "positions": {
            "title": "🎽 Positions",
            "type": "array",
            "description": "Positions to keep, such as <code>QB</code>, <code>Quarterback</code>, <code>Point Guard</code>. Leave empty for all.",
            "items": {
              "type": "string"
            }
          },
          "daysAhead": {
            "title": "📅 Days ahead (games mode)",
            "minimum": 0,
            "maximum": 60,
            "type": "integer",
            "description": "How far forward the schedule goes in Games mode. 0 means today only.",
            "default": 7
          },
          "includePlayers": {
            "title": "👥 List every injured player, not just those out",
            "type": "boolean",
            "description": "Teams and Games modes: include the full injured list inside each row, alongside the players who are definitely out.",
            "default": true
          },
          "maxItems": {
            "title": "🔢 Maximum rows",
            "minimum": 1,
            "maximum": 100000,
            "type": "integer",
            "description": "Stops the run once this many rows are in the dataset.",
            "default": 5000
          },
          "proxyConfiguration": {
            "title": "🌐 Proxy",
            "type": "object",
            "description": "Not needed — ESPN answers Apify's own network directly. Only turn this on if your account requires all traffic through a proxy.",
            "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
                  }
                }
              },
              "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
                  }
                }
              }
            }
          }
        }
      }
    }
  }
}