Tokos Rates

Funding on Hyperliquid

The hourly print, in plain words.

Funding in plain words

A perpetual future never expires, so something has to keep its price near the spot price. That something is funding: a payment between longs and shorts. When the perp trades above the oracle price, longs pay shorts; below it, shorts pay longs. The payment is the position's notional times the funding rate.

On Hyperliquid it is paid every hour, at the top of the hour UTC. The rate for an hour is built from the premium of the perp over the oracle during that hour plus a small interest component, and it is capped at 4% per hour by Hyperliquid.

Where the prints come from

Hyperliquid publishes every settled print on its public info API. Tokos reads exactly that, with no key:

curl -s https://api.hyperliquid.xyz/info -H 'content-type: application/json' \
  -d '{"type":"fundingHistory","coin":"HYPE","startTime":1795680000000}'
# [{"coin":"HYPE","fundingRate":"0.0000125","premium":"0.0003348488","time":1795680000003}, ...]
  • One record per coin per hour, time a fraction of a second after the top of the hour.
  • fundingRate is a decimal per hour. 0.0000125 is 0.00125% per hour, about 10.95% a year at that pace. Positive means longs pay shorts.
  • At most 500 records per call; older history pages by startTime.
  • metaAndAssetCtxs carries the running estimate for the hour in progress; predictedFundings lists Hyperliquid with a one-hour interval next to venues that pay every eight hours.

Units on Tokos

Contracts store a rate per hour as an integer scaled by 10^18: 0.0000125 becomes 12,500,000,000,000. USDC amounts are base units with 6 decimals. The public API returns both the decimal string Hyperliquid published and the integer form.