API Overview
d.pro's backend API versus the Hyperliquid API — what each covers and when to use which.
API Overview
d.pro exposes two distinct API surfaces:
- d.pro Backend API (
dpro-backend) — d.pro-specific features: referrals, OPC, watchlist, cohort, leaderboard, skill market - Hyperliquid API — trading execution, market data, account state, WebSocket streams
For core trading operations (placing orders, reading positions, subscribing to market data), use the Hyperliquid API directly. d.pro's UI wraps it, but you can also call it directly.
For d.pro-exclusive features, use the d.pro Backend API.
The d.pro backend runs on Fastify (via NestJS) and exposes a REST API at the base path /api/v1/. All protected endpoints require a JWT token obtained via the authentication flow.
API surfaces
d.pro Backend API
Base URL: https://api.d.pro/api/v1/
Authentication: Bearer JWT (see Authentication)
Modules and endpoints:
| Module | Base Path | Description |
|---|---|---|
| Auth | /auth | JWT session management |
| Referral System | /referral | Create codes, bind, claim rewards |
| OPC | /opc | White-label platform management |
| Watchlist | /watchlist | Address group monitoring |
| Cohort | /cohort | Comparative analytics |
| Leaderboard | /leaderboard | Enhanced leaderboard |
| Skill Market | /skill-market | Browse and download AI skills |
| Hyperliquid Proxy | /hl | Proxied Hyperliquid data (with caching) |
| Revenue | /revenue | OPC revenue rounds |
| Claim | /claim | Claim rounds management |
Content type: application/json for all requests and responses.
Pagination: All list endpoints support page and limit query parameters.
Hyperliquid API
All Hyperliquid API calls are POST requests to two endpoints:
| Endpoint | Usage |
|---|---|
https://api.hyperliquid.xyz/info | Read-only: market data, account state |
https://api.hyperliquid.xyz/exchange | Write: place orders, transfers, modifications |
Request format:
{
"type": "clearinghouseState",
"user": "0x..."
}WebSocket: wss://api.hyperliquid.xyz/ws for real-time subscriptions.
For complete Hyperliquid API documentation, see Hyperliquid's official docs.
d.pro API quick reference
Authentication
JWT session flow — challenge, sign, token, refresh.
Referral API
Create codes, list referees, claim rewards.
OPC API
Create and manage white-label platforms.
Watchlist API
Group and monitor wallet addresses.
Rate limits
The d.pro API enforces per-IP and per-authenticated-user rate limits. Exceeding the limit returns HTTP 429.
Hyperliquid's API has its own rate limits — see the Hyperliquid rate limits documentation for details.
Error format
d.pro API errors follow standard HTTP semantics:
{
"statusCode": 401,
"message": "Unauthorized",
"error": "Invalid or expired JWT token"
}Hyperliquid API errors are embedded in HTTP 200 responses:
{
"status": "err",
"response": "Order would immediately cross"
}