Skip to main content

HyperCore JSON-RPC API

Dwellir provides a JSON-RPC 2.0 HTTP endpoint for querying HyperCore fill data. The API serves trade fill blocks with wire-level compatibility, so existing client code works unmodified.

Endpoint#

POST https://api-hyperliquid-mainnet-jsonrpc.n.dwellir.com/<API-KEY>/hypercore

All requests use standard JSON-RPC 2.0 over HTTP with Content-Type: application/json.

Available Methods#

MethodDescription
hl_getBatchBlocksReturn fill blocks in a [from, to] range for a given stream
hl_getLatestBlockNumberReturn the highest block number for a given stream

hl_getBatchBlocks#

Retrieve a batch of fill blocks for a specified range. Each block contains trade events with timestamps and fill details.

Ideal for:

  • Backfilling historical trade data
  • Batch processing fill events
  • Building trade analytics pipelines

View hl_getBatchBlocks Documentation →

hl_getLatestBlockNumber#

Get the highest block number currently available for a stream. Use this to determine the current head before fetching batch blocks.

Ideal for:

  • Discovering the latest available data
  • Polling for new blocks
  • Synchronization and catch-up logic

View hl_getLatestBlockNumber Documentation →

Supported Streams#

Currently only the trades stream is implemented. The upstream API also defines streams for orders, book updates, TWAP, events, and writer actions; these may be added in the future.

Error Codes#

Standard JSON-RPC 2.0 error codes are used:

CodeMeaning
-32700Parse error
-32600Invalid request
-32601Method not found
-32602Invalid params
-32603Internal error

Constraints#

  • No batches — Array-wrapped requests are rejected (-32600)
  • No notifications — An id field (string or number) is required
  • Body limit — 8 KiB max request body
  • Timeouts — Each request gets a 30 s context deadline

Query HyperCore fill data with Dwellir's JSON-RPC API. Get your API key →