# GET /v2/leagues/{id}/rounds

Group: Leagues

Lists every round of a season and indicates which one is current.

Plans: Every plan, Free included.

Note: Round numbers are not unique across phases — a qualifying round 1 and a league-phase round 1 can coexist — so pass both slug and prefix of the round to /fixtures to hit the right one. Where our data source does not structure a competition in rounds (NBA / NHL regular seasons, individual tennis or MMA events), this list is empty even though fixtures may still have fixture.round set.

## Parameters

| Name | In | Required | Description |
| --- | --- | --- | --- |
| `id` | path | yes | league id issued by DataSportsAPI, a positive integer |
| `season` | query | yes | season id, as listed by /v2/leagues/{id}/seasons |

## Response

- `data`: `Rounds`
- `meta`: season
- Objects: Rounds (https://datasportsapi.com/markdown/reference.md#rounds)

## Errors

- 404 not_found — the season id does not belong to this league; the error message names the offending parameter, and /v2/leagues/{id}/seasons lists the valid ones

Plus the common errors (https://datasportsapi.com/markdown/docs.md#errors).

## Request

cURL:

```bash
curl -H "Authorization: Bearer sk_live_…" \
    "https://api.datasportsapi.com/v2/leagues/{id}/rounds?season=…"
```

TypeScript:

```ts
const { data, meta } = await client.leagues.rounds(id, { season });
```

Python:

```python
res = client.leagues.rounds(id, season=season)
```

Go:

```go
res, err := client.Leagues.Rounds(ctx, id, &datasportsapi.LeaguesRoundsParams{Season: season})
```

CLI:

```bash
$ dsa leagues rounds <id> --season <season>
```

## Example response

```json
{ "data": { "current": { "number": 3, "name": null, "slug": null, "prefix": null },
    "rounds": [ { "number": 1, "name": "Qualification Round 1", "slug": "qualification-round-1", "prefix": null },
                { "number": 636, "name": "Playoff round", "slug": "playoff-round", "prefix": "Qualification" },
                { "number": 1, "name": null, "slug": null, "prefix": null }, … ] },
  "meta": { "season": 200390 } }
```

---

Base URL: https://api.datasportsapi.com. Authenticate each /v2 call with the header `Authorization: Bearer <key>` (secret keys begin with `sk_live_`).
HTML: https://datasportsapi.com/docs/leagues/rounds/ · All docs: https://datasportsapi.com/markdown/docs.md · Data reference: https://datasportsapi.com/markdown/reference.md
