Skip to content

Match statistics and lineups of a tournament match

GET
/api/public/tournament-match/{id}/stats
curl --request GET \
--url https://foxleague.ai/api/public/tournament-match/example/stats

The statistics of a tournament or challenge match, asked by its public id (matches[].id of GET /api/tournaments/{id}), in the shape of GET /api/matches/{id}/stats. From the kickoff until its broadcast ends it answers the lineup-only form gated: true with player_names, for the live viewer; once the broadcast ends, the full analysis.

Who: anyone. A session header that is present but invalid answers 401.

Refusals:

  • Match not found: no such public id; a match before its kickoff; a next-round match while a match that sends one of its teams there is still on air.
  • No stats available for this match: the result is public but no analysis exists for the match.
id
required
string

The match’s public id (matches[].id of the tournament): 22 URL-safe characters.

Success or a refusal: read success (the refusals are in the description).

Media type application/json
object
code

A machine-readable reason next to error, set only where the caller must act differently. tx_pending: the payment was not refused but could not be verified yet; keep the transaction hash and confirm again with the same hash, never pay twice.

string | null
data

The answer. Present when success is true.

object
analyzer

Name of the analysis.

string
away_formation

The away side’s formation, when known.

string
away_lineup

The away squad, when known, in the same form as home_lineup.

gated

true on the lineup-only form; absent on the full analysis.

boolean
goals

Every goal with its time, side and scorer.

Array
home_formation

The home side’s formation, when known.

string
home_lineup

The home squad, when known: formation, lineup and substitutes (NFT nonces) and players with each card’s attributes, level, condition and portrait.

match

Teams (left_team, right_team), final_score, penalties (null without a shootout), decided_by and the match’s length.

object
player_names

Map of home-<n> or away-<n> (the player’s number on the pitch, 1 to 11) to {name, shirt_number, country} of the card.

object
player_slot_identities

Map of squad slot (0 to 17 home, 18 to 35 away) to {name, shirt_number, country} of the card, for the viewer.

object
player_types

Technical data of the recording; not needed to show the match.

object
players

Per-player statistics for left and right.

object
possession

Ball possession in percent: overall, first_half and second_half, each with left and right.

object
server_params

Technical data of the recording; not needed to show the match.

object
team_stats

Team totals for left and right: shots, passes, tackles, saves, fouls, corners, cards and more.

object
timeline

The match’s events in order.

Array
version

Version of the analysis format.

string
error

Why the request was refused, in plain words. Present when success is false.

string | null
success
required

true when the request did what it asked. false is a refusal: read error.

boolean
Example
{
"data": {
"gated": true,
"player_names": {
"away-10": {
"country": 19,
"name": "Teo Brandt",
"shirt_number": 10
},
"home-9": {
"country": 7,
"name": "Marco Vela",
"shirt_number": 9
}
}
},
"success": true
}

No valid session. The body is plain text: Missing Authorization header, Invalid Authorization format, Invalid session token or Session expired or invalid. Sign in again.

Media type text/plain
string
Example
Session expired or invalid

A server read failed. The body is empty.