Get Interest Accrual History

Queries historical interest charges, calculation bases and applicable annual rates. FIXED does not necessarily mean fixed-term borrowing.

Recent Requests
Log in to see full request history
TimeStatusUser Agent
Retrieving recent requests…
LoadingLoading…

Returns paginated MarginX interest-accrual records across your groups or for one specified group. Each record contains the rate, calculation base and new interest for that period, not the current unpaid interest balance.

Rate limit: 10 requests per minute per API key.

API key access

Requires a signed LTP Open API request with READ permission. See Authentication.

API key typeCan callScope
Main User Level API key (also the Main Portfolio key)YesInterest records in margin groups belonging to the main user.
Sub-user Level API keyNoNot supported.
Dedicated Sub Portfolio Level API keyNoNot supported.
Exchange-native API keyNoUse an LTP Main User Level API key.

Query parameters

All query parameters are optional.

NameTypeDefaultDescription
pageinteger1One-based page number. Zero, negative or empty values use 1.
pageSizeinteger20Records per page, maximum 1000. Zero, negative or empty values use 20; values above 1000 are rejected.
groupIdstringNo filterExact margin group ID. Omit to query all your groups. If supplied, it must be a positive integer expressed as a string. Empty/whitespace values and group names are invalid.
sortBystringcreatedAtcreatedAt, periodOutstandingAmount, periodInterestAmount or annualInterestRate. Empty uses createdAt.
sortDirectionstringDESCASC or DESC. Input is case-insensitive. Empty uses DESC.

Quantities are in each record's currency. There is no quoteCurrency parameter or valuation-currency conversion.

Pagination and filtering

  • Non-integer or out-of-range integer pagination values return 1002. An integer pageSize above 1000 returns 100400; it is not silently capped.
  • Sorting is applied before pagination. A page beyond the end returns list: [] and retains the matching totalSize. There is no pageNum field.
  • A valid group without interest history returns success with totalSize: 0 and list: []. An unavailable or deleted group returns an error instead.

Response fields

FieldTypeDescription
codeinteger200 means success; any other value indicates an error.
messagestringResult message.
data.pageintegerPage number used.
data.pageSizeintegerPage size used.
data.totalSizeintegerTotal matching records, not just the current page.
data.listarray of objectsInterest records on this page.

Interest record: data.list[]

IDs, quantities and annual interest rates are strings. Timestamps are Unix milliseconds. Each record keeps its applicable historical rate rather than replacing it with the current rate.

FieldTypeDescription
groupIdstringMargin group ID.
groupNamestringGroup name.
primeTypestringAccount family of the member carrying the debt: dma or rapidx.
memberIdstringDMA account ID or RapidX Portfolio ID of that member.
venuestringMember's exchange; for RapidX, its specific Portfolio venue.
currencystringCurrency used for the calculation base and interest quantities.
currencyDetailsobject or nullCurrency metadata; see below.
interestRateTypestringFLOATING for the standard floating rate, or FIXED for a fixed rate. FIXED can also result from an administrative fixed-rate adjustment; it does not necessarily identify a fixed-term loan.
termDaysinteger or nullFixed-term duration in days when applicable and available. null for floating records and for administratively fixed-rate records without a fixed term.
maturityDateinteger or nullFixed-term maturity time in Unix milliseconds when applicable and available. May be null even when interestRateType is FIXED.
annualInterestRatestringAnnual rate applied to this record, as a decimal. "0.1345" means 13.45% annually, not a daily rate.
periodInterestAmountstringNew interest charged for this period, in currency, not accumulated unpaid interest.
periodOutstandingAmountstringCalculation base used for this record, in currency. Usually includes outstanding principal and interest, and may also include borrowing repaid within the preceding cycle but still subject to this interest calculation. It is not simply the period-end unpaid balance.
createdAtintegerRecord creation time in Unix milliseconds.

Do not infer a fixed borrowing duration from interestRateType=FIXED alone. Rate type and loan duration are separate concepts. Likewise, do not replace periodOutstandingAmount with the current outstanding balance when interpreting a historical interest record.

currencyDetails

FieldTypeDescription
idintegerCurrency identifier.
iconUrlstringCurrency icon URL.
currencyNamestringCurrency display name.
slugstringCurrency slug.
referenceAssetIdinteger or nullReference asset identifier.
multipliernumber or nullConversion multiplier to the reference asset.

The response panel includes floating, administratively fixed-rate and fixed-term record examples, plus empty-list and error responses.

Error codes

Errors can return HTTP 200 with a non-success JSON code. Check code, not HTTP status alone. See Error Codes for shared errors.

CodeWhen it occursWhat to do
1002A pagination value cannot be converted to a supported integer.Send integer values; the message identifies the affected field.
100400Invalid group ID, pageSize above 1000, or invalid sorting parameters.Use the supported values. Omit groupId for all groups; do not send an empty value.
-1The requested group is unavailable; observed message: resource unavailable.Check the group ID and whether it still exists.
2000Signature verification fails.Check the signature and authentication headers.
2003The calling API key level is not allowed.Use a Main User Level API key.
2004The key lacks a required permission.Use a key with READ permission.
100429Rate limit exceeded.Reduce the request rate.
Query Params
integer
Defaults to 1

One-based page number; non-positive or empty values use 1. Invalid integer format or range returns 1002.

integer
≤ 1000
Defaults to 20

Records per page; non-positive or empty values use 20. More than 1000 returns 100400.

string
enum
Defaults to createdAt

Historical record sort field. Empty uses createdAt.

Allowed:
string
enum
Defaults to DESC

Sort direction. Input is case-insensitive. Empty uses DESC.

Allowed:
string

Exact group ID. Omit for all groups; empty, whitespace and group names are invalid.

Headers
string
required

Current Unix timestamp in seconds, also used in the signature.

string
required

HMAC-SHA256 hex signature; see Authentication.

string
required

Current Unix timestamp in microseconds.

Response

Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here! Or choose an example:
application/json