GET /providers
List available perpetual provider platforms.Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
x-lifi-api-key | header | string | Yes | API key |
x-lifi-integrator | header | string | No | Integrator identifier |
Response 200
wsUrl field is optional — it may be absent for providers that don’t support WebSocket streaming.
Each ProviderMarketInfo in markets describes a sub-market within the provider:
| Field | Type | Description |
|---|---|---|
id | string | Market identifier (used as market in AssetIdentity) |
quoteAsset | string | null | Quote asset for this market (e.g., "USDC") |
getProviders()
GET /assets
List all tradeable assets for a provider.Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
provider | query | string | Yes | Provider identifier |
x-lifi-api-key | header | string | Yes | API key |
x-lifi-integrator | header | string | No | Integrator identifier |
Response 200
Asset:
| Field | Type | Description |
|---|---|---|
assetId | string | Provider’s canonical asset identity (e.g., "BTC", "xyz:PURR", "@142") |
market | string | Market category (e.g., "hyperliquid", "xyz", "spot") |
displaySymbol | string | UI-friendly base symbol (e.g., "BTC", "PURR") |
displayQuote | string | null | Quote asset (e.g., "USDC") — null for non-standard markets |
displayName | string? | Full asset name (e.g., "Bitcoin") |
logoURI | string | URL to asset logo |
szDecimals | number | Size decimal places |
maxLeverage | number | Maximum allowed leverage |
onlyIsolated | boolean | Whether only isolated margin is supported |
isMarginCollateral | boolean? | Whether this asset can be used as margin collateral |
funding | FundingInfo | Current funding rate and next funding time |
openInterest | string? | Total open interest in USD |
volume24h | string? | 24-hour trading volume in USD |
prevDayPrice | string? | Previous day’s price |
markPrice | string | Current mark price |
getAssets()
GET /assets/
Get details for a single asset.Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
symbol | path | string | Yes | Asset identifier (e.g., BTC) |
provider | query | string | Yes | Provider identifier |
x-lifi-api-key | header | string | Yes | API key |
x-lifi-integrator | header | string | No | Integrator identifier |
Response 200
Returns a single Asset object (same shape as items in the /assets response).
Response 404
Asset not found error.
SDK: getAsset()
GET /prices
Get current mid prices for all assets. Lightweight endpoint for frequent polling.Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
provider | query | string | Yes | Provider identifier |
symbols | query | string | No | Comma-separated list of asset IDs to filter (e.g., BTC,ETH) |
x-lifi-api-key | header | string | Yes | API key |
x-lifi-integrator | header | string | No | Integrator identifier |
Response 200
AssetPrice:
| Field | Type | Description |
|---|---|---|
assetId | string | Asset identifier |
price | string | Current mid price |
getPrices()
GET /ohlcv/
Get OHLCV candle data for charts.Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
symbol | path | string | Yes | Asset identifier |
provider | query | string | Yes | Provider identifier |
interval | query | string | Yes | Candle interval: 1m, 3m, 5m, 15m, 30m, 1h, 2h, 4h, 8h, 12h, 1d, 3d, 1w, 1M |
startTime | query | integer | No | Start timestamp (ms) |
endTime | query | integer | No | End timestamp (ms) |
limit | query | integer | No | Max candles (default 100, max 1000) |
x-lifi-api-key | header | string | Yes | API key |
x-lifi-integrator | header | string | No | Integrator identifier |
Response 200
Response 404
Asset not found error.
SDK: getOhlcv()
GET /orderbook/
Get current orderbook snapshot.Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
symbol | path | string | Yes | Asset identifier |
provider | query | string | Yes | Provider identifier |
depth | query | integer | No | Price levels (default 20, max 100) |
x-lifi-api-key | header | string | Yes | API key |
x-lifi-integrator | header | string | No | Integrator identifier |
Response 200
Response 404
Asset not found error.
SDK: getOrderbook()