Rarible Collection Leader Board API

The Collection Leader Board API from Rarible β€” 2 operation(s) for collection leader board.

OpenAPI Specification

rarible-collection-leader-board-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: OpenAPI definition Charts Collection Leader Board API
  version: v0.1
  description: '# Exciting News


    Hey there, amazing developers! πŸ‘‹


    We''ve got some fantastic news to share that will make your experience with our product even better. We''re thrilled to announce the implementation of API-Keys, which brings a new level of control and convenience to your development process. So, let''s dive right into the details! ✨


    ## API-Keys for Enhanced Functionality πŸ”‘


    Starting now, we have introduced API-Keys to streamline your interactions with our methods. You might have noticed a slight change while making requests – now, all you need to do is include the parameter `X-API-KEY` in the Header of your request. Simple as that!


    ## Get Your API-Key in a Snap! ⚑️


    Securing your API-Key is a breeze. We''ve made the process super user-friendly to ensure you can get started quickly. Just head over to our website and fill out a simple form. Once you''ve done that, your shiny new API-Key will be delivered straight to your email inbox. Easy peasy! πŸ“§


    [Get Your API-Key Here](https://api.rarible.org/registration)

    [Configure SDK with API-key](https://github.com/rarible/sdk#api-querying)


    ## Unlock the Power of the Rarible Protocol πŸ”“


    As passionate developers, we know you''re always hungry for knowledge and eager to explore new frontiers. That''s why we invite you to discover the incredible world of the Rarible Protocol. By visiting our dedicated protocol page, you''ll gain access to a treasure trove of useful information, tips, and insights that will elevate your development skills to new heights. πŸš€


    [Explore the Rarible Protocol](https://rarible.org)


    So, buckle up and get ready for an enhanced development journey with our API-Keys. We''re excited to see what you''ll create using our revamped system! πŸ’ͺπŸš€


    Stay curious, keep innovating, and happy coding! ✨


    [P.S. Join our Discord Server to stay up to date and ask questions](https://discord.gg/rarifoundation)

    '
servers:
- url: https://{environment}.rarible.org
  description: Production (Mainnet)
  variables:
    environment:
      enum:
      - api
      - testnet-api
      default: api
security:
- ApiKeyAuth: []
tags:
- name: Collection Leader Board
  x-controller: CollectionLeaderboardController
paths:
  /v2.0/data/leaderboard/collections:
    get:
      tags:
      - Collection Leader Board
      summary: Get NFT Collections leaderboard
      description: Collections leaderboard
      operationId: getCollectionLeaderboard
      parameters:
      - name: blockchains
        in: query
        description: Blockchain networks
        required: false
        schema:
          type: array
          items:
            $ref: '#/components/schemas/OlapBlockchain'
      - name: period
        in: query
        description: Time period for aggregation
        required: false
        schema:
          $ref: '#/components/schemas/OlapPeriod'
      - name: sort
        in: query
        description: Collections sorting
        required: false
        schema:
          $ref: '#/components/schemas/OlapLeaderboardSort'
      - name: direction
        in: query
        description: Collections sorting direction
        required: false
        schema:
          $ref: '#/components/schemas/OlapLeaderboardSortDirection'
      - name: limit
        in: query
        description: Limit of records in leaderboard
        required: false
        schema:
          type: integer
          format: int32
          default: 10
      - name: offset
        in: query
        description: Offset reference
        required: false
        schema:
          type: integer
          format: int32
          default: 0
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OlapCollectionLeaderboardResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OlapError'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OlapError'
  /v2.0/data/leaderboard/collections/byOwner:
    get:
      tags:
      - Collection Leader Board
      summary: Get NFT Collections leaderboard for a specific owner addresses
      description: User collections leaderboard
      operationId: getCollectionLeaderboardByOwner
      parameters:
      - name: owners
        in: query
        required: true
        description: Addresses of the owner
        schema:
          type: array
          items:
            $ref: '#/components/schemas/UnionAddress'
      - name: blockchains
        in: query
        description: Blockchain networks
        required: false
        schema:
          type: array
          items:
            $ref: '#/components/schemas/OlapBlockchain'
      - name: period
        in: query
        description: Time period for aggregation
        required: false
        schema:
          $ref: '#/components/schemas/OlapPeriod'
      - name: sort
        in: query
        description: Collections sorting
        required: false
        schema:
          $ref: '#/components/schemas/OlapLeaderboardSort'
      - name: direction
        in: query
        description: Collections sorting direction
        required: false
        schema:
          $ref: '#/components/schemas/OlapLeaderboardSortDirection'
      - name: limit
        in: query
        description: Limit of records in leaderboard
        required: false
        schema:
          type: integer
          format: int32
          default: 10
      - name: continuation
        in: query
        required: false
        description: Continuation token from the previous response
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OlapCollectionLeaderboardResponse'
        '400':
          description: Bad Request
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OlapError'
        '500':
          description: Internal Server Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/OlapError'
components:
  schemas:
    OlapBlockchain:
      type: string
      enum:
      - ETHEREUM
      - POLYGON
      - SOLANA
      - ARBITRUM
      - CHILIZ
      - LIGHTLINK
      - ZKSYNC
      - BASE
      - RARI
      - APTOS
      - ZKLINK
      - QUAI
      - ECLIPSE
      - ELECTRONEUM
      - SAAKURU
      - OASIS
      - MATCH
      - MOONBEAM
      - ETHERLINK
      - ZKCANDY
      - BERACHAIN
      - ABSTRACT
      - SHAPE
      - TELOS
      - HEDERAEVM
      - VICTION
      - SETTLUS
      - GOAT
      - HYPEREVM
      - MEGAETH
      - MEGAETHTESTNET
      - MEGAETHTESTNETV2
      - BASECAMP
      - CAMP
      - SOMNIA
      - ARENAZ
      - INJECTIVE
      - INJECTIVETESTNET
      - APECHAIN
      - BLOCKCHAINKEK
      - STELLAR
      - ZILLIQA
      - FRAXTAL
      - XLAYER
      - MONAD
    OlapCollectionLeaderboardStatistics:
      type: object
      required:
      - listed
      - items
      - owners
      properties:
        listed:
          type: integer
          format: int64
        items:
          type: integer
          format: int64
        owners:
          type: integer
          format: int64
        floor:
          $ref: '#/components/schemas/OlapPriceWithUsd'
        topOffer:
          $ref: '#/components/schemas/OlapPriceWithUsd'
    OlapLeaderboardSortDirection:
      type: string
      default: DESC
      enum:
      - ASC
      - DESC
    OlapLeaderboardSort:
      type: string
      default: VOLUME
      enum:
      - VOLUME
      - VOLUME_CHANGE
      - FLOOR
      - FLOOR_CHANGE
      - SALES
      - SALES_CHANGE
      - LISTED
      - OWNERS
    OlapCollectionLeaderboardItem:
      required:
      - id
      - sales
      - volume
      - floorHistory
      - globalStats
      type: object
      properties:
        id:
          type: string
          description: Identifier of collection
        sales:
          type: integer
          format: int64
        volume:
          $ref: '#/components/schemas/OlapPriceWithUsd'
        floorChangePercent:
          type: number
          format: bigdecimal
        floorHistory:
          $ref: '#/components/schemas/OlapHistoryValuesByTimestamps'
        globalStats:
          $ref: '#/components/schemas/OlapCollectionLeaderboardStatistics'
    OlapCollectionLeaderboardResponse:
      type: object
      properties:
        continuation:
          type: string
        result:
          type: array
          items:
            $ref: '#/components/schemas/OlapCollectionLeaderboardItem'
    UnionAddress:
      type: string
      description: Blockchain address in Union format `${blockchainGroup}:${token}`
      example: ETHEREUM:0x4765273c477c2dc484da4f1984639e943adccfeb
    OlapPriceWithUsd:
      required:
      - currency
      - value
      type: object
      properties:
        currency:
          type: string
        value:
          type: number
          description: Amount of currency
          format: bigdecimal
        valueUsd:
          type: number
          description: Amount in USD
          format: bigdecimal
    OlapPeriod:
      type: string
      enum:
      - MIN5
      - MIN30
      - H1
      - H6
      - D1
      - D7
      - D30
      - D180
      - D365
      - ALL
      description: "Period:\n  * `MIN5` - Last 5 minutes\n  * `MIN30` - Last 30 minutes\n  * `H1` - Last 1 hour\n  * `H6` - Last 6 hours\n  * `D1` - Last 1 day\n  * `D7` - Last 7 days\n  * `D30` - Last 30 days\n  * `D180` - Last 180 days (roughly 6 months)\n  * `D365` - Last 365 days (roughly 1 year)\n  * `ALL` - For all time\n"
    OlapError:
      required:
      - code
      - message
      type: object
      properties:
        code:
          type: string
          description: Code
          enum:
          - INVALID_INPUT
          - NOT_FOUND
          - UNKNOWN
        message:
          type: string
          description: Message
    OlapHistoryValuesByTimestamps:
      required:
      - timestamps
      - values
      type: object
      properties:
        timestamps:
          type: array
          description: Timestamps of historical statistics
          items:
            type: integer
            format: int64
            description: Unix epoch of historical statistics
        values:
          type: array
          description: Values of historical statistics
          items:
            type: number
            description: Value of historical statistics
            format: bigdecimal
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY
      x-default: 11111111-1111-1111-1111-111111111111