Engine
Market data
Where the engine and the app get their prices, books and trades.
Engine feeds
| Feed | Source | Details |
|---|---|---|
| Hyperliquid WebSocket | wss://api.hyperliquid.xyz/ws (testnet with HL_NETWORK=testnet) | Subscribes to allMids, plus l2Book and trades for each coin: @107 (HYPE spot), HYPE (perp), @334 (KNTQ spot) and ARB_HL_COIN if set. Ping every 25 s; reconnects with a backoff from 1 s doubling up to 30 s |
| Hyperliquid info API | https://api.hyperliquid.xyz/info | Asset contexts (funding, mark) every 30 s. In live mode also meta, spotMeta, open orders, fills and balances |
| Montra feed | Elysium RPC (V4 quoter) + https://api.montramarkets.xyz/api/tokens/{token} | Every 8 s: quote a 0.05 HYPE buy, then sell those tokens back. Mid = √(buy price × sell price), the pool's price with the fee taken out on both sides. Token metadata (fee, symbol) refreshed every 120 s |
| Elysium RPC | ELYSIUM_RPC_URL, default https://rpc.elysium.kinetiq.xyz | Treasury limits, pending creator fees, FeeSplitter pool id, balances, quotes |
The Montra feed refuses to price a pool if Montra's API reports a poolId different from the one the engine derives. The heartbeat reports each feed's health: Hyperliquid OK if a message arrived in the last 15 s, Montra if a price is under 60 s old (GET /api/v1/status, engine.feeds).
Markets
| Id | Venue | Kind | Base / quote | Hyperliquid coin | Used by |
|---|---|---|---|---|---|
MOTION-HYPE | Montra | pool | MOTION / HYPE | token: MOTION_TOKEN, else the stand-in | montra-mm, arb |
HYPE-USDC | HyperCore | spot | HYPE / USDC | @107 | hypercore-mm |
HYPE-PERP | HyperCore | perp | HYPE / USDC | HYPE | hedge |
KNTQ-USDC | HyperCore | spot | KNTQ / USDC | @334 | hypercore-mm |
Hyperliquid's price rule: at most 5 significant figures and 6 − size decimals (perps) or 8 − size decimals (spot) decimals. Sizes are rounded down to the market's size decimals (2 for the HyperCore markets, 0 for the pool).
What the app reads directly
The app does not route market data through the API. It reads books and trades from Hyperliquid's WebSocket, candles and contexts from Hyperliquid's info API, and token info, trades and candles from Montra's API. See Architecture.