Skip to main content
Schema: hypercore.core Table: ez_perp_funding_payments Type: View

What

Per-user funding payments on perpetual positions, enriched with market metadata. Funding is exchanged between long and short holders every hour based on the funding rate. Positive funding_amount means the user received funding; negative means they paid.

Key Use Cases

  • Analyzing per-user funding costs/income
  • Calculating net funding exposure by coin or address
  • Understanding funding rate impact on position profitability
  • Tracking funding payment distribution across the market

Important Relationships

  • Derived from silver__funding_payments which parses silver__misc_events
  • Enriched with core__dim_perp_markets via coin
  • Related to core__ez_perp_funding_rates for market-level rates

Commonly-used Fields

  • user_address: Address receiving/paying funding
  • coin: Perp asset identifier
  • funding_amount: Funding received (positive) or paid (negative)
  • position_size: User’s position size at time of funding
  • funding_rate: Funding rate applied

Sample queries

-- Funding payment P&L: who profits from funding? (last 7 days)
SELECT
    user_address,
    coin,
    COUNT(*) AS payment_count,
    ROUND(SUM(funding_amount), 2) AS net_funding,
    ROUND(SUM(CASE WHEN funding_amount > 0 THEN funding_amount ELSE 0 END), 2) AS received,
    ROUND(SUM(CASE WHEN funding_amount < 0 THEN funding_amount ELSE 0 END), 2) AS paid
FROM hypercore.core.ez_perp_funding_payments
WHERE block_timestamp >= DATEADD('day', -7, CURRENT_DATE)
    AND coin = 'BTC'
GROUP BY 1, 2
ORDER BY net_funding DESC
LIMIT 20;

Columns

Column NameData TypeDescription
BLOCK_NUMBERNUMBERL1 block number containing this event.
BLOCK_TIMESTAMPTIMESTAMP_NTZBlock production timestamp on the Hyperliquid L1. This is the canonical time for ordering blockchain events.
EVENT_TIMESTAMPTIMESTAMP_NTZExact timestamp of the event from the L1, extracted from the event payload.
USER_ADDRESSTEXTHyperCore address of the primary user involved in this event.
COINTEXTRaw asset identifier. Perps use plain ticker (e.g. BTC), spot uses @token_index format (e.g. @2), prelaunch uses xyz:name prefix.
ASSET_INDEXNUMBERNumeric index for the asset on the Hyperliquid exchange.
SIZE_DECIMALSNUMBERDecimal precision for order sizes on this market.
MAX_LEVERAGENUMBERMaximum allowed leverage for this perpetual market.
FUNDING_AMOUNTFLOATFunding amount received (positive) or paid (negative) by the user.
POSITION_SIZEFLOATUser’s position size at the time of the funding payment.
FUNDING_RATEFLOATHourly funding rate. Positive means longs pay shorts; negative means shorts pay longs.
INSERTED_TIMESTAMPTIMESTAMP_NTZTimestamp when the record was inserted into this table (Snowflake SYSDATE).
MODIFIED_TIMESTAMPTIMESTAMP_NTZTimestamp when the record was last modified in this table (Snowflake SYSDATE).
EZ_PERP_FUNDING_PAYMENTS_IDTEXTSurrogate key generated from block_number, user_address, and coin
_INVOCATION_IDTEXTdbt invocation identifier for tracking which run produced this record.