/api/sol/perp/* REST endpoints field-for-field. All *UsdE6 and price/size integers are native ClickHouse UInt64 returned as Int64-safe values (divide by 1,000,000 for USD-scaled fields). Timestamps are millis-since-epoch.
marketId is always <venue>:<SYMBOL>-PERP (e.g. jup:SOL-PERP). Today only jup is supported.
perpMarkets
List supported perpetuals with last-24h volume and trade counts.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
venue | String | no | Filter to one venue (e.g. "jup"). Defaults to all. |
Return type
volume24HUsd is in USDC e6 (Jupiter size_usd_delta convention).
Example
perpCandles
OHLCV candles per market and timeframe. Backed by perp_ohlcv_{1s,1m,5m,15m,1h,4h,1d}.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
marketId | String! | yes | jup:SOL-PERP etc. |
timeframe | String | no | One of 1s, 1m (default), 5m, 15m, 1h, 4h, 1d. |
limit | Int | no | Default 100, max 2000. |
from | String | no | Inclusive lower bound, ms-since-epoch as a string. |
to | String | no | Inclusive upper bound, ms-since-epoch as a string. |
Return type
Example
perpOi
Per-minute open-interest series sampled from perp_positions. Read this alongside perpCandles to overlay long/short OI on the chart.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
marketId | String! | yes | |
limit | Int | no | Default 100, max 2000. |
from | String | no | Ms-since-epoch as string. |
to | String | no | Ms-since-epoch as string. |
Return type
perpTrades
Recent fills (taker prints) on a market, newest first.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
marketId | String! | yes | |
limit | Int | no | Default 100, max 1000. |
from | String | no | Ms-since-epoch. |
to | String | no | Ms-since-epoch. |
Return type
perpLiquidations
Liquidation events on a market, newest first.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
marketId | String! | yes | |
limit | Int | no | Default 100, max 1000. |
from | String | no | |
to | String | no |
Return type
perpMarketOrders
Pending or historical trigger orders on a market — feeds the orderbook view. Aggregates the multi-row perp_orders event log per orderId via argMax. Excludes orders whose underlying position has been liquidated or fully closed.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
marketId | String! | yes | |
state | String | no | open (default), filled, cancelled, all. |
limit | Int | no | Default 100, max 2000. |
Return type
triggerAbove encodes the comparison direction: true = fire when oracle ≥ triggerPrice, false = fire when oracle ≤ triggerPrice. The combination with side derives whether the order is a TP or SL.
perpWalletPositions
Open positions for one wallet. Latest row per position_pubkey from perp_positions FINAL where is_open = 1.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
address | String! | yes | Wallet pubkey, ≥ 32 chars. |
Return type
perpWalletTrades
Fills for one wallet across every market.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
address | String! | yes | |
limit | Int | no | Default 100, max 1000. |
from | String | no | |
to | String | no |
Return type
perpWalletLiquidations
Liquidation events for one wallet across every market.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
address | String! | yes | |
limit | Int | no | Default 100, max 1000. |
from | String | no | |
to | String | no |
Return type
perpWalletOrders
Pending or historical trigger orders for one wallet. Same PerpOrder shape as perpMarketOrders.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
address | String! | yes | |
state | String | no | open (default), filled, cancelled, all. |
limit | Int | no | Default 100, max 1000. |
Example
perpWalletPnl
Per-(market, venue) volume and fees aggregate for one wallet. Sourced from the _mv_perp_wallet_positions materialized view.
Arguments
| Name | Type | Required | Description |
|---|---|---|---|
address | String! | yes |
Return type
grossPnlE6 is intentionally 0 until the parser surfaces realized PnL; netPnlE6 exposes only the negative-fees component to make this state explicit. Don’t display either as “PnL” until both fields are populated.
