Historical dataset · API key
List dataset markets
Every stock, commodity, FX and index perp the dataset serves: venue, symbol, underlying, leverage cap, funding interval and when its record starts.
GET
/api/perps/data/marketscurl "https://optimistfi.com/api/perps/data/markets?class=equity" \
-H "Authorization: Bearer $OPTIMISTFI_API_KEY"Send the key from your server, never from a browser. Keys are issued on the Get an API key page.
Parameters
classstringquery
A comma list of classes. Default: all four.
One of equity, commodity, fx or index.
Response
A real response, trimmed to one row per list. With format=csv the same rows come as CSV under one header row.
{
"venues": [
"hyperliquid",
"tradexyz",
"kinetiq",
"entropyio",
"paragon",
"lighter",
"gains",
"qfex",
"veranta"
],
"classes": [
"equity",
"commodity",
"fx",
"index"
],
"markets": [
{
"venue": "tradexyz",
"venueSymbol": "xyz:TSLA",
"base": "TSLA",
"assetClass": "equity",
"ticker": "TSLA",
"maxLeverage": 20,
"fundingIntervalHours": 1,
"firstSeen": "2026-09-28T18:53:47Z",
"lastSeen": "2026-10-07T20:00:14Z"
}
],
"count": 1,
"byVenue": {
"tradexyz": {
"equity": 1
}
},
"bases": 1
}Errors
| Status | Code | When |
|---|---|---|
| 400 | invalid_parameter | A parameter is missing, out of range or not one of its allowed values. The message names it. |
| 401 | unauthorized | A dataset endpoint was called without a valid API key. |
| 429 | rate_limited | More than 60 dataset requests in a minute on one key. |
| 503 | unavailable | No venue, or the dataset, answered in time. |
Every error carries error (the reason in words), code and requestId. See Errors and rate limits.

