Stats Perform · Schema

Stats Perform Event

Schema for a Stats Perform sports event (game/match) with score and status information.

SportsSports DataFootballBaseballBasketballHockeySoccerGolfTennisLive ScoresStatisticsSports Analytics

Properties

Name Type Description
eventId string Unique event identifier.
startDateTime string Event start date and time.
status string Current event status.
sport string Sport category.
league string League identifier (e.g., nfl, mlb, nba, nhl).
homeTeam object
awayTeam object
homeScore integernull Home team score.
awayScore integernull Away team score.
periods array Period/quarter/inning breakdown of the score.
venue stringnull Venue where the event takes place.
attendance integernull Game attendance.
View JSON Schema on GitHub

JSON Schema

stats-perform-event-schema.json Raw ↑
{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "https://raw.githubusercontent.com/api-evangelist/stats-perform/main/json-schema/stats-perform-event-schema.json",
  "title": "Stats Perform Event",
  "description": "Schema for a Stats Perform sports event (game/match) with score and status information.",
  "type": "object",
  "properties": {
    "eventId": {
      "type": "string",
      "description": "Unique event identifier."
    },
    "startDateTime": {
      "type": "string",
      "format": "date-time",
      "description": "Event start date and time."
    },
    "status": {
      "type": "string",
      "enum": ["pre-event", "in-progress", "final", "postponed", "cancelled"],
      "description": "Current event status."
    },
    "sport": {
      "type": "string",
      "enum": ["football", "baseball", "basketball", "hockey", "soccer", "golf", "tennis"],
      "description": "Sport category."
    },
    "league": {
      "type": "string",
      "description": "League identifier (e.g., nfl, mlb, nba, nhl)."
    },
    "homeTeam": {
      "$ref": "#/$defs/TeamRef"
    },
    "awayTeam": {
      "$ref": "#/$defs/TeamRef"
    },
    "homeScore": {
      "type": ["integer", "null"],
      "minimum": 0,
      "description": "Home team score."
    },
    "awayScore": {
      "type": ["integer", "null"],
      "minimum": 0,
      "description": "Away team score."
    },
    "periods": {
      "type": "array",
      "items": {
        "type": "object",
        "properties": {
          "periodNumber": {
            "type": "integer"
          },
          "homeScore": {
            "type": "integer"
          },
          "awayScore": {
            "type": "integer"
          }
        }
      },
      "description": "Period/quarter/inning breakdown of the score."
    },
    "venue": {
      "type": ["string", "null"],
      "description": "Venue where the event takes place."
    },
    "attendance": {
      "type": ["integer", "null"],
      "description": "Game attendance."
    }
  },
  "required": ["eventId", "startDateTime", "status", "sport", "league"],
  "$defs": {
    "TeamRef": {
      "type": "object",
      "properties": {
        "teamId": {
          "type": "string"
        },
        "name": {
          "type": "string"
        },
        "abbreviation": {
          "type": "string"
        }
      },
      "required": ["teamId", "name"]
    }
  }
}