thesportsdb-client
    Preparing search index...

    Interface League

    A league or cup. Lists (all_leagues.php, v2 search/league) fill only a few fields; look it up by id for the rest.

    interface League {
        alternateNames: readonly string[];
        apiFootballId: number | null;
        apiFootballV3Id: number | null;
        badge: string | null;
        banner: string | null;
        country: string | null;
        currentSeason: string | null;
        description: string | null;
        descriptions: Readonly<Record<string, string>>;
        division: number | null;
        eventNaming: string | null;
        fanart: readonly string[];
        firstEventDate: string | null;
        formedYear: number | null;
        gender: string | null;
        id: number | null;
        isComplete: boolean | null;
        isCup: boolean | null;
        isLocked: boolean | null;
        kind: "League";
        logo: string | null;
        name: string | null;
        poster: string | null;
        raw: RawRecord;
        socials: Socials;
        sport: string | null;
        trophy: string | null;
        tvRights: string | null;
    }

    Hierarchy (View Summary)

    Index
    alternateNames: readonly string[]

    strLeagueAlternate, split on commas

    apiFootballId: number | null

    idAPIfootball

    apiFootballV3Id: number | null

    idAPIfootballv3

    badge: string | null

    strBadge

    banner: string | null

    strBanner

    country: string | null

    strCountry

    currentSeason: string | null

    strCurrentSeason, e.g. 2026-2027 or 2026. Pass it to season endpoints.

    description: string | null

    The English description.

    descriptions: Readonly<Record<string, string>>

    strDescriptionEN, strDescriptionDE, ... keyed by language code (EN, DE)

    division: number | null

    intDivision: 1 for a top flight; cups often use 0 or 99

    eventNaming: string | null

    strNaming: the event-name template, e.g. {strHomeTeam} vs {strAwayTeam}

    fanart: readonly string[]

    strFanart1..strFanart4

    firstEventDate: string | null

    dateFirstEvent (YYYY-MM-DD)

    formedYear: number | null

    intFormedYear

    gender: string | null

    strGender

    id: number | null

    idLeague

    isComplete: boolean | null

    strComplete: whether TheSportsDB considers its data complete

    isCup: boolean | null

    idCup: true for a cup competition

    isLocked: boolean | null

    strLocked

    kind: "League"
    logo: string | null

    strLogo

    name: string | null

    strLeague

    poster: string | null

    strPoster

    raw: RawRecord

    Every field as the API sent it (blank strings as null). Use it for unmodelled fields: team.raw["strKeywords"].

    socials: Socials
    sport: string | null

    strSport

    trophy: string | null

    strTrophy

    tvRights: string | null

    strTvRights: free text