NFL Rosters, Snap Context, and Cross-Season Player Tracking via REST API
Track NFL franchise moves, snap usage, and multi-season player stats across Sleeper, ESPN, Yahoo, and PFR with OpenPigskin's GSIS-backed REST API.
Why cross-season player tracking breaks when players change teams
NFL rosters turn over relentlessly every March and at the trade deadline. Any analytics table or fantasy database keyed on (team, name) or (team, jersey_number) breaks immediately when veterans switch clubs or rookies inherit vacated numbers.
Real records from OpenPigskin's 24,872-player index illustrate how common this is across just two seasons. Sam Darnold (player_nfl_00-0034869, drafted 2018 Round 1 Pick 3 by NYJ) logged 2024 with MIN (18 games, 4,564 passing yards, 36 TDs, 321.86 PPR) before starting 2025 with SEA (20 games, 4,720 passing yards, 30 TDs, 285.0 PPR). Cooper Kupp (player_nfl_00-0033908, drafted 2017 Round 3 Pick 69 by LA) played 2024 with LA (14 games, 108 targets, 73 receptions, 800 yards, 6 TDs) and 2025 with SEA (19 games, 94 targets, 62 receptions, 750 yards, 3 TDs). Even more subtly, Kenneth Walker III (player_nfl_00-0038134, drafted 2022 Round 2 Pick 41 by SEA) shows team: SEA across his 2024 and 2025 season rows while latest_team is already updated to KC (latest_team_id: team_nfl_kc).
Because OpenPigskin anchors every player permanently to player_nfl_{gsis_id}, career history, splits and cross-platform links stay unified across every franchise move.
Understand what OpenPigskin exposes for roster & player context
OpenPigskin does not publish a separate speculative depth-chart feed or pre-snap practice-report endpoint; instead, it gives you verified, zero-fabrication roster and usage primitives across four endpoints: GET /v1/search (resolve players by name or prefixed external ID), GET /v1/players/{id} (bio, draft metadata, latest_team, external_ids, career totals and year-by-year seasons[] with each season's team), GET /v1/games/{id}/boxscore (exact game participants across passing, rushing, receiving, defense and kicking), and GET /v1/games/{id}/plays (snap-level passer_id, rusher_id and receiver_id involvement).
Keeping latest_team separate from seasons[i].team is deliberate: use latest_team for current team affiliation and seasons[i].team when attributing historical production to a franchise.
{
"data": {
"id": "player_nfl_00-0033908",
"gsis_id": "00-0033908",
"name": "Cooper Kupp",
"position": "WR",
"latest_team": "SEA",
"latest_team_id": "team_nfl_sea",
"jersey_number": 10,
"college": "Eastern Washington",
"draft": { "year": 2017, "round": 3, "pick": 69, "team": "LA" },
"external_ids": {
"gsis": "00-0033908",
"espn": "2977187",
"pfr": "KuppCo00",
"pff": "11824",
"nfl": "44881",
"sleeper": "4039",
"yahoo": "30182",
"rotowire": "11863",
"fantasypros": "16433",
"mfl": "13164"
},
"seasons": [
{ "season": 2025, "team": "SEA", "games": 19, "targets": 94, "rec": 62, "rec_yds": 750, "rec_td": 3, "ppr": 153.0 },
{ "season": 2024, "team": "LA", "games": 14, "targets": 108, "rec": 73, "rec_yds": 800, "rec_td": 6, "ppr": 190.0 }
]
},
"meta": { "source": "nflverse", "licence": "CC BY 4.0" }
}Reconstruct empirical positional depth and usage share from /boxscore
Published depth charts are often outdated by kickoff, whereas game box scores reveal true backfield and receiver hierarchy immediately. By fetching a team's recent games from GET /v1/games?team=SEA&season=2025 and reading GET /v1/games/{id}/boxscore (both available on the free Starter plan), you can rank every running back by carry share and every pass catcher by target share across any rolling window.
In Super Bowl LX (game_nfl_2025_22_SEA_NE), for example, /boxscore immediately quantifies Seattle's bell-cow backfield usage: Kenneth Walker III logged 27 of Seattle's 29 RB carries (135 yards) compared to George Holani's 2 carries (6 yards), while New England split backfield touches between Rhamondre Stevenson (7 rushes, 23 yards) and TreVeyon Henderson (6 rushes, 19 yards).
type Boxscore = {
rushing: { player_id: string; name: string; position: string | null; team: string; attempts: number; yards: number }[];
receiving: { player_id: string; name: string; position: string | null; team: string; targets: number; receptions: number; yards: number }[];
};
export async function teamUsageDepth(teamAbbr: string, gameIds: string[], apiKey: string) {
const rbCarries = new Map<string, { name: string; carries: number; yards: number }>();
const targetShare = new Map<string, { name: string; pos: string | null; targets: number; rec: number }>();
let totalRbCarries = 0;
let totalTargets = 0;
for (const gid of gameIds) {
const res = await fetch(`https://openpigskinapi.com/v1/games/${gid}/boxscore`, {
headers: { Authorization: `Bearer ${apiKey}` },
});
if (!res.ok) continue;
const { data } = (await res.json()) as { data: Boxscore };
for (const r of data.rushing) {
if (r.team !== teamAbbr || r.position !== "RB") continue;
totalRbCarries += r.attempts;
const cur = rbCarries.get(r.player_id) ?? { name: r.name, carries: 0, yards: 0 };
cur.carries += r.attempts;
cur.yards += r.yards;
rbCarries.set(r.player_id, cur);
}
for (const rec of data.receiving) {
if (rec.team !== teamAbbr) continue;
totalTargets += rec.targets;
const cur = targetShare.get(rec.player_id) ?? { name: rec.name, pos: rec.position, targets: 0, rec: 0 };
cur.targets += rec.targets;
cur.rec += rec.receptions;
targetShare.set(rec.player_id, cur);
}
}
return {
backfield: [...rbCarries.entries()]
.map(([player_id, v]) => ({
player_id,
...v,
carryShare: totalRbCarries ? Number((v.carries / totalRbCarries).toFixed(3)) : 0,
}))
.sort((a, b) => b.carries - a.carries),
receivers: [...targetShare.entries()]
.map(([player_id, v]) => ({
player_id,
...v,
targetShare: totalTargets ? Number((v.targets / totalTargets).toFixed(3)) : 0,
}))
.sort((a, b) => b.targets - a.targets),
};
}Add snap-level situational usage from /v1/games/{id}/plays
Total carries and targets do not distinguish a two-minute drill specialist from a short-yardage back. Layering GET /v1/games/{id}/plays (Developer plan and above) onto your box-score roster lets you segment every player_nfl_* ID by down (for example 3rd-down targets), red-zone involvement (yardline_100 <= 20) and quarter.
Because passer_id, rusher_id and receiver_id on /plays use the exact same player_nfl_{gsis_id} primary key as /boxscore and /players/{id}, joining situational play shares back to a player's draft capital, physical profile (height_inches, weight_lbs) or Sleeper/ESPN roster ID requires zero string normalization.
# Look up Matthew Stafford via Sleeper ID 421 -> player_nfl_00-0026498
curl "https://openpigskinapi.com/v1/search?q=sleeper:421&type=player" \
-H "Authorization: Bearer op_live_YOUR_KEY"
# Pull home/away, playoff, indoor/outdoor and opponent splits
curl "https://openpigskinapi.com/v1/players/player_nfl_00-0026498/splits?opponent=SEA" \
-H "Authorization: Bearer op_live_YOUR_KEY"Keep franchise codes consistent across 28 seasons of history
Cross-season player pipelines also fail when historical team abbreviations drift. OpenPigskin normalizes legacy franchise codes at ingest time (OAK to LV, SD to LAC, STL and LAR to LA, WSH to WAS, JAC to JAX) across /v1/teams, /v1/players/{id}, /v1/games and /v1/live.
When syncing an external fantasy league (Sleeper, ESPN, Yahoo or MFL) into your own database, store OpenPigskin's player_nfl_* ID as your canonical foreign key, cache the external_ids map on first lookup, and refresh player profiles weekly during the season to pick up trades and updated career/season totals.