GET
GetFundingRatePublicGet current and predicted funding rates for perpetual markets.
Request
| Parameter | Type | Description |
|---|---|---|
market_idoptional | uint32 |
Response
| Field | Type | Description |
|---|---|---|
market_id | uint32 | |
funding_rate | int64 | 8 decimals, e.g. 100000 = 0.001 = 0.1% |
mark_price | int64 | Mark price used for funding |
index_price | int64 | Index price (oracle) |
next_funding_time | int64 | UNIX nanos until next funding |
predicted_rate | int64 | Predicted next funding rate |
Example
Request
import { RealmClient } from '@realm/sdk';const client = new RealmClient('https://api.realm.com');const response = await client.getFundingRate({ /* params */ });console.log(response);
Response
{// Response fields}