Building an AI agent? Start with /llms.txt for the full site index.
Derivatives & Convertibles
Per-contract daily futures context: near-month futures close vs spot index (basis and basis%), open interest and its daily change, days-to-settlement with a settlement flag, three-institution net OI, and put/call ratio. Derived from TAIFEX daily futures + spot index. Not a forecast, not a recommendation.
GET /v2/datasets/futures-daily-contextThis dataset is in build and not yet queryable via the API. The coverage and honest limitations below are the real database state; it moves off "Building" once serving lands (targeted 8/1).
| Field | Type | Description |
|---|---|---|
futures_close | index_pts | |
spot_close | index_pts | |
basis | index_pts | futures−spot |
basis_pct | ratio | |
open_interest | contracts | |
oi_delta | contracts | daily Δ |
days_to_settlement | days | |
settlement_flag | bool | |
inst_net_oi_foreign | contracts | NULL pre-2023-07 |
put_call_ratio | ratio | NULL where no options data |
6,923 rows, 1998-07-21..2026-07-16. Three-institution net OI columns (inst_net_oi_*) are only populated where TAIFEX institutional OI exists (free source = 3-year rolling from 2023-07; earlier rows carry NULL inst OI). put_call_ratio populated where options data exists.
A real response from this endpoint. Rows are returned under "data", and provenance is carried in the shape shown below — it is not identical across datasets, so read this page's rather than assuming another's.
{ "dataset_id": "futures-daily-context", "row_count": 3, "data": [ { "contract": "TX", "trade_date": "2026-07-16", "near_contract_month": "202608", "futures_close": 45700.0, "spot_close": 45624.98, "basis": 75.02, "basis_pct": 0.1644, "open_interest": 106669.0, "oi_delta": 95677.0, "days_to_settlement": 34, "put_call_ratio": null }, { "contract": "TX", "trade_date": "2026-07-15", "near_contract_month": "202607", "futures_close": 45830.0, "spot_close": 45631.59, "basis": 198.41, "basis_pct": 0.4348, "open_interest": 10992.0, "oi_delta": -9070.0, "days_to_settlement": 0, "put_call_ratio": null }, { "contract": "TX", "trade_date": "2026-07-14", "near_contract_month": "202607", "futures_close": 44815.0, "spot_close": 44737.95, "basis": 77.05, "basis_pct": 0.1722, "open_interest": 20062.0, "oi_delta": -33067.0, "days_to_settlement": 1, "put_call_ratio": null } ]}Captured from the live API on 2026-07-20.
curl "https://api.twmarketdata.com/v2/datasets/futures-daily-context?symbol=2330" \ -H "X-API-Key: sk_live_..."| Parameter | Required | Type | Description |
|---|---|---|---|
symbol | Yes | string | Ticker, e.g. 2330. |
start_date | No | string (YYYY-MM-DD) | Start of the query range. |
end_date | No | string (YYYY-MM-DD) | End of the query range. |
limit | No | integer | Maximum rows to return. |
A first call:
import requests resp = requests.get( "https://api.twmarketdata.com/v2/datasets/futures-daily-context", params={"symbol": "2330"}, headers={"X-API-Key": "sk_live_..."},)resp.raise_for_status()print(resp.json()["data"])With a date-range filter:
import requests # The full verified example — the same call with every supported filter set.resp = requests.get( "https://api.twmarketdata.com/v2/datasets/futures-daily-context", params={"symbol": "2330"}, headers={"X-API-Key": "sk_live_..."},)resp.raise_for_status()for row in resp.json()["data"]: print(row)This endpoint is GET /v2/datasets/futures-daily-context. The full machine-readable schema (parameters, security, response envelope) lives in the OpenAPI spec.