Resources / API
API Reference
REST and WebSocket APIs for programmatic access to markets, orders, positions, and real-time data on Hyperliquid DEX.
Base URL
api.perpex.io/v1Auth
JWT Bearer01
REST Endpoints
Method
Endpoint
Description
GET
/api/v1/marketsList all available trading pairs and market data
GET
/api/v1/orderbook/:symbolReal-time orderbook depth for a symbol
GET
/api/v1/accountAccount balances, positions, and margin info
POST
/api/v1/ordersPlace a new order (limit, market, stop, etc.)
DELETE
/api/v1/orders/:idCancel an existing open order
GET
/api/v1/tradesTrade history with pagination and filters
02
WebSocket Channels
Endpoint
wss://ws.perpex.iotradesReal-time trade stream for subscribed symbols
orderbookOrderbook updates with configurable depth
positionsUser position changes and liquidation alerts
candlesOHLCV candlestick data at various intervals
03
Authentication
Authentication requires API keys which can be generated from your account dashboard with customizable permissions for enhanced security. All authenticated requests must include a JWT Bearer token in the Authorization header.
Our API is designed for high performance with low latency and includes rate limiting to ensure fair usage. SDKs and client libraries are available in JavaScript, Python, and TypeScript to simplify integration.