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

# Get interest history for a subaccount

> Returns realized interest settlements per subaccount, for a single subaccount or an entire wallet (specify exactly one), optionally bounded by a start/end timestamp window. Each entry gives the settled interest as a decimal, where a negative value was paid (borrowed) and a positive value was received (supplied).



## OpenAPI

````yaml /openapi.json post /private/get_interest_history
openapi: 3.1.0
info:
  title: Derive v3 API
  version: 0.2.0
  description: JSON-RPC 2.0 methods, served over WebSocket and HTTP POST.
servers:
  - url: https://api.derive.xyz/v3
    description: Production (HTTP POST base)
  - url: https://testnet.api.derive.xyz/v3
    description: Testnet (HTTP POST base)
security: []
tags:
  - name: Subaccounts
    description: >-
      List, inspect, and label subaccounts, portfolios, positions, and
      collateral.
  - name: Session Keys
    description: Register, edit, and list delegated signing keys.
  - name: Account
    description: Wallet-level account information and settings.
  - name: Orderbook
    description: Place, replace, cancel, and query orders, trigger orders, and algos.
  - name: RFQ
    description: 'Request-for-quote: send RFQs, quote, and execute block trades.'
  - name: Vault Shareholders
    description: >-
      Deposit into and withdraw from vaults, and track shares, requests, and
      performance.
  - name: Vault Curators
    description: >-
      Create and operate curated vaults: settle deposit and withdrawal requests,
      and manage vault metadata.
  - name: History
    description: >-
      Per-account historical records: orders, trades, transfers, and
      settlements.
  - name: Market Maker Protection
    description: Configure, read, and reset market-maker protection.
  - name: Transfers & Withdrawals
    description: Move collateral between subaccounts, to other wallets, and on-chain.
  - name: System
    description: Rate limits and transaction lookups.
  - name: Market Data
    description: Instruments, currencies, tickers, and market-wide feeds.
  - name: Referrals
    description: Referral codes and program performance.
  - name: Other
    description: Uncategorized.
paths:
  /private/get_interest_history:
    post:
      tags:
        - History
      summary: Get interest history for a subaccount
      description: >-
        Returns realized interest settlements per subaccount, for a single
        subaccount or an entire wallet (specify exactly one), optionally bounded
        by a start/end timestamp window. Each entry gives the settled interest
        as a decimal, where a negative value was paid (borrowed) and a positive
        value was received (supplied).
      operationId: private_get_interest_history
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/GetInterestHistoryRequest'
      responses:
        '200':
          description: Success
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/InterestHistoryResult'
        default:
          description: JSON-RPC error (see Error Codes)
components:
  schemas:
    GetInterestHistoryRequest:
      description: >-
        Parameters for `private/get_interest_history`. `wallet`, when set, takes
        precedence over `subaccount_id` and returns the whole wallet's
        settlements. `[start_timestamp, end_timestamp]` is a unix-millisecond
        window. Results are capped at 1000 rows, newest first.
      type: object
      properties:
        end_timestamp:
          description: 'End of the window, unix milliseconds (default: now / unbounded).'
          default: null
          type:
            - integer
            - 'null'
          format: uint64
          minimum: 0
        start_timestamp:
          description: Start of the window, unix milliseconds (default 0).
          default: null
          type:
            - integer
            - 'null'
          format: uint64
          minimum: 0
        subaccount_id:
          default: null
          type:
            - integer
            - 'null'
          format: uint64
          minimum: 0
        wallet:
          default: null
          type:
            - string
            - 'null'
    InterestHistoryResult:
      type: object
      required:
        - events
      properties:
        events:
          type: array
          items:
            $ref: '#/components/schemas/InterestPayment'
    InterestPayment:
      description: >-
        One realized interest settlement. `interest` is a decimal string;
        negative = paid, positive = received. `timestamp` is unix ms.
      type: object
      required:
        - interest
        - subaccount_id
        - timestamp
      properties:
        interest:
          type: string
        subaccount_id:
          type: integer
          format: uint64
          minimum: 0
        timestamp:
          type: integer
          format: int64

````

## Related topics

- [Get deposit history for a subaccount](/api-reference/history/get-deposit-history-for-a-subaccount.md)
- [Get withdrawal history for a subaccount](/api-reference/history/get-withdrawal-history-for-a-subaccount.md)
- [Get perpetual funding history for a subaccount](/api-reference/history/get-perpetual-funding-history-for-a-subaccount.md)
