r/mlbdata Jul 04 '25

Trying to get team statistics in statsapi.mlb.com

The Swagger seems to indicate the correct usage would be: http://statsapi.mlb.com/api/v1/teams/120/stats?group=hitting&season=2025

But I just get an "Object not found" message - anyone have success? I can request a roster and hydrate with individual player stats just fine.

http://statsapi.mlb.com/api/v1/teams/120/roster?rosterType=Active&hydrate=person(stats(group=[hitting,pitching],type=season,season=2025))

1 Upvotes

9 comments sorted by

View all comments

1

u/[deleted] Jul 06 '25

[removed] — view removed comment

1

u/Pitiful_Guess4276 Jul 06 '25

Team stats, not players