Team statistics
Retrieve a team's statistics for each league and season it has played in. The response is a list with one entry per league and season.
- Refresh interval
- Immediately once a match is finished
The team id comes from
teams.
fromDate is required and must follow the
YYYY-MM-DD format. Statistics are aggregated from that date onwards, so it
sets the window rather than being a filter you can omit. Pair it with
timezone to have the boundary interpreted in your own location rather than
UTC.
Total, home and away
Each entry holds three sets rather than one. total is the full record
across the window, home covers matches played at home and
away covers the rest.
Each set is shaped the same way. games holds played,
wins, loses and draws, and
goals holds scored and received. So a home and
away split needs no second request and no arithmetic on your side.
Each entry also names the league and season its figures belong to through
leagueId, leagueName and season.
goals holds totals for the league and season rather than per match
averages, so scored and received grow with every match played
in the window.
Parameters
| Parameter | Type | Description |
|---|---|---|
idrequired
|
numberpath | Requested team id. |
fromDaterequired
|
string |
Date that follows the YYYY-MM-DD format.e.g. 2023-08-06
|
timezoneoptional |
stringdefault Etc/UTC
|
Valid timezone identifier.e.g. Europe/London
|
Request
curl --request GET \
--url 'https://handball.highlightly.net/teams/statistics/{id}?fromDate=2023-08-06' \
--header 'x-rapidapi-key: YOUR_API_KEY'
const params = new URLSearchParams({
fromDate: '2023-08-06'
})
const response = await fetch(`https://handball.highlightly.net/teams/statistics/{id}?${params}`, {
headers: {
'x-rapidapi-key': process.env.HIGHLIGHTLY_API_KEY
}
})
if (!response.ok) {
throw new Error(`Highlightly responded ${response.status}`)
}
const data = await response.json()
import os
import requests
response = requests.get(
'https://handball.highlightly.net/teams/statistics/{id}',
params={
'fromDate': '2023-08-06',
},
headers={
'x-rapidapi-key': os.environ['HIGHLIGHTLY_API_KEY'],
},
timeout=10,
)
response.raise_for_status()
data = response.json()
Response
totalHandballTeamTotalStatsResponserequiredTotal game and points statistics corresponding to specific league-season.8 fields
gamesHandballTeamTotalGameStatsResponserequiredNumber of games team has played, won, and lost during a specific
league-season.4 fields
playednumberrequiredNumber of games team has played during a specific league-season.
winsnumberrequiredNumber of games team has won during a specific league-season.
losesnumberrequiredNumber of games team has lost during a specific league-season.
drawsnumberrequiredNumber of games team has played a draw during a specific
league-season.
goalsHandballTeamTotalGoalsStatsResponserequiredNumber of goals team has scored, and received during a specific
league-season.2 fields
scorednumberrequiredNumber of goals team has scored during a specific league-season.
receivednumberrequiredNumber of goals team has received during a specific league-season.
homeHandballTeamHomeStatsResponserequiredGame and point statistics corresponding to specific league-season, where the team
has played as a home team.8 fields
gamesHandballTeamHomeGameStatsResponserequiredNumber of games team has played, won, and lost during a specific
league-season, whilst playing as home team.4 fields
playednumberrequiredNumber of games team has played as home team during a specific
league-season.
winsnumberrequiredNumber of games team has won as home team during a specific
league-season.
losesnumberrequiredNumber of games team has lost as home team during a specific
league-season.
drawsnumberrequiredNumber of games team has played a draw as home team during a specific
league-season.
goalsHandballTeamHomeGoalsStatsResponserequiredNumber of points team has scored and received, during a specific
league-season, whilst playing as away team.2 fields
scorednumberrequiredNumber of goals team has scored whilst playing as home team during a
specific league-season.
receivednumberrequiredNumber of goals team has received whilst playing as home team during a
specific league-season.
awayHandballTeamAwayStatsResponserequiredGame and point statistics corresponding to specific league-season, where the team
has played as an away team.8 fields
gamesHandballTeamAwayGameStatsResponserequiredGame related statistics team has played as away team, during a specific
league-season.4 fields
playednumberrequiredNumber of games team has played as home team during a specific
league-season.
winsnumberrequiredNumber of games team has won as home team during a specific
league-season.
losesnumberrequiredNumber of games team has lost as home team during a specific
league-season.
drawsnumberrequiredNumber of games team has played a draw as home team during a specific
league-season.
goalsHandballTeamAwayGoalsStatsResponserequiredNumber of goals team has scored and received as away team, during a specific
league-season.2 fields
scorednumberrequiredNumber of points team has scored as away team, during a specific
league-season.
receivednumberrequiredNumber of points team has received as away team, during a specific
league-season.
leagueIdnumberrequiredLeague id to which team statistics are associated.
leagueNamestringrequiredLeague name to which team statistics are associated.
seasonnumberrequiredSeason year to which team statistics are associated.
Example response
[
{
"total": {
"games": {
"played": 30,
"wins": 20,
"loses": 7,
"draws": 3
},
"goals": {
"scored": 935,
"received": 815
}
},
"home": {
"games": {
"played": 15,
"wins": 12,
"loses": 1,
"draws": 1
},
"goals": {
"scored": 500,
"received": 399
}
},
"away": {
"games": {
"played": 15,
"wins": 8,
"loses": 6,
"draws": 1
},
"goals": {
"scored": 435,
"received": 416
}
},
"leagueId": 88437,
"leagueName": "Liga ASOBAL",
"season": 2023
}
]
Values are the examples declared in the OpenAPI spec, not a captured live response.
Errors
| Status | Description |
|---|---|
400 |
Bad request descriptive error. |
500 |
Internal server error. |