Get ETF price history
get_price_historyDaily and intraday price bars and trade-by-trade details for TWSE- and TPEx-listed ETFs. Data comes from the CubeLV Market Data API (https://cubelv.com/en/mcp/taiwan-etfs/): pick a method and pass its arguments in args. Quotes, price history and holdings accept only ETF codes (search_etfs lists them).
Methods:
history (Candlesticks (OHLCV)): Daily, weekly, monthly and intraday candles. TWSE/TPEx stocks and ETFs: 1d, 1w, 1mo (optionally adjusted for ex-rights/ex-dividend and splits) and 1m, 3m, 5m, 15m, 30m, 60m; today's daily candle appears after the 13:30 close (volume is board-lot trading until the exchange daily file arrives around 15:00, then it also includes odd lots and after-hours fixed-price trading). TAIFEX futures: daily candles for all products since 1998 (regular session) via continuous codes (TXF1, CDF3, MXFW1) or a specific month (TXF202611). TAIFEX intraday candles (1m, 3m, 5m, 15m, 30m, 60m) use the front/next continuous code (product code plus 1 or 2) or MXFW1 and include the current session: TAIEX TXF, mini TAIEX MXF, electronics EXF, finance FXF, non-finance non-electronics XIF and TWD gold TGF since 2011-01-03, gold GDF since 2011-01-05, TOPIX TJF since 2015-12-21, MXFW1 since 2013-07-31; US index futures Dow UDF and S&P 500 SPF since 2017-05-15, Nasdaq-100 UNF since 2019-10-01, PHLX Semiconductor SXF since 2023-12-18. The night session of US index futures (session night, 15:00-05:00 Taipei time, dated to the next trading day) covers US regular trading hours, so for intraday Nasdaq, Dow, S&P 500 or semiconductor index history over several years query UNF1, UDF1, SPF1 or SXF1 (volume is TAIFEX contracts, far smaller than CME). Sessions: 1m and 3m have day and night sessions (night since TAIFEX opened it: TXF, MXF, UDF, SPF 2017-05-15; UNF, SXF from their first day; EXF 2018-11-20; GDF, TGF 2018-07-03; TJF 2024-12-10; FXF 2025-06-24; XIF has no night session); 5m to 60m: TXF, MXF, SPF, UNF, SXF day and night, UDF night only, EXF, FXF, XIF, GDF, TGF, TJF, MXFW1 day only. Front/next month of FTSE Taiwan TWN, MSCI Taiwan MTW, Hang Seng HSI, FTSE China A50 CN and Nikkei NK have day-session 5m to 60m only (since 2026-03-27), no 1m or 3m. US stocks: 1d, 60m, 30m, 15m, 5m are split/dividend-adjusted, 1m and 3m are raw; 5m to 60m are the same 1-minute data as 1m (bundle files where available, otherwise aggregated from 1m and adjusted like the daily candles), so every day with 1m also has 5m to 60m: the market-wide range is the dataset us_minute_bars, and each symbol starts at its own first 1m day. Taiwan index daily candles exist for TAIEX, the TPEx index and sector indices (see dailyHistory in indices); warrants have daily candles only. Returns the most recent limit candles within from-to (default 240, max 8000); page backwards through long histories (limit 8000 per segment for years of intraday candles) by setting to to the day before the earliest candle returned until the result is empty. Args: market (required): Market: TWSE, TPEX, TAIFEX, NASDAQ, NYSE or AMEX (US ETFs listed on NYSE Arca or Cboe BZX use AMEX); a market/symbol mismatch returns 404; symbol (required): Symbol (US preferred shares like ABR$D). TAIFEX daily: continuous code (TXF1, CDF3, MXFW2) or specific month (TXF202611, MXF202610W4); TAIFEX intraday: front/next continuous code (TXF1, UNF1, UDF2) or MXFW1; from: Start date, YYYYMMDD; to: End date, YYYYMMDD; limit: Most recent N candles within from-to (default 240, about one year of daily candles; max 8000, larger values count as 8000). For earlier or longer histories read in segments with from and to: limit 8000 per segment for years of intraday candles, setting the next segment's to to the day before the earliest candle returned, until the result is empty; interval: Candle interval: 1d, 1w, 1mo, 1m, 3m, 5m, 15m, 30m, 60m. Taiwan stocks: all; TAIFEX: 1d for all contracts, intraday for front/next continuous codes and MXFW1 (products, sessions and start dates in the summary); US stocks: 1d, 60m, 30m, 15m, 5m, 3m, 1m. US 5m, 15m, 30m, 60m and 1m are the same data: bundle files where available, otherwise aggregated from regular-session 1m and adjusted to the same day's adjusted daily candle (unfinished candles are not returned); US 3m is aggregated from raw 1m. Each candle's at is its end time; adjusted: Adjust Taiwan daily/weekly/monthly candles for ex-rights/ex-dividend and splits (available from 20030505 for TWSE and 20000901 for TPEx; an earlier from returns 422). US daily and 5m-60m candles are always adjusted; session: Intraday session: day = regular session, night = after-hours session (TAIFEX night session 15:00-05:00 Taipei time, dated to the next trading day), all = both (default). TAIFEX daily candles cover the regular session only.
trades (Trade-by-trade details and buy/sell pressure): Tick-by-tick trades of one Taiwan stock on a trading day (newest first, page with before) plus outside (buy-initiated), inside (sell-initiated) and unclassified volume; available from 2018-12-07 (not for warrants). If date is omitted, the latest trading day with intraday trades is used (looking back up to 5 trading days). outerVolume, innerVolume, unknownVolume and totalTrades are whole-day totals independent of limit and before, so use limit=1 when only totals are needed. One symbol per request; intraday requests replay the whole day and get slower with more trades, so for many symbols use the sides field of quotes, or subscribe for live updates. Up to 5000 trades per page. Args: market (required): Market: TWSE or TPEX; symbol (required): Symbol (uppercase letters/digits and . _ -, up to 32 chars); date: Trading day, YYYYMMDD, not after today; when given only that day is queried; limit: Trades per page (1-5000, default 200); before: Pagination cursor: nextBefore from the previous page (HHMMSS[mmm|uuuuuu][:sequence]).
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"method": "<method>"
},
"name": "get_price_history"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| args | No | Arguments of the method, as listed in the tool description | |
| lang | No | Language for data labels (industries, statement items, categories) and links: en, ja, ko or vi; default en | |
| method | Yes | Method from the list in the tool description |