League Table

get
Get All Tables for a League Season

https://api.footystats.org/league-tables?key=YOURKEY&season_id=X
Sample Response (Access URL below) https://api.footystats.org/league-tables?key=example&season_id=2012 This endpoint returns all of the League Tables applicable to a league season. Endpoint will return multiple tables if they exist in a league.
Request
Response
Request
Query Parameters
max_time
optional
integer
UNIX Timestamp of the time in which you like the table for. For example, 1553476090 is the Unix representation of March 25, 2019. This will get you the table for that exact point in time.
key
required
string
The API will do its best to find a cake matching the provided recipe.
season_id
required
integer
League season ID
Response
200: OK
Cake successfully retrieved.
{
success: true,
data: {
all_matches_table_overall: [],
all_matches_table_home: [ ],
all_matches_table_away: [ ],
specific_tables: [
{
round: "1st Qualifying Round",
table: null,
groups: null
},
{
round: "Group Stage",
table: null,
groups: [
{
name: "Group A",
table: [
{
id: "76",
seasonGoals_home: 5,
seasonGoals_away: 5,
seasonConceded_away: 2,
seasonConceded_home: 4,
seasonGoals: 10,
points: 11,
seasonConceded: 6,
seasonGoalDifference: 4,
seasonWins_home: 1,
seasonWins_away: 2,
seasonWins_overall: 3,
seasonDraws_home: 1,
seasonDraws_away: 1,
seasonDraws_overall: 2,
seasonLosses_away: 0,
seasonLosses_overall: 1,
seasonLosses_home: 1,
matchesPlayed: 6,
name: "Villarreal CF",
country: null,
cleanName: "Villarreal",
shortHand: "villarreal-cf",
url: "/clubs/spain/villarreal-cf",
seasonURL_overall: "/clubs/spain/villarreal-cf",
seasonURL_home: "/clubs/spain/villarreal-cf",
seasonURL_away: "/clubs/spain/villarreal-cf",
position: 1,
zone: [ ],
corrections: 0,
wdl_record: "wddwwl"
},

You can test this API call by using the key "example" and loading the league tables from the English Premier League 2018/2019 season (ID: 1625).

Variable

Explanation

league_table

If the league only has a single round with no play-off matches (ie Premier League), the League Table is stored here.

Returns NULL if the league is a Cup format.

all_matches_table_overall

Full table across all matches played during the season. For example, if this is a cup competition, then we will generate a table with all teams across all the matches that they've played. This is not necessarily the league table.

all_matches_table_home / all_matches_table_away

Full table only taking into account either Home matches or Away matches.

specific_tables

Array. Contains tables for each round of a season. Many leagues in the world have multiple rounds with league tables during 1 season.

ie Uruguay Primera Division

Apertura - Table

Intermediate Round - Group Tables

Clausura - Table

Final Play-Offs - NULL (no table)

ie Championship Regular Season - Table

Play-Offs - NULL (no table)

ie UEFA Champions League

Qualification Matches - NULL (no table)

Group Round - Table for each group

8th Finals - NULL (no table)

Quarter Finals - NULL (no table)