Skip to main content
The hyperliquid.predictions.trades table contains every Hyperliquid HIP-4 prediction-market trade. event_name = 'Settlement' rows mark settlement events; all other rows are regular trades.

Table Columns

Identifiers

Column NameDescription
event_nameEvent type: ‘Trade’ for a fill, ‘Settlement’ for a settlement event.
projectTop-level project namespace (hyperliquid).
protocolProtocol within the project (hyperliquid_hip4).
chainThe blockchain network (hyperliquid).
exchange_typeTrade execution venue type (orderbook).
coinHL-native side-token identifier (e.g. ‘#54760’).
encodingHL-canonical numeric encoding for the side-token.
outcome_idHIP-4 outcome identifier (shared by both token sides).
token_sideWhich side of the outcome’s YES/NO pair the row represents (0 or 1).
asset_idHL-canonical numeric identifier for the side-token.
trade_idThe HL trade ID (tid).
transaction_hashThe HL transaction hash for the fill.
timestampUTC timestamp of the fill.
unique_idDeterministic unique identifier per row.
_created_atRow creation timestamp.
_updated_atRow last update timestamp.

Counterparties

Column NameDescription
buyer_addressBuyer of the side-token.
seller_addressSeller of the side-token.
maker_addressMaker (resting-order) address. NULL on synthetic mints.
taker_addressTaker (aggressing-order) address.
side_nameOne of ‘BUY’, ‘SELL’, ‘SETTLE’. NULL on some synthetic-mint rows.
buyer_dirDirection string for the buyer leg (e.g. ‘Open Long’, ‘Settlement’).
seller_dirDirection string for the seller leg.
buyer_crossedWhether the buyer’s order was the aggressor.
seller_crossedWhether the seller’s order was the aggressor.
buyer_order_idOrder ID for the buyer’s order.
seller_order_idOrder ID for the seller’s order.
buyer_twap_idTWAP order ID if the buyer’s order was a TWAP order.
seller_twap_idTWAP order ID if the seller’s order was a TWAP order.

Trade Economics

Column NameDescription
priceTrade price as a 0..1 probability.
sizeTrade size in side-tokens.
collateral_tokenCollateral token symbol for the trade (e.g. ‘USDH’).
collateral_token_decimalsDecimals of the collateral token.
collateral_amountNative-unit collateral value of the trade.
usd_exchange_rateUSD price of the collateral token. 1.0 for USDH.
usd_collateral_amountUSD value of the trade.

Fees

Column NameDescription
fee_tokenToken in which the trade fee was paid (e.g. ‘USDH’, ‘USDC’). NULL when no fee was charged.
seller_fee_tokenToken in which the seller’s fee was paid. HIP-4 buyer and seller can pay in different tokens.
buyer_fee_tokenToken in which the buyer’s fee was paid.
buyer_feeBuyer-side fee in buyer_fee_token units.
seller_feeSeller-side fee in seller_fee_token units.
buyer_fee_usdBuyer-side fee in USD.
seller_fee_usdSeller-side fee in USD.
tx_feeTotal fee for the transaction in native token units.
tx_fee_usdTotal fee for the transaction in USD.
builder_feeTotal builder fee for the trade.
buyer_builder_feeBuilder fee paid by the buyer, in buyer_fee_token units.
seller_builder_feeBuilder fee paid by the seller, in seller_fee_token units.
buyer_builder_fee_usdBuyer’s builder fee in USD.
seller_builder_fee_usdSeller’s builder fee in USD.
buyer_builder_addressBuilder address that received the buyer’s builder fee.
seller_builder_addressBuilder address that received the seller’s builder fee.

Position & PnL

Column NameDescription
buyer_start_positionBuyer’s position in this side-token before the trade.
seller_start_positionSeller’s position in this side-token before the trade.
buyer_closed_pnlClosed PnL realized by the buyer on this fill.
seller_closed_pnlClosed PnL realized by the seller on this fill.
is_synthetic_mintTrue when the trade represents a synthetic mint, burn, or cross-coin pairing.

Sample Query

SELECT
  timestamp,
  coin,
  side_name,
  size,
  price,
  usd_collateral_amount,
  buyer_address,
  seller_address
FROM hyperliquid.predictions.trades
WHERE timestamp >= CURRENT_DATE - 7
  AND event_name = 'Trade'
ORDER BY timestamp DESC
LIMIT 100