NHL — NHL Web API — Ppt
nhl_ppt_replay
Pull the replay metadata (game header plus goal, video clip and sprite links) for one game event.
Endpoint URL: GET https://api-web.nhle.com/v1/ppt-replay/{game_id}/{event_number}
Valid URL: https://api-web.nhle.com/v1/ppt-replay/2025020500/261
| API Parameter | Python | Pattern | Required | Nullable | Description |
|---|---|---|---|---|---|
game_id | game_id | Y | game_id path parameter. | ||
event_number | event_number | Y | Event id of the play within the game (the play-by-play event_id). |
Returns
return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.
| col_name | type | description |
|---|---|---|
game_id | Int64 | Unique game identifier. |
game_date | String | Game date. |
game_state | String | Game state (e.g., FINAL, LIVE). |
game_type | Int64 | Game type the row belongs to. |
away_team_abbrev | String | Away team abbreviation. |
away_team_dark_logo | String | URL to the away team dark logo. |
away_team_id | Int64 | Away team identifier. |
away_team_logo | String | URL to the away team logo. |
away_team_name_default | String | Away team common name (default locale, e.g., 'Canadiens'). |
away_team_place_name_default | String | Away team place name (default language). |
away_team_place_name_with_preposition_default | String | Away team place name with preposition (default). |
away_team_place_name_with_preposition_fr | String | Away team place name with preposition (French). |
goal_assists | String | Goal events only (a non-goal event's frame has no goal_* columns). JSON-encoded list of the goal's assists (player id, names, assists to date, sweater number). |
goal_away_score | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Away team's score after the goal. |
goal_event_id | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Play-by-play event id of the goal. |
goal_first_name_default | String | Goal events only (a non-goal event's frame has no goal_* columns). Goal scorer's first name (default locale). |
goal_goal_modifier | String | Goal events only (a non-goal event's frame has no goal_* columns). Modifier the feed attaches to the goal (e.g., 'none'). |
goal_goals_to_date | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Goal scorer's season goal total, counting this goal. |
goal_headshot | String | Goal events only (a non-goal event's frame has no goal_* columns). URL of the goal scorer's headshot image. |
goal_highlight_clip | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Video id of the goal's English highlight clip. |
goal_highlight_clip_fr | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Video id of the goal's French highlight clip. |
goal_highlight_clip_sharing_url | String | Goal events only (a non-goal event's frame has no goal_* columns). NHL.com sharing URL of the goal's English highlight clip. |
goal_highlight_clip_sharing_url_fr | String | Goal events only (a non-goal event's frame has no goal_* columns). NHL.com sharing URL of the goal's French highlight clip. |
goal_home_score | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Home team's score after the goal. |
goal_home_team_defending_side | String | Goal events only (a non-goal event's frame has no goal_* columns). Side of the rink ('left' or 'right') the home team defends in the goal's period. |
goal_is_home | Boolean | Goal events only (a non-goal event's frame has no goal_* columns). True when the scoring team is the home team. |
goal_last_name_default | String | Goal events only (a non-goal event's frame has no goal_* columns). Goal scorer's last name (default locale). |
goal_leading_team_abbrev_default | String | Goal events only (a non-goal event's frame has no goal_* columns). Abbreviation of the team leading after the goal. |
goal_logo_url | String | Goal events only (a non-goal event's frame has no goal_* columns). URL of the scoring team's logo. |
goal_name_default | String | Goal events only (a non-goal event's frame has no goal_* columns). Goal scorer's display name (default locale, e.g., 'Z. Bolduc'). |
goal_period_descriptor_max_regulation_periods | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Number of regulation periods in the game (3). |
goal_period_descriptor_number | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Period the goal was scored in. |
goal_period_descriptor_period_type | String | Goal events only (a non-goal event's frame has no goal_* columns). Type of the period the goal was scored in ('REG', 'OT' or 'SO'). |
goal_player_id | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). NHL player id of the goal scorer. |
goal_ppt_replay_url | String | Goal events only (a non-goal event's frame has no goal_* columns). URL of the goal's puck-and-player tracking replay sprite file. |
goal_shot_type | String | Goal events only (a non-goal event's frame has no goal_* columns). Shot type of the goal (e.g., 'wrist', 'snap', 'slap'). |
goal_situation_code | String | Goal events only (a non-goal event's frame has no goal_* columns). Four-digit on-ice situation code at the goal: away goalie, away skaters, home skaters, home goalie (e.g., '1551'). |
goal_strength | String | Goal events only (a non-goal event's frame has no goal_* columns). Strength the goal was scored at ('ev', 'pp' or 'sh'). |
goal_sweater_number | Int64 | Goal events only (a non-goal event's frame has no goal_* columns). Goal scorer's sweater number. |
goal_team_abbrev_default | String | Goal events only (a non-goal event's frame has no goal_* columns). Abbreviation of the scoring team. |
goal_time_in_period | String | Goal events only (a non-goal event's frame has no goal_* columns). Elapsed time in the period at the goal (MM:SS). |
home_team_abbrev | String | Home team abbreviation. |
home_team_dark_logo | String | URL to the home team dark logo. |
home_team_id | Int64 | Home team identifier. |
home_team_logo | String | URL to the home team logo. |
home_team_name_default | String | Home team common name (default locale, e.g., 'Rangers'). |
home_team_place_name_default | String | Home team place name (default language). |
home_team_place_name_with_preposition_default | String | Home team place name with preposition (default). |
home_team_place_name_with_preposition_fr | String | Home team place name with preposition (French). |
return_parsed=False — the raw JSON payload: a dict, or a list for the endpoints that answer an array (nhl_postal_lookup, nhl_smartlinks).
Raises
| Exception | Description |
|---|---|
NoDataError | The host answered 404 -- the requested resource does not exist. |
ValueError | The host answered 400 / 422 -- the request is wrong; retrying cannot help. |
AssetFetchError | The fetch failed (a non-2xx answer or a connection failure after retries, e.g. 401/403/429/5xx, or an empty or unreadable 200 body) -- the answer is unknown, not empty. |
Example
nhl_ppt_replay(game_id=2025020500, event_number=261)
nhl_ppt_replay_goal
Pull the replay metadata for one goal event (the host redirects to the event replay).
Endpoint URL: GET https://api-web.nhle.com/v1/ppt-replay/goal/{game_id}/{event_number}
Valid URL: https://api-web.nhle.com/v1/ppt-replay/goal/2025020500/261
| API Parameter | Python | Pattern | Required | Nullable | Description |
|---|---|---|---|---|---|
game_id | game_id | Y | game_id path parameter. | ||
event_number | event_number | Y | Event id of the goal within the game (the play-by-play event_id). |
Returns
return_parsed=True (default) — a tidy polars.DataFrame with the columns below; pass return_as_pandas=True for a pandas.DataFrame.
| col_name | type | description |
|---|---|---|
game_id | Int64 | Unique game identifier. |
game_date | String | Game date. |
game_state | String | Game state (e.g., FINAL, LIVE). |
game_type | Int64 | Game type the row belongs to. |
away_team_abbrev | String | Away team abbreviation. |
away_team_dark_logo | String | URL to the away team dark logo. |
away_team_id | Int64 | Away team identifier. |
away_team_logo | String | URL to the away team logo. |
away_team_name_default | String | Away team common name (default locale, e.g., 'Canadiens'). |
away_team_place_name_default | String | Away team place name (default language). |
away_team_place_name_with_preposition_default | String | Away team place name with preposition (default). |
away_team_place_name_with_preposition_fr | String | Away team place name with preposition (French). |
goal_assists | String | JSON-encoded list of the goal's assists (player id, names, assists to date, sweater number). |
goal_away_score | Int64 | Away team's score after the goal. |
goal_event_id | Int64 | Play-by-play event id of the goal. |
goal_first_name_default | String | Goal scorer's first name (default locale). |
goal_goal_modifier | String | Modifier the feed attaches to the goal (e.g., 'none'). |
goal_goals_to_date | Int64 | Goal scorer's season goal total, counting this goal. |
goal_headshot | String | URL of the goal scorer's headshot image. |
goal_highlight_clip | Int64 | Video id of the goal's English highlight clip. |
goal_highlight_clip_fr | Int64 | Video id of the goal's French highlight clip. |
goal_highlight_clip_sharing_url | String | NHL.com sharing URL of the goal's English highlight clip. |
goal_highlight_clip_sharing_url_fr | String | NHL.com sharing URL of the goal's French highlight clip. |
goal_home_score | Int64 | Home team's score after the goal. |
goal_home_team_defending_side | String | Side of the rink ('left' or 'right') the home team defends in the goal's period. |
goal_is_home | Boolean | True when the scoring team is the home team. |
goal_last_name_default | String | Goal scorer's last name (default locale). |
goal_leading_team_abbrev_default | String | Abbreviation of the team leading after the goal. |
goal_logo_url | String | URL of the scoring team's logo. |
goal_name_default | String | Goal scorer's display name (default locale, e.g., 'Z. Bolduc'). |
goal_period_descriptor_max_regulation_periods | Int64 | Number of regulation periods in the game (3). |
goal_period_descriptor_number | Int64 | Period the goal was scored in. |
goal_period_descriptor_period_type | String | Type of the period the goal was scored in ('REG', 'OT' or 'SO'). |
goal_player_id | Int64 | NHL player id of the goal scorer. |
goal_ppt_replay_url | String | URL of the goal's puck-and-player tracking replay sprite file. |
goal_shot_type | String | Shot type of the goal (e.g., 'wrist', 'snap', 'slap'). |
goal_situation_code | String | Four-digit on-ice situation code at the goal: away goalie, away skaters, home skaters, home goalie (e.g., '1551'). |
goal_strength | String | Strength the goal was scored at ('ev', 'pp' or 'sh'). |
goal_sweater_number | Int64 | Goal scorer's sweater number. |
goal_team_abbrev_default | String | Abbreviation of the scoring team. |
goal_time_in_period | String | Elapsed time in the period at the goal (MM:SS). |
home_team_abbrev | String | Home team abbreviation. |
home_team_dark_logo | String | URL to the home team dark logo. |
home_team_id | Int64 | Home team identifier. |
home_team_logo | String | URL to the home team logo. |
home_team_name_default | String | Home team common name (default locale, e.g., 'Rangers'). |
home_team_place_name_default | String | Home team place name (default language). |
home_team_place_name_with_preposition_default | String | Home team place name with preposition (default). |
home_team_place_name_with_preposition_fr | String | Home team place name with preposition (French). |
return_parsed=False — the raw JSON payload: a dict, or a list for the endpoints that answer an array (nhl_postal_lookup, nhl_smartlinks).
Raises
| Exception | Description |
|---|---|
NoDataError | The host answered 404 -- the requested resource does not exist. |
ValueError | The host answered 400 / 422 -- the request is wrong; retrying cannot help. |
AssetFetchError | The fetch failed (a non-2xx answer or a connection failure after retries, e.g. 401/403/429/5xx, or an empty or unreadable 200 body) -- the answer is unknown, not empty. |
Example
nhl_ppt_replay_goal(game_id=2025020500, event_number=261)