osu-api-v2-js
    Preparing search index...

    Function getRanking

    • Get the top players of the game, with some filters!

      Parameters

      • this: API
      • ruleset: Ruleset

        Self-explanatory, is also known as "Gamemode"

      • type: "score" | "performance"

        Rank players by their performance points or by their ranked score?

      • Optionalconfig: {
            country?: string;
            filter?: "all" | "friends";
            page?: number;
            variant?: "4k" | "7k";
        }

        Specify which page, country, filter out non-friends...

        • Optionalcountry?: string

          Only get players from a specific country, using its ISO 3166-1 alpha-2 country code! (France would be FR, United States US)

        • Optionalfilter?: "all" | "friends"

          What kind of players do you want to see? Keep in mind friends has no effect if no authorized user

        • Optionalpage?: number

          Imagine the array you get as a page, it can only have a maximum of 50 players, while 50 others may be on the next one

        • Optionalvariant?: "4k" | "7k"

          If type is performance and ruleset is mania, choose between 4k and 7k!

      Returns Promise<User.Ranking>