Skip to main content

LBA — Lega Basket Serie A site API (www.legabasket.it/api, Italy) — Player

lba_players​

Players of a season, 50 per page (walk the pages with page).

Endpoint URL: GET https://www.legabasket.it/api/players/get-players

Valid URL: https://www.legabasket.it/api/players/get-players?items=50&year=2027

API ParameterPythonPatternRequiredNullableDescription
yearseasonYSeason END year (2027 = 2026-27). Omitted = the site's default season (unverified).
pagepageYPage number, 1-based. Omitted = the first page.

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
seasonintegerSeason END year (2027 = 2026-27): the row's START year + 1.
player_idintegerPlayer id (global).
namecharacterPlayer's given name.
surnamecharacterPlayer's family name.
codecharacterPlayer code SURNAME3-NAME3-YY.
team_namecharacterTeam name in that season, with its sponsor (Nutribullet Treviso Basket); changes with the sponsor.
yearintegerSeason START year (2026 = 2026-27); sdv END year = year + 1. The season of the team the row places the player on.
player_picture_keycharacterImage key: the image is {cdn_url}/{key}, resized copies {cdn_url}/variants/{key}/thumb or /large (the site's getApiImageUrl).

return_parsed=False — the raw JSON Dict payload, unparsed.

Example​

lba_players(season=2027)

Last validated n/a.

lba_player​

Player bio with current-season totals, highs and averages (one row).

Endpoint URL: GET https://www.legabasket.it/api/players/get-player-by-id

Valid URL: https://www.legabasket.it/api/players/get-player-by-id?stats=1&id=969

API ParameterPythonPatternRequiredNullableDescription
idplayer_idYPlayer id (player_id in lba_players or a box score), e.g. 969. Global: one id for a whole career.

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
player_idintegerPlayer id (global).
codecharacterPlayer code SURNAME3-NAME3-YY.
namecharacterPlayer's given name.
surnamecharacterPlayer's family name.
place_of_birthcharacterBirthplace (Italian spelling).
birth_datecharacterBirth date, Date YYYY-MM-DD.
updated_atcharacterTimestamp, ISO-8601 with the Italian offset.
ext_codecharacterExternal (data feed) player code; equals code in the samples.
seo_meta_titlecharacterSEO title (null in the samples).
seo_meta_descriptioncharacterSEO description (null in the samples).
photo_picture_keycharacterImage key: the image is {cdn_url}/{key}, resized copies {cdn_url}/variants/{key}/thumb or /large (the site's getApiImageUrl).
fullbody_picture_keycharacterImage key: the image is {cdn_url}/{key}, resized copies {cdn_url}/variants/{key}/thumb or /large (the site's getApiImageUrl). Null in every sample.
start_datecharacterContract start with the team, Date YYYY-MM-DD.
end_datecharacterContract end with the team, Date YYYY-MM-DD.
player_numbercharacterJersey number, number sent as a string.
uefa_ratiocharacterEligibility class for the foreign-player quota: I, E or C (7 / 6 / 1 on the Treviso roster; reading as Italian / EU / non-EU is inferred).
heightintegerPlayer's height in centimetres.
weightintegerPlayer's weight in kilograms.
team_idintegerTeam id (team-season) of his current team.
player_role_descriptioncharacterPosition, Italian (see players[].player_role of the roster route).
player_alpha3characterNationality, ISO alpha-3.
player_country_namecharacterNationality, Italian country name (Italia = Italy); map to English through player_alpha3 (ISO 3166 alpha-3), not by translating the name.
player_countrycharacterContinent, Italian name (Europa = Europe; the other values are presumably Africa, America, Asia, Oceania, unobserved).
team_codecharacter`\
team_namecharacterTeam name in that season, with its sponsor (Nutribullet Treviso Basket); changes with the sponsor.
yearintegerSeason START year (2026 = 2026-27); sdv END year = year + 1. The season of the team the row places the player on.
team_logo_keycharacterImage key: the image is {cdn_url}/{key}, resized copies {cdn_url}/variants/{key}/thumb or /large (the site's getApiImageUrl).
stats_played_matchesintegerGames played this regular season.
stats_totals_highs_rs_player_idintegerPlayer id (global, one per career).
stats_totals_highs_rs_championship_serie_codecharacterSeries code, A1 = Serie A.
stats_totals_highs_rs_quintet_sumintegerCurrent regular-season total of starts (in the starting five).
stats_totals_highs_rs_points_sumintegerCurrent regular-season total of points.
stats_totals_highs_rs_played_minutes_sumintegerCurrent regular-season total of minutes played.
stats_totals_highs_rs_played_matches_sumintegerCurrent regular-season total of games played.
stats_totals_highs_rs_total_matches_sumintegerCurrent regular-season total of team games while the player was listed (a player with 3 of 21 shows 21; inferred).
stats_totals_highs_rs_done_fouls_sumintegerCurrent regular-season total of fouls committed.
stats_totals_highs_rs_suffered_fouls_sumintegerCurrent regular-season total of fouls drawn.
stats_totals_highs_rs_shots_2p_realized_sumintegerCurrent regular-season total of 2-point field goals made.
stats_totals_highs_rs_shots_2p_total_sumintegerCurrent regular-season total of 2-point field goals attempted.
stats_totals_highs_rs_slam_dunk_sumintegerCurrent regular-season total of dunks.
stats_totals_highs_rs_shots_3p_realized_sumintegerCurrent regular-season total of 3-point field goals made.
stats_totals_highs_rs_shots_3p_total_sumintegerCurrent regular-season total of 3-point field goals attempted.
stats_totals_highs_rs_free_throws_realized_sumintegerCurrent regular-season total of free throws made.
stats_totals_highs_rs_free_throws_total_sumintegerCurrent regular-season total of free throws attempted.
stats_totals_highs_rs_offensive_rebound_sumintegerCurrent regular-season total of offensive rebounds.
stats_totals_highs_rs_defensive_rebound_sumintegerCurrent regular-season total of defensive rebounds.
stats_totals_highs_rs_ball_stop_given_sumintegerCurrent regular-season total of blocks.
stats_totals_highs_rs_ball_stop_received_sumintegerCurrent regular-season total of own shots blocked.
stats_totals_highs_rs_lost_balls_sumintegerCurrent regular-season total of turnovers.
stats_totals_highs_rs_regain_balls_sumintegerCurrent regular-season total of steals.
stats_totals_highs_rs_assists_sumintegerCurrent regular-season total of assists.
stats_totals_highs_rs_rating_lega_sumintegerCurrent regular-season total of LBA efficiency rating (valutazione).
stats_totals_highs_rs_rating_oer_sumnumericOER over the regular season (1.04 for 3 games: an average despite sum`; inferred).
stats_totals_highs_rs_avg_points_sumintegerCurrent regular-season total of plus-minus, despite the name (see the game-log row, where it equals the box score plus_minus).
stats_totals_highs_rs_quintet_maxintegerCurrent regular-season single-game high of starts (in the starting five).
stats_totals_highs_rs_points_maxintegerCurrent regular-season single-game high of points.
stats_totals_highs_rs_played_minutes_maxintegerCurrent regular-season single-game high of minutes played.
stats_totals_highs_rs_done_fouls_maxintegerCurrent regular-season single-game high of fouls committed.
stats_totals_highs_rs_suffered_fouls_maxintegerCurrent regular-season single-game high of fouls drawn.
stats_totals_highs_rs_shots_2p_realized_maxintegerCurrent regular-season single-game high of 2-point field goals made.
stats_totals_highs_rs_shots_2p_total_maxintegerCurrent regular-season single-game high of 2-point field goals attempted.
stats_totals_highs_rs_shots_2p_perc_maxintegerCurrent regular-season single-game high of 2-point field-goal percentage, 0-100.
stats_totals_highs_rs_slam_dunk_maxintegerCurrent regular-season single-game high of dunks.
stats_totals_highs_rs_shots_3p_realized_maxintegerCurrent regular-season single-game high of 3-point field goals made.
stats_totals_highs_rs_shots_3p_total_maxintegerCurrent regular-season single-game high of 3-point field goals attempted.
stats_totals_highs_rs_shots_3p_perc_maxintegerCurrent regular-season single-game high of 3-point field-goal percentage, 0-100.
stats_totals_highs_rs_free_throws_realized_maxintegerCurrent regular-season single-game high of free throws made.
stats_totals_highs_rs_free_throws_total_maxintegerCurrent regular-season single-game high of free throws attempted.
stats_totals_highs_rs_free_throws_perc_maxintegerCurrent regular-season single-game high of free-throw percentage, 0-100.
stats_totals_highs_rs_offensive_rebound_maxintegerCurrent regular-season single-game high of offensive rebounds.
stats_totals_highs_rs_defensive_rebound_maxintegerCurrent regular-season single-game high of defensive rebounds.
stats_totals_highs_rs_total_rebounds_maxintegerCurrent regular-season single-game high of total rebounds.
stats_totals_highs_rs_ball_stop_given_maxintegerCurrent regular-season single-game high of blocks.
stats_totals_highs_rs_ball_stop_received_maxintegerCurrent regular-season single-game high of own shots blocked.
stats_totals_highs_rs_lost_balls_maxintegerCurrent regular-season single-game high of turnovers.
stats_totals_highs_rs_regain_balls_maxintegerCurrent regular-season single-game high of steals.
stats_totals_highs_rs_assists_maxintegerCurrent regular-season single-game high of assists.
stats_totals_highs_rs_rating_lega_maxintegerCurrent regular-season single-game high of LBA efficiency rating (valutazione).
stats_totals_highs_rs_rating_oer_maxnumericCurrent regular-season single-game high of OER (points / (FGA + turnovers + FTA / 2)).
stats_totals_highs_rs_avg_points_maxintegerCurrent regular-season single-game high of plus-minus, despite the name (see the game-log row, where it equals the box score plus_minus).
stats_totals_highs_rs_adp_maxintegerCurrent regular-season single-game high of plus-minus (as match_adp).
stats_totals_highs_rs_idintegerAlways null (not a key).
stats_avg_rs_player_idintegerPlayer id (global, one per career).
stats_avg_rs_championship_serie_codecharacterSeries code, A1 = Serie A.
stats_avg_rs_quintet_avgnumericCurrent regular-season per-game average of starts (in the starting five), number sent as a string.
stats_avg_rs_points_avgnumericCurrent regular-season per-game average of points, number sent as a string.
stats_avg_rs_played_minutes_avgnumericCurrent regular-season per-game average of minutes played, number sent as a string.
stats_avg_rs_played_matches_avgnumericAlways 1.0 (games divided by games), number sent as a string.
stats_avg_rs_total_matches_avgnumericAlways 1.0, number sent as a string.
stats_avg_rs_done_fouls_avgnumericCurrent regular-season per-game average of fouls committed, number sent as a string.
stats_avg_rs_suffered_fouls_avgnumericCurrent regular-season per-game average of fouls drawn, number sent as a string.
stats_avg_rs_shots_2p_realized_avgnumericCurrent regular-season per-game average of 2-point field goals made, number sent as a string.
stats_avg_rs_shots_2p_total_avgnumericCurrent regular-season per-game average of 2-point field goals attempted, number sent as a string.
stats_avg_rs_slam_dunk_avgnumericCurrent regular-season per-game average of dunks, number sent as a string.
stats_avg_rs_shots_3p_realized_avgnumericCurrent regular-season per-game average of 3-point field goals made, number sent as a string.
stats_avg_rs_shots_3p_total_avgnumericCurrent regular-season per-game average of 3-point field goals attempted, number sent as a string.
stats_avg_rs_free_throws_realized_avgnumericCurrent regular-season per-game average of free throws made, number sent as a string.
stats_avg_rs_free_throws_total_avgnumericCurrent regular-season per-game average of free throws attempted, number sent as a string.
stats_avg_rs_offensive_rebound_avgnumericCurrent regular-season per-game average of offensive rebounds, number sent as a string.
stats_avg_rs_defensive_rebound_avgnumericCurrent regular-season per-game average of defensive rebounds, number sent as a string.
stats_avg_rs_ball_stop_given_avgnumericCurrent regular-season per-game average of blocks, number sent as a string.
stats_avg_rs_ball_stop_received_avgnumericCurrent regular-season per-game average of own shots blocked, number sent as a string.
stats_avg_rs_lost_balls_avgnumericCurrent regular-season per-game average of turnovers, number sent as a string.
stats_avg_rs_regain_balls_avgnumericCurrent regular-season per-game average of steals, number sent as a string.
stats_avg_rs_assists_avgnumericCurrent regular-season per-game average of assists, number sent as a string.
stats_avg_rs_rating_lega_avgnumericCurrent regular-season per-game average of LBA efficiency rating (valutazione), number sent as a string.
stats_avg_rs_rating_oer_avgnumericPer-game average OER (a number, unlike the other avg` values).
stats_avg_rs_avg_points_avgnumericCurrent regular-season per-game average of plus-minus, despite the name (see the game-log row, where it equals the box score plus_minus), number sent as a string.
stats_avg_rs_idintegerAlways null (not a key).

return_parsed=False — the raw JSON Dict payload, unparsed.

Example​

lba_player(player_id=969)

Last validated n/a.

lba_player_stats​

A player's career by championship: per-game averages, single-game highs and totals.

Endpoint URL: GET https://www.legabasket.it/api/players/get-player-stats

Valid URL: https://www.legabasket.it/api/players/get-player-stats?id=969

API ParameterPythonPatternRequiredNullableDescription
idplayer_idYPlayer id (player_id in lba_players or a box score), e.g. 969. Global: one id for a whole career.

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
player_idintegerPlayer id (global: one id for a whole career); the request's player.
stat_typecharacterStatistic of the row: avg (per game), max (single-game high) or sum (total).
seasonintegerSeason END year (2027 = 2026-27): the row's START year + 1.
championship_yearintegerSeason START year (2026 = 2026-27); sdv END year = year + 1.
championship_positionintegerDisplay order of the competition within the season (1 = Regular Season; inferred).
championship_namecharacterCompetition name (Regular Season, Play Off, Coppa Italia, ...).
team_namecharacterTeam name in that season, with its sponsor (Nutribullet Treviso Basket); changes with the sponsor.
quintetintegerPer-game average of starts (in the starting five) in that season, competition and team.
pointsnumericPer-game average of points in that season, competition and team.
played_minutesnumericPer-game average of minutes played in that season, competition and team.
played_matchesintegerGames played in that season, competition and team: a count, the same in the avg, max and sum rows.
total_matchesintegerTeam games while the player was listed (a player with 3 of 21 shows 21; inferred) in that season, competition and team: a count, the same in the avg, max and sum rows.
done_foulsintegerPer-game average of fouls committed in that season, competition and team.
suffered_foulsintegerPer-game average of fouls drawn in that season, competition and team.
shots_2p_realizednumericPer-game average of 2-point field goals made in that season, competition and team.
shots_2p_totalintegerPer-game average of 2-point field goals attempted in that season, competition and team.
slam_dunkintegerPer-game average of dunks in that season, competition and team.
shots_3p_realizedintegerPer-game average of 3-point field goals made in that season, competition and team.
shots_3p_totalintegerPer-game average of 3-point field goals attempted in that season, competition and team.
free_throws_realizedintegerPer-game average of free throws made in that season, competition and team.
free_throws_totalintegerPer-game average of free throws attempted in that season, competition and team.
offensive_reboundintegerPer-game average of offensive rebounds in that season, competition and team.
defensive_reboundintegerPer-game average of defensive rebounds in that season, competition and team.
total_reboundintegerPer-game average of total rebounds in that season, competition and team.
ball_stop_givenintegerPer-game average of blocks in that season, competition and team.
ball_stop_receivedintegerPer-game average of own shots blocked in that season, competition and team.
lost_ballsintegerPer-game average of turnovers in that season, competition and team.
regain_ballsintegerPer-game average of steals in that season, competition and team.
assistsintegerPer-game average of assists in that season, competition and team.
rating_legaintegerPer-game average of LBA efficiency rating (valutazione) in that season, competition and team.
rating_oernumericPer-game average of OER (points / (FGA + turnovers + FTA / 2)) in that season, competition and team.
avg_pointsnumericPer-game average of plus-minus, despite the name (see the game-log row, where it equals the box score plus_minus) in that season, competition and team.
aplus_dpintegerPer-game average of aplus_dp, an unverified metric (not plus-minus or assists: Macura 2026-27 has 9 against plus-minus 8 and 3 assists) in that season, competition and team.

return_parsed=False — the raw JSON Dict payload, unparsed.

Example​

lba_player_stats(player_id=969)

Last validated n/a.

lba_players_leaderboard​

Season player leaderboard for one category (per-game average).

Endpoint URL: GET https://www.legabasket.it/api/statistics/get-players-statistics

Valid URL: https://www.legabasket.it/api/statistics/get-players-statistics?cs_id=1&s=2027&cat=points

API ParameterPythonPatternRequiredNullableDescription
sseasonYSeason END year (2027 = 2026-27). Omitted = the site's default season (unverified).
catcategoryYCategory: points, rating_lega, total_rebound, assists, shots_3p_perc, ... (the site's filters.categories).

Returns​

return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.

col_nametypedescription
seasonintegerSeason END year (2027 = 2026-27): the row's START year + 1.
categorycharacterCategory of this row (the cat param, e.g. points).
player_idintegerPlayer id (global, one per career).
namecharacterGiven name (players) / team name (teams).
surnamecharacterPlayer's family name.
team_namecharacterTeam name in that season, with its sponsor (Nutribullet Treviso Basket); changes with the sponsor.
tv_namecharacterShort team name for TV graphics.
yearintegerSeason START year (2026 = 2026-27); sdv END year = year + 1.
category_filter_totalintegerSeason total in the category.
attemptsintegerShots attempted in the zone, parsed from num.
presencesintegerGames the player appeared in, counted for the leaderboard.
minutesnumericMinutes per game (players: decimal string 28.67) / total minutes (teams: integer).
score_40_minnumericValue per 40 minutes.
scorenumericValue in the category under the ob order (default avg = per game); players send a decimal string, teams a number.
team_idintegerTeam id (team-season).
player_photo_keycharacterImage key: the image is {cdn_url}/{key}, resized copies {cdn_url}/variants/{key}/thumb or /large (the site's getApiImageUrl).

return_parsed=False — the raw JSON Dict payload, unparsed.

Example​

lba_players_leaderboard(category='points', season=2027)

Last validated n/a.