Skip to content

Resource RankingResource

CrucifiedPain edited this page Jun 26, 2026 · 9 revisions

RankingResource (client.ranking)

Endpoints: • ranking.getRanking

.get()

Get a ranking leaderboard.

Args: ranking_type: One of 25 ranking types (country, user, or MU). Use the RankingType enum for tab-completion.

Example: entries = await client.ranking.get(RankingType.USER_WEALTH) for e in entries: print(e.rank, e.name, e.value)

Signature

await client.ranking.get(ranking_type: 'RankingType | str') -> 'list[RankingEntry]'

Parameters

Name Type Default
ranking_type RankingType | str Required

Return Models

RankingEntry

Field Type Required
_id string Optional
__v integer Optional
rank integer Optional
user string Optional
name string Optional
country string Optional
value number Optional
tier string Optional
mu string Optional
image string Optional

.invalidate_cache()

Clear the SWR cache for all resources.

Signature

await client.ranking.invalidate_cache() -> 'None'

Clone this wiki locally