API
REST
Every route with its parameters, body and response fields.
Every route, with its parameters, body and response fields, generated from the same schemas the API validates with. Shared rules (values, paging, signing) are on API, and the codes a route can fail with are on Errors.
Exchange
GET /health
Liveness: 200 { status } always.
Response 200
| Field | Type | Description |
|---|
status | string | |
GET /v1/status
Mode, chain mode, program id, withdrawals and faucet switches, engine state, last batch.
Response 200
| Field | Type | Description |
|---|
mode | fixture | live | |
chain | off | localnet | mainnet | |
programId | address | null | the Strobe program when chain is on; null when off |
withdrawalsEnabled | boolean | |
faucetEnabled | boolean | |
faucetAmount | decimal | USDC per claim |
engine | object | |
engine.state | connecting | live | unreachable | |
engine.reachable | boolean | |
lastBatch | object | null | |
lastBatch.number | integer | 1 or more. |
lastBatch.slot | integer | null | the Solana slot the batch landed in; null while chain is off |
lastBatch.accountsTouched | integer | |
lastBatch.stateHash | string | hex SHA-256 of the full engine state after the batch |
lastBatch.signature | signature | null | the batch transaction's signature; null while chain is off |
lastBatch.chain | off | localnet | mainnet | |
lastBatch.at | epoch ms | |
lastBatch.time | ISO 8601 UTC | |
season | string | |
contractVersion | string | |
serverTime | epoch ms | |
GET /v1/markets
The three markets with their rules and live ticker.
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].symbol | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].base | string | |
items[].quote | string | |
items[].tickSize | decimal | |
items[].lotSize | decimal | |
items[].minSize | decimal | |
items[].priceDecimals | integer | decimal places of a price and of a size, from the tick and lot sizes |
items[].sizeDecimals | integer | |
items[].maxLeverage | integer | |
items[].maintenanceMarginFraction | decimal | maintenance margin as a fraction of notional (half the initial margin at max leverage) |
items[].takerFeeBps | decimal | |
items[].makerFeeBps | decimal | |
items[].fundingIntervalSeconds | integer | |
items[].ticker | object | |
items[].ticker.market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].ticker.index | decimal | median of the Coinbase and Kraken tickers |
items[].ticker.mark | decimal | |
items[].ticker.last | decimal | null | |
items[].ticker.bestBid | decimal | null | |
items[].ticker.bestAsk | decimal | null | |
items[].ticker.fundingRate | signed decimal | this hour's funding rate as a fraction of notional (longs pay when positive) |
items[].ticker.nextFundingAt | epoch ms | |
items[].ticker.nextFundingTime | ISO 8601 UTC | |
items[].ticker.volume24h | decimal | USDC notional traded over the last 24 h |
items[].ticker.open24h | decimal | the mark 24 h ago, and the change since as a fraction (0.0123 = +1.23%) |
items[].ticker.change24h | signed decimal | |
items[].ticker.openInterest | decimal | open interest in base units (one side) |
items[].ticker.at | epoch ms | |
asOf | ISO 8601 UTC | |
GET /v1/markets/{market}/book
Order book levels with sequence number.
Path
| Field | Type | Description |
|---|
market | market | |
Query
| Field | Type | Description |
|---|
depthoptional | integer | 1 to 100. |
Response 200
| Field | Type | Description |
|---|
market | SOL-PERP | BTC-PERP | ETH-PERP | |
seq | integer | sequence of the last change included; deltas continue from it |
bids | any[][] | |
asks | any[][] | |
at | epoch ms | |
GET /v1/markets/{market}/trades
Recent trades, newest first, each with the taker order ack time.
Path
| Field | Type | Description |
|---|
market | market | |
Query
| Field | Type | Description |
|---|
limitoptional | integer | 1 to 200. |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].id | id | |
items[].market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].price | decimal | |
items[].size | decimal | |
items[].takerSide | buy | sell | |
items[].ackMicros | integer µs | the taker order's receive-to-ack time in the engine |
items[].ackSource | engine | fixture | |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
asOf | ISO 8601 UTC | |
GET /v1/markets/{market}/candles
Candles by interval, oldest first.
Path
| Field | Type | Description |
|---|
market | market | |
Query
| Field | Type | Description |
|---|
interval | 1m | 5m | 15m | 1h | 4h | 1d | |
endoptional | epoch ms | candles starting before this epoch ms (default: now) |
limitoptional | integer | 1 to 1000. |
Response 200
| Field | Type | Description |
|---|
market | SOL-PERP | BTC-PERP | ETH-PERP | |
interval | 1m | 5m | 15m | 1h | 4h | 1d | |
items | object[] | |
items[].start | epoch ms | bucket start, epoch ms |
items[].open | decimal | |
items[].high | decimal | |
items[].low | decimal | |
items[].close | decimal | |
items[].volume | decimal | base units traded |
items[].notional | decimal | USDC traded |
items[].trades | integer | |
asOf | ISO 8601 UTC | |
GET /v1/markets/{market}/ticker
Index, mark, funding, 24 h volume and change, open interest.
Path
| Field | Type | Description |
|---|
market | market | |
Response 200
| Field | Type | Description |
|---|
market | SOL-PERP | BTC-PERP | ETH-PERP | |
index | decimal | median of the Coinbase and Kraken tickers |
mark | decimal | |
last | decimal | null | |
bestBid | decimal | null | |
bestAsk | decimal | null | |
fundingRate | signed decimal | this hour's funding rate as a fraction of notional (longs pay when positive) |
nextFundingAt | epoch ms | |
nextFundingTime | ISO 8601 UTC | |
volume24h | decimal | USDC notional traded over the last 24 h |
open24h | decimal | the mark 24 h ago, and the change since as a fraction (0.0123 = +1.23%) |
change24h | signed decimal | |
openInterest | decimal | open interest in base units (one side) |
at | epoch ms | |
GET /v1/latency
Engine receive-to-ack p50/p99 in microseconds over a window.
Response 200
| Field | Type | Description |
|---|
p50Micros | integer µs | |
p99Micros | integer µs | |
samples | integer | |
windowSeconds | integer | |
source | engine | fixture | |
at | epoch ms | |
GET /v1/batches
Settlement batches, newest first.
Query
| Field | Type | Description |
|---|
cursoroptional | string | |
limitoptional | integer | 1 to 100. Default 24. |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].number | integer | 1 or more. |
items[].slot | integer | null | the Solana slot the batch landed in; null while chain is off |
items[].accountsTouched | integer | |
items[].stateHash | string | hex SHA-256 of the full engine state after the batch |
items[].signature | signature | null | the batch transaction's signature; null while chain is off |
items[].chain | off | localnet | mainnet | |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
page | object | |
page.nextCursor | string | null | |
page.hasMore | boolean | |
asOf | ISO 8601 UTC | |
chain | off | localnet | mainnet | |
GET /v1/leaderboard
Season Zero standings, plus the rank of wallet.
Query
| Field | Type | Description |
|---|
cursoroptional | string | |
limitoptional | integer | 1 to 100. Default 24. |
walletoptional | address | |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].rank | integer | 1 or more. |
items[].address | address | |
items[].filledNotional | decimal | |
items[].points | decimal | |
items[].pnl | signed decimal | |
page | object | |
page.nextCursor | string | null | |
page.hasMore | boolean | |
asOf | ISO 8601 UTC | |
season | string | |
traders | integer | |
me | object | null | the `wallet` asked about; null when not asked or not ranked yet |
me.rank | integer | 1 or more. |
me.address | address | |
me.filledNotional | decimal | |
me.points | decimal | |
me.pnl | signed decimal | |
GET /v1/invites/{code}
Whether an invite code is valid, used or unknown.
Path
| Field | Type | Description |
|---|
code | string | |
Response 200
| Field | Type | Description |
|---|
code | string | |
status | valid | used | unknown | |
Accounts
GET /v1/accounts/{address}
Equity, margins, leverage, points, rank and faucet state.
Path
| Field | Type | Description |
|---|
address | address | |
Response 200
| Field | Type | Description |
|---|
address | address | |
admitted | boolean | entered Season Zero with an invite code |
collateral | signed decimal | deposits + faucet + realized PnL + funding - fees - withdrawals |
unrealizedPnl | signed decimal | |
equity | signed decimal | |
initialMargin | decimal | initial margin of open positions at their chosen leverage |
maintenanceMargin | decimal | |
freeMargin | decimal | equity - initial margin of positions and resting orders, floored at 0 |
notional | decimal | |
leverageUsed | decimal | notional / equity |
leverage | Record<string, integer> | the chosen leverage per market (1 to max) |
points | decimal | |
rank | integer | null | |
filledNotional | decimal | |
faucet | object | |
faucet.enabled | boolean | |
faucet.amount | decimal | |
faucet.nextClaimAt | epoch ms | null | null when a claim is possible now |
at | epoch ms | |
GET /v1/accounts/{address}/positions
Open positions with live PnL and liquidation price.
Path
| Field | Type | Description |
|---|
address | address | |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].side | long | short | |
items[].size | decimal | absolute size in base units |
items[].entryPrice | decimal | |
items[].markPrice | decimal | |
items[].notional | decimal | |
items[].leverage | integer | |
items[].initialMargin | decimal | |
items[].maintenanceMargin | decimal | |
items[].unrealizedPnl | signed decimal | |
items[].realizedPnl | signed decimal | |
items[].funding | signed decimal | net funding since the position opened; positive = received |
items[].liquidationPrice | decimal | null | null when no price liquidates it |
items[].openedAt | epoch ms | |
items[].openedTime | ISO 8601 UTC | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/orders
Resting orders.
Path
| Field | Type | Description |
|---|
address | address | |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].orderId | id | |
items[].clientOrderId | string | null | |
items[].market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].side | buy | sell | |
items[].kind | limit | market | |
items[].price | decimal | null | null for a market order |
items[].size | decimal | |
items[].filledSize | decimal | |
items[].remainingSize | decimal | |
items[].timeInForce | gtc | ioc | post_only | |
items[].reduceOnly | boolean | |
items[].status | resting | partially_filled | filled | cancelled | |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/fills
Fills, newest first, with ack time and the price at the click.
Path
| Field | Type | Description |
|---|
address | address | |
Query
| Field | Type | Description |
|---|
cursoroptional | string | |
limitoptional | integer | 1 to 100. Default 24. |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].tradeId | id | |
items[].orderId | id | |
items[].market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].side | buy | sell | |
items[].liquidity | maker | taker | |
items[].price | decimal | |
items[].size | decimal | |
items[].notional | decimal | |
items[].fee | signed decimal | USDC; maker fills pay 0 |
items[].realizedPnl | signed decimal | |
items[].points | decimal | |
items[].liquidation | boolean | a fill of the engine's liquidation order against this account |
items[].ackMicros | integer µs | null | the order's receive-to-ack time; null on maker fills (the taker's order was the one acked) |
items[].ackSource | engine | fixture | |
items[].arrivalPrice | decimal | null | the best price on the other side when the order arrived: the price at the click |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
page | object | |
page.nextCursor | string | null | |
page.hasMore | boolean | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/funding
Hourly funding payments, newest first.
Path
| Field | Type | Description |
|---|
address | address | |
Query
| Field | Type | Description |
|---|
cursoroptional | string | |
limitoptional | integer | 1 to 100. Default 24. |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].rate | signed decimal | the hour's rate |
items[].positionSize | signed decimal | signed position size at the funding time (negative = short) |
items[].indexPrice | decimal | the index price at the funding instant; funding settles at the index, not the mark |
items[].payment | signed decimal | USDC; positive = received |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
page | object | |
page.nextCursor | string | null | |
page.hasMore | boolean | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/transfers
Deposits, withdrawals and faucet claims, newest first.
Path
| Field | Type | Description |
|---|
address | address | |
Query
| Field | Type | Description |
|---|
cursoroptional | string | |
limitoptional | integer | 1 to 100. Default 24. |
kindoptional | deposit | withdrawal | faucet | |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].id | id | |
items[].kind | deposit | withdrawal | faucet | |
items[].amount | decimal | |
items[].status | pending | confirmed | paid | failed | deposits: pending → confirmed; withdrawals: pending → paid; faucet claims: confirmed |
items[].signature | signature | null | |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
page | object | |
page.nextCursor | string | null | |
page.hasMore | boolean | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/liquidations
Liquidations, newest first.
Path
| Field | Type | Description |
|---|
address | address | |
Query
| Field | Type | Description |
|---|
cursoroptional | string | |
limitoptional | integer | 1 to 100. Default 24. |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].market | SOL-PERP | BTC-PERP | ETH-PERP | |
items[].side | long | short | |
items[].size | decimal | |
items[].price | decimal | |
items[].fee | decimal | liquidation fee to the insurance fund |
items[].realizedPnl | signed decimal | |
items[].at | epoch ms | |
items[].time | ISO 8601 UTC | |
page | object | |
page.nextCursor | string | null | |
page.hasMore | boolean | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/equity
Equity points over time for the portfolio chart.
Path
| Field | Type | Description |
|---|
address | address | |
Query
| Field | Type | Description |
|---|
rangeoptional | 1d | 7d | 30d | all | |
Response 200
| Field | Type | Description |
|---|
address | address | |
range | 1d | 7d | 30d | all | |
points | object[] | |
points[].at | epoch ms | |
points[].equity | signed decimal | |
asOf | ISO 8601 UTC | |
GET /v1/accounts/{address}/invites
The wallet's own three invite codes.
Path
| Field | Type | Description |
|---|
address | address | |
Response 200
| Field | Type | Description |
|---|
items | object[] | |
items[].code | string | |
items[].status | valid | used | |
items[].usedBy | address | null | |
items[].usedAt | epoch ms | null | |
asOf | ISO 8601 UTC | |
Sessions and actions
GET /v1/sessions/nonce
A nonce and the fields of the session message the wallet signs.
Response 200
| Field | Type | Description |
|---|
domain | string | |
uri | string | |
chainId | string | |
statement | string | |
nonce | string | |
nonceToken | string | send back with the proof |
issuedAt | ISO 8601 UTC | |
nonceExpiresAt | ISO 8601 UTC | the message must be signed and sent before this |
sessionExpiresAt | ISO 8601 UTC | the session key's expiry the message must carry (issuedAt + 7 days) |
POST /v1/sessions
Verify the signed session message, admit the wallet with its invite code, register the session key.
Body
| Field | Type | Description |
|---|
wallet | address | |
sessionKey | address | |
signedMessage | base64 | the exact bytes the wallet signed, base64 |
signature | base64 | the wallet's ed25519 signature over them, base64 |
nonceToken | string | |
Response 201
| Field | Type | Description |
|---|
session | object | |
session.wallet | address | |
session.sessionKey | address | |
session.status | active | expired | revoked | |
session.expiresAt | epoch ms | |
session.expiresTime | ISO 8601 UTC | |
session.createdAt | epoch ms | |
admittedNow | boolean | true when this registration admitted the wallet with its invite code |
invites | object[] | the wallet's own three codes to pass on |
invites[].code | string | |
invites[].status | valid | used | |
invites[].usedBy | address | null | |
invites[].usedAt | epoch ms | null | |
GET /v1/sessions/{sessionKey}
A session key: active, expired or revoked.
Path
| Field | Type | Description |
|---|
sessionKey | string | |
Response 200
| Field | Type | Description |
|---|
wallet | address | |
sessionKey | address | |
status | active | expired | revoked | |
expiresAt | epoch ms | |
expiresTime | ISO 8601 UTC | |
createdAt | epoch ms | |
POST /v1/actions
A signed trading action (the WebSocket takes the same envelope).
Body
| Field | Type | Description |
|---|
account | address | the trading wallet |
sessionKey | address | the session key that signs; registered to `account` |
id | string | the client's id for this action, echoed on its ack or reject 1 to 64 letters, digits, - or _. |
nonce | integer | epoch ms at signing; accepted within ±ACTION_WINDOW_MS of the server clock, once per session key |
action | object, one of several shapes | |
signature | base64 | the session key's ed25519 signature over actionMessage(unsigned), base64 |
type: "place_order"
| Field | Type | Description |
|---|
type | "place_order" | |
market | SOL-PERP | BTC-PERP | ETH-PERP | |
side | buy | sell | |
kind | limit | market | |
size | decimal | |
priceoptional | decimal | limit orders only |
timeInForceoptional | gtc | ioc | post_only | limit orders only; absent = gtc |
reduceOnlyoptional | boolean | |
clientOrderIdoptional | string | 1 to 64 letters, digits, - or _. |
type: "cancel_order"
| Field | Type | Description |
|---|
type | "cancel_order" | |
market | SOL-PERP | BTC-PERP | ETH-PERP | |
orderId | id | |
type: "cancel_all"
| Field | Type | Description |
|---|
type | "cancel_all" | |
marketoptional | SOL-PERP | BTC-PERP | ETH-PERP | |
type: "close_position"
| Field | Type | Description |
|---|
type | "close_position" | |
market | SOL-PERP | BTC-PERP | ETH-PERP | |
sizeoptional | decimal | |
type: "set_leverage"
| Field | Type | Description |
|---|
type | "set_leverage" | |
market | SOL-PERP | BTC-PERP | ETH-PERP | |
leverage | integer | |
type: "claim_faucet"
| Field | Type | Description |
|---|
type | "claim_faucet" | |
type: "revoke_session"
| Field | Type | Description |
|---|
type | "revoke_session" | |
kind: "order"
| Field | Type | Description |
|---|
id | string | the action's client id |
ackMicros | integer µs | receive-to-ack time in the engine |
ackSource | engine | fixture | |
at | epoch ms | |
kind | "order" | |
action | place_order | close_position | |
orderId | id | |
clientOrderId | string | null | |
market | SOL-PERP | BTC-PERP | ETH-PERP | |
side | buy | sell | |
status | resting | partially_filled | filled | cancelled | |
size | decimal | |
filledSize | decimal | |
remainingSize | decimal | |
averagePrice | decimal | null | volume-weighted fill price; null without fills |
fills | object[] | |
fills[].tradeId | id | |
fills[].price | decimal | |
fills[].size | decimal | |
fills[].fee | signed decimal | |
fills[].liquidity | maker | taker | |
arrivalPrice | decimal | null | the best price on the other side when the order arrived (the price at the click); null on an empty side |
kind: "cancel"
| Field | Type | Description |
|---|
id | string | the action's client id |
ackMicros | integer µs | receive-to-ack time in the engine |
ackSource | engine | fixture | |
at | epoch ms | |
kind | "cancel" | |
action | cancel_order | cancel_all | |
cancelled | id[] | |
kind: "leverage"
| Field | Type | Description |
|---|
id | string | the action's client id |
ackMicros | integer µs | receive-to-ack time in the engine |
ackSource | engine | fixture | |
at | epoch ms | |
kind | "leverage" | |
market | SOL-PERP | BTC-PERP | ETH-PERP | |
leverage | integer | |
kind: "faucet"
| Field | Type | Description |
|---|
id | string | the action's client id |
ackMicros | integer µs | receive-to-ack time in the engine |
ackSource | engine | fixture | |
at | epoch ms | |
kind | "faucet" | |
amount | decimal | |
nextClaimAt | epoch ms | |
kind: "revoke"
| Field | Type | Description |
|---|
id | string | the action's client id |
ackMicros | integer µs | receive-to-ack time in the engine |
ackSource | engine | fixture | |
at | epoch ms | |
kind | "revoke" | |
sessionKey | address | |
Chain transactions
POST /v1/deposits/build
Build a deposit transaction for the wallet to sign (chain on).
Body
| Field | Type | Description |
|---|
wallet | address | |
amount | decimal | |
Response 200
| Field | Type | Description |
|---|
id | string | |
transactionBase64 | base64 | |
blockhash | string | |
lastValidBlockHeight | integer | |
cosigned | boolean | the server adds its signature after the wallet's (withdrawals: the engine co-signs) |
POST /v1/withdrawals/build
Build a withdrawal the engine co-signs (chain on).
Body
| Field | Type | Description |
|---|
wallet | address | |
amount | decimal | |
Response 200
| Field | Type | Description |
|---|
id | string | |
transactionBase64 | base64 | |
blockhash | string | |
lastValidBlockHeight | integer | |
cosigned | boolean | the server adds its signature after the wallet's (withdrawals: the engine co-signs) |
POST /v1/transactions/submit
Relay signed bytes, or report a wallet-sent signature.
mode: "relay"
| Field | Type | Description |
|---|
mode | "relay" | |
buildId | string | |
signedTransactionBase64 | base64 | |
idempotencyKey | string | 8 to 64 characters. |
mode: "wallet-sent"
| Field | Type | Description |
|---|
mode | "wallet-sent" | |
buildId | string | |
signature | signature | |
idempotencyKey | string | 8 to 64 characters. |
Response 200
| Field | Type | Description |
|---|
id | string | |
status | submitted | unconfirmed | confirmed | finalized | failed | expired | |
signatureoptional | string | |
erroroptional | object | |
error.stage | build | wallet-rejected | wallet-changed | simulation | send | confirm | |
error.message | string | |
error.nextStepoptional | string | |
error.retryable | boolean | |
error.programoptional | object | |
error.program.address | string | |
error.program.code | integer | null | |
error.program.name | string | null | |
GET /v1/transactions/{id}
A built transaction: submitted, confirmed, failed or expired.
Path
| Field | Type | Description |
|---|
id | string | |
Response 200
| Field | Type | Description |
|---|
id | string | |
status | submitted | unconfirmed | confirmed | finalized | failed | expired | |
signatureoptional | string | |
erroroptional | object | |
error.stage | build | wallet-rejected | wallet-changed | simulation | send | confirm | |
error.message | string | |
error.nextStepoptional | string | |
error.retryable | boolean | |
error.programoptional | object | |
error.program.address | string | |
error.program.code | integer | null | |
error.program.name | string | null | |