MLB Stats API Docs

Type to search endpoints by name, path, or keyword.

GET/api/v1/teams/{teamId}

Get team by id

A single team by its id.

On this page

Try it

Path
Query
https://statsapi.mlb.com/api/v1/teams/119?season=2026
const res = await fetch('https://statsapi.mlb.com/api/v1/teams/119?season=2026')
const data = await res.json()
curl -s 'https://statsapi.mlb.com/api/v1/teams/119?season=2026'

Reference

Path parameters

NameTypeRequiredDescription
teamIdnumberyes

Team id, e.g. 119 (Los Angeles Dodgers).

Query parameters

NameTypeRequiredDescription
seasonnumberno

Four-digit year.

hydratecsvno

Comma-separated hydrations.

fieldscsvno

Comma-separated field paths to keep (trims the response), e.g. teams,id,name.

Response

Type: TeamsResponse

/** `GET /api/v1/teams` */
export interface TeamsResponse extends WithCopyright {
	teams: Team[]
}

Notes

  • Like the list endpoint, the single-team response is still wrapped in a teams array of length 1.

Build with it

Live examples powered by this endpoint with real data. Inspiration — restyle and remix freely.

Team card

Logo, ballpark, division, and founding year — a team identity badge.

Loading live data…

Example URLs

  • Dodgers (2026): https://statsapi.mlb.com/api/v1/teams/119?season=2026