openapi: 3.0.3
info:
  title: photon-indexer
  description: Solana indexer for general compression
  license:
    name: Apache-2.0
  version: 0.50.0
servers:
  - url: https://mainnet.helius-rpc.com
paths:
  /:
    summary: getCompressedMintTokenHolders
    post:
      requestBody:
        content:
          application/json:
            schema:
              type: object
              required:
                - jsonrpc
                - id
                - method
                - params
              properties:
                id:
                  type: string
                  description: An ID to identify the request.
                  enum:
                    - test-account
                jsonrpc:
                  type: string
                  description: The version of the JSON-RPC protocol.
                  enum:
                    - '2.0'
                method:
                  type: string
                  description: The name of the method to invoke.
                  enum:
                    - getCompressedMintTokenHolders
                params:
                  type: object
                  required:
                    - mint
                  properties:
                    cursor:
                      allOf:
                        - $ref: '#/components/schemas/Base58String'
                      nullable: true
                    limit:
                      allOf:
                        - $ref: '#/components/schemas/Limit'
                      nullable: true
                    mint:
                      $ref: '#/components/schemas/SerializablePubkey'
                  additionalProperties: false
        required: true
      responses:
        '200':
          description: ''
          content:
            application/json:
              schema:
                type: object
                required:
                  - context
                  - value
                properties:
                  context:
                    $ref: '#/components/schemas/Context'
                  value:
                    $ref: '#/components/schemas/OwnerBalanceList'
                additionalProperties: false
        '429':
          description: Exceeded rate limit.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
        '500':
          description: >-
            The server encountered an unexpected condition that prevented it
            from fulfilling the request.
          content:
            application/json:
              schema:
                type: object
                properties:
                  error:
                    type: string
components:
  schemas:
    Base58String:
      type: string
      description: A base 58 encoded string.
      default: 3J98t1WpEZ73CNm
      example: 3J98t1WpEZ73CNm
    Context:
      type: object
      required:
        - slot
      properties:
        slot:
          type: integer
          default: 100
          example: 100
    Limit:
      type: integer
      format: int64
      minimum: 0
    OwnerBalance:
      type: object
      required:
        - owner
        - balance
      properties:
        balance:
          $ref: '#/components/schemas/UnsignedInteger'
        owner:
          $ref: '#/components/schemas/SerializablePubkey'
    OwnerBalanceList:
      type: object
      required:
        - items
      properties:
        cursor:
          $ref: '#/components/schemas/Base58String'
        items:
          type: array
          items:
            $ref: '#/components/schemas/OwnerBalance'
    SerializablePubkey:
      type: string
      description: A Solana public key represented as a base58 string.
      default: 111111152P2r5yt6odmBLPsFCLBrFisJ3aS7LqLAT
      example: 111111152P2r5yt6odmBLPsFCLBrFisJ3aS7LqLAT
    UnsignedInteger:
      type: integer
      default: 100
      example: 100
