krapio
Library referenceClasses

TokenRankedApi

api.krunker.io behind a token: the ranked system's own api, plain {data} without an error field on success

Constructors

Constructor

new TokenRankedApi(api, auth): TokenRankedApi;

Parameters

ParameterType
apiKrunkerClient
authRecord<string, string>

Returns

TokenRankedApi

Methods

connection()

connection(): Promise<RankedConnection>;

GET /ranked/me/connection, the ranked lobby the player is bound to, serverUrl null without one

Returns

Promise<RankedConnection>


dailySpin()

dailySpin(): Promise<DailySpinProgress>;

GET /daily-spin/progress, the daily spin meter

Returns

Promise<DailySpinProgress>


leaderboard()

leaderboard(season, query?): Promise<SeasonRankings>;

GET /leaderboards/rankings/season/:season[/region/:region], 40 per page in the game; a token is required although the board is public

Parameters

ParameterType
seasonnumber
query?SeasonRankingsQuery

Returns

Promise<SeasonRankings>


matchHistory()

matchHistory(season, query?): Promise<RankedMatchHistory>;

GET /match-history/me/season/:season/gameMode/:mode/isRanked/:ranked[/region/:region]; the game sends the literal "undefined" as mode for all modes, which the api accepts

Parameters

ParameterType
seasonnumber
query?RankedMatchHistoryQuery

Returns

Promise<RankedMatchHistory>


profile()

profile(season, region?): Promise<RankedProfile>;

GET /player-profile/me/season/:season[/region/:region], the player's ranked card with season totals (accuracy included)

Parameters

ParameterType
seasonnumber
region?number

Returns

Promise<RankedProfile>

On this page