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

# Get fee revenue generated by a referrer's network

> Net fees the referred network paid, the builder kickbacks owed on those same fills,
and the difference — the basis an affiliate commission would be computed on. Returns
no commission amount: no rate is signed off and no accrual ledger exists.



## OpenAPI

````yaml /api-reference/openapi.json get /api/v1/referrals/fees
openapi: 3.1.0
info:
  title: Decibel Trading API
  description: >-
    RESTful API for Decibel. Provides read-only endpoints for market data,
    trading operations, positions, and analytics.
  contact:
    name: Decibel Team
    url: https://decibel.trade/
  license:
    name: ''
  version: 1.0.0
servers:
  - url: https://api.mainnet.aptoslabs.com/decibel
    description: Mainnet
  - url: https://api.testnet.aptoslabs.com/decibel
    description: Testnet
security:
  - bearerAuth: []
tags:
  - name: Market Data
    description: Market information and real-time data endpoints
  - name: User
    description: User information and account management
  - name: Account
    description: Account-specific endpoints and data
  - name: Trades
    description: Trading operations and history
  - name: Positions
    description: User position management
  - name: Orders
    description: Order management and history
  - name: TWAP
    description: Time-weighted average price orders
  - name: Bulk Orders
    description: Bulk order management
  - name: Vaults
    description: Vault operations and management
  - name: Analytics
    description: Analytics and performance metrics
  - name: Points
    description: Points-related account metrics
  - name: Trading Points
    description: Trading points endpoints
  - name: Trading Hz
    description: Trading Hz endpoints
  - name: Tier
    description: Tier information endpoints
  - name: Streaks
    description: User streak tracking endpoints
  - name: Predeposit Rewards
    description: Season 0 predeposit USDC rewards
  - name: Referrals
    description: Referral code management and tracking
  - name: Affiliates
    description: Affiliate code and earnings endpoints
  - name: Campaigns
    description: On-chain reward campaign endpoints
paths:
  /api/v1/referrals/fees:
    get:
      tags:
        - Referrals
      summary: Get fee revenue generated by a referrer's network
      description: >-
        Net fees the referred network paid, the builder kickbacks owed on those
        same fills,

        and the difference — the basis an affiliate commission would be computed
        on. Returns

        no commission amount: no rate is signed off and no accrual ledger
        exists.
      operationId: handle_referral_fees
      parameters:
        - name: referrer_account
          in: query
          description: The referrer's wallet address (not a subaccount address)
          required: true
          schema:
            type: string
        - name: days
          in: query
          description: Trailing UTC days to cover. Defaults to 30, clamped to 90.
          required: false
          schema:
            type: integer
            format: int64
            minimum: 0
      responses:
        '200':
          description: Fee revenue generated by the referral network
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ReferralFees'
        '400':
          description: Invalid address
        '500':
          description: Database error
components:
  schemas:
    ReferralFees:
      type: object
      description: >-
        Fee revenue a referrer's network generated over the window.


        Carries no commission figure: the rate is not signed off and no accrual
        ledger exists.

        What it does carry is the basis such a figure would be computed from.
      required:
        - net_fees_usd
        - builder_payouts_usd
        - commission_basis_usd
        - days
      properties:
        builder_payouts_usd:
          type: number
          format: double
          description: >-
            Builder kickbacks owed on those same fills, in USD. Deducted before
            commission.
        commission_basis_usd:
          type: number
          format: double
          description: '`net_fees_usd - builder_payouts_usd`'
        days:
          type: integer
          format: int64
          description: The window actually used, after clamping
          minimum: 0
        net_fees_usd:
          type: number
          format: double
          description: >-
            Fees the network paid minus rebates it received, in USD. Can go
            negative on a

            net-rebated network.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer token from Geomi. See
        [Authentication](/api-reference/rest/authentication) for setup
        instructions.

````