Skip to content

Latest commit

 

History

History
1129 lines (1030 loc) · 31.9 KB

File metadata and controls

1129 lines (1030 loc) · 31.9 KB

LeaguesService

A list of all methods in the LeaguesService service. Click on the method name to view detailed information about that method.

Methods Description
get_leagues List leagues
get_leagues_league_id_or_slug Get a single league by ID or by slug
get_leagues_league_id_or_slug_matches List matches of the given league
get_leagues_league_id_or_slug_matches_past List past matches for the given league
get_leagues_league_id_or_slug_matches_running List currently running matches for the given league
get_leagues_league_id_or_slug_matches_upcoming List upcoming matches for the given league
get_leagues_league_id_or_slug_series List series for the given league
get_leagues_league_id_or_slug_tournaments List tournaments of the given league

get_leagues

List leagues

  • HTTP Method: GET
  • Endpoint: /leagues

Parameters

Name Type Required Description
filter FilterOverLeagues Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverLeagues Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverLeagues Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[League]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverLeagues, RangeOverLeagues, SearchOverLeagues

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
filter=FilterOverLeagues(
    id_=[
        7
    ],
    modified_at=[
        "offici"
    ],
    name=[
        "ad ut"
    ],
    slug=[
        "p_"
    ],
    url=[
        "esse aliqu"
    ]
)
range=RangeOverLeagues(
    id_=[
        10
    ],
    modified_at=[
        "ut nulla"
    ],
    name=[
        "ea mol"
    ],
    slug=[
        "pmjvmw-84d"
    ],
    url=[
        "ea aliquip"
    ]
)
sort=[
    ""
]
search=SearchOverLeagues(
    name="Duis dolo",
    slug="-teig",
    url="adipisicing"
)
page=1

result = sdk.leagues.get_leagues(
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)

get_leagues_league_id_or_slug

Get a single league by ID or by slug

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug

Return Type

League

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7

result = sdk.leagues.get_leagues_league_id_or_slug(league_id_or_slug=league_id_or_slug)

print(result)

get_leagues_league_id_or_slug_matches

