How-to build a schedule page
Welcome to the how-to build a season fixture schedule guide. This is a follow-up on the rounds, groups and stages tutorial. Rounds, groups and stages are, in fact, the building blocks of a season schedule. Now, in this how-to guide, we will use those building blocks to create a season fixture schedule. This schedule will show all the fixtures yet to come. We’ll show you how to create a season fixture schedule for the English Premier League (league id: 8) and one for the Champions League (league id: 2).

Step 1: Assemble the tools

You’re going to need the following tools:
  • Sportmonks API token
  • Code editor (Visual studio used in examples)
  • Postman (optional)

Step 2: Request the rounds of the English Premier League

We chose the English Premier League because it’s a domestic league without any different stages or groups, but it does have multiple rounds across their season. That’s why we’re going to request the rounds of the English Premier League season 20/21 (season id: 17420). We’ll use the following URL:
Request
Response
1
https://soccer.sportmonks.com/api/v2.0/seasons/17420?api_token={API_TOKEN}&include=rounds
Copied!
1
{
2
"data": {
3
"id": 17420,
4
"name": "2020/2021",
5
"league_id": 8,
6
"is_current_season": true,
7
"current_round_id": 201970,
8
"current_stage_id": 77448322,
9
"rounds": {
10
"data": [
11
{
12
"id": 201963,
13
"name": 1,
14
"league_id": 8,
15
"season_id": 17420,
16
"stage_id": 77448322,
17
"start": "2020-09-12",
18
"end": "2020-09-14"
19
},
20
{
21
"id": 201964,
22
"name": 2,
23
"league_id": 8,
24
"season_id": 17420,
25
"stage_id": 77448322,
26
"start": "2020-09-19",
27
"end": "2020-09-21"
28
},
29
{
30
"id": 201965,
31
"name": 3,
32
"league_id": 8,
33
"season_id": 17420,
34
"stage_id": 77448322,
35
"start": "2020-09-26",
36
"end": "2020-09-28"
37
},
38
{
39
"id": 201966,
40
"name": 4,
41
"league_id": 8,
42
"season_id": 17420,
43
"stage_id": 77448322,
44
"start": "2020-10-03",
45
"end": "2020-10-04"
46
},
47
{
48
"id": 201967,
49
"name": 5,
50
"league_id": 8,
51
"season_id": 17420,
52
"stage_id": 77448322,
53
"start": "2020-10-17",
54
"end": "2020-10-19"
55
},
56
{
57
"id": 201968,
58
"name": 6,
59
"league_id": 8,
60
"season_id": 17420,
61
"stage_id": 77448322,
62
"start": "2020-10-23",
63
"end": "2020-10-26"
64
},
65
{
66
"id": 201969,
67
"name": 7,
68
"league_id": 8,
69
"season_id": 17420,
70
"stage_id": 77448322,
71
"start": "2020-10-30",
72
"end": "2020-11-02"
73
},
74
{
75
"id": 201970,
76
"name": 8,
77
"league_id": 8,
78
"season_id": 17420,
79
"stage_id": 77448322,
80
"start": "2020-11-06",
81
"end": "2020-11-08"
82
},
83
{
84
"id": 201971,
85
"name": 9,
86
"league_id": 8,
87
"season_id": 17420,
88
"stage_id": 77448322,
89
"start": "2020-11-21",
90
"end": "2020-11-23"
91
},
92
{
93
"id": 201972,
94
"name": 10,
95
"league_id": 8,
96
"season_id": 17420,
97
"stage_id": 77448322,
98
"start": "2020-11-27",
99
"end": "2020-11-30"
Copied!
Now that we have all the English Premier League rounds, we want to check which fixture ids are associated with each round. Here are several examples of correct requests:
Request 1
Response 1
Request 2
Response 2
Request 3
Response 3
1
https://soccer.sportmonks.com/api/v2.0/seasons/17420?api_token={API_TOKEN}&include=rounds.fixtures
Copied!
1
{
2
"data": {
3
"id": 17420,
4
"name": "2020/2021",
5
"league_id": 8,
6
"is_current_season": true,
7
"current_round_id": 201970,
8
"current_stage_id": 77448322,
9
"rounds": {
10
"data": [
11
{
12
"id": 201963,
13
"name": 1,
14
"league_id": 8,
15
"season_id": 17420,
16
"stage_id": 77448322,
17
"start": "2020-09-12",
18
"end": "2020-09-14",
19
"fixtures": {
20
"data": [
21
{
22
"id": 16924595,
23
"league_id": 8,
24
"season_id": 17420,
25
"stage_id": 77448322,
26
"round_id": 201963,
27
"group_id": null,
28
"aggregate_id": null,
29
"venue_id": 200,
30
"referee_id": null,
31
"localteam_id": 27,
32
"visitorteam_id": 14,
33
"winner_team_id": null,
34
"weather_report": {
35
"code": "rain",
36
"type": "light rain",
37
"icon": "https://cdn.sportmonks.com/images/weather/10n.png",
38
"temperature": {
39
"temp": 54.34,
40
"unit": "fahrenheit"
41
},
42
"temperature_celcius": {
43
"temp": 12.4,
44
"unit": "celcius"
45
},
46
"clouds": "100%",
47
"humidity": "95%",
48
"pressure": 1012,
49
"wind": {
50
"speed": "3 m/s",
51
"degree": 257
52
},
53
"coordinates": {
54
"lat": 53.8,
55
"lon": -2.23
56
},
57
"updated_at": "2020-09-11T21:45:05.220485Z"
58
},
59
"commentaries": false,
60
"attendance": null,
61
"pitch": null,
62
"details": null,
63
"neutral_venue": false,
64
"winning_odds_calculated": false,
65
"formations": {
66
"localteam_formation": null,
67
"visitorteam_formation": null
68
},
69
"scores": {
70
"localteam_score": 0,
71
"visitorteam_score": 0,
72
"localteam_pen_score": null,
73
"visitorteam_pen_score": null,
74
"ht_score": null,
75
"ft_score": null,
76
"et_score": null,
77
"ps_score": null
78
},
79
"time": {
80
"status": "POSTP",
81
"starting_at": {
82
"date_time": "2020-09-12 00:00:00",
83
"date": "2020-09-12",
84
"time": "00:00:00",
85
"timestamp": 1599868800,
86
"timezone": "UTC"
87
},
88
"minute": null,
89
"second": null,
90
"added_time": null,
91
"extra_minute": null,
92
"injury_time": null
93
},
94
"coaches": {
95
"localteam_coach_id": 455461,
96
"visitorteam_coach_id": 524307
97
},
98
"standings": {
99
"localteam_position": 4,
100
"visitorteam_position": 13
101
},
102
"assistants": {
103
"first_assistant_id": null,
104
"second_assistant_id": null,
105
"fourth_official_id": null
106
},
107
"leg": "1/1",
108
"colors": null,
109
"deleted": false
110
},
Copied!
1
https://soccer.sportmonks.com/api/v2.0/seasons/17420?api_token={API_TOKEN}&include=fixtures.localTeam,fixtures.visitorTeam
Copied!
1
{
2
"data": {
3
"id": 17420,
4
"name": "2020/2021",
5
"league_id": 8,
6
"is_current_season": true,
7
"current_round_id": 201970,
8
"current_stage_id": 77448322,
9
"fixtures": {
10
"data": [
11
{
12
"id": 16924595,
13
"league_id": 8,
14
"season_id": 17420,
15
"stage_id": 77448322,
16
"round_id": 201963,
17
"group_id": null,
18
"aggregate_id": null,
19
"venue_id": 200,
20
"referee_id": null,
21
"localteam_id": 27,
22
"visitorteam_id": 14,
23
"winner_team_id": null,
24
"weather_report": {
25
"code": "rain",
26
"type": "light rain",
27
"icon": "https://cdn.sportmonks.com/images/weather/10n.png",
28
"temperature": {
29
"temp": 54.34,
30
"unit": "fahrenheit"
31
},
32
"temperature_celcius": {
33
"temp": 12.4,
34
"unit": "celcius"
35
},
36
"clouds": "100%",
37
"humidity": "95%",
38
"pressure": 1012,
39
"wind": {
40
"speed": "3 m/s",
41
"degree": 257
42
},
43
"coordinates": {
44
"lat": 53.8,
45
"lon": -2.23
46
},
47
"updated_at": "2020-09-11T21:45:05.220485Z"
48
},
49
"commentaries": false,
50
"attendance": null,
51
"pitch": null,
52
"details": null,
53
"neutral_venue": false,
54
"winning_odds_calculated": false,
55
"formations": {
56
"localteam_formation": null,
57
"visitorteam_formation": null
58
},
59
"scores": {
60
"localteam_score": 0,
61
"visitorteam_score": 0,
62
"localteam_pen_score": null,
63
"visitorteam_pen_score": null,
64
"ht_score": null,
65
"ft_score": null,
66
"et_score": null,
67
"ps_score": null
68
},
69
"time": {
70
"status": "POSTP",
71
"starting_at": {
72
"date_time": "2020-09-12 00:00:00",
73
"date": "2020-09-12",
74
"time": "00:00:00",
75
"timestamp": 1599868800,
76
"timezone": "UTC"
77
},
78
"minute": null,
79
"second": null,
80
"added_time": null,
81
"extra_minute": null,
82
"injury_time": null
83
},
84
"coaches": {
85
"localteam_coach_id": 455461,
86
"visitorteam_coach_id": 524307
87
},
88
"standings": {
89
"localteam_position": 4,
90
"visitorteam_position": 13
91
},
92
"assistants": {
93
"first_assistant_id": null,
94
"second_assistant_id": null,
95
"fourth_official_id": null
96
},
97
"leg": "1/1",
98
"colors": null,
99
"deleted": false,
100
"localTeam": {
101
"data": {
102
"id": 27,
103
"legacy_id": 387,
104
"name": "Burnley",
105
"short_code": "BUR",
106
"twitter": "@BurnleyOfficial",
107
"country_id": 462,
108
"national_team": false,
109
"founded": 1882,
110
"logo_path": "https://cdn.sportmonks.com/images//soccer/teams/27/27.png",
111
"venue_id": 200,
112
"current_season_id": 17420
113
}
114
},
115
"visitorTeam": {
116
"data": {
117
"id": 14,
118
"legacy_id": 375,
119
"name": "Manchester United",
120
"short_code": "MUN",
121
"twitter": "@ManUtd",
122
"country_id": 462,
123
"national_team": false,
124
"founded": 1878,
125
"logo_path": "https://cdn.sportmonks.com/images//soccer/teams/14/14.png",
126
"venue_id": 206,
127
"current_season_id": 17420
128
}
129
}
Copied!
1
https://soccer.sportmonks.com/api/v2.0/rounds/201970?api_token={API_TOKEN}&include=fixtures.localTeam,fixtures.visitorTeam
Copied!
1
{
2
"data": {
3
"id": 201970,
4
"name": 8,
5
"league_id": 8,
6
"season_id": 17420,
7
"stage_id": 77448322,
8
"start": "2020-11-06",
9
"end": "2020-11-08",
10
"fixtures": {
11
"data": [
12
{
13
"id": 16924666,
14
"league_id": 8,
15
"season_id": 17420,
16
"stage_id": 77448322,
17
"round_id": 201970,
18
"group_id": null,
19
"aggregate_id": null,
20
"venue_id": 480,
21
"referee_id": 15241,
22
"localteam_id": 78,
23
"visitorteam_id": 27,
24
"winner_team_id": null,
25
"weather_report": {
26
"code": "clear",
27
"type": "clear sky",
28
"icon": "https://cdn.sportmonks.com/images/weather/01n.png",
29
"temperature": {
30
"temp": 47.01,
31
"unit": "fahrenheit"
32
},
33
"temperature_celcius": {
34
"temp": 8.3,
35
"unit": "celcius"
36
},
37
"clouds": "0%",
38
"humidity": "81%",
39
"pressure": 1023,
40
"wind": {
41
"speed": "6.93 m/s",
42
"degree": 80
43
},
44
"coordinates": {
45
"lat": 50.86,
46
"lon": -0.08
47
},
48
"updated_at": "2020-11-06T19:15:05.909812Z"
49
},
50
"commentaries": true,
51
"attendance": 0,
52
"pitch": null,
53
"details": null,
54
"neutral_venue": false,
55
"winning_odds_calculated": true,
56
"formations": {
57
"localteam_formation": "5-3-2",
58
"visitorteam_formation": "4-4-2"
59
},
60
"scores": {
61
"localteam_score": 0,
62
"visitorteam_score": 0,
63
"localteam_pen_score": null,
64
"visitorteam_pen_score": null,
65
"ht_score": "0-0",
66
"ft_score": "0-0",
67
"et_score": null,
68
"ps_score": null
69
},
70
"time": {
71
"status": "FT",
72
"starting_at": {
73
"date_time": "2020-11-06 17:30:00",
74
"date": "2020-11-06",
75
"time": "17:30:00",
76
"timestamp": 1604683800,
77
"timezone": "UTC"
78
},
79
"minute": 93,
80
"second": null,
81
"added_time": null,
82
"extra_minute": null,
83
"injury_time": null
84
},
85
"coaches": {
86
"localteam_coach_id": 452683,
87
"visitorteam_coach_id": 455461
88
},
89
"standings": {
90
"localteam_position": 16,
91
"visitorteam_position": 20
92
},
93
"assistants": {
94
"first_assistant_id": 12090,
95
"second_assistant_id": 14665,
96
"fourth_official_id": 13561
97
},
98
"leg": "1/1",
99
"colors": {
100
"localteam": {
101
"color": "#002B87",
102
"kit_colors": "#002B87,#F0F0F0,#F0F0F0,#F0F0F0,#F0F0F0,#FFDF1B,#F0F0F0"
103
},
104
"visitorteam": {
105
"color": "#FBED32",
106
"kit_colors": "#FBED32,#FBED32,#262626,#262626,#C40010,#0046A8,#940014"
107
}
108
},
109
"deleted": false,
110
"localTeam": {
111
"data": {
112
"id": 78,
113
"legacy_id": 409,
114
"name": "Brighton & Hove Albion",
115
"short_code": "BRH",
116
"twitter": "@OfficialBHAFC",
117
"country_id": 462,
118
"national_team": false,
119
"founded": 1901,
120
"logo_path": "https://cdn.sportmonks.com/images//soccer/teams/14/78.png",
121
"venue_id": 480,
122
"current_season_id": 17420
123
}
124
},
125
"visitorTeam": {
126
"data": {
127
"id": 27,
128
"legacy_id": 387,
129
"name": "Burnley",
130
"short_code": "BUR",
131
"twitter": "@BurnleyOfficial",
132
"country_id": 462,
133
"national_team": false,
134
"founded": 1882,
135
"logo_path": "https://cdn.sportmonks.com/images//soccer/teams/27/27.png",
136
"venue_id": 200,
137
"current_season_id": 17420
138
}
139
}
Copied!
Request 3 is used when you want to request the fixtures of a specific round id.
In this example, the EPL only has one stage, but other leagues may have multiple stages. In that case, we suggest you use the following request:
1
https://soccer.sportmonks.com/api/v2.0/seasons/17420?api_token={API_TOKEN}&include=stages.rounds.fixtures.localTeam,stages.rounds.fixtures.visitorTeam
Copied!
Your request may be too big, if that's the case, pagination will kick in. You can refer to our Pagination tutorial for more information
Our Football API 2.0 has now given you the data of every round of the English Premier League and every fixture per round. This is the data you need to create the seasonal fixture schedule of the English Premier League.
In step 3, we’re going to show you how you can do the same for the Champions League, which will be significantly harder because the Champions League works with rounds, groups and stages.

Step 3: Request the Champions League stages

Let's take a look at the Champions League season 20/21 (season id: 17299). We start from a top position. We first request all the stages and can then work-out all the fixtures per stage and group.
Request
Response
1
https://soccer.sportmonks.com/api/v2.0/seasons/17299?api_token={API_TOKEN}&include=stages
Copied!
1
{
2
"data": {
3
"id": 17299,
4
"name": "2020/2021",
5
"league_id": 2,
6
"is_current_season": true,
7
"current_round_id": 211704,
8
"current_stage_id": 77448760,
9
"stages": {
10
"data": [
11
{
12
"id": 77447933,
13
"name": "Final",
14
"type": "Knock Out",
15
"league_id": 2,
16
"season_id": 17299,
17
"sort_order": 11,
18
"has_standings": false
19
},
20
{
21
"id": 77447934,
22
"name": "Semi-finals",
23
"type": "Knock Out",
24
"league_id": 2,
25
"season_id": 17299,
26
"sort_order": 10,
27
"has_standings": false
28
},
29
{
30
"id": 77447935,
31
"name": "Quarter-finals",
32
"type": "Knock Out",
33
"league_id": 2,
34
"season_id": 17299,
35
"sort_order": 9,
36
"has_standings": false
37
},
38
{
39
"id": 77447936,
40
"name": "8th Finals",
41
"type": "Knock Out",
42
"league_id": 2,
43
"season_id": 17299,
44
"sort_order": 8,
45
"has_standings": false
46
},
47
{
48
"id": 77448760,
49
"name": "Group Stage",
50
"type": "Group Stage",
51
"league_id": 2,
52
"season_id": 17299,
53
"sort_order": 7,
54
"has_standings": true
55
},
56
{
57
"id": 77447937,
58
"name": "Play-offs",
59
"type": "Qualifying",
60
"league_id": 2,
61
"season_id": 17299,
62
"sort_order": 6,
63
"has_standings": false
64
},
65
{
66
"id": 77447938,
67
"name": "3rd Qualifying Round",
68
"type": "Qualifying",
69
"league_id": 2,
70
"season_id": 17299,
71
"sort_order": 5,
72
"has_standings": false
73
},
74
{
75
"id": 77447939,
76
"name": "2nd Qualifying Round",
77
"type": "Qualifying",
78
"league_id": 2,
79
"season_id": 17299,
80
"sort_order": 4,
81
"has_standings": false
82
},
83
{
84
"id": 77447940,
85
"name": "1st Qualifying Round",
86
"type": "Qualifying",
87
"league_id": 2,
88
"season_id": 17299,
89
"sort_order": 3,
90
"has_standings": false
91
},
92
{
93
"id": 77447941,
94
"name": "Preliminary Round - Final",
95
"type": "Knock Out",
96
"league_id": 2,
97
"season_id": 17299,
98
"sort_order": 2,
99
"has_standings": false
100
},
101
{
102
"id": 77447942,
103
"name": "Preliminary Round - Semi-finals",
104
"type": "Knock Out",
105
"league_id": 2,
106
"season_id": 17299,
107
"sort_order": 1,
108
"has_standings": false
109
}
110
]
111
}
112
},
Copied!
We can see that the Champions League has the following stages:
  • Preliminary round - Semi-finals
  • Preliminary round - Final
  • 1st Qualifying round
  • 2nd Qualifying round
  • 3rd Qualifying round
  • Play-offs
  • Group Stage
  • 8th Finals
  • Quarter-finals
  • Semi-finals
  • Final

Requesting the fixtures

While, yes, we can use the nested include.fixturesagain. This would result in a huge, hard to read response. You can see for yourself with the following request that will give you an overview of everything about the Champions League:
1
https://soccer.sportmonks.com/api/v2.0/seasons/17299?api_token={API_TOKEN}&include=stages.rounds.fixtures.localTeam,stages.rounds.fixtures.visitorTeam
Copied!
Instead, we will use the get stage by id endpoint with fixtures as include:
Request
Response
1
https://soccer.sportmonks.com/api/v2.0/stages/77447942?api_token={API_TOKEN}&include=fixtures.localTeam,fixtures.visitorTeam
Copied!
1
{
2
"data": {
3
"id": 77447942,
4
"name": "Preliminary Round - Semi-finals",
5
"type": "Knock Out",
6
"league_id": 2,
7
"season_id": 17299,
8
"sort_order": 1,
9
"has_standings": false,
10
"fixtures": {
11
"data": [
12
{
13
"id": 16744816,
14
"league_id": 2,
15
"season_id": 17299,
16
"stage_id": 77447942,
17
"round_id": null,
18
"group_id": null,
19
"aggregate_id": null,
20
"venue_id": 6276,
21
"referee_id": 32453,
22
"localteam_id": 5444,
23
"visitorteam_id": 260,
24
"winner_team_id": 260,
25
"weather_report": {
26
"code": "clouds",
27
"type": "few clouds",
28
"icon": "https://cdn.sportmonks.com/images/weather/02d.png",
29
"temperature": {
30
"temp": 85.82,
31
"unit": "fahrenheit"
32
},
33
"temperature_celcius": {
34
"temp": 29.9,
35
"unit": "celcius"
36
},
37
"clouds": "20%",
38
"humidity": "38%",
39
"pressure": 1019,
40
"wind": {
41
"speed": "6.93 m/s",
42
"degree": 60
43
},
44
"coordinates": {
45
"lat": 46.38,
46
"lon": 6.24
47
},
48
"updated_at": "2020-08-08T14:45:08.788657Z"
49
},
50
"commentaries": false,
51
"attendance": null,
52
"pitch": null,
53
"details": null,
54
"neutral_venue": false,
55
"winning_odds_calculated": true,
56
"formations": {
57
"localteam_formation": "4-3-3",
58
"visitorteam_formation": "4-2-3-1"
59
},
60
"scores": {
61
"localteam_score": 0,
62
"visitorteam_score": 2,
63
"localteam_pen_score": null,
64
"visitorteam_pen_score": null,
65
"ht_score": "0-0",
66
"ft_score": "0-2",
67
"et_score": null,
68
"ps_score": null
69
},
70
"time": {
71
"status": "FT",
72
"starting_at": {
73
"date_time": "2020-08-08 13:00:00",
74
"date": "2020-08-08",
75
"time": "13:00:00",
76
"timestamp": 1596891600,
77
"timezone": "UTC"
78
},
79
"minute": 90,
80
"second": null,
81
"added_time": null,
82
"extra_minute": null,
83
"injury_time": null
84
},
85
"coaches": {
86
"localteam_coach_id": 4598949,
87
"visitorteam_coach_id": 524279
88
},
89
"standings": {
90
"localteam_position": 2,
91
"visitorteam_position": 1
92
},
93
"assistants": {
94
"first_assistant_id": 19343,
95
"second_assistant_id": 14520,
96
"fourth_official_id": 36286
97
},
98
"leg": "1/1",
99
"colors": null,
100
"deleted": false,
101
"localTeam": {
102
"data": {
103
"id": 5444,
104
"legacy_id": null,
105
"name": "Tre Fiori",
106
"short_code": null,
107
"twitter": null,
108
"country_id": 3347,
109
"national_team": false,
110
"founded": 1949,
111
"logo_path": "https://cdn.sportmonks.com/images//soccer/teams/4/5444.png",
112
"venue_id": 3598,
113
"current_season_id": 16007
114
}
115
},
116
"visitorTeam": {
117
"data": {
118
"id": 260,
119
"legacy_id": 1929,
120
"name": "Linfield",
121
"short_code": null,
122
"twitter": null,
123
"country_id": 491,
124
"national_team": false,
125
"founded": 1886,
126
"logo_path": "https://cdn.sportmonks.com/images//soccer/teams/4/260.png",
127
"venue_id": 8014,
128
"current_season_id": 17602
129
}
130
}
Copied!
This will request all the fixtures of the preliminary round - semi-finals (stage id #77447942). You can repeat this step for all the other stages, except for the group stages. Because there are eight groups (A-H), we want to subdivide this stage (stage id #77448760) into their respective groups. We use the nested include groups.fixtures:
Request
Response
1
https://soccer.sportmonks.com/api/v2.0/stages/77448760?api_token={API_TOKEN}&include=groups.fixtures
Copied!
1
{
2
"data": {
3
"id": 77448760,
4
"name": "Group Stage",
5
"type": "Group Stage",
6
"league_id": 2,
7
"season_id": 17299,
8
"sort_order": 7,
9
"has_standings": true,
10
"groups": {
11
"data": [
12
{
13
"id": 244365,
14
"name": "Group A",
15
"league_id": 2,
16
"season_id": 17299,
17