Rarible Points API

The Points API from Rarible β€” 3 operation(s) for points.

OpenAPI Specification

rarible-points-api-openapi.yml Raw ↑
openapi: 3.0.3
info:
  title: OpenAPI definition Charts Points 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: Points
  x-controller: PointsController
paths:
  /v0.1/points/rewards:
    get:
      tags:
      - Points
      summary: Get the leaderboard of awarded points across blockchains
      description: Returns a paginated list of wallets with awarded points and rankings
      operationId: getPointsRewards
      parameters:
      - name: size
        in: query
        required: false
        description: 'Maximum number of results (default: 50)'
        schema:
          type: integer
          default: 50
          minimum: 1
          maximum: 1000
      - name: continuation
        in: query
        required: false
        description: Pagination cursor (point number and address to continue from)
        schema:
          type: string
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RewardEntities'
        '400':
          $ref: '#/components/responses/BadRequest'
        '500':
          $ref: '#/components/responses/ServerError'
  /v0.1/points/rewards/{address}:
    get:
      tags:
      - Points
      summary: Get awarded points by address
      description: Returns reward information grouped by blockchain for a specific wallet address
      operationId: getPointsRewardsByAddress
      parameters:
      - name: address
        in: path
        required: true
        description: Wallet address
        schema:
          type: string
          example: ETHEREUM:0x1234567890123456789012345678901234567890
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RewardsByBlockchain'
        '404':
          $ref: '#/components/responses/EntityNotFound'
        '400':
          $ref: '#/components/responses/BadRequest'
        '500':
          $ref: '#/components/responses/ServerError'
  /v0.1/points/claim/signature:
    get:
      tags:
      - Points
      summary: Sign a message to claim rewards
      description: A user uses this resource to sign a request to use their points collected through Points Program to claim the rewards (RARI)
      operationId: getClaimSignature
      parameters:
      - name: blockchain
        in: query
        description: Blockchain
        required: true
        schema:
          $ref: '#/components/schemas/Blockchain'
      - name: signer
        description: Address of the user who is claiming the reward
        in: query
        required: true
        schema:
          $ref: '#/components/schemas/UnionAddress'
      - name: epoch
        description: Number of the epoch in which the user is claiming the reward
        in: query
        required: true
        schema:
          $ref: '#/components/schemas/BigInteger'
      - name: points
        description: The number of points to claim
        in: query
        required: true
        schema:
          $ref: '#/components/schemas/BigDecimal'
      responses:
        '200':
          description: OK
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/RewardsClaimSignatureResponse'
        '400':
          $ref: '#/components/responses/BadRequest'
        '500':
          $ref: '#/components/responses/ServerError'
components:
  schemas:
    UnionApiErrorServerError:
      required:
      - code
      - message
      type: object
      properties:
        code:
          type: string
          enum:
          - UNKNOWN
          default: UNKNOWN
        message:
          type: string
          description: Error message
    RewardEntity:
      type: object
      properties:
        rewardWallet:
          $ref: '#/components/schemas/UnionAddress'
          description: Wallet address with blockchain prefix
          example: ETHEREUM:0x1234567890123456789012345678901234567890
        points:
          description: Points accumulated by the wallet
          $ref: '#/components/schemas/BigDecimal'
        rank:
          type: integer
          format: int64
          description: Rank position of the wallet
          example: 1
      required:
      - rewardWallet
      - points
    UnionAddress:
      type: string
      description: Blockchain address in Union format `${blockchainGroup}:${token}`
      example: ETHEREUM:0x4765273c477c2dc484da4f1984639e943adccfeb
    RewardsClaimSignatureResponse:
      type: object
      properties:
        signature:
          type: string
      required:
      - signature
    RewardByBlockchainEntity:
      type: object
      properties:
        rewardWallet:
          $ref: '#/components/schemas/UnionAddress'
          description: Wallet address with blockchain prefix
          example: ETHEREUM:0x1234567890123456789012345678901234567890
        points:
          description: Points accumulated by the wallet
          $ref: '#/components/schemas/BigDecimal'
        rank:
          type: integer
          format: int64
          description: Rank position of the wallet
          example: 1
        blockchain:
          $ref: '#/components/schemas/Blockchain'
      required:
      - rewardWallet
      - points
      - blockchain
    BigDecimal:
      type: string
      example: 123456.789
    UnionApiErrorBadRequest:
      required:
      - code
      - message
      type: object
      properties:
        code:
          type: string
          enum:
          - BAD_REQUEST
          - VALIDATION
          default: BAD_REQUEST
        message:
          type: string
          description: Error message
    RewardEntities:
      type: object
      properties:
        entities:
          type: array
          description: List of reward entities
          items:
            $ref: '#/components/schemas/RewardEntity'
        continuation:
          type: string
          description: Continuation token to paginate rewards search result
      required:
      - entities
    BigInteger:
      type: string
      example: 123456
    RewardsByBlockchain:
      type: object
      description: List of rewards by blockchain for a specific address
      properties:
        rewards:
          type: array
          description: List of reward entities for each blockchain
          items:
            $ref: '#/components/schemas/RewardByBlockchainEntity'
      required:
      - rewards
      example:
        rewards:
        - rewardWallet: ETHEREUM:0x1234567890123456789012345678901234567890
          points: '1200'
          rank: 5
          blockchain: ETHEREUM
        - rewardWallet: ETHEREUM:0x1234567890123456789012345678901234567890
          points: '300'
          rank: 15
          blockchain: POLYGON
    Blockchain:
      type: string
      enum:
      - APTOS
      - ETHEREUM
      - POLYGON
      - SOLANA
      - ARBITRUM
      - CHILIZ
      - LIGHTLINK
      - ZKSYNC
      - BASE
      - RARI
      - 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
      example: ETHEREUM
    UnionApiErrorEntityNotFound:
      required:
      - code
      - message
      type: object
      properties:
        code:
          type: string
          enum:
          - NOT_FOUND
          default: NOT_FOUND
        message:
          type: string
          description: Error message
  responses:
    ServerError:
      description: Internal Server Error
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/UnionApiErrorServerError'
    BadRequest:
      description: Bad Request
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/UnionApiErrorBadRequest'
    EntityNotFound:
      description: Not Found
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/UnionApiErrorEntityNotFound'
  securitySchemes:
    ApiKeyAuth:
      type: apiKey
      in: header
      name: X-API-KEY
      x-default: 11111111-1111-1111-1111-111111111111