postreef
All schemas

Sports Highlight

vidextract.predefined.sports_highlight.v1

A sports highlight or match recap extracted from a video. Captures the sport, the teams or competitors, the score, and the notable moments in order. Only record scores, names, and minutes actually shown or stated — omit otherwise.

Fields

sportrequired
string

The sport, lowercased — e.g. 'football', 'basketball', 'tennis'.

competition
string

League, tournament, or friendly if shown — e.g. 'Champions League', 'pre-season friendly'.

teams
string[]

Teams or competitors involved, as shown on the scoreboard or stated.

finalScore
string

Final or current score as shown, e.g. '2-1'. Omit if never displayed.

venue
string

Stadium or city if mentioned. Omit otherwise.

keyMomentsrequired
object[]

Notable plays in the order they happen — goals, saves, fouls, turning points.

summary
string

One or two sentences on how the passage of play unfolded.

JSON Schema

{
  "$schema": "https://json-schema.org/draft/2020-12/schema",
  "$id": "vidextract.predefined.sports_highlight.v1",
  "title": "Sports Highlight",
  "description": "A sports highlight or match recap extracted from a video. Captures the sport, the teams or competitors, the score, and the notable moments in order. Only record scores, names, and minutes actually shown or stated — omit otherwise.",
  "type": "object",
  "required": [
    "sport",
    "keyMoments"
  ],
  "additionalProperties": false,
  "properties": {
    "sport": {
      "type": "string",
      "description": "The sport, lowercased — e.g. 'football', 'basketball', 'tennis'."
    },
    "competition": {
      "type": "string",
      "description": "League, tournament, or friendly if shown — e.g. 'Champions League', 'pre-season friendly'."
    },
    "teams": {
      "type": "array",
      "description": "Teams or competitors involved, as shown on the scoreboard or stated.",
      "items": {
        "type": "string"
      }
    },
    "finalScore": {
      "type": "string",
      "description": "Final or current score as shown, e.g. '2-1'. Omit if never displayed."
    },
    "venue": {
      "type": "string",
      "description": "Stadium or city if mentioned. Omit otherwise."
    },
    "keyMoments": {
      "type": "array",
      "description": "Notable plays in the order they happen — goals, saves, fouls, turning points.",
      "minItems": 1,
      "items": {
        "type": "object",
        "required": [
          "event"
        ],
        "additionalProperties": false,
        "properties": {
          "event": {
            "type": "string",
            "description": "What happened, e.g. 'Header cleared off the line', 'Penalty awarded'."
          },
          "player": {
            "type": "string",
            "description": "Player involved if identifiable. Omit otherwise."
          },
          "team": {
            "type": "string",
            "description": "Team the moment belongs to, if clear. Omit otherwise."
          },
          "minute": {
            "type": "string",
            "description": "Match clock as shown, e.g. \"23'\". Omit if not displayed."
          },
          "videoTimestamp": {
            "type": "string",
            "description": "Start timestamp in the clip, 'mm:ss'. Omit if unknown.",
            "pattern": "^(\\d{1,2}:)?\\d{1,2}:\\d{2}$"
          }
        }
      }
    },
    "summary": {
      "type": "string",
      "description": "One or two sentences on how the passage of play unfolded."
    }
  }
}

Use it via the API

Pass schemaId: "vidextract.predefined.sports_highlight.v1" when you submit an extraction. The call returns an id immediately. Poll GET /v1/extractions/{id}/result (or register a webhook) for the structured result.

curl -s -X POST https://postreef.com/v1/extractions \
  -H "x-api-key: $VIDEXTRACT_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"url": "https://www.youtube.com/watch?v=dQw4w9WgXcQ",
       "inputs": ["transcript", "comments"],
       "schemaId": "vidextract.predefined.sports_highlight.v1"}'

Full request/response shape in the API reference; copy-paste poll loops in the API quickstart.

Pass schemaId: "vidextract.predefined.sports_highlight.v1" in your request to extract with this schema.