View Source API Reference hyperliquid v0.3.1

Modules

Documentation for Hyperliquid.

Root API module providing unified access to all Hyperliquid endpoints.

Canonical JSON encoding for exchange actions.

Common schemas used across multiple Hyperliquid API endpoints.

Balance for a specific spot token.

Open order with additional display information.

State of the TWAP order.

Helper module for generating delegated wrapper functions for API endpoints.

DSL for defining API endpoints with automatic request/response handling.

Behavior defining the contract for API endpoint modules.

Convenience functions for Exchange API endpoints.

Activate or deactivate an account as a HIP-4 outcome deployer.

Enable or disable DEX abstraction for an agent.

Transfer an asset between DEXs on behalf of a user, signed by an agent wallet.

Agent-triggered abstraction mode configuration.

Approve an agent to trade on behalf of your account.

Approve a builder to charge fees.

Authorize the signing account for an AQAV2 role on a token.

Modify multiple existing orders in a batch on Hyperliquid.

Borrow or lend tokens in the Hyperliquid borrow/lend protocol.

Deposit native token from spot account into staking balance.

Perform a validator signer action (unjail).

Perform validator management actions.

Withdraw from staking balance back to spot account.

Cancel orders on Hyperliquid by order ID.

Cancel orders on Hyperliquid by client order ID.

Claim staking rewards.

Convert account to multi-sig user.

Create a new sub-account.

Configure block type for EVM transactions.

Link a HyperCore token to its deployed HyperEVM contract.

Bid for a gossip priority slot.

Move collateral in or out of a HIP-3 DEX's liquidator account.

Shared utilities for resolving private keys and validating addresses in exchange modules.

Link staking addresses together.

Modify a single existing order on Hyperliquid.

Send a no-op (heartbeat) to keep connection alive.

Place orders on Hyperliquid.

Deploy and manage HIP-3 perpetual contracts.

Create a new referrer code.

Reserve additional rate limit capacity.

Schedule all open orders to be cancelled at a specified time.

Transfer tokens between different perp DEXs, spot balance, users, and/or sub-accounts.

Send tokens from core to EVM with a custom data payload.

Set display name for user account.

Set the referrer code for your account.

Deploy and manage HIP-1 and HIP-2 spot tokens.

Send spot tokens to another address.

User-level spot configuration actions.

Disable a trading user previously linked to a staking account.

Create or modify a sub-account.

Transfer spot tokens between main account and sub-account.

Transfer funds between main account and sub-account.

Delegate or undelegate stake to/from a validator.

Top up an isolated-only position's margin back to a target leverage.

Place a TWAP (Time-Weighted Average Price) order.

Add or remove margin from an isolated position.

Update leverage for a perpetual asset.

Transfer USD between spot and perp accounts.

Send USD to another address.

Enable or disable DEX abstraction for the calling user.

Split, merge and negate HIP-4 prediction market outcome positions.

Enable or disable portfolio margin mode for the calling user.

Set account abstraction mode for a user.

Shared EIP-712 signing for user-signed exchange actions.

Validator vote on risk-free rate for quote assets.

Distribute profits to vault followers.

Create or modify a vault.

Transfer funds to/from a vault.

Initiate a withdrawal request.

DSL for defining authenticated exchange endpoints with signing support.

Convenience functions for Explorer API endpoints.

Block details from the Hyperliquid L1 explorer.

Transaction details from the explorer.

User transaction history from the explorer.

Convenience functions for Info API endpoints.

Active trading data for a specific asset and user.

Information about aligned quote tokens.

Borrow/lend reserve state data.

Mapping of coin symbols to mid prices.

Metadata for perpetual assets across all or a specific DEX.

Margin table with leverage tiers.

Individual tier in a margin requirements table.

Trading universe parameters for perpetual asset.

List of builder addresses approved by a user for MEV operations.

Borrow/lend reserve state for a specific token.

User's borrow/lend positions and account health.

OHLCV candle data for a coin.

Single candle data point.

Account summary for perpetual trading.

User's staking delegations.

Individual delegation to a validator.

History of user's delegation actions.

User's staking rewards history.

Summary of user's delegation status.

Exchange operational status.

Extra agents authorized by a user.

Extra agent information.

Open orders with frontend display information.

Open order with frontend info.

Historical funding rates for an asset.

Historical funding rate record.

Status of the gossip priority slot auctions.

Gossip network root IP addresses.

Historical orders for a user.

VIP status check for a user.

L2 order book snapshot for a coin.

Order book level with bids and asks.

Leading vaults information.

Vault that a user is leading.

Legal/compliance check for a user.

Liquidatable positions.

Margin table details.

Maximum builder fee for a user.

Maximum market order notional values.

Max market order notional entry.

Metadata for perpetual assets.

Tuple of margin table ID and its details.

Individual tier in a margin requirements table.

Trading universe parameters for perpetual asset.

Metadata and context for perpetual assets.

