{
  "openapi": "3.1.0",
  "info": {
    "title": "Barnburner Spoiler-Free NFL Ratings API",
    "version": "1.0.0",
    "description": "Free, read-only, spoiler-free NFL game watchability ratings (0 to 5 scale). Never returns final scores, winners, post-game standings, comments, or held playoff matchups."
  },
  "servers": [
    {
      "url": "https://api.barnburner.football"
    }
  ],
  "paths": {
    "/api/v1/this-week": {
      "get": {
        "operationId": "getThisWeekNflRatings",
        "summary": "Get the active NFL week's games ranked spoiler-free",
        "responses": {
          "200": {
            "description": "Active week spoiler-free game rankings"
          }
        }
      }
    },
    "/api/v1/weeks/{code}": {
      "get": {
        "operationId": "getWeekNflRatings",
        "summary": "Get spoiler-free ratings for a single 2026 NFL week",
        "parameters": [
          {
            "name": "code",
            "in": "path",
            "required": true,
            "schema": { "type": "string" },
            "description": "Week code: 1..18, wc, div, conf, or sb"
          }
        ],
        "responses": {
          "200": { "description": "Week spoiler-free game rankings" },
          "404": { "description": "Week not found" }
        }
      }
    },
    "/api/v1/games/{id}": {
      "get": {
        "operationId": "getNflGameVerdict",
        "summary": "Get the spoiler-free watchability verdict for a single NFL game",
        "parameters": [
          {
            "name": "id",
            "in": "path",
            "required": true,
            "schema": { "type": "string" },
            "description": "Numeric game ID or canonical Barnburner slug"
          }
        ],
        "responses": {
          "200": { "description": "Spoiler-free game verdict" },
          "404": { "description": "Game not found" }
        }
      }
    },
    "/api/v1/top": {
      "get": {
        "operationId": "getTopNflGames",
        "summary": "Get the highest-rated spoiler-free NFL games of 2026",
        "parameters": [
          {
            "name": "limit",
            "in": "query",
            "schema": { "type": "integer", "minimum": 1, "maximum": 25, "default": 25 }
          },
          {
            "name": "min_rating",
            "in": "query",
            "schema": { "type": "number", "minimum": 0, "maximum": 5, "default": 0 }
          }
        ],
        "responses": {
          "200": { "description": "Top rated games of the season" }
        }
      }
    },
    "/api/v1/teams/{slug}": {
      "get": {
        "operationId": "getTeamSpoilerFreeReplays",
        "summary": "Get spoiler-free replay ratings for a specific NFL team",
        "parameters": [
          {
            "name": "slug",
            "in": "path",
            "required": true,
            "schema": { "type": "string" },
            "description": "Team slug, abbreviation, or nickname (e.g. chicago-bears, CHI, bears)"
          }
        ],
        "responses": {
          "200": { "description": "Team spoiler-free replay rankings" },
          "404": { "description": "Team not found" }
        }
      }
    },
    "/mcp": {
      "get": {
        "operationId": "getMcpDiscovery",
        "summary": "Stateless Streamable-HTTP MCP server discovery document",
        "responses": {
          "200": { "description": "MCP server capabilities and tool list" }
        }
      },
      "post": {
        "operationId": "postMcpJsonRpc",
        "summary": "JSON-RPC 2.0 Streamable-HTTP MCP endpoint",
        "responses": {
          "200": { "description": "JSON-RPC 2.0 response" },
          "202": { "description": "Accepted notification" }
        }
      }
    }
  }
}
