Skip to main content

Open Interest

Open interest for the futures/options tracking a market index.

Endpoint

GET /index/v1/openInterest

Authentication: Standard plan. Requires a valid platform API key (X-Primit-API-Key) tied to an active Standard plan (标准套餐) subscription or above. See Authentication.

Query parameters

NameTypeRequiredDefaultNotes
symbolstringYesIndex code, e.g. SPX, NDX.
periodstringNo1dAggregation period.
limitintegerNo30Number of data points to return.

Response — 200 OK

{
"symbol": "SPX",
"openInterest": "2310544",
"time": 1745884800000
}

Errors

HTTPCause
401Missing or invalid X-Primit-API-Key.
403No active Standard plan (subscription expired or never purchased).
404symbol not found.
422Missing symbol.

Example

curl -s "https://api.pipai.org/index/v1/openInterest?symbol=SPX" \
-H "X-Primit-API-Key: $PRIMIT_API_KEY"