getLeagueSeasons

suspend fun getLeagueSeasons(leagueId: String, pagination: PaginationQuery = PaginationQuery()): Deferred<LeagueSeasonList>

Retrieves a list of seasons for a specific league based on the provided leagueId.

Return

A Deferred object representing the list of seasons for the specified league.

Parameters

leagueId

The ID of the league for which to retrieve the list of seasons.

pagination

An optional PaginationQuery object for customizing the pagination of the results.

Throws

If the API is in maintenance.

If the requested league is not found.

If the API returns an unexpected gateway exception.