> ## Documentation Index
> Fetch the complete documentation index at: https://docs.rabbithole.gg/llms.txt
> Use this file to discover all available pages before exploring further.

# Get referrer earnings per campaign

> Per-campaign referral earnings for a referrer. Rows are status 'estimated' while a campaign is live (referees' current accrued rewards with the referral rate applied, then scaled pro-rata into the referral pool against every referrer's share — amount is the projected payout) and 'final' once the post-finalize entitlement exists (amount is the committed pool-capped payout). Every row carries the distributor's referralPool and claimWindowDuration (null without a referral program), claimWindowEnd (unix seconds, null until the referral root is published), and claimTxHash/claimedAt from the indexed on-chain ReferralClaimed event, null until the referrer has claimed.



## OpenAPI

````yaml https://api-tbi.boost.xyz/v1/openapi.json get /v1/referrals/stats/{address}
openapi: 3.1.0
info:
  title: Boost Time-Based Incentives SDK API
  version: 1.0.0
  description: >-
    Public /v1 API surface for the Boost TBI SDK. Internal Rabbithole, admin,
    Polymarket, and widget routes are intentionally excluded.
servers:
  - url: https://api-tbi.boost.xyz
    description: Production
  - url: http://localhost:3000
    description: Local development
security: []
tags:
  - name: Campaigns
    description: Campaign discovery, detail, and stats endpoints.
  - name: Claims
    description: Claim proof and claim status endpoints.
  - name: Forwarder
    description: Boost Forwarder target discovery and direct deposit transaction builders.
  - name: Referrals
    description: >-
      Referral attribution: signed per-campaign binds, referrer earnings, and
      claim proofs.
  - name: Users
    description: User rewards and balance endpoints.
paths:
  /v1/referrals/stats/{address}:
    get:
      tags:
        - Referrals
      summary: Get referrer earnings per campaign
      description: >-
        Per-campaign referral earnings for a referrer. Rows are status
        'estimated' while a campaign is live (referees' current accrued rewards
        with the referral rate applied, then scaled pro-rata into the referral
        pool against every referrer's share — amount is the projected payout)
        and 'final' once the post-finalize entitlement exists (amount is the
        committed pool-capped payout). Every row carries the distributor's
        referralPool and claimWindowDuration (null without a referral program),
        claimWindowEnd (unix seconds, null until the referral root is
        published), and claimTxHash/claimedAt from the indexed on-chain
        ReferralClaimed event, null until the referrer has claimed.
      operationId: getReferralStats
      parameters:
        - name: address
          in: path
          required: true
          description: EVM address. Responses normalize addresses to lowercase.
          schema:
            type: string
        - name: chainId
          in: query
          required: false
          description: Reward chain ID.
          schema:
            type: integer
            exclusiveMinimum: 0
            maximum: 9007199254740991
        - name: X-Boost-Ref-Id
          in: header
          required: false
          description: >-
            Optional partner attribution reference ID. Values are manually
            assigned by Boost and must be at most 128 characters.
          schema:
            type: string
            minLength: 1
            maxLength: 128
            pattern: ^[A-Za-z0-9][A-Za-z0-9._:-]*$
      responses:
        '200':
          description: Referral stats
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ReferralStatsResponse'
        '400':
          description: Validation failed
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V1ErrorResponse'
        '429':
          description: Rate limited
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V1ErrorResponse'
        '500':
          description: Internal server error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/V1ErrorResponse'
components:
  schemas:
    ReferralStatsResponse:
      type: object
      properties:
        data:
          type: array
          items:
            type: object
            properties:
              id:
                type: object
                properties:
                  chainId:
                    type: integer
                    exclusiveMinimum: 0
                    maximum: 9007199254740991
                  campaignIndex:
                    type: integer
                    minimum: 0
                    maximum: 9007199254740991
                required:
                  - chainId
                  - campaignIndex
                additionalProperties: false
              referrer: {}
              status:
                type: string
                enum:
                  - estimated
                  - final
              refereeCount:
                type: integer
                minimum: 0
                maximum: 9007199254740991
              refereesEarned:
                type: string
                pattern: ^(0|[1-9]\d*)$
              uncappedAmount:
                type: string
                pattern: ^(0|[1-9]\d*)$
              amount:
                anyOf:
                  - type: string
                    pattern: ^(0|[1-9]\d*)$
                  - type: 'null'
              referralPool:
                anyOf:
                  - type: string
                    pattern: ^(0|[1-9]\d*)$
                  - type: 'null'
              claimWindowDuration:
                anyOf:
                  - type: string
                    pattern: ^(0|[1-9]\d*)$
                  - type: 'null'
              claimWindowEnd:
                anyOf:
                  - type: string
                    pattern: ^(0|[1-9]\d*)$
                  - type: 'null'
              claimTxHash:
                anyOf:
                  - {}
                  - type: 'null'
              claimedAt:
                anyOf:
                  - type: string
                    pattern: ^(0|[1-9]\d*)$
                  - type: 'null'
              rewardToken:
                type: object
                properties:
                  address: {}
                  decimals:
                    type: integer
                    minimum: 0
                    maximum: 9007199254740991
                  symbol:
                    type: string
                required:
                  - address
                  - decimals
                  - symbol
                additionalProperties: false
            required:
              - id
              - referrer
              - status
              - refereeCount
              - refereesEarned
              - uncappedAmount
              - amount
              - referralPool
              - claimWindowDuration
              - claimWindowEnd
              - claimTxHash
              - claimedAt
              - rewardToken
            additionalProperties: false
      required:
        - data
      additionalProperties: false
    V1ErrorResponse:
      type: object
      properties:
        error:
          type: string
        code:
          type: string
          enum:
            - INVALID_PARAMS
            - NOT_FOUND
            - RATE_LIMITED
            - INTERNAL_ERROR
            - INVALID_SIGNATURE
            - SELF_REFERRAL
            - ALREADY_BOUND
            - ALREADY_PARTICIPATING
            - CAMPAIGN_NOT_BINDABLE
            - INVALID_SESSION
            - WALLET_NOT_LINKED
            - REFERRER_NOT_LINKED
            - CYCLIC_REFERRAL
        details:
          anyOf:
            - {}
            - type: 'null'
      required:
        - error
        - code
        - details
      additionalProperties: false

````