Documentation / Teams
Roster
GET /v1/teams/{team_id}/rosterLive and up
The players who dressed for a team in a season, with number, position and games, for leagues with game detail.
GET
https://api.icehockeyapi.com/v1/teams/{team_id}/rosterhttps://api.icehockeyapi.com/v1/teams/tm_kpzj338v/roster?season_id=ss_0n4zhhnacurl "https://api.icehockeyapi.com/v1/teams/tm_kpzj338v/roster?season_id=ss_0n4zhhna" \ -H "X-API-Key: YOUR_KEY"
200 OKExample answer from the data, 12 Oct
{
"data": [
{
"player": {
"id": "pl_5t0tyjwh",
"name": "Gabe Perreault"
},
"number": "94",
"position": "right_wing",
"games": 10
},
{
"player": {
"id": "pl_90ce8vqz",
"name": "Alberts Smits"
},
"number": "63",
"position": "defense",
"games": 10
},
{
"player": {
"id": "pl_9phqbmpc",
"name": "Mika Zibanejad"
},
"number": "93",
"position": "center",
"games": 9
}
],
"meta": {
"count": 45,
"team_id": "tm_kpzj338v",
"season_id": "ss_0n4zhhna",
"plan": "Complete"
}
}Run works once the API is live; the code above works now.
Parameters
| Name | In | Type | What it does |
|---|---|---|---|
team_id required | path | id | A team, from /v1/teams. |
season_id required | query | id | A season, from /v1/leagues/{league_id}/seasons. |
Returns
| Field | Type |
|---|---|
player | object |
player.id | string |
player.name | string |
number | string |
position | string |
games | int |