---
title: "Get server leaderboards"
method: GET
path: "/v2/server/{serverId}/leaderboards"
tags: ["Server Leaderboards"]
---

# Get server leaderboards

`GET /v2/server/{serverId}/leaderboards`

## Request

- Base URL: `https://api.clashk.ing`
- URL: `https://api.clashk.ing/v2/server/{serverId}/leaderboards`
- Auth: one of:
  - HTTP bearer
  - HTTP bearer

## Path parameters

- `serverId` string, required

## Query parameters

- `limit_players` union
  - number
  - 'NaN'
  - 'Infinity'
  - '-Infinity'
- `limit_clans` union
  - number
  - 'NaN'
  - 'Infinity'
  - '-Infinity'
- `sort_by` string

## Response `200`

Success

- object
  - `server_id` string, required: Discord snowflake as an unsigned decimal string
  - `total_players` union, required
    - number
    - 'NaN'
    - 'Infinity'
    - '-Infinity'
  - `total_clans` union, required
    - number
    - 'NaN'
    - 'Infinity'
    - '-Infinity'
  - `players` object[], required
    - `player_tag` string, required
    - `player_name` string, required
    - `townhall_level` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `clan_tag` string, required
    - `clan_name` string, required
    - `trophies` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `global_rank` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `local_rank` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `location_id` string, nullable
    - `country_code` string, nullable
    - `country_name` string, nullable
    - `legend_trophies` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
  - `clans` object[], required
    - `clan_tag` string, required
    - `clan_name` string, required
    - `global_rank` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `local_rank` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `country_code` string, nullable
    - `country_name` string, nullable
    - `clan_level` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `clan_points` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `member_count` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'
    - `capital_points` union
      - number
      - 'NaN'
      - 'Infinity'
      - '-Infinity'

---

[API](https://skmtc.dev/clashk/apis/clashking-api.md) - [All operations](https://skmtc.dev/clashk/apis/clashking-api/llms.txt) - [OpenAPI document](https://skmtc.dev/clashk/apis/clashking-api/revisions/8411b4ef8009?raw)
