GET/api/v1/people/{personId}/stats/game/{gamePk}
Person game stats
A person’s stat line for a single game.
On this page
Try it
https://statsapi.mlb.com/api/v1/people/660271/stats/game/744914const res = await fetch('https://statsapi.mlb.com/api/v1/people/660271/stats/game/744914')
const data = await res.json()curl -s 'https://statsapi.mlb.com/api/v1/people/660271/stats/game/744914'
Reference
Path parameters
| Name | Type | Required | Description |
|---|---|---|---|
personId | number | yes | Person id, e.g. |
gamePk | number | yes | Game id from the schedule endpoint. |
Response
Type: StatsResponse
/**
* `GET /api/v1/stats`, `/people/{personId}/stats`, and
* `/people/{personId}/stats/game/{gamePk}`.
*/
export interface StatsResponse extends WithCopyright {
stats: StatGroup[]
}Notes
Returns empty
splitsif the person did not appear in that game.
Build with it
Live examples powered by this endpoint with real data. Inspiration — restyle and remix freely.
Single-game line
One player’s batting line for one game.
Loading live data…
Example URLs
- Player stat line in a game:
https://statsapi.mlb.com/api/v1/people/660271/stats/game/744914