ESPN API endpoint
Returns the full team list for a sport and league. The `sport` enum accepts `football`, `basketball`, `baseball`, `hockey`, and `soccer`. The `league` enum accepts `nfl`, `college-football`, `nba`, `wnba`, `mens-college-basketball`, `womens-college-basketball`, `mlb`, `nhl`, `eng.1`, `esp.1`, `ita.1`, `ger.1`, `fra.1`, `usa.1`, and `uefa.champions`; it must be valid for the chosen sport.
/espn/teamsQuery parameters:
sport: required enum. Allowed values: football, basketball, baseball, hockey, soccer.league: required enum, must be valid for the chosen sport. Allowed values: nfl, college-football, nba, wnba, mens-college-basketball, womens-college-basketball, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, usa.1, uefa.champions.Notable response behavior:
200 with zero teams.sport/league values return an invalid-parameter error before upstream IO.| Field | Filled in, of 30 checked | Values in the sample |
|---|---|---|
| id | 30 | |
| uid | 30 | |
| abbreviation | 30 | “ATL” and 29 other values |
| display_name | 30 | |
| short_display_name | 30 | |
| name | 30 | “Hawks” and 29 other values |
| location | 30 | “Atlanta” and 29 other values |
| color | 30 | “c8102e” and 26 other values |
| alternate_color | 30 | “fdb927” and 22 other values |
| logo | 30 | a.espncdn.com |
| Parameter | Type | Required | Default | Description | Example |
|---|---|---|---|---|---|
| sport | string | Yes | Sport key Allowed values: football, basketball, baseball, hockey, soccer. | basketball | |
| league | string | Yes | League key (must be valid for the sport) Allowed values: nfl, college-football, nba, wnba, mens-college-basketball, womens-college-basketball, mlb, nhl, eng.1, esp.1, ita.1, ger.1, fra.1, usa.1, uefa.champions. | nba | |
| x-api-key (header) | string | Yes | API key required |
curl -X GET "https://api.crawlora.net/api/v1/espn/teams?sport=basketball&league=nba" \ -H "x-api-key: $CRAWLORA_API_KEY"
{
"code": 200,
"msg": "OK",
"data": {
"sport": "basketball",
"league": "nba",
"count": 30,
"source_url": "https://site.api.espn.com/apis/site/v2/sports/basketball/nba/teams",
"fetched_at": "2026-07-06T00:00:00Z",
"teams": [
{
"id": "1",
"abbreviation": "ATL",
"display_name": "Atlanta Hawks",
"location": "Atlanta",
"logo": "https://a.espncdn.com/i/teamlogos/nba/500/atl.png"
}
]
}
}Request schema
No body schema
Response schema
#/definitions/espn.teamsResponseDoc
| Field | Type | Required | Enum | Bounds | Example | Description |
|---|---|---|---|---|---|---|
| code | integer | No | 200 | |||
| data | espn.TeamsResponse | No | ||||
| data.count | integer | No | 32 | Number of teams returned. | ||
| data.fetched_at | string | No | Time the data was fetched, in UTC (RFC 3339). | |||
| data.league | string | No | League key that was requested, for example `nfl`. | |||
| data.source_url | string | No | URL the data was read from. | |||
| data.sport | string | No | Sport key that was requested, for example `football`. | |||
| data.teams | array | No | Teams in the league, one entry per team. | |||
| data.teams[].abbreviation | string | No | KC | Short team code, for example `KC`. | ||
| data.teams[].alternate_color | string | No | Team's secondary colour code, as ESPN gives it. | |||
| data.teams[].color | string | No | Team's primary colour code, as ESPN gives it. | |||
| data.teams[].display_name | string | No | Kansas City Chiefs | Full team name, for example `Kansas City Chiefs`. | ||
| data.teams[].id | string | No | 12 | ESPN team id, for example `12`. Use it as the `team` parameter of the team and roster endpoints. | ||
| data.teams[].location | string | No | Kansas City | Team's city or region, for example `Kansas City`. | ||
| data.teams[].logo | string | No | URL of the team logo image. | |||
| data.teams[].name | string | No | Chiefs | Team nickname without the location, for example `Chiefs`. | ||
| data.teams[].short_display_name | string | No | Chiefs | Shortened team name, for example `Chiefs`. | ||
| data.teams[].uid | string | No | ESPN's unique identifier string for the team. | |||
| msg | string | No | OK |
| Status | Description | Schema |
|---|---|---|
| 400 | Bad Request | #/definitions/app.Response |
| 404 | Not Found | #/definitions/app.Response |
| 429 | Too Many Requests | #/definitions/app.Response |
| 503 | Service Unavailable | #/definitions/app.Response |
Use environment variables for secrets and keep Crawlora API keys server-side.
curl -X GET "https://api.crawlora.net/api/v1/espn/teams?sport=basketball&league=nba" \
-H "x-api-key: $CRAWLORA_API_KEY"