Historical dataset · API key
Funding history
Every funding settlement of an underlying on every served venue, as a rate per hour, back to each listing where the venue publishes it. At most 366 days a request.
/api/perps/data/fundingcurl "https://optimistfi.com/api/perps/data/funding?base=TSLA&from=2026-01-01&to=2026-10-07" \
-H "Authorization: Bearer $OPTIMISTFI_API_KEY"Parameters
basestringqueryrequired
The underlying: TSLA, XAU, EURUSD.
venuestringquery
Only this venue's markets.
One of hyperliquid, tradexyz, kinetiq, entropyio, paragon, lighter, gains, qfex or veranta.
fromstringquery
Start: epoch seconds, a date (2026-09-01) or an ISO time. Default: 7 days before `to`.
tostringquery
End, in the same forms. Default: now.
formatstringquerydefault json
CSV has one header row with the same field names.
One of json or csv.
Response
A real response, trimmed to one row per list. With format=csv the same rows come as CSV under one header row.
{
"base": "TSLA",
"from": "2026-10-07T18:00:00Z",
"to": "2026-10-07T20:00:00Z",
"count": 1,
"columns": [
"timestamp",
"time",
"venue",
"venueSymbol",
"base",
"fundingRateHourly"
],
"rows": [
{
"timestamp": 1791399600,
"time": "2026-10-07T19:00:00Z",
"venue": "tradexyz",
"venueSymbol": "xyz:TSLA",
"base": "TSLA",
"fundingRateHourly": 6.25e-06
}
]
}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.

