Skip to content

Function: getTopRank() ​

ts
function getTopRank(profile: objectOutputType, scope?: PikaNetworkRankScope): 
  | objectOutputType<{
  displayName: ZodOptional<ZodString>;
  expiry: ZodOptional<ZodNumber>;
  name: ZodOptional<ZodString>;
  season: ZodOptional<ZodNullable<ZodString>>;
  server: ZodOptional<ZodString>;
}, ZodTypeAny, "passthrough">
  | null;

Returns the highest donor or staff rank in the requested scope.

global selects ranks assigned network-wide, a gamemode selects that gamemode's ladder, and all considers every donor rank.

Parameters ​

ParameterTypeDefault value
profileobjectOutputTypeundefined
scopePikaNetworkRankScope'global'

Returns ​

| objectOutputType<{ displayName: ZodOptional<ZodString>; expiry: ZodOptional<ZodNumber>; name: ZodOptional<ZodString>; season: ZodOptional<ZodNullable<ZodString>>; server: ZodOptional<ZodString>; }, ZodTypeAny, "passthrough"> | null

Distributed under the MIT License.