History

private/get_interest_history

Changed on

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 asset the interest settled on and the settled interest as a decimal, where a negative value was paid (borrowed) and a positive value was received (supplied).

post/private/get_interest_history

Request

  • Base URL
    https://api.derive.xyz/v3
  • Auth
    API key in header X-DeriveWallet and API key in header X-DeriveTimestamp and API key in header X-DeriveSignature

Request body

GetInterestHistoryRequest required

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.

end_timestamp, integer nullable

End of the window, unix milliseconds (default: now / unbounded).

start_timestamp, integer nullable

Start of the window, unix milliseconds (default 0).

subaccount_id, integer nullable
wallet, string nullable

Response

Success

InterestHistoryResult required
events, InterestPayment[] required

Changes

    • info

      added the optional property events/items/asset to the response with the status

    • info

      the endpoint scheme security DeriveWallet AND DeriveTimestamp AND DeriveSignature was added to the API

    • info

      added the media type application/json for the response with the status