Nakama Leaderboards API

Write and list leaderboard records.

Operations 2

GET /v2/leaderboard/{leaderboard_id} List records from a leaderboard #
POST /v2/leaderboard/{leaderboard_id} Write a record to a leaderboard #

Work with this as data

Every API here is available over the APIs.io API and to AI agents over MCP.

MCP server

One button, every client — Claude, Cursor, VS Code and the rest.

https://apis.io/mcp

Tools for apis

7 MCP tools reach this
  • find_apisBrowse and filter every API in the catalog.
  • get_api_artifactsOne API's artifacts, grouped by type.
  • get_openapiThe primary OpenAPI for this API.
  • find_similar_apisAPIs that look like this one.
  • apis_io_searchSTART HERE — APIs, providers and tags for one query, each with its total.
  • resolveTurn a domain, URL or GitHub org into the provider it belongs to.
  • find_cohortsEvery scored population of providers in the catalog.
All 92 tools →

Call it yourself

curl for this page
This API
curl "https://apis.io/api/v1/apis/nakama-leaderboards-api"
All apis
curl "https://apis.io/api/v1/apis?limit=25"

Discovery needs no key. Ratings and market analysis are Pro.

Get an API key

Free tier, no form to fill in. Signing in shares your email address with us — we store it to create your key and to recognise you if you sign in with another provider. See our Privacy Policy and Terms.

A second provider on the same verified email joins the account you already have.

OpenAPI Specification

nakama-leaderboards-api-openapi.yml Raw ↑
openapi: 3.2.0
info:
  title: Nakama Leaderboards API
  description: Representative OpenAPI description of the core REST API for Nakama, the open-source game and app backend server by Heroic Labs.
  termsOfService: https://heroiclabs.com/terms/
  contact:
    name: Heroic Labs
    url: https://heroiclabs.com/
    email: support@heroiclabs.com
  license:
    name: Apache 2.0
    url: https://github.com/heroiclabs/nakama/blob/master/LICENSE
  version: '2.0'
servers:
- url: http://127.0.0.1:7350
  description: Default self-hosted Nakama server. Replace host/port with your Heroic Cloud project URL in production.
security:
- BearerAuth: []
tags:
- name: Leaderboards
  description: Write and list leaderboard records.
paths:
  /v2/leaderboard/{leaderboard_id}:
    get:
      operationId: listLeaderboardRecords
      tags:
      - Leaderboards
      summary: List records from a leaderboard
      parameters:
      - in: path
        name: leaderboard_id
        required: true
        schema:
          type: string
        description: The leaderboard id.
      - in: query
        name: owner_ids
        schema:
          type: array
          items:
            type: string
        description: One or more owners to retrieve records for.
      - in: query
        name: limit
        schema:
          type: integer
          format: int32
      - in: query
        name: cursor
        schema:
          type: string
      responses:
        '200':
          description: A list of leaderboard records.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LeaderboardRecordList'
    post:
      operationId: writeLeaderboardRecord
      tags:
      - Leaderboards
      summary: Write a record to a leaderboard
      parameters:
      - in: path
        name: leaderboard_id
        required: true
        schema:
          type: string
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/WriteLeaderboardRecordRequest'
      responses:
        '200':
          description: The written leaderboard record.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/LeaderboardRecord'
components:
  schemas:
    LeaderboardRecordList:
      type: object
      properties:
        records:
          type: array
          items:
            $ref: '#/components/schemas/LeaderboardRecord'
        owner_records:
          type: array
          items:
            $ref: '#/components/schemas/LeaderboardRecord'
        next_cursor:
          type: string
        prev_cursor:
          type: string
    WriteLeaderboardRecordRequest:
      type: object
      properties:
        score:
          type: string
          format: int64
        subscore:
          type: string
          format: int64
        metadata:
          type: string
    LeaderboardRecord:
      type: object
      description: Represents a complete leaderboard record with all scores and associated metadata.
      properties:
        leaderboard_id:
          type: string
        owner_id:
          type: string
        username:
          type: string
        score:
          type: string
          format: int64
        subscore:
          type: string
          format: int64
        num_score:
          type: integer
          format: int32
        metadata:
          type: string
        create_time:
          type: string
          format: date-time
        update_time:
          type: string
          format: date-time
        expiry_time:
          type: string
          format: date-time
        rank:
          type: string
          format: int64
  securitySchemes:
    BasicAuth:
      type: http
      scheme: basic
      description: HTTP Basic auth using the server key as the username and an empty password. Guards the authenticate endpoints.
    BearerAuth:
      type: http
      scheme: bearer
      bearerFormat: JWT
      description: 'The JWT session token returned by an authenticate call, sent as `Authorization: Bearer <session_token>`.'
externalDocs:
  description: Nakama documentation
  url: https://heroiclabs.com/docs/nakama/