@fugle/node-twstock 2.2.1-alpha.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +1837 -0
- package/lib/enums/exchange.enum.d.ts +5 -0
- package/lib/enums/exchange.enum.js +9 -0
- package/lib/enums/futopt.enum.d.ts +34 -0
- package/lib/enums/futopt.enum.js +38 -0
- package/lib/enums/index.d.ts +6 -0
- package/lib/enums/index.enum.d.ts +67 -0
- package/lib/enums/index.enum.js +71 -0
- package/lib/enums/index.js +22 -0
- package/lib/enums/industry.enum.d.ts +40 -0
- package/lib/enums/industry.enum.js +44 -0
- package/lib/enums/market.enum.d.ts +5 -0
- package/lib/enums/market.enum.js +9 -0
- package/lib/enums/scraper.enum.d.ts +10 -0
- package/lib/enums/scraper.enum.js +14 -0
- package/lib/index.d.ts +2 -0
- package/lib/index.js +18 -0
- package/lib/interfaces/futopt-exchange-rates.interface.d.ts +13 -0
- package/lib/interfaces/futopt-exchange-rates.interface.js +2 -0
- package/lib/interfaces/futopt-historical.interface.d.ts +23 -0
- package/lib/interfaces/futopt-historical.interface.js +2 -0
- package/lib/interfaces/futopt-institutional.interface.d.ts +21 -0
- package/lib/interfaces/futopt-institutional.interface.js +2 -0
- package/lib/interfaces/futopt-large-traders.interface.d.ts +16 -0
- package/lib/interfaces/futopt-large-traders.interface.js +2 -0
- package/lib/interfaces/futopt-mxf-retail-position.interface.d.ts +7 -0
- package/lib/interfaces/futopt-mxf-retail-position.interface.js +2 -0
- package/lib/interfaces/futopt-quote.interface.d.ts +31 -0
- package/lib/interfaces/futopt-quote.interface.js +2 -0
- package/lib/interfaces/futopt-tmf-retail-position.interface.d.ts +7 -0
- package/lib/interfaces/futopt-tmf-retail-position.interface.js +2 -0
- package/lib/interfaces/futopt-txo-put-call-ratio.interface.d.ts +9 -0
- package/lib/interfaces/futopt-txo-put-call-ratio.interface.js +2 -0
- package/lib/interfaces/futopt.interface.d.ts +7 -0
- package/lib/interfaces/futopt.interface.js +2 -0
- package/lib/interfaces/index-historical.interface.d.ts +11 -0
- package/lib/interfaces/index-historical.interface.js +2 -0
- package/lib/interfaces/index-quote.interface.d.ts +13 -0
- package/lib/interfaces/index-quote.interface.js +2 -0
- package/lib/interfaces/index-trades.interface.d.ts +9 -0
- package/lib/interfaces/index-trades.interface.js +2 -0
- package/lib/interfaces/index.d.ts +37 -0
- package/lib/interfaces/index.js +53 -0
- package/lib/interfaces/market-breadth.interface.d.ts +11 -0
- package/lib/interfaces/market-breadth.interface.js +2 -0
- package/lib/interfaces/market-institutional.interface.d.ts +10 -0
- package/lib/interfaces/market-institutional.interface.js +2 -0
- package/lib/interfaces/market-margin-trades.interface.d.ts +19 -0
- package/lib/interfaces/market-margin-trades.interface.js +2 -0
- package/lib/interfaces/market-trades.interface.d.ts +7 -0
- package/lib/interfaces/market-trades.interface.js +2 -0
- package/lib/interfaces/rate-limit-options.interface.d.ts +4 -0
- package/lib/interfaces/rate-limit-options.interface.js +2 -0
- package/lib/interfaces/stock-capital-reductions.interface.d.ts +23 -0
- package/lib/interfaces/stock-capital-reductions.interface.js +2 -0
- package/lib/interfaces/stock-dividends.interface.d.ts +27 -0
- package/lib/interfaces/stock-dividends.interface.js +2 -0
- package/lib/interfaces/stock-eps.interface.d.ts +8 -0
- package/lib/interfaces/stock-eps.interface.js +2 -0
- package/lib/interfaces/stock-fini-holdings.interface.d.ts +12 -0
- package/lib/interfaces/stock-fini-holdings.interface.js +2 -0
- package/lib/interfaces/stock-futopt.interface.d.ts +8 -0
- package/lib/interfaces/stock-futopt.interface.js +2 -0
- package/lib/interfaces/stock-historical.interface.d.ts +14 -0
- package/lib/interfaces/stock-historical.interface.js +2 -0
- package/lib/interfaces/stock-institutional.interface.d.ts +12 -0
- package/lib/interfaces/stock-institutional.interface.js +2 -0
- package/lib/interfaces/stock-margin-trades.interface.d.ts +20 -0
- package/lib/interfaces/stock-margin-trades.interface.js +2 -0
- package/lib/interfaces/stock-quote.interface.d.ts +19 -0
- package/lib/interfaces/stock-quote.interface.js +2 -0
- package/lib/interfaces/stock-revenue.interface.d.ts +8 -0
- package/lib/interfaces/stock-revenue.interface.js +2 -0
- package/lib/interfaces/stock-shareholders.interface.d.ts +11 -0
- package/lib/interfaces/stock-shareholders.interface.js +2 -0
- package/lib/interfaces/stock-short-sales.interface.d.ts +19 -0
- package/lib/interfaces/stock-short-sales.interface.js +2 -0
- package/lib/interfaces/stock-splits.interface.d.ts +12 -0
- package/lib/interfaces/stock-splits.interface.js +2 -0
- package/lib/interfaces/stock-values.interface.d.ts +10 -0
- package/lib/interfaces/stock-values.interface.js +2 -0
- package/lib/interfaces/stock.interface.d.ts +8 -0
- package/lib/interfaces/stock.interface.js +2 -0
- package/lib/interfaces/stocks-capital-reduction-announcement.interface.d.ts +19 -0
- package/lib/interfaces/stocks-capital-reduction-announcement.interface.js +2 -0
- package/lib/interfaces/stocks-dividends-announcement.interface.d.ts +21 -0
- package/lib/interfaces/stocks-dividends-announcement.interface.js +2 -0
- package/lib/interfaces/stocks-etf-split-announcement.interface.d.ts +11 -0
- package/lib/interfaces/stocks-etf-split-announcement.interface.js +2 -0
- package/lib/interfaces/stocks-listing-application.interface.d.ts +16 -0
- package/lib/interfaces/stocks-listing-application.interface.js +2 -0
- package/lib/interfaces/stocks-split-announcement.interface.d.ts +11 -0
- package/lib/interfaces/stocks-split-announcement.interface.js +2 -0
- package/lib/interfaces/ticker.interface.d.ts +10 -0
- package/lib/interfaces/ticker.interface.js +2 -0
- package/lib/scrapers/index.d.ts +10 -0
- package/lib/scrapers/index.js +26 -0
- package/lib/scrapers/isin-scraper.d.ts +13 -0
- package/lib/scrapers/isin-scraper.js +76 -0
- package/lib/scrapers/mis-taifex-scraper.d.ts +17 -0
- package/lib/scrapers/mis-taifex-scraper.js +126 -0
- package/lib/scrapers/mis-twse-scraper.d.ts +15 -0
- package/lib/scrapers/mis-twse-scraper.js +97 -0
- package/lib/scrapers/mops-scraper.d.ts +17 -0
- package/lib/scrapers/mops-scraper.js +64 -0
- package/lib/scrapers/scraper-factory.d.ts +25 -0
- package/lib/scrapers/scraper-factory.js +62 -0
- package/lib/scrapers/scraper.d.ts +6 -0
- package/lib/scrapers/scraper.js +20 -0
- package/lib/scrapers/taifex-scraper.d.ts +44 -0
- package/lib/scrapers/taifex-scraper.js +406 -0
- package/lib/scrapers/tdcc-scraper.d.ts +11 -0
- package/lib/scrapers/tdcc-scraper.js +82 -0
- package/lib/scrapers/tpex-scraper.d.ts +95 -0
- package/lib/scrapers/tpex-scraper.js +786 -0
- package/lib/scrapers/twse-scraper.d.ts +110 -0
- package/lib/scrapers/twse-scraper.js +967 -0
- package/lib/twstock.d.ts +229 -0
- package/lib/twstock.js +507 -0
- package/lib/utils/as-exchange.util.d.ts +2 -0
- package/lib/utils/as-exchange.util.js +15 -0
- package/lib/utils/as-index.util.d.ts +1 -0
- package/lib/utils/as-index.util.js +178 -0
- package/lib/utils/as-industry.util.d.ts +2 -0
- package/lib/utils/as-industry.util.js +49 -0
- package/lib/utils/date-converter.util.d.ts +47 -0
- package/lib/utils/date-converter.util.js +113 -0
- package/lib/utils/html-cleaner.util.d.ts +29 -0
- package/lib/utils/html-cleaner.util.js +45 -0
- package/lib/utils/index.d.ts +7 -0
- package/lib/utils/index.js +23 -0
- package/lib/utils/is-warrant.util.d.ts +1 -0
- package/lib/utils/is-warrant.util.js +25 -0
- package/lib/utils/parse-numeric.util.d.ts +21 -0
- package/lib/utils/parse-numeric.util.js +58 -0
- package/package.json +70 -0
|
@@ -0,0 +1,110 @@
|
|
|
1
|
+
import { Scraper } from './scraper';
|
|
2
|
+
import { IndexHistorical, IndexTrades, MarketBreadth, MarketInstitutional, MarketMarginTrades, MarketTrades, StockCapitalReductions, StocksCapitalReductionAnnouncement, StockDividends, StocksDividendAnnouncement, StocksEtfSplitAnnouncement, StockFiniHoldings, StockHistorical, StockInstitutional, StocksListingApplication, StockMarginTrades, StockShortSales, StockSplits, StocksSplitAnnouncement, StockValues } from '../interfaces';
|
|
3
|
+
export declare class TwseScraper extends Scraper {
|
|
4
|
+
fetchStocksHistorical(options: {
|
|
5
|
+
date: string;
|
|
6
|
+
symbol?: string;
|
|
7
|
+
}): Promise<StockHistorical | StockHistorical[] | null | undefined>;
|
|
8
|
+
fetchStocksInstitutional(options: {
|
|
9
|
+
date: string;
|
|
10
|
+
symbol?: string;
|
|
11
|
+
}): Promise<StockInstitutional | StockInstitutional[] | null | undefined>;
|
|
12
|
+
fetchStocksFiniHoldings(options: {
|
|
13
|
+
date: string;
|
|
14
|
+
symbol?: string;
|
|
15
|
+
}): Promise<StockFiniHoldings | StockFiniHoldings[] | null | undefined>;
|
|
16
|
+
fetchStocksMarginTrades(options: {
|
|
17
|
+
date: string;
|
|
18
|
+
symbol?: string;
|
|
19
|
+
}): Promise<StockMarginTrades | StockMarginTrades[] | null | undefined>;
|
|
20
|
+
fetchStocksShortSales(options: {
|
|
21
|
+
date: string;
|
|
22
|
+
symbol?: string;
|
|
23
|
+
}): Promise<StockShortSales | StockShortSales[] | null | undefined>;
|
|
24
|
+
fetchStocksValues(options: {
|
|
25
|
+
date: string;
|
|
26
|
+
symbol?: string;
|
|
27
|
+
}): Promise<StockValues | StockValues[] | null | undefined>;
|
|
28
|
+
fetchStocksDividends(options: {
|
|
29
|
+
startDate: string;
|
|
30
|
+
endDate: string;
|
|
31
|
+
symbol?: string;
|
|
32
|
+
includeDetail?: boolean;
|
|
33
|
+
}): Promise<StockDividends[]>;
|
|
34
|
+
fetchStocksDividendsDetail(options: {
|
|
35
|
+
date: string;
|
|
36
|
+
symbol: string;
|
|
37
|
+
}): Promise<Record<string, any> | null>;
|
|
38
|
+
fetchStocksDividendsAnnouncement(options?: {
|
|
39
|
+
symbol?: string;
|
|
40
|
+
includeDetail?: boolean;
|
|
41
|
+
}): Promise<StocksDividendAnnouncement[]>;
|
|
42
|
+
fetchStocksCapitalReductions(options: {
|
|
43
|
+
startDate: string;
|
|
44
|
+
endDate: string;
|
|
45
|
+
symbol?: string;
|
|
46
|
+
includeDetail?: boolean;
|
|
47
|
+
}): Promise<StockCapitalReductions[]>;
|
|
48
|
+
fetchStockCapitalReductionDetail(options: {
|
|
49
|
+
symbol: string;
|
|
50
|
+
date: string;
|
|
51
|
+
}): Promise<Record<string, any> | null>;
|
|
52
|
+
fetchStocksDividendsAnnouncementDetail(options: {
|
|
53
|
+
date: string;
|
|
54
|
+
symbol: string;
|
|
55
|
+
}): Promise<Record<string, any> | null>;
|
|
56
|
+
fetchStocksCapitalReductionAnnouncementDetail(options: {
|
|
57
|
+
symbol: string;
|
|
58
|
+
date: string;
|
|
59
|
+
}): Promise<Record<string, any> | null>;
|
|
60
|
+
fetchStocksSplitAnnouncementDetail(options: {
|
|
61
|
+
symbol: string;
|
|
62
|
+
date: string;
|
|
63
|
+
}): Promise<Record<string, any> | null>;
|
|
64
|
+
fetchStocksCapitalReductionAnnouncement(options?: {
|
|
65
|
+
symbol?: string;
|
|
66
|
+
includeDetail?: boolean;
|
|
67
|
+
}): Promise<StocksCapitalReductionAnnouncement[]>;
|
|
68
|
+
fetchStocksSplits(options: {
|
|
69
|
+
startDate: string;
|
|
70
|
+
endDate: string;
|
|
71
|
+
symbol?: string;
|
|
72
|
+
}): Promise<StockSplits[]>;
|
|
73
|
+
fetchStocksEtfSplits(options: {
|
|
74
|
+
startDate: string;
|
|
75
|
+
endDate: string;
|
|
76
|
+
symbol?: string;
|
|
77
|
+
reverseSplit?: boolean;
|
|
78
|
+
}): Promise<StockSplits[]>;
|
|
79
|
+
fetchStocksSplitAnnouncement(options?: {
|
|
80
|
+
symbol?: string;
|
|
81
|
+
includeDetail?: boolean;
|
|
82
|
+
}): Promise<StocksSplitAnnouncement[]>;
|
|
83
|
+
fetchStocksEtfSplitAnnouncement(options?: {
|
|
84
|
+
symbol?: string;
|
|
85
|
+
}): Promise<StocksEtfSplitAnnouncement[]>;
|
|
86
|
+
fetchStocksListingApplicants(options?: {
|
|
87
|
+
symbol?: string;
|
|
88
|
+
year?: number;
|
|
89
|
+
}): Promise<StocksListingApplication[]>;
|
|
90
|
+
fetchIndicesHistorical(options: {
|
|
91
|
+
date: string;
|
|
92
|
+
symbol?: string;
|
|
93
|
+
}): Promise<IndexHistorical | IndexHistorical[] | null | undefined>;
|
|
94
|
+
fetchIndicesTrades(options: {
|
|
95
|
+
date: string;
|
|
96
|
+
symbol?: string;
|
|
97
|
+
}): Promise<IndexTrades | IndexTrades[] | null | undefined>;
|
|
98
|
+
fetchMarketTrades(options: {
|
|
99
|
+
date: string;
|
|
100
|
+
}): Promise<MarketTrades | null>;
|
|
101
|
+
fetchMarketBreadth(options: {
|
|
102
|
+
date: string;
|
|
103
|
+
}): Promise<MarketBreadth | null>;
|
|
104
|
+
fetchMarketInstitutional(options: {
|
|
105
|
+
date: string;
|
|
106
|
+
}): Promise<MarketInstitutional | null>;
|
|
107
|
+
fetchMarketMarginTrades(options: {
|
|
108
|
+
date: string;
|
|
109
|
+
}): Promise<MarketMarginTrades | null>;
|
|
110
|
+
}
|