List matches of the given league

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}/matches

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug
filter FilterOverMatches Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverMatches Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverMatches Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[Match]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverMatches, RangeOverMatches, SearchOverMatches

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7
filter=FilterOverMatches(
    begin_at=[
        "ani"
    ],
    detailed_stats=False,
    draw=False,
    end_at=[
        "ad ut com"
    ],
    finished=False,
    forfeit=False,
    future=True,
    id_=[
        3
    ],
    league_id=[
        9
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "aute sit"
    ],
    name=[
        "exercitation te"
    ],
    not_started=False,
    number_of_games=[
        8
    ],
    opponent_id=[
        10
    ],
    opponents_filled=True,
    past=False,
    running=True,
    scheduled_at=[
        "esse aute n"
    ],
    serie_id=[
        10
    ],
    slug=[
        "HiGqjR9"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    unscheduled=False,
    videogame=[
        1
    ],
    videogame_title=[
        6
    ],
    videogame_version=[
        "1125897835.45"
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
range=RangeOverMatches(
    begin_at=[
        "al"
    ],
    detailed_stats=[
        False
    ],
    draw=[
        False
    ],
    end_at=[
        "do d"
    ],
    forfeit=[
        False
    ],
    id_=[
        6
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "dolore ve"
    ],
    name=[
        "dolore "
    ],
    number_of_games=[
        10
    ],
    scheduled_at=[
        "nisi sed aut"
    ],
    slug=[
        "bAjOZ"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
sort=[
    ""
]
search=SearchOverMatches(
    match_type="all_games_played",
    name="nulla veniam ",
    slug="WfL1ZPQ",
    status="canceled",
    winner_type="Player"
)
page=1

result = sdk.leagues.get_leagues_league_id_or_slug_matches(
    league_id_or_slug=league_id_or_slug,
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)

get_leagues_league_id_or_slug_matches_past

List past matches for the given league

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}/matches/past

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug
filter FilterOverMatches Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverMatches Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverMatches Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[Match]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverMatches, RangeOverMatches, SearchOverMatches

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7
filter=FilterOverMatches(
    begin_at=[
        "ani"
    ],
    detailed_stats=False,
    draw=False,
    end_at=[
        "ad ut com"
    ],
    finished=False,
    forfeit=False,
    future=True,
    id_=[
        3
    ],
    league_id=[
        9
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "aute sit"
    ],
    name=[
        "exercitation te"
    ],
    not_started=False,
    number_of_games=[
        8
    ],
    opponent_id=[
        10
    ],
    opponents_filled=True,
    past=False,
    running=True,
    scheduled_at=[
        "esse aute n"
    ],
    serie_id=[
        10
    ],
    slug=[
        "HiGqjR9"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    unscheduled=False,
    videogame=[
        1
    ],
    videogame_title=[
        6
    ],
    videogame_version=[
        "1125897835.45"
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
range=RangeOverMatches(
    begin_at=[
        "al"
    ],
    detailed_stats=[
        False
    ],
    draw=[
        False
    ],
    end_at=[
        "do d"
    ],
    forfeit=[
        False
    ],
    id_=[
        6
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "dolore ve"
    ],
    name=[
        "dolore "
    ],
    number_of_games=[
        10
    ],
    scheduled_at=[
        "nisi sed aut"
    ],
    slug=[
        "bAjOZ"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
sort=[
    ""
]
search=SearchOverMatches(
    match_type="all_games_played",
    name="nulla veniam ",
    slug="WfL1ZPQ",
    status="canceled",
    winner_type="Player"
)
page=1

result = sdk.leagues.get_leagues_league_id_or_slug_matches_past(
    league_id_or_slug=league_id_or_slug,
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)

get_leagues_league_id_or_slug_matches_running

List currently running matches for the given league

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}/matches/running

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug
filter FilterOverMatches Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverMatches Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverMatches Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[Match]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverMatches, RangeOverMatches, SearchOverMatches

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7
filter=FilterOverMatches(
    begin_at=[
        "ani"
    ],
    detailed_stats=False,
    draw=False,
    end_at=[
        "ad ut com"
    ],
    finished=False,
    forfeit=False,
    future=True,
    id_=[
        3
    ],
    league_id=[
        9
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "aute sit"
    ],
    name=[
        "exercitation te"
    ],
    not_started=False,
    number_of_games=[
        8
    ],
    opponent_id=[
        10
    ],
    opponents_filled=True,
    past=False,
    running=True,
    scheduled_at=[
        "esse aute n"
    ],
    serie_id=[
        10
    ],
    slug=[
        "HiGqjR9"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    unscheduled=False,
    videogame=[
        1
    ],
    videogame_title=[
        6
    ],
    videogame_version=[
        "1125897835.45"
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
range=RangeOverMatches(
    begin_at=[
        "al"
    ],
    detailed_stats=[
        False
    ],
    draw=[
        False
    ],
    end_at=[
        "do d"
    ],
    forfeit=[
        False
    ],
    id_=[
        6
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "dolore ve"
    ],
    name=[
        "dolore "
    ],
    number_of_games=[
        10
    ],
    scheduled_at=[
        "nisi sed aut"
    ],
    slug=[
        "bAjOZ"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
sort=[
    ""
]
search=SearchOverMatches(
    match_type="all_games_played",
    name="nulla veniam ",
    slug="WfL1ZPQ",
    status="canceled",
    winner_type="Player"
)
page=1

result = sdk.leagues.get_leagues_league_id_or_slug_matches_running(
    league_id_or_slug=league_id_or_slug,
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)

get_leagues_league_id_or_slug_matches_upcoming

List upcoming matches for the given league

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}/matches/upcoming

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug
filter FilterOverMatches Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverMatches Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverMatches Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[Match]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverMatches, RangeOverMatches, SearchOverMatches

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7
filter=FilterOverMatches(
    begin_at=[
        "ani"
    ],
    detailed_stats=False,
    draw=False,
    end_at=[
        "ad ut com"
    ],
    finished=False,
    forfeit=False,
    future=True,
    id_=[
        3
    ],
    league_id=[
        9
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "aute sit"
    ],
    name=[
        "exercitation te"
    ],
    not_started=False,
    number_of_games=[
        8
    ],
    opponent_id=[
        10
    ],
    opponents_filled=True,
    past=False,
    running=True,
    scheduled_at=[
        "esse aute n"
    ],
    serie_id=[
        10
    ],
    slug=[
        "HiGqjR9"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    unscheduled=False,
    videogame=[
        1
    ],
    videogame_title=[
        6
    ],
    videogame_version=[
        "1125897835.45"
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
range=RangeOverMatches(
    begin_at=[
        "al"
    ],
    detailed_stats=[
        False
    ],
    draw=[
        False
    ],
    end_at=[
        "do d"
    ],
    forfeit=[
        False
    ],
    id_=[
        6
    ],
    match_type=[
        "all_games_played"
    ],
    modified_at=[
        "dolore ve"
    ],
    name=[
        "dolore "
    ],
    number_of_games=[
        10
    ],
    scheduled_at=[
        "nisi sed aut"
    ],
    slug=[
        "bAjOZ"
    ],
    status=[
        "canceled"
    ],
    tournament_id=[
        3
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
sort=[
    ""
]
search=SearchOverMatches(
    match_type="all_games_played",
    name="nulla veniam ",
    slug="WfL1ZPQ",
    status="canceled",
    winner_type="Player"
)
page=1

result = sdk.leagues.get_leagues_league_id_or_slug_matches_upcoming(
    league_id_or_slug=league_id_or_slug,
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)

get_leagues_league_id_or_slug_series

List series for the given league

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}/series

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug
filter FilterOverSeries Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverSeries Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverSeries Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[Serie]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverSeries, RangeOverSeries, SearchOverSeries

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7
filter=FilterOverSeries(
    begin_at=[
        "sunt cillum dol"
    ],
    end_at=[
        "dolor"
    ],
    id_=[
        5
    ],
    league_id=[
        7
    ],
    modified_at=[
        "deserunt"
    ],
    name=[
        "laboris"
    ],
    season=[
        "proident"
    ],
    slug=[
        "_9"
    ],
    videogame_title=[
        7
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ],
    year=[
        None
    ]
)
range=RangeOverSeries(
    begin_at=[
        "sint c"
    ],
    end_at=[
        "ex dolore tempo"
    ],
    id_=[
        6
    ],
    league_id=[
        6
    ],
    modified_at=[
        "lab"
    ],
    name=[
        "animea labore e"
    ],
    season=[
        "ipsum i"
    ],
    slug=[
        "8"
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ],
    year=[
        None
    ]
)
sort=[
    ""
]
search=SearchOverSeries(
    name="fugia",
    season="aute al",
    slug="cc3u_",
    winner_type="Player"
)
page=1

result = sdk.leagues.get_leagues_league_id_or_slug_series(
    league_id_or_slug=league_id_or_slug,
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)

get_leagues_league_id_or_slug_tournaments

List tournaments of the given league

  • HTTP Method: GET
  • Endpoint: /leagues/{league_id_or_slug}/tournaments

Parameters

Name Type Required Description
league_id_or_slug LeagueIdOrSlug A league ID or slug
filter FilterOverShortTournaments Options to filter results. String fields are case sensitive
For more information on filtering, see docs.
range RangeOverShortTournaments Options to select results within ranges
For more information on ranges, see docs.
sort List[any] Options to sort results
For more information on sorting, see docs.
search SearchOverShortTournaments Options to search results
For more information on searching, see docs.
page Page Pagination in the form of page=2 or page[size]=30&page[number]=2
per_page int Equivalent to page[size]

Return Type

List[ShortTournament]

Example Usage Code Snippet

from pandascore_client import PandascoreClient, Environment
from pandascore_client.models import FilterOverShortTournaments, RangeOverShortTournaments, SearchOverShortTournaments

sdk = PandascoreClient(
    access_token="YOUR_ACCESS_TOKEN",
    base_url=Environment.DEFAULT.value,
    timeout=10000
)
league_id_or_slug=7
filter=FilterOverShortTournaments(
    begin_at=[
        "pariat"
    ],
    detailed_stats=True,
    end_at=[
        "eli"
    ],
    has_bracket=False,
    id_=[
        4
    ],
    live_supported=False,
    modified_at=[
        "cillu"
    ],
    name=[
        "Excepteur do"
    ],
    prizepool=[
        "in ut veniam "
    ],
    serie_id=[
        10
    ],
    slug=[
        "z160_"
    ],
    tier=[
        "a"
    ],
    videogame_title=[
        5
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
range=RangeOverShortTournaments(
    begin_at=[
        "et"
    ],
    detailed_stats=[
        True
    ],
    end_at=[
        "commo"
    ],
    has_bracket=[
        False
    ],
    id_=[
        1
    ],
    modified_at=[
        "nul"
    ],
    name=[
        "enim "
    ],
    prizepool=[
        "qui ull"
    ],
    serie_id=[
        3
    ],
    slug=[
        "vyokv"
    ],
    tier=[
        "a"
    ],
    winner_id=[
        7
    ],
    winner_type=[
        "Player"
    ]
)
sort=[
    ""
]
search=SearchOverShortTournaments(
    name="sunt minim",
    prizepool="utid magna es",
    slug="50l9n",
    tier="a",
    winner_type="Player"
)
page=1

result = sdk.leagues.get_leagues_league_id_or_slug_tournaments(
    league_id_or_slug=league_id_or_slug,
    filter=filter,
    range=range,
    sort=sort,
    search=search,
    page=page,
    per_page=50
)

print(result)