Context for a specific perpetual asset.

Metadata for perpetual assets.

Tuple of margin table ID and its details.

Individual tier in a margin requirements table.

Trading universe parameters for perpetual asset.

User's open orders.

Status of a specific order.

Prediction market (HIP-4) outcome metadata.

A single prediction market outcome.

A prediction market question, the container for named outcomes.

Templates that HIP-4 outcome deployers instantiate.

Category and description annotation for a specific perpetual.

All perpetual coins with their assigned categories.

Concise category annotations for perp coins.

Annotation for a single perp coin.

Status of the perpetual deployment auction.

Limits for a builder-deployed perpetual DEX.

Coin-specific open interest cap.

Overall status metrics for a builder-deployed perpetual market.

List of all perpetual DEXs.

Perpetual DEX information.

List of perpetuals currently at their open interest cap.

User portfolio performance data.

Portfolio data for a specific time period.

Portfolio metrics for the period.

Pre-transfer validation check.

Predicted funding rates for perpetuals.

Funding predictions for a specific coin.

Recent trades for a coin.

Referral information for a user.

Referrer state information.

Settlement information for a HIP-4 prediction market outcome.

Account summary for spot trading.

Balance for a specific spot token.

Escrowed balance for a specific asset.

Spot token deployment state.

Spot token deployment state.

Metadata for spot assets.

Trading universe details.

Metadata and context for spot assets.

Context for a specific spot asset.

Spot pair deployment auction status.

User's sub-accounts.

Extended sub-accounts information.

Extended sub-account info.

TWAP order history for a user.

Current USDC deposit and withdrawal routing.

User's account abstraction mode.

User's accrued borrow/lend interest across all positions.

User DEX abstraction settings.

User's trading fee rates.

User's trade fills.

User's trade fills filtered by time range.

User's funding payment history.

Individual funding payment record.

User's non-funding ledger updates.

User's rate limit status.

User's role information.

Multi-sig signers for a user.

User's TWAP slice fills.

User's TWAP slice fills filtered by time.

Detailed vault information.

One-shot REST snapshot of comprehensive user and market data.

Registry for discovering and introspecting API endpoints.

Convenience functions for Stats API endpoints.

Leaderboard data from the Hyperliquid stats API.

Vaults data from the Hyperliquid stats API.

WebSocket subscription for active asset context.

WebSocket subscription for active asset data.

WebSocket subscription for active spot asset context.

WebSocket subscription for asset contexts across all DEXes.

WebSocket subscription for a user's clearinghouse state across all DEXes.

WebSocket subscription for all mid prices.

WebSocket subscription for asset contexts for perpetuals.

WebSocket subscription for best bid/offer.

WebSocket subscription for candlestick data.

WebSocket subscription for user's clearinghouse state.

WebSocket subscription for explorer block updates.

WebSocket subscription for explorer transactions.

WebSocket subscription for low-latency mark and mid price updates.

WebSocket subscription for order book data.

WebSocket subscription for user notifications.

WebSocket subscription for open orders.

WebSocket subscription for order status updates.

WebSocket subscription for HIP-4 prediction market metadata changes.

WebSocket subscription for spot asset contexts.

WebSocket subscription for spot state.

WebSocket subscription for recent trades.

WebSocket subscription for TWAP execution states.

WebSocket subscription for user event stream.

WebSocket subscription for user's trade fills.

WebSocket subscription for user's funding payments.

WebSocket subscription for historical order updates.

WebSocket subscription for ledger updates.

WebSocket subscription for user TWAP history.

WebSocket subscription for user TWAP slice fills.

WebSocket subscription for comprehensive user and market data.

WebSocket subscription for comprehensive user and market data (v3 format).

DSL for defining WebSocket subscription endpoints.

Application cache for storing asset lists and exchange meta information.

GenServer for async cache initialization with retry logic.

Configuration module for Hyperliquid application.

Shared exception for both REST API and JSON-RPC errors.

Hyperliquid-specific custom JSON-RPC methods.

Standard Ethereum JSON-RPC methods for Hyperliquid EVM.

Network-related JSON-RPC methods for Hyperliquid EVM.

Dynamic registry for named RPC endpoints.

Web3-related JSON-RPC methods for Hyperliquid EVM.

Writes subscription events to configured storage backends.

Telemetry events emitted by Hyperliquid.

HTTP transport layer for Hyperliquid API.

JSON-RPC transport for Hyperliquid EVM.

WebSocket transport using Mint for Hyperliquid API.

Provides utility functions for the Hyperliquid application.

Formatting utilities for Hyperliquid prices and sizes.

Provides helper functions for handling time intervals supported by Hyperliquid.

WebSocket connection handler with automatic reconnection.

WebSocket connection and subscription manager.

Represents an active subscription.

Supervisor for the WebSocket subsystem.

Mix Tasks

Generates Elixir Ecto schemas from the @nktkas/hyperliquid TypeScript SDK.