Building an AI agent? Start with /llms.txt for the full site index.
Capital Flows
Foreign holding
Foreign holding
GET /v2/datasets/foreign-holdingForeign holding is a Taiwan market dataset sourced from TWSE, served by TW Market Data as GET /v2/datasets/foreign-holding.
Overview
Foreign holding — grain: ticker / trade_date.
| Field | Type | Description |
|---|---|---|
ticker | string | |
trade_date | string | |
market | string | |
name | string | |
isin | string | |
shares_issued | number | |
remaining_investable | number | |
held_shares | number | |
remaining_pct | number | Remaining investable (%) |
holding_pct | number | Foreign holding (%) |
limit_change_date | string |
Coverage
| Rows | — |
| Window | Coverage starts 2004-02 |
| Grade | Verified |
Example response
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.
{ "api_version": "v2", "dataset": "foreign_holding", "dataset_version": "v2.0.0-preview", "release_version": "v2.2026-08-04.preview", "release_date": "2026-08-04", "data_as_of": "2026-08-04", "request_context": { "ticker": "0050", "as_of_date": "2026-08-04", "family": "chip_deep", "field_group_type": "canonical", "dataset_view": "foreign_holding_v1", "scope": "twse_qfiis_foreign_and_mainland_holding_daily", "coverage_type": "daily_per_ticker_holding_snapshot", "supported_filter_fields": [ "ticker", "market", "trade_date" ], "ticker_filter": "0050", "market_filter": null, "date_range": { "date_from": null, "date_to": null }, "applied_default_window": false, "default_window_days": null, "order_by": "ticker ASC, trade_date DESC" }, "data": [ { "ticker": "0050", "trade_date": "2026-08-04", "market": "TWSE", "name": "<Chinese value - see the zh page>", "isin": "TW0000050004", "shares_issued": 22489500000, "remaining_investable": 21261492785, "held_shares": 1228007215, "remaining_pct": 94.53, "holding_pct": 5.46, "limit_change_date": "2026-07-02", "provider": "twse_official", "source_role": "official_twse_qfiis", "source_authority": "<Chinese value - see the zh page>", "source_family": "TWSE_MI_QFIIS", "lineage": { "row_index": 10, "source_hash": "qfiis:20260804", "payload_date": "20260804", "request_date": "2026-08-04", "endpoint_name": "rwd_fund_MI_QFIIS", "source_authority": "<Chinese value - see the zh page>" }, "not_investment_advice": true }, { "ticker": "0050", "trade_date": "2026-08-03", "market": "TWSE", "name": "<Chinese value - see the zh page>", "isin": "TW0000050004", "shares_issued": 22487000000, "remaining_investable": 21229326239, "held_shares": 1257673761, "remaining_pct": 94.4, "holding_pct": 5.59, "limit_change_date": "2026-07-02", "provider": "twse_official", "source_role": "official_twse_qfiis", "source_authority": "<Chinese value - see the zh page>", "source_family": "TWSE_MI_QFIIS", "lineage": { "row_index": 10, "source_hash": "qfiis:20260803", "payload_date": "20260803", "request_date": "2026-08-03", "endpoint_name": "rwd_fund_MI_QFIIS", "source_authority": "<Chinese value - see the zh page>" }, "not_investment_advice": true } ], "quality": { "freshness_state": "fresh", "freshness_as_of": "2026-08-04", "completeness_ratio": 1, "quality_status": "ready", "ticker_count": 1 }, "lineage": { "source_role": "canonical", "selected_source": "twse_mi_qfiis", "fallback_chain": [], "policy_notes": [ "official/public-first canonical", "<Chinese value - see the zh page>", "held_shares / holding_pct are the published aggregate; no beneficial-owner identity" ] }, "error": { "error_code": null, "error_message": null, "dataset": "foreign_holding", "request_id": "read-api-20260804", "blocking_gate": null }, "dataset_id": "foreign_holding", "data_count": 50, "known_gaps": [ "twse_only_scope", "no_tpex_coverage", "qfiis_daily_snapshot_only" ], "warnings": [ "not_investment_advice", "twse_only_scope" ], "not_investment_advice": true}Captured from the live API on 2026-07-20.
Chinese data values are shown as a marker here so this page stays in English; the /zh page shows them verbatim.
Provenance
These columns are returned alongside the data and record where the row came from. They are provenance, not the dataset's subject matter, so they are listed here rather than in the field table.
providersource_rolesource_authoritysource_familylineagenot_investment_adviceGetting started
- Put your key in the X-API-Key header.
- Add query parameters (symbol, date range, limit).
- Send the request and read the data array.
curl "https://api.twmarketdata.com/v2/datasets/foreign-holding?symbol=2330" \ -H "X-API-Key: sk_live_..."Filtering
| 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. |
Python
A first call:
import requests resp = requests.get( "https://api.twmarketdata.com/v2/datasets/foreign-holding", 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/foreign-holding", params={"symbol": "2330"}, headers={"X-API-Key": "sk_live_..."},)resp.raise_for_status()for row in resp.json()["data"]: print(row)OpenAPI
This endpoint is GET /v2/datasets/foreign-holding. The full machine-readable schema (parameters, security, response envelope) lives in the OpenAPI spec.