fmp-node-api 0.1.7 → 0.1.8
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/dist/index.d.mts +1970 -1812
- package/dist/index.d.ts +1970 -1812
- package/dist/index.js +2 -2
- package/dist/index.mjs +2 -2
- package/dist/types-only.d.mts +610 -549
- package/dist/types-only.d.ts +610 -549
- package/package.json +2 -2
package/dist/index.d.mts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { FMPConfig, APIResponse,
|
|
1
|
+
import { FMPConfig, APIResponse, EarningsCalendar, EarningsConfirmed, DividendsCalendar, EconomicsCalendar, IPOCalendar, SplitsCalendar, CompanyProfile, ExecutiveCompensation, CompanyNotes, HistoricalEmployeeCount, SharesFloat, HistoricalSharesFloat, EarningsCallTranscript, CompanyTranscriptData, TreasuryRate, EconomicIndicator, ETFHoldingDates, ETFHolding, ETFHolder, ETFProfile, ETFWeighting, ETFCountryWeighting, ETFStockExposure, IncomeStatement, BalanceSheet, CashFlowStatement, KeyMetrics, FinancialRatios, EnterpriseValue, CashflowGrowth, IncomeGrowth, BalanceSheetGrowth, FinancialGrowth, EarningsHistorical, EarningsSurprises, InsiderTradingRSSResponse, InsiderTradingSearchResponse, TransactionTypesResponse, InsidersBySymbolResponse, InsiderTradeStatisticsResponse, CikMapperResponse, CikMapperBySymbolResponse, BeneficialOwnershipResponse, FailToDeliverResponse, TransactionType, Form13FResponse, InstitutionalHolderResponse, StockList, ETFList, CryptoList, ForexList, AvailableIndexesList, MarketHours, MarketPerformance, MarketSectorPerformance, MarketIndex, MutualFundHolding, Quote, HistoricalPriceResponse, HistoricalPriceData, ScreenerParams, Screener, AvailableExchanges, AvailableSectors, AvailableIndustries, AvailableCountries, RSSFeedItem, RSSFeedAllItem, RSSFeedV3Item, RSSFeed8KItem, SECFiling, IndustryClassification, IndustryClassificationCode, SenateTradingResponse, SenateHouseTradingByNameResponse, HouseTradingResponse, MarketCap, StockSplitResponse, StockDividendResponse, StockRealTimePrice, StockRealTimePriceFull } from './types-only.mjs';
|
|
2
2
|
export { CompaniesPriceListResponse, DateRangeParams, EconomicIndicatorName, Exchange, IndividualIndustryClassificationParams, IndustryClassificationCodesParams, MarketHoliday, PaginationParams, Period, PeriodParams, QueryParams, RSSFeed8KParams, RSSFeedParams, RSSFeedV3Params, SECFilingsParams, StockDividend, StockListResponse, StockSplit, SymbolParams } from './types-only.mjs';
|
|
3
3
|
export { FMPValidation } from './utils/validation.mjs';
|
|
4
4
|
|
|
@@ -24,537 +24,552 @@ declare class FMPClient {
|
|
|
24
24
|
private getClientForVersion;
|
|
25
25
|
}
|
|
26
26
|
|
|
27
|
-
declare class
|
|
28
|
-
private
|
|
29
|
-
constructor(
|
|
27
|
+
declare class CalendarEndpoints {
|
|
28
|
+
private _client;
|
|
29
|
+
constructor(_client: FMPClient);
|
|
30
30
|
/**
|
|
31
|
-
* Get
|
|
31
|
+
* Get earnings calendar data
|
|
32
32
|
*
|
|
33
|
-
*
|
|
34
|
-
*
|
|
35
|
-
*
|
|
33
|
+
* Provides upcoming earnings announcements for all publicly traded companies
|
|
34
|
+
* within a specified date range. Essential for tracking earnings season,
|
|
35
|
+
* market events, and investment timing decisions.
|
|
36
36
|
*
|
|
37
|
-
* @param
|
|
37
|
+
* @param params - Earnings calendar request parameters
|
|
38
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to today)
|
|
39
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
38
40
|
*
|
|
39
|
-
* @returns Promise resolving to
|
|
41
|
+
* @returns Promise resolving to array of earnings calendar data with announcement details
|
|
40
42
|
*
|
|
41
43
|
* @example
|
|
42
44
|
* ```typescript
|
|
43
|
-
* // Get
|
|
44
|
-
* const
|
|
45
|
-
*
|
|
45
|
+
* // Get earnings calendar for next week
|
|
46
|
+
* const earningsCalendar = await fmp.calendar.getEarningsCalendar({
|
|
47
|
+
* from: '2024-01-15',
|
|
48
|
+
* to: '2024-01-22'
|
|
49
|
+
* });
|
|
50
|
+
* earningsCalendar.data.forEach(earning => {
|
|
51
|
+
* console.log(`${earning.date}: ${earning.symbol} - Est. EPS: ${earning.estimatedEps}`);
|
|
52
|
+
* });
|
|
46
53
|
*
|
|
47
|
-
* // Get
|
|
48
|
-
* const
|
|
54
|
+
* // Get earnings calendar for current month
|
|
55
|
+
* const monthlyEarnings = await fmp.calendar.getEarningsCalendar({
|
|
56
|
+
* from: '2024-01-01',
|
|
57
|
+
* to: '2024-01-31'
|
|
58
|
+
* });
|
|
49
59
|
* ```
|
|
50
60
|
*
|
|
51
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
61
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#earnings-calendar-earnings|FMP Earnings Calendar Documentation}
|
|
52
62
|
*/
|
|
53
|
-
|
|
63
|
+
getEarningsCalendar(params?: {
|
|
64
|
+
from?: string;
|
|
65
|
+
to?: string;
|
|
66
|
+
}): Promise<APIResponse<EarningsCalendar[]>>;
|
|
54
67
|
/**
|
|
55
|
-
* Get
|
|
68
|
+
* Get confirmed earnings calendar data
|
|
56
69
|
*
|
|
57
|
-
*
|
|
58
|
-
*
|
|
59
|
-
*
|
|
70
|
+
* Provides confirmed earnings announcements with verified dates and times.
|
|
71
|
+
* These are earnings announcements that have been officially confirmed
|
|
72
|
+
* by companies, providing more reliable scheduling information.
|
|
60
73
|
*
|
|
61
|
-
* @param
|
|
74
|
+
* @param params - Confirmed earnings calendar request parameters
|
|
75
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to today)
|
|
76
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
62
77
|
*
|
|
63
|
-
* @returns Promise resolving to
|
|
78
|
+
* @returns Promise resolving to array of confirmed earnings calendar data
|
|
64
79
|
*
|
|
65
80
|
* @example
|
|
66
81
|
* ```typescript
|
|
67
|
-
* // Get
|
|
68
|
-
* const
|
|
69
|
-
*
|
|
70
|
-
*
|
|
82
|
+
* // Get confirmed earnings for next week
|
|
83
|
+
* const confirmedEarnings = await fmp.calendar.getEarningsConfirmed({
|
|
84
|
+
* from: '2024-01-15',
|
|
85
|
+
* to: '2024-01-22'
|
|
86
|
+
* });
|
|
87
|
+
* confirmedEarnings.data.forEach(earning => {
|
|
88
|
+
* console.log(`${earning.date}: ${earning.symbol} - Confirmed: ${earning.time}`);
|
|
71
89
|
* });
|
|
72
90
|
*
|
|
73
|
-
* // Get
|
|
74
|
-
* const
|
|
91
|
+
* // Get confirmed earnings for current month
|
|
92
|
+
* const monthlyConfirmed = await fmp.calendar.getEarningsConfirmed({
|
|
93
|
+
* from: '2024-01-01',
|
|
94
|
+
* to: '2024-01-31'
|
|
95
|
+
* });
|
|
75
96
|
* ```
|
|
76
97
|
*
|
|
77
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
98
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#earnings-confirmed-earnings|FMP Earnings Confirmed Documentation}
|
|
78
99
|
*/
|
|
79
|
-
|
|
100
|
+
getEarningsConfirmed(params?: {
|
|
101
|
+
from?: string;
|
|
102
|
+
to?: string;
|
|
103
|
+
}): Promise<APIResponse<EarningsConfirmed[]>>;
|
|
80
104
|
/**
|
|
81
|
-
* Get
|
|
105
|
+
* Get dividends calendar data
|
|
82
106
|
*
|
|
83
|
-
*
|
|
84
|
-
*
|
|
85
|
-
*
|
|
107
|
+
* Provides upcoming dividend payments and ex-dividend dates for all
|
|
108
|
+
* publicly traded companies within a specified date range. Essential
|
|
109
|
+
* for dividend investors and income-focused strategies.
|
|
86
110
|
*
|
|
87
|
-
* @param
|
|
111
|
+
* @param params - Dividends calendar request parameters
|
|
112
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to today)
|
|
113
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
88
114
|
*
|
|
89
|
-
* @returns Promise resolving to
|
|
115
|
+
* @returns Promise resolving to array of dividends calendar data with payment details
|
|
90
116
|
*
|
|
91
117
|
* @example
|
|
92
118
|
* ```typescript
|
|
93
|
-
* // Get
|
|
94
|
-
* const
|
|
95
|
-
*
|
|
96
|
-
*
|
|
119
|
+
* // Get dividends calendar for next week
|
|
120
|
+
* const dividendsCalendar = await fmp.calendar.getDividendsCalendar({
|
|
121
|
+
* from: '2024-01-15',
|
|
122
|
+
* to: '2024-01-22'
|
|
123
|
+
* });
|
|
124
|
+
* dividendsCalendar.data.forEach(dividend => {
|
|
125
|
+
* console.log(`${dividend.date}: ${dividend.symbol} - Amount: $${dividend.amount}`);
|
|
97
126
|
* });
|
|
98
127
|
*
|
|
99
|
-
* // Get
|
|
100
|
-
* const
|
|
128
|
+
* // Get dividends calendar for current month
|
|
129
|
+
* const monthlyDividends = await fmp.calendar.getDividendsCalendar({
|
|
130
|
+
* from: '2024-01-01',
|
|
131
|
+
* to: '2024-01-31'
|
|
132
|
+
* });
|
|
101
133
|
* ```
|
|
102
134
|
*
|
|
103
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#dividends-
|
|
135
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#dividends-calendar-dividends|FMP Dividends Calendar Documentation}
|
|
104
136
|
*/
|
|
105
|
-
|
|
137
|
+
getDividendsCalendar(params?: {
|
|
138
|
+
from?: string;
|
|
139
|
+
to?: string;
|
|
140
|
+
}): Promise<APIResponse<DividendsCalendar[]>>;
|
|
106
141
|
/**
|
|
107
|
-
* Get
|
|
142
|
+
* Get economic calendar data
|
|
108
143
|
*
|
|
109
|
-
* Provides
|
|
110
|
-
*
|
|
111
|
-
*
|
|
144
|
+
* Provides upcoming economic events, indicators, and data releases
|
|
145
|
+
* that can impact financial markets. Essential for understanding
|
|
146
|
+
* market-moving events and economic trends.
|
|
112
147
|
*
|
|
113
|
-
* @param
|
|
148
|
+
* @param params - Economic calendar request parameters
|
|
149
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to today)
|
|
150
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
114
151
|
*
|
|
115
|
-
* @returns Promise resolving to array of
|
|
152
|
+
* @returns Promise resolving to array of economic calendar data with event details
|
|
116
153
|
*
|
|
117
154
|
* @example
|
|
118
155
|
* ```typescript
|
|
119
|
-
* // Get
|
|
120
|
-
* const
|
|
121
|
-
*
|
|
122
|
-
*
|
|
123
|
-
*
|
|
124
|
-
*
|
|
125
|
-
* console.log(`${
|
|
156
|
+
* // Get economic calendar for next week
|
|
157
|
+
* const economicCalendar = await fmp.calendar.getEconomicsCalendar({
|
|
158
|
+
* from: '2024-01-15',
|
|
159
|
+
* to: '2024-01-22'
|
|
160
|
+
* });
|
|
161
|
+
* economicCalendar.data.forEach(event => {
|
|
162
|
+
* console.log(`${event.date}: ${event.event} - Country: ${event.country}`);
|
|
126
163
|
* });
|
|
127
164
|
*
|
|
128
|
-
* // Get
|
|
129
|
-
* const
|
|
165
|
+
* // Get economic calendar for current month
|
|
166
|
+
* const monthlyEconomic = await fmp.calendar.getEconomicsCalendar({
|
|
167
|
+
* from: '2024-01-01',
|
|
168
|
+
* to: '2024-01-31'
|
|
169
|
+
* });
|
|
130
170
|
* ```
|
|
171
|
+
*
|
|
172
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#economics-calendar-economics-data|FMP Economic Calendar Documentation}
|
|
131
173
|
*/
|
|
132
|
-
|
|
174
|
+
getEconomicsCalendar(params?: {
|
|
175
|
+
from?: string;
|
|
176
|
+
to?: string;
|
|
177
|
+
}): Promise<APIResponse<EconomicsCalendar[]>>;
|
|
133
178
|
/**
|
|
134
|
-
* Get
|
|
179
|
+
* Get IPO calendar data
|
|
135
180
|
*
|
|
136
|
-
* Provides
|
|
137
|
-
*
|
|
138
|
-
*
|
|
181
|
+
* Provides upcoming initial public offerings (IPOs) and their details
|
|
182
|
+
* within a specified date range. Essential for tracking new market
|
|
183
|
+
* entrants and investment opportunities in newly public companies.
|
|
139
184
|
*
|
|
140
|
-
* @param
|
|
185
|
+
* @param params - IPO calendar request parameters
|
|
186
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to today)
|
|
187
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
141
188
|
*
|
|
142
|
-
* @returns Promise resolving to array of
|
|
189
|
+
* @returns Promise resolving to array of IPO calendar data with offering details
|
|
143
190
|
*
|
|
144
191
|
* @example
|
|
145
192
|
* ```typescript
|
|
146
|
-
* // Get
|
|
147
|
-
* const
|
|
148
|
-
*
|
|
149
|
-
*
|
|
150
|
-
*
|
|
151
|
-
*
|
|
152
|
-
* console.log(`${
|
|
153
|
-
* console.log(` Bid: $${stock.bidPrice} (${stock.bidSize} shares)`);
|
|
154
|
-
* console.log(` Ask: $${stock.askPrice} (${stock.askSize} shares)`);
|
|
155
|
-
* console.log(` Last: $${stock.lastSalePrice} (${stock.lastSaleSize} shares)`);
|
|
156
|
-
* console.log(` Volume: ${stock.volume.toLocaleString()}`);
|
|
193
|
+
* // Get IPO calendar for next week
|
|
194
|
+
* const ipoCalendar = await fmp.calendar.getIPOCalendar({
|
|
195
|
+
* from: '2024-01-15',
|
|
196
|
+
* to: '2024-01-22'
|
|
197
|
+
* });
|
|
198
|
+
* ipoCalendar.data.forEach(ipo => {
|
|
199
|
+
* console.log(`${ipo.date}: ${ipo.symbol} - Price: $${ipo.price}, Shares: ${ipo.shares.toLocaleString()}`);
|
|
157
200
|
* });
|
|
158
201
|
*
|
|
159
|
-
* // Get
|
|
160
|
-
* const
|
|
202
|
+
* // Get IPO calendar for current month
|
|
203
|
+
* const monthlyIPOs = await fmp.calendar.getIPOCalendar({
|
|
204
|
+
* from: '2024-01-01',
|
|
205
|
+
* to: '2024-01-31'
|
|
206
|
+
* });
|
|
161
207
|
* ```
|
|
162
208
|
*
|
|
163
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
209
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#ipo-calender-by-ipo-calendar|FMP IPO Calendar Documentation}
|
|
164
210
|
*/
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
private client;
|
|
170
|
-
constructor(client: FMPClient);
|
|
211
|
+
getIPOCalendar(params?: {
|
|
212
|
+
from?: string;
|
|
213
|
+
to?: string;
|
|
214
|
+
}): Promise<APIResponse<IPOCalendar[]>>;
|
|
171
215
|
/**
|
|
172
|
-
* Get
|
|
216
|
+
* Get stock splits calendar data
|
|
173
217
|
*
|
|
174
|
-
* Provides
|
|
175
|
-
*
|
|
176
|
-
*
|
|
218
|
+
* Provides upcoming stock splits for publicly traded companies within
|
|
219
|
+
* a specified date range. Essential for understanding corporate actions
|
|
220
|
+
* that affect share prices and trading dynamics.
|
|
177
221
|
*
|
|
178
|
-
* @param params -
|
|
179
|
-
* @param params.
|
|
180
|
-
* @param params.
|
|
181
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
222
|
+
* @param params - Stock splits calendar request parameters
|
|
223
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to today)
|
|
224
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
182
225
|
*
|
|
183
|
-
* @returns Promise resolving to array of
|
|
226
|
+
* @returns Promise resolving to array of stock splits calendar data with split details
|
|
184
227
|
*
|
|
185
228
|
* @example
|
|
186
229
|
* ```typescript
|
|
187
|
-
* // Get
|
|
188
|
-
* const
|
|
189
|
-
*
|
|
190
|
-
*
|
|
230
|
+
* // Get stock splits calendar for next week
|
|
231
|
+
* const splitsCalendar = await fmp.calendar.getSplitsCalendar({
|
|
232
|
+
* from: '2024-01-15',
|
|
233
|
+
* to: '2024-01-22'
|
|
234
|
+
* });
|
|
235
|
+
* splitsCalendar.data.forEach(split => {
|
|
236
|
+
* console.log(`${split.date}: ${split.symbol} - Ratio: ${split.numerator}:${split.denominator}`);
|
|
191
237
|
* });
|
|
192
238
|
*
|
|
193
|
-
* // Get
|
|
194
|
-
* const
|
|
239
|
+
* // Get stock splits calendar for current month
|
|
240
|
+
* const monthlySplits = await fmp.calendar.getSplitsCalendar({
|
|
241
|
+
* from: '2024-01-01',
|
|
242
|
+
* to: '2024-01-31'
|
|
243
|
+
* });
|
|
195
244
|
* ```
|
|
196
245
|
*
|
|
197
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs
|
|
246
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#splits-calendar-splits|FMP Stock Splits Calendar Documentation}
|
|
198
247
|
*/
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
248
|
+
getSplitsCalendar(params?: {
|
|
249
|
+
from?: string;
|
|
250
|
+
to?: string;
|
|
251
|
+
}): Promise<APIResponse<SplitsCalendar[]>>;
|
|
252
|
+
}
|
|
253
|
+
|
|
254
|
+
declare class CompanyEndpoints {
|
|
255
|
+
private client;
|
|
256
|
+
constructor(client: FMPClient);
|
|
204
257
|
/**
|
|
205
|
-
* Get
|
|
258
|
+
* Get comprehensive company profile and information
|
|
206
259
|
*
|
|
207
|
-
* Provides
|
|
208
|
-
* and
|
|
209
|
-
*
|
|
260
|
+
* Provides detailed company information including financial metrics, business description,
|
|
261
|
+
* headquarters location, and key performance indicators. Essential for fundamental analysis
|
|
262
|
+
* and understanding a company's business model and market position.
|
|
210
263
|
*
|
|
211
|
-
* @param
|
|
212
|
-
* @param params.symbol - The stock symbol to get balance sheet for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
213
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
214
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
264
|
+
* @param symbol - The stock symbol to get the profile for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
215
265
|
*
|
|
216
|
-
* @returns Promise resolving to
|
|
266
|
+
* @returns Promise resolving to comprehensive company profile with financial and business information
|
|
217
267
|
*
|
|
218
268
|
* @example
|
|
219
269
|
* ```typescript
|
|
220
|
-
* // Get
|
|
221
|
-
* const
|
|
222
|
-
*
|
|
223
|
-
*
|
|
224
|
-
* });
|
|
270
|
+
* // Get Apple's company profile
|
|
271
|
+
* const profile = await fmp.company.getCompanyProfile('AAPL');
|
|
272
|
+
* console.log(`Company: ${profile.data.companyName}`);
|
|
273
|
+
* console.log(`Industry: ${profile.data.industry}`);
|
|
274
|
+
* console.log(`Market Cap: $${profile.data.mktCap.toLocaleString()}`);
|
|
275
|
+
* console.log(`Description: ${profile.data.description.substring(0, 100)}...`);
|
|
225
276
|
*
|
|
226
|
-
* // Get
|
|
227
|
-
* const
|
|
277
|
+
* // Get Microsoft's profile
|
|
278
|
+
* const msftProfile = await fmp.company.getCompanyProfile('MSFT');
|
|
228
279
|
* ```
|
|
229
280
|
*
|
|
230
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
281
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#profile-symbol|FMP Company Profile Documentation}
|
|
231
282
|
*/
|
|
232
|
-
|
|
233
|
-
symbol: string;
|
|
234
|
-
period?: 'annual' | 'quarter';
|
|
235
|
-
limit?: number;
|
|
236
|
-
}): Promise<APIResponse<BalanceSheet[]>>;
|
|
283
|
+
getCompanyProfile(symbol: string): Promise<APIResponse<CompanyProfile>>;
|
|
237
284
|
/**
|
|
238
|
-
* Get
|
|
285
|
+
* Get executive compensation and governance information
|
|
239
286
|
*
|
|
240
|
-
* Provides
|
|
241
|
-
* and
|
|
242
|
-
*
|
|
287
|
+
* Provides detailed compensation data for company executives including salary, bonuses,
|
|
288
|
+
* stock options, and other benefits. Essential for governance analysis and understanding
|
|
289
|
+
* executive pay structures and alignment with shareholder interests.
|
|
243
290
|
*
|
|
244
|
-
* @param
|
|
245
|
-
* @param params.symbol - The stock symbol to get cash flow statement for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
246
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
247
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
291
|
+
* @param symbol - The stock symbol to get executive compensation for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
248
292
|
*
|
|
249
|
-
* @returns Promise resolving to array of
|
|
293
|
+
* @returns Promise resolving to array of executive compensation data with detailed pay information
|
|
250
294
|
*
|
|
251
295
|
* @example
|
|
252
296
|
* ```typescript
|
|
253
|
-
* // Get
|
|
254
|
-
* const
|
|
255
|
-
*
|
|
256
|
-
* console.log(`${
|
|
297
|
+
* // Get Apple's executive compensation
|
|
298
|
+
* const compensation = await fmp.company.getExecutiveCompensation('AAPL');
|
|
299
|
+
* compensation.data.forEach(exec => {
|
|
300
|
+
* console.log(`${exec.name} (${exec.title}):`);
|
|
301
|
+
* console.log(` Salary: $${exec.salary.toLocaleString()}`);
|
|
302
|
+
* console.log(` Bonus: $${exec.bonus.toLocaleString()}`);
|
|
303
|
+
* console.log(` Stock Options: $${exec.stockAwards.toLocaleString()}`);
|
|
257
304
|
* });
|
|
258
305
|
*
|
|
259
|
-
* // Get
|
|
260
|
-
* const
|
|
306
|
+
* // Get Tesla's executive compensation
|
|
307
|
+
* const teslaComp = await fmp.company.getExecutiveCompensation('TSLA');
|
|
261
308
|
* ```
|
|
262
309
|
*
|
|
263
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
310
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#executive-compensation|FMP Executive Compensation Documentation}
|
|
264
311
|
*/
|
|
265
|
-
|
|
266
|
-
symbol: string;
|
|
267
|
-
period?: 'annual' | 'quarter';
|
|
268
|
-
limit?: number;
|
|
269
|
-
}): Promise<APIResponse<CashFlowStatement[]>>;
|
|
312
|
+
getExecutiveCompensation(symbol: string): Promise<APIResponse<ExecutiveCompensation[]>>;
|
|
270
313
|
/**
|
|
271
|
-
* Get
|
|
314
|
+
* Get company notes and financial disclosures
|
|
272
315
|
*
|
|
273
|
-
* Provides
|
|
274
|
-
*
|
|
275
|
-
*
|
|
316
|
+
* Provides important notes and disclosures from company financial statements.
|
|
317
|
+
* These notes contain critical information about accounting policies, risks,
|
|
318
|
+
* contingencies, and other material information that affects financial analysis.
|
|
276
319
|
*
|
|
277
|
-
* @param
|
|
278
|
-
* @param params.symbol - The stock symbol to get key metrics for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
279
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
280
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
320
|
+
* @param symbol - The stock symbol to get notes for (e.g., 'AAPL', 'MSFT', 'JPM')
|
|
281
321
|
*
|
|
282
|
-
* @returns Promise resolving to array of
|
|
322
|
+
* @returns Promise resolving to array of company notes with detailed disclosure information
|
|
283
323
|
*
|
|
284
324
|
* @example
|
|
285
325
|
* ```typescript
|
|
286
|
-
* // Get
|
|
287
|
-
* const
|
|
288
|
-
*
|
|
289
|
-
* console.log(
|
|
326
|
+
* // Get Apple's company notes
|
|
327
|
+
* const notes = await fmp.company.getCompanyNotes('AAPL');
|
|
328
|
+
* notes.data.forEach(note => {
|
|
329
|
+
* console.log(`Note ${note.noteNumber}: ${note.noteTitle}`);
|
|
330
|
+
* console.log(` Content: ${note.noteContent.substring(0, 100)}...`);
|
|
290
331
|
* });
|
|
291
332
|
*
|
|
292
|
-
* // Get
|
|
293
|
-
* const
|
|
333
|
+
* // Get JPMorgan's notes
|
|
334
|
+
* const jpmNotes = await fmp.company.getCompanyNotes('JPM');
|
|
294
335
|
* ```
|
|
295
336
|
*
|
|
296
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
337
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#company-notes|FMP Company Notes Documentation}
|
|
297
338
|
*/
|
|
298
|
-
|
|
299
|
-
symbol: string;
|
|
300
|
-
period?: 'annual' | 'quarter';
|
|
301
|
-
limit?: number;
|
|
302
|
-
}): Promise<APIResponse<KeyMetrics[]>>;
|
|
339
|
+
getCompanyNotes(symbol: string): Promise<APIResponse<CompanyNotes[]>>;
|
|
303
340
|
/**
|
|
304
|
-
* Get
|
|
341
|
+
* Get historical employee count data
|
|
305
342
|
*
|
|
306
|
-
* Provides
|
|
307
|
-
*
|
|
308
|
-
*
|
|
343
|
+
* Provides historical data on company employee counts over time.
|
|
344
|
+
* Useful for analyzing company growth, operational efficiency, and workforce trends.
|
|
345
|
+
* Employee count is often a key indicator of company expansion or contraction.
|
|
309
346
|
*
|
|
310
|
-
* @param
|
|
311
|
-
* @param params.symbol - The stock symbol to get financial ratios for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
312
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
313
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
347
|
+
* @param symbol - The stock symbol to get historical employee count for (e.g., 'AAPL', 'MSFT', 'AMZN')
|
|
314
348
|
*
|
|
315
|
-
* @returns Promise resolving to array of
|
|
349
|
+
* @returns Promise resolving to array of historical employee count data with year-by-year information
|
|
316
350
|
*
|
|
317
351
|
* @example
|
|
318
352
|
* ```typescript
|
|
319
|
-
* // Get
|
|
320
|
-
* const
|
|
321
|
-
*
|
|
322
|
-
* console.log(`${
|
|
353
|
+
* // Get Apple's employee count history
|
|
354
|
+
* const employees = await fmp.company.getHistoricalEmployeeCount('AAPL');
|
|
355
|
+
* employees.data.forEach(year => {
|
|
356
|
+
* console.log(`${year.year}: ${year.employeeCount.toLocaleString()} employees`);
|
|
323
357
|
* });
|
|
324
358
|
*
|
|
325
|
-
* // Get
|
|
326
|
-
* const
|
|
359
|
+
* // Get Amazon's employee growth
|
|
360
|
+
* const amazonEmployees = await fmp.company.getHistoricalEmployeeCount('AMZN');
|
|
327
361
|
* ```
|
|
328
362
|
*
|
|
329
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
363
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#historical-employee-count|FMP Historical Employee Count Documentation}
|
|
330
364
|
*/
|
|
331
|
-
|
|
332
|
-
symbol: string;
|
|
333
|
-
period?: 'annual' | 'quarter';
|
|
334
|
-
limit?: number;
|
|
335
|
-
}): Promise<APIResponse<FinancialRatios[]>>;
|
|
365
|
+
getHistoricalEmployeeCount(symbol: string): Promise<APIResponse<HistoricalEmployeeCount[]>>;
|
|
336
366
|
/**
|
|
337
|
-
* Get
|
|
367
|
+
* Get current shares float information
|
|
338
368
|
*
|
|
339
|
-
* Provides
|
|
340
|
-
*
|
|
341
|
-
*
|
|
369
|
+
* Provides the total number of shares that are publicly traded (float) for a company.
|
|
370
|
+
* The float is calculated by subtracting restricted shares from total outstanding shares.
|
|
371
|
+
* Important for understanding liquidity, volatility, and trading dynamics.
|
|
342
372
|
*
|
|
343
|
-
* @param
|
|
344
|
-
* @param params.symbol - The stock symbol to get enterprise value for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
345
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
346
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
373
|
+
* @param symbol - The stock symbol to get shares float for (e.g., 'AAPL', 'TSLA', 'NVDA')
|
|
347
374
|
*
|
|
348
|
-
* @returns Promise resolving to
|
|
375
|
+
* @returns Promise resolving to shares float data with current float information
|
|
349
376
|
*
|
|
350
377
|
* @example
|
|
351
378
|
* ```typescript
|
|
352
|
-
* // Get
|
|
353
|
-
* const
|
|
354
|
-
*
|
|
355
|
-
*
|
|
356
|
-
* });
|
|
379
|
+
* // Get Apple's shares float
|
|
380
|
+
* const float = await fmp.company.getSharesFloat('AAPL');
|
|
381
|
+
* console.log(`Float: ${float.data.sharesFloat.toLocaleString()} shares`);
|
|
382
|
+
* console.log(`Outstanding: ${float.data.sharesOutstanding.toLocaleString()} shares`);
|
|
383
|
+
* console.log(`Restricted: ${float.data.restrictedShares.toLocaleString()} shares`);
|
|
357
384
|
*
|
|
358
|
-
* // Get
|
|
359
|
-
* const
|
|
385
|
+
* // Get Tesla's float
|
|
386
|
+
* const teslaFloat = await fmp.company.getSharesFloat('TSLA');
|
|
360
387
|
* ```
|
|
361
388
|
*
|
|
362
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
389
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#shares-float|FMP Shares Float Documentation}
|
|
363
390
|
*/
|
|
364
|
-
|
|
365
|
-
symbol: string;
|
|
366
|
-
period?: 'annual' | 'quarter';
|
|
367
|
-
limit?: number;
|
|
368
|
-
}): Promise<APIResponse<EnterpriseValue[]>>;
|
|
391
|
+
getSharesFloat(symbol: string): Promise<APIResponse<SharesFloat>>;
|
|
369
392
|
/**
|
|
370
|
-
* Get
|
|
393
|
+
* Get historical shares float data
|
|
371
394
|
*
|
|
372
|
-
* Provides
|
|
373
|
-
*
|
|
374
|
-
*
|
|
395
|
+
* Provides historical data on company shares float over time.
|
|
396
|
+
* Useful for analyzing changes in liquidity, share issuance, and corporate actions
|
|
397
|
+
* that affect the number of publicly traded shares.
|
|
375
398
|
*
|
|
376
|
-
* @param
|
|
377
|
-
* @param params.symbol - The stock symbol to get cash flow growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
378
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
379
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
399
|
+
* @param symbol - The stock symbol to get historical shares float for (e.g., 'AAPL', 'TSLA', 'NVDA')
|
|
380
400
|
*
|
|
381
|
-
* @returns Promise resolving to array of
|
|
401
|
+
* @returns Promise resolving to array of historical shares float data with date-by-date information
|
|
382
402
|
*
|
|
383
403
|
* @example
|
|
384
404
|
* ```typescript
|
|
385
|
-
* // Get
|
|
386
|
-
* const
|
|
387
|
-
*
|
|
388
|
-
* console.log(`${
|
|
405
|
+
* // Get Apple's historical float
|
|
406
|
+
* const historicalFloat = await fmp.company.getHistoricalSharesFloat('AAPL');
|
|
407
|
+
* historicalFloat.data.forEach(entry => {
|
|
408
|
+
* console.log(`${entry.date}: ${entry.sharesFloat.toLocaleString()} shares`);
|
|
389
409
|
* });
|
|
390
410
|
*
|
|
391
|
-
* // Get
|
|
392
|
-
* const
|
|
411
|
+
* // Get Tesla's float history
|
|
412
|
+
* const teslaHistory = await fmp.company.getHistoricalSharesFloat('TSLA');
|
|
393
413
|
* ```
|
|
394
414
|
*
|
|
395
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs
|
|
415
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#company-historical-share-float|FMP Historical Shares Float Documentation}
|
|
396
416
|
*/
|
|
397
|
-
|
|
398
|
-
symbol: string;
|
|
399
|
-
period?: 'annual' | 'quarter';
|
|
400
|
-
limit?: number;
|
|
401
|
-
}): Promise<APIResponse<CashflowGrowth[]>>;
|
|
417
|
+
getHistoricalSharesFloat(symbol: string): Promise<APIResponse<HistoricalSharesFloat[]>>;
|
|
402
418
|
/**
|
|
403
|
-
* Get
|
|
419
|
+
* Get earnings call transcript for specific quarter
|
|
404
420
|
*
|
|
405
|
-
* Provides
|
|
406
|
-
*
|
|
407
|
-
*
|
|
421
|
+
* Provides the full transcript of a company's earnings conference call.
|
|
422
|
+
* Contains detailed Q&A sessions, management commentary, and insights into
|
|
423
|
+
* company performance, strategy, and future outlook.
|
|
408
424
|
*
|
|
409
|
-
* @param params -
|
|
410
|
-
* @param params.symbol - The stock symbol to get
|
|
411
|
-
* @param params.
|
|
412
|
-
* @param params.
|
|
425
|
+
* @param params - Earnings call transcript request parameters
|
|
426
|
+
* @param params.symbol - The stock symbol to get transcript for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
427
|
+
* @param params.year - The year of the earnings call (e.g., 2024)
|
|
428
|
+
* @param params.quarter - The quarter of the earnings call (1, 2, 3, or 4)
|
|
413
429
|
*
|
|
414
|
-
* @returns Promise resolving to
|
|
430
|
+
* @returns Promise resolving to earnings call transcript with full text content
|
|
415
431
|
*
|
|
416
432
|
* @example
|
|
417
433
|
* ```typescript
|
|
418
|
-
* // Get
|
|
419
|
-
* const
|
|
420
|
-
*
|
|
421
|
-
*
|
|
422
|
-
*
|
|
423
|
-
*
|
|
424
|
-
* // Get quarterly income growth for Microsoft
|
|
425
|
-
* const quarterlyGrowth = await fmp.financial.getIncomeGrowth({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
426
|
-
* ```
|
|
427
|
-
*
|
|
428
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#income-statement-growth|FMP Income Growth Documentation}
|
|
429
|
-
*/
|
|
430
|
-
getIncomeGrowth(params: {
|
|
431
|
-
symbol: string;
|
|
432
|
-
period?: 'annual' | 'quarter';
|
|
433
|
-
limit?: number;
|
|
434
|
-
}): Promise<APIResponse<IncomeGrowth[]>>;
|
|
435
|
-
/**
|
|
436
|
-
* Get balance sheet growth data
|
|
437
|
-
*
|
|
438
|
-
* Provides balance sheet growth rates showing how quickly a company's
|
|
439
|
-
* assets, liabilities, and equity are growing over time. Essential for
|
|
440
|
-
* analyzing capital structure trends and financial position changes.
|
|
441
|
-
*
|
|
442
|
-
* @param params - Balance sheet growth request parameters
|
|
443
|
-
* @param params.symbol - The stock symbol to get balance sheet growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
444
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
445
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
446
|
-
*
|
|
447
|
-
* @returns Promise resolving to array of balance sheet growth data with growth metrics
|
|
448
|
-
*
|
|
449
|
-
* @example
|
|
450
|
-
* ```typescript
|
|
451
|
-
* // Get balance sheet growth for Apple
|
|
452
|
-
* const balanceSheetGrowth = await fmp.financial.getBalanceSheetGrowth({ symbol: 'AAPL' });
|
|
453
|
-
* balanceSheetGrowth.data.forEach(growth => {
|
|
454
|
-
* console.log(`${growth.date}: Assets Growth ${growth.totalAssetsGrowth}%, Equity Growth ${growth.totalStockholdersEquityGrowth}%`);
|
|
434
|
+
* // Get Apple's Q1 2024 earnings call
|
|
435
|
+
* const transcript = await fmp.company.getEarningsCallTranscript({
|
|
436
|
+
* symbol: 'AAPL',
|
|
437
|
+
* year: 2024,
|
|
438
|
+
* quarter: 1
|
|
455
439
|
* });
|
|
440
|
+
* console.log(`Transcript: ${transcript.data[0].content.substring(0, 200)}...`);
|
|
456
441
|
*
|
|
457
|
-
* // Get
|
|
458
|
-
* const
|
|
442
|
+
* // Get Tesla's Q4 2023 earnings call
|
|
443
|
+
* const teslaTranscript = await fmp.company.getEarningsCallTranscript({
|
|
444
|
+
* symbol: 'TSLA',
|
|
445
|
+
* year: 2023,
|
|
446
|
+
* quarter: 4
|
|
447
|
+
* });
|
|
459
448
|
* ```
|
|
460
449
|
*
|
|
461
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs
|
|
450
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#earnings-transcript-earnings-transcripts|FMP Earnings Call Transcript Documentation}
|
|
462
451
|
*/
|
|
463
|
-
|
|
452
|
+
getEarningsCallTranscript(params: {
|
|
464
453
|
symbol: string;
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
}): Promise<APIResponse<
|
|
454
|
+
year: number;
|
|
455
|
+
quarter: number;
|
|
456
|
+
}): Promise<APIResponse<EarningsCallTranscript>>;
|
|
468
457
|
/**
|
|
469
|
-
* Get
|
|
458
|
+
* Get available earnings call transcript dates
|
|
470
459
|
*
|
|
471
|
-
* Provides
|
|
472
|
-
*
|
|
473
|
-
*
|
|
460
|
+
* Provides a list of all available earnings call transcript dates for a company.
|
|
461
|
+
* Useful for discovering which quarters have transcripts available before
|
|
462
|
+
* requesting the full transcript content.
|
|
474
463
|
*
|
|
475
|
-
* @param
|
|
476
|
-
* @param params.symbol - The stock symbol to get financial growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
477
|
-
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
478
|
-
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
464
|
+
* @param symbol - The stock symbol to get transcript dates for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
479
465
|
*
|
|
480
|
-
* @returns Promise resolving to array of
|
|
466
|
+
* @returns Promise resolving to array of available transcript dates with quarter information
|
|
481
467
|
*
|
|
482
468
|
* @example
|
|
483
469
|
* ```typescript
|
|
484
|
-
* // Get
|
|
485
|
-
* const
|
|
486
|
-
*
|
|
487
|
-
* console.log(
|
|
470
|
+
* // Get Apple's available transcript dates
|
|
471
|
+
* const transcriptDates = await fmp.company.getCompanyTranscriptData('AAPL');
|
|
472
|
+
* transcriptDates.data.forEach(date => {
|
|
473
|
+
* console.log(`Q${date.quarter} ${date.year}: ${date.date}`);
|
|
488
474
|
* });
|
|
489
475
|
*
|
|
490
|
-
* // Get
|
|
491
|
-
* const
|
|
476
|
+
* // Get Microsoft's transcript availability
|
|
477
|
+
* const msftDates = await fmp.company.getCompanyTranscriptData('MSFT');
|
|
492
478
|
* ```
|
|
493
479
|
*
|
|
494
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs
|
|
480
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#transcript-dates-earnings-transcripts|FMP Company Transcript Data Documentation}
|
|
495
481
|
*/
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
482
|
+
getCompanyTranscriptData(symbol: string): Promise<APIResponse<CompanyTranscriptData[]>>;
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
declare class EconomicEndpoints {
|
|
486
|
+
private client;
|
|
487
|
+
constructor(client: FMPClient);
|
|
501
488
|
/**
|
|
502
|
-
* Get
|
|
489
|
+
* Get treasury rates data
|
|
503
490
|
*
|
|
504
|
-
* Provides historical
|
|
505
|
-
*
|
|
506
|
-
*
|
|
491
|
+
* Provides historical treasury rates for various maturities including
|
|
492
|
+
* 1-month, 3-month, 6-month, 1-year, 2-year, 3-year, 5-year, 7-year,
|
|
493
|
+
* 10-year, 20-year, and 30-year treasury bonds. Essential for analyzing
|
|
494
|
+
* interest rate trends, yield curves, and fixed income investments.
|
|
507
495
|
*
|
|
508
|
-
* @param params -
|
|
509
|
-
* @param params.
|
|
510
|
-
* @param params.
|
|
496
|
+
* @param params - Treasury rates request parameters
|
|
497
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to 1 year ago)
|
|
498
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to today)
|
|
511
499
|
*
|
|
512
|
-
* @returns Promise resolving to array of
|
|
500
|
+
* @returns Promise resolving to array of treasury rates data with yield information
|
|
513
501
|
*
|
|
514
502
|
* @example
|
|
515
503
|
* ```typescript
|
|
516
|
-
* // Get
|
|
517
|
-
* const
|
|
518
|
-
*
|
|
519
|
-
*
|
|
504
|
+
* // Get treasury rates for the last year
|
|
505
|
+
* const treasuryRates = await fmp.economic.getTreasuryRates({
|
|
506
|
+
* from: '2023-01-01',
|
|
507
|
+
* to: '2023-12-31'
|
|
508
|
+
* });
|
|
509
|
+
* treasuryRates.data.forEach(rate => {
|
|
510
|
+
* console.log(`${rate.date}: 10Y ${rate.tenY}%, 2Y ${rate.twoY}%`);
|
|
520
511
|
* });
|
|
521
512
|
*
|
|
522
|
-
* // Get
|
|
523
|
-
* const
|
|
513
|
+
* // Get recent treasury rates
|
|
514
|
+
* const recentRates = await fmp.economic.getTreasuryRates({
|
|
515
|
+
* from: '2024-01-01'
|
|
516
|
+
* });
|
|
524
517
|
* ```
|
|
525
518
|
*
|
|
526
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
519
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#treasury-rates|FMP Treasury Rates Documentation}
|
|
527
520
|
*/
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
}): Promise<APIResponse<
|
|
521
|
+
getTreasuryRates(params: {
|
|
522
|
+
from?: string;
|
|
523
|
+
to?: string;
|
|
524
|
+
}): Promise<APIResponse<TreasuryRate[]>>;
|
|
532
525
|
/**
|
|
533
|
-
* Get
|
|
526
|
+
* Get economic indicators data
|
|
534
527
|
*
|
|
535
|
-
* Provides
|
|
536
|
-
*
|
|
537
|
-
*
|
|
528
|
+
* Provides real-time and historical economic data for a wide variety of
|
|
529
|
+
* economic indicators including GDP, unemployment, inflation, retail sales,
|
|
530
|
+
* and many others. Essential for macroeconomic analysis and understanding
|
|
531
|
+
* economic trends and cycles.
|
|
538
532
|
*
|
|
539
|
-
* @param
|
|
533
|
+
* @param params - Economic indicators request parameters
|
|
534
|
+
* @param params.name - The economic indicator to retrieve
|
|
535
|
+
* @param params.from - Start date in YYYY-MM-DD format (optional, defaults to 1 year ago)
|
|
536
|
+
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to today)
|
|
540
537
|
*
|
|
541
|
-
* @returns Promise resolving to array of
|
|
538
|
+
* @returns Promise resolving to array of economic indicator data with historical values
|
|
542
539
|
*
|
|
543
540
|
* @example
|
|
544
541
|
* ```typescript
|
|
545
|
-
* // Get
|
|
546
|
-
* const
|
|
547
|
-
*
|
|
548
|
-
*
|
|
542
|
+
* // Get GDP data for the last year
|
|
543
|
+
* const gdpData = await fmp.economic.getEconomicIndicators({
|
|
544
|
+
* name: 'GDP',
|
|
545
|
+
* from: '2023-01-01',
|
|
546
|
+
* to: '2023-12-31'
|
|
547
|
+
* });
|
|
548
|
+
* gdpData.data.forEach(gdp => {
|
|
549
|
+
* console.log(`${gdp.date}: GDP $${gdp.value.toLocaleString()} billion`);
|
|
549
550
|
* });
|
|
550
551
|
*
|
|
551
|
-
* // Get
|
|
552
|
-
* const
|
|
552
|
+
* // Get unemployment rate data
|
|
553
|
+
* const unemploymentData = await fmp.economic.getEconomicIndicators({
|
|
554
|
+
* name: 'unemploymentRate',
|
|
555
|
+
* from: '2024-01-01'
|
|
556
|
+
* });
|
|
557
|
+
*
|
|
558
|
+
* // Get inflation rate data
|
|
559
|
+
* const inflationData = await fmp.economic.getEconomicIndicators({
|
|
560
|
+
* name: 'inflationRate',
|
|
561
|
+
* from: '2023-01-01',
|
|
562
|
+
* to: '2023-12-31'
|
|
563
|
+
* });
|
|
553
564
|
* ```
|
|
554
565
|
*
|
|
555
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
566
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#economic-indicators-economics-data|FMP Economic Indicators Documentation}
|
|
556
567
|
*/
|
|
557
|
-
|
|
568
|
+
getEconomicIndicators(params: {
|
|
569
|
+
name: 'GDP' | 'realGDP' | 'nominalPotentialGDP' | 'realGDPPerCapita' | 'federalFunds' | 'CPI' | 'inflationRate' | 'inflation' | 'retailSales' | 'consumerSentiment' | 'durableGoods' | 'unemploymentRate' | 'totalNonfarmPayroll' | 'initialClaims' | 'industrialProductionTotalIndex' | 'newPrivatelyOwnedHousingUnitsStartedTotalUnits' | 'totalVehicleSales' | 'retailMoneyFunds' | 'smoothedUSRecessionProbabilities' | '3MonthOr90DayRatesAndYieldsCertificatesOfDeposit' | 'commercialBankInterestRateOnCreditCardPlansAllAccounts' | '30YearFixedRateMortgageAverage' | '15YearFixedRateMortgageAverage';
|
|
570
|
+
from?: string;
|
|
571
|
+
to?: string;
|
|
572
|
+
}): Promise<APIResponse<EconomicIndicator[]>>;
|
|
558
573
|
}
|
|
559
574
|
|
|
560
575
|
declare class ETFEndpoints {
|
|
@@ -748,1008 +763,1374 @@ declare class ETFEndpoints {
|
|
|
748
763
|
getStockExposure(symbol: string): Promise<APIResponse<ETFStockExposure[]>>;
|
|
749
764
|
}
|
|
750
765
|
|
|
751
|
-
declare class
|
|
766
|
+
declare class FinancialEndpoints {
|
|
752
767
|
private client;
|
|
753
768
|
constructor(client: FMPClient);
|
|
754
769
|
/**
|
|
755
|
-
* Get
|
|
770
|
+
* Get income statement data
|
|
756
771
|
*
|
|
757
|
-
* Provides
|
|
758
|
-
*
|
|
759
|
-
*
|
|
760
|
-
* interest rate trends, yield curves, and fixed income investments.
|
|
772
|
+
* Provides comprehensive income statement data including revenue, expenses,
|
|
773
|
+
* net income, and earnings per share. Essential for analyzing company
|
|
774
|
+
* profitability, revenue trends, and financial performance over time.
|
|
761
775
|
*
|
|
762
|
-
* @param params -
|
|
763
|
-
* @param params.
|
|
764
|
-
* @param params.
|
|
776
|
+
* @param params - Income statement request parameters
|
|
777
|
+
* @param params.symbol - The stock symbol to get income statement for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
778
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
779
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
765
780
|
*
|
|
766
|
-
* @returns Promise resolving to array of
|
|
781
|
+
* @returns Promise resolving to array of income statement data with financial metrics
|
|
767
782
|
*
|
|
768
783
|
* @example
|
|
769
784
|
* ```typescript
|
|
770
|
-
* // Get
|
|
771
|
-
* const
|
|
772
|
-
*
|
|
773
|
-
*
|
|
774
|
-
* });
|
|
775
|
-
* treasuryRates.data.forEach(rate => {
|
|
776
|
-
* console.log(`${rate.date}: 10Y ${rate.tenY}%, 2Y ${rate.twoY}%`);
|
|
785
|
+
* // Get annual income statements for Apple
|
|
786
|
+
* const incomeStatements = await fmp.financial.getIncomeStatement({ symbol: 'AAPL' });
|
|
787
|
+
* incomeStatements.data.forEach(statement => {
|
|
788
|
+
* console.log(`${statement.date}: Revenue $${statement.revenue.toLocaleString()}, Net Income $${statement.netIncome.toLocaleString()}`);
|
|
777
789
|
* });
|
|
778
790
|
*
|
|
779
|
-
* // Get
|
|
780
|
-
* const
|
|
781
|
-
* from: '2024-01-01'
|
|
782
|
-
* });
|
|
791
|
+
* // Get quarterly income statements for Microsoft
|
|
792
|
+
* const quarterlyIncome = await fmp.financial.getIncomeStatement({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
783
793
|
* ```
|
|
784
794
|
*
|
|
785
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
795
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#income-statement|FMP Income Statement Documentation}
|
|
786
796
|
*/
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
797
|
+
getIncomeStatement(params: {
|
|
798
|
+
symbol: string;
|
|
799
|
+
period?: 'annual' | 'quarter';
|
|
800
|
+
limit?: number;
|
|
801
|
+
}): Promise<APIResponse<IncomeStatement[]>>;
|
|
791
802
|
/**
|
|
792
|
-
* Get
|
|
803
|
+
* Get balance sheet data
|
|
793
804
|
*
|
|
794
|
-
* Provides
|
|
795
|
-
*
|
|
796
|
-
* and
|
|
797
|
-
* economic trends and cycles.
|
|
805
|
+
* Provides comprehensive balance sheet data including assets, liabilities,
|
|
806
|
+
* and shareholder equity. Essential for analyzing company financial position,
|
|
807
|
+
* liquidity, and capital structure.
|
|
798
808
|
*
|
|
799
|
-
* @param params -
|
|
800
|
-
* @param params.
|
|
801
|
-
* @param params.
|
|
802
|
-
* @param params.
|
|
809
|
+
* @param params - Balance sheet request parameters
|
|
810
|
+
* @param params.symbol - The stock symbol to get balance sheet for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
811
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
812
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
803
813
|
*
|
|
804
|
-
* @returns Promise resolving to array of
|
|
814
|
+
* @returns Promise resolving to array of balance sheet data with financial position metrics
|
|
805
815
|
*
|
|
806
816
|
* @example
|
|
807
817
|
* ```typescript
|
|
808
|
-
* // Get
|
|
809
|
-
* const
|
|
810
|
-
*
|
|
811
|
-
*
|
|
812
|
-
* to: '2023-12-31'
|
|
813
|
-
* });
|
|
814
|
-
* gdpData.data.forEach(gdp => {
|
|
815
|
-
* console.log(`${gdp.date}: GDP $${gdp.value.toLocaleString()} billion`);
|
|
816
|
-
* });
|
|
817
|
-
*
|
|
818
|
-
* // Get unemployment rate data
|
|
819
|
-
* const unemploymentData = await fmp.economic.getEconomicIndicators({
|
|
820
|
-
* name: 'unemploymentRate',
|
|
821
|
-
* from: '2024-01-01'
|
|
818
|
+
* // Get annual balance sheets for Apple
|
|
819
|
+
* const balanceSheets = await fmp.financial.getBalanceSheet({ symbol: 'AAPL' });
|
|
820
|
+
* balanceSheets.data.forEach(sheet => {
|
|
821
|
+
* console.log(`${sheet.date}: Assets $${sheet.totalAssets.toLocaleString()}, Equity $${sheet.totalStockholdersEquity.toLocaleString()}`);
|
|
822
822
|
* });
|
|
823
823
|
*
|
|
824
|
-
* // Get
|
|
825
|
-
* const
|
|
826
|
-
* name: 'inflationRate',
|
|
827
|
-
* from: '2023-01-01',
|
|
828
|
-
* to: '2023-12-31'
|
|
829
|
-
* });
|
|
824
|
+
* // Get quarterly balance sheets for Microsoft
|
|
825
|
+
* const quarterlyBalance = await fmp.financial.getBalanceSheet({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
830
826
|
* ```
|
|
831
827
|
*
|
|
832
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
828
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#balance-sheet-statement|FMP Balance Sheet Documentation}
|
|
833
829
|
*/
|
|
834
|
-
|
|
835
|
-
|
|
836
|
-
|
|
837
|
-
|
|
838
|
-
}): Promise<APIResponse<
|
|
839
|
-
}
|
|
840
|
-
|
|
841
|
-
declare class MarketEndpoints {
|
|
842
|
-
private client;
|
|
843
|
-
constructor(client: FMPClient);
|
|
830
|
+
getBalanceSheet(params: {
|
|
831
|
+
symbol: string;
|
|
832
|
+
period?: 'annual' | 'quarter';
|
|
833
|
+
limit?: number;
|
|
834
|
+
}): Promise<APIResponse<BalanceSheet[]>>;
|
|
844
835
|
/**
|
|
845
|
-
* Get
|
|
836
|
+
* Get cash flow statement data
|
|
846
837
|
*
|
|
847
|
-
* Provides
|
|
848
|
-
*
|
|
849
|
-
* and
|
|
850
|
-
* availability and market status.
|
|
838
|
+
* Provides comprehensive cash flow data including operating, investing,
|
|
839
|
+
* and financing cash flows. Essential for analyzing company cash generation,
|
|
840
|
+
* capital allocation, and financial sustainability.
|
|
851
841
|
*
|
|
852
|
-
* @
|
|
842
|
+
* @param params - Cash flow statement request parameters
|
|
843
|
+
* @param params.symbol - The stock symbol to get cash flow statement for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
844
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
845
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
846
|
+
*
|
|
847
|
+
* @returns Promise resolving to array of cash flow statement data with cash flow metrics
|
|
853
848
|
*
|
|
854
849
|
* @example
|
|
855
850
|
* ```typescript
|
|
856
|
-
* // Get
|
|
857
|
-
* const
|
|
858
|
-
*
|
|
859
|
-
*
|
|
860
|
-
*
|
|
851
|
+
* // Get annual cash flow statements for Apple
|
|
852
|
+
* const cashFlows = await fmp.financial.getCashFlowStatement({ symbol: 'AAPL' });
|
|
853
|
+
* cashFlows.data.forEach(flow => {
|
|
854
|
+
* console.log(`${flow.date}: Operating CF $${flow.operatingCashFlow.toLocaleString()}, Free CF $${flow.freeCashFlow.toLocaleString()}`);
|
|
855
|
+
* });
|
|
861
856
|
*
|
|
862
|
-
* //
|
|
863
|
-
*
|
|
864
|
-
* console.log('Markets are currently open for trading');
|
|
865
|
-
* } else {
|
|
866
|
-
* console.log('Markets are closed');
|
|
867
|
-
* }
|
|
857
|
+
* // Get quarterly cash flow statements for Microsoft
|
|
858
|
+
* const quarterlyCashFlow = await fmp.financial.getCashFlowStatement({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
868
859
|
* ```
|
|
869
860
|
*
|
|
870
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
861
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#cashflow-statement|FMP Cash Flow Statement Documentation}
|
|
871
862
|
*/
|
|
872
|
-
|
|
863
|
+
getCashFlowStatement(params: {
|
|
864
|
+
symbol: string;
|
|
865
|
+
period?: 'annual' | 'quarter';
|
|
866
|
+
limit?: number;
|
|
867
|
+
}): Promise<APIResponse<CashFlowStatement[]>>;
|
|
873
868
|
/**
|
|
874
|
-
* Get
|
|
869
|
+
* Get key financial metrics
|
|
875
870
|
*
|
|
876
|
-
* Provides
|
|
877
|
-
*
|
|
878
|
-
*
|
|
871
|
+
* Provides essential financial metrics including revenue, net income,
|
|
872
|
+
* P/E ratio, and other key performance indicators. Essential for
|
|
873
|
+
* fundamental analysis and company valuation.
|
|
879
874
|
*
|
|
880
|
-
* @
|
|
875
|
+
* @param params - Key metrics request parameters
|
|
876
|
+
* @param params.symbol - The stock symbol to get key metrics for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
877
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
878
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
879
|
+
*
|
|
880
|
+
* @returns Promise resolving to array of key metrics data with financial indicators
|
|
881
881
|
*
|
|
882
882
|
* @example
|
|
883
883
|
* ```typescript
|
|
884
|
-
* // Get
|
|
885
|
-
* const
|
|
886
|
-
*
|
|
887
|
-
* console.log(`${
|
|
888
|
-
* console.log(` Open: $${market.open}, High: $${market.dayHigh}, Low: $${market.dayLow}`);
|
|
884
|
+
* // Get key metrics for Apple
|
|
885
|
+
* const keyMetrics = await fmp.financial.getKeyMetrics({ symbol: 'AAPL' });
|
|
886
|
+
* keyMetrics.data.forEach(metric => {
|
|
887
|
+
* console.log(`${metric.date}: P/E ${metric.peRatio}, ROE ${metric.roe}%`);
|
|
889
888
|
* });
|
|
890
889
|
*
|
|
891
|
-
* //
|
|
892
|
-
* const
|
|
893
|
-
* console.log(`S&P 500 performance: ${sp500?.changesPercentage}%`);
|
|
894
|
-
*
|
|
895
|
-
* // Check market sentiment
|
|
896
|
-
* const gainers = marketPerformance.data.filter(market => market.changesPercentage > 0);
|
|
897
|
-
* const losers = marketPerformance.data.filter(market => market.changesPercentage < 0);
|
|
898
|
-
* console.log(`Gaining indices: ${gainers.length}, Losing indices: ${losers.length}`);
|
|
890
|
+
* // Get quarterly key metrics for Microsoft
|
|
891
|
+
* const quarterlyMetrics = await fmp.financial.getKeyMetrics({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
899
892
|
* ```
|
|
900
893
|
*
|
|
901
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
894
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#key-metrics|FMP Key Metrics Documentation}
|
|
902
895
|
*/
|
|
903
|
-
|
|
896
|
+
getKeyMetrics(params: {
|
|
897
|
+
symbol: string;
|
|
898
|
+
period?: 'annual' | 'quarter';
|
|
899
|
+
limit?: number;
|
|
900
|
+
}): Promise<APIResponse<KeyMetrics[]>>;
|
|
904
901
|
/**
|
|
905
|
-
* Get
|
|
902
|
+
* Get financial ratios
|
|
906
903
|
*
|
|
907
|
-
* Provides
|
|
908
|
-
*
|
|
909
|
-
*
|
|
910
|
-
* Useful for day trading, momentum strategies, and market analysis.
|
|
904
|
+
* Provides comprehensive financial ratios including P/B ratio, ROE,
|
|
905
|
+
* debt-to-equity, and other important ratios. Essential for analyzing
|
|
906
|
+
* company financial health and comparing with peers.
|
|
911
907
|
*
|
|
912
|
-
* @
|
|
908
|
+
* @param params - Financial ratios request parameters
|
|
909
|
+
* @param params.symbol - The stock symbol to get financial ratios for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
910
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
911
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
912
|
+
*
|
|
913
|
+
* @returns Promise resolving to array of financial ratios data with ratio metrics
|
|
913
914
|
*
|
|
914
915
|
* @example
|
|
915
916
|
* ```typescript
|
|
916
|
-
* // Get
|
|
917
|
-
* const
|
|
918
|
-
*
|
|
919
|
-
*
|
|
920
|
-
* gainers.data.forEach((stock, index) => {
|
|
921
|
-
* console.log(`${index + 1}. ${stock.symbol} (${stock.name})`);
|
|
922
|
-
* console.log(` Price: $${stock.price} | Change: +${stock.change} (${stock.changesPercentage}%)`);
|
|
923
|
-
* console.log(` Volume: ${stock.volume.toLocaleString()}`);
|
|
917
|
+
* // Get financial ratios for Apple
|
|
918
|
+
* const ratios = await fmp.financial.getFinancialRatios({ symbol: 'AAPL' });
|
|
919
|
+
* ratios.data.forEach(ratio => {
|
|
920
|
+
* console.log(`${ratio.date}: P/B ${ratio.priceToBookRatio}, Debt/Equity ${ratio.debtToEquity}`);
|
|
924
921
|
* });
|
|
925
922
|
*
|
|
926
|
-
* //
|
|
927
|
-
* const
|
|
928
|
-
* console.log(`Stocks with >10% gains: ${bigGainers.length}`);
|
|
929
|
-
*
|
|
930
|
-
* // Check volume leaders among gainers
|
|
931
|
-
* const highVolumeGainers = gainers.data.filter(stock => stock.volume > 1000000);
|
|
932
|
-
* console.log(`High volume gainers (>1M shares): ${highVolumeGainers.length}`);
|
|
923
|
+
* // Get quarterly ratios for Microsoft
|
|
924
|
+
* const quarterlyRatios = await fmp.financial.getFinancialRatios({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
933
925
|
* ```
|
|
934
926
|
*
|
|
935
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
927
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#metrics-ratios|FMP Financial Ratios Documentation}
|
|
936
928
|
*/
|
|
937
|
-
|
|
929
|
+
getFinancialRatios(params: {
|
|
930
|
+
symbol: string;
|
|
931
|
+
period?: 'annual' | 'quarter';
|
|
932
|
+
limit?: number;
|
|
933
|
+
}): Promise<APIResponse<FinancialRatios[]>>;
|
|
938
934
|
/**
|
|
939
|
-
* Get
|
|
935
|
+
* Get enterprise value data
|
|
940
936
|
*
|
|
941
|
-
* Provides
|
|
942
|
-
*
|
|
943
|
-
*
|
|
944
|
-
* Useful for risk management, short selling strategies, and market analysis.
|
|
937
|
+
* Provides enterprise value metrics including total enterprise value,
|
|
938
|
+
* market cap, and debt information. Essential for company valuation
|
|
939
|
+
* and comparing companies with different capital structures.
|
|
945
940
|
*
|
|
946
|
-
* @
|
|
941
|
+
* @param params - Enterprise value request parameters
|
|
942
|
+
* @param params.symbol - The stock symbol to get enterprise value for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
943
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
944
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
945
|
+
*
|
|
946
|
+
* @returns Promise resolving to array of enterprise value data with valuation metrics
|
|
947
947
|
*
|
|
948
948
|
* @example
|
|
949
949
|
* ```typescript
|
|
950
|
-
* // Get
|
|
951
|
-
* const
|
|
952
|
-
*
|
|
953
|
-
*
|
|
954
|
-
* losers.data.forEach((stock, index) => {
|
|
955
|
-
* console.log(`${index + 1}. ${stock.symbol} (${stock.name})`);
|
|
956
|
-
* console.log(` Price: $${stock.price} | Change: ${stock.change} (${stock.changesPercentage}%)`);
|
|
957
|
-
* console.log(` Volume: ${stock.volume.toLocaleString()}`);
|
|
950
|
+
* // Get enterprise value for Apple
|
|
951
|
+
* const enterpriseValue = await fmp.financial.getEnterpriseValue({ symbol: 'AAPL' });
|
|
952
|
+
* enterpriseValue.data.forEach(ev => {
|
|
953
|
+
* console.log(`${ev.date}: EV $${ev.enterpriseValue.toLocaleString()}, Market Cap $${ev.marketCapitalization.toLocaleString()}`);
|
|
958
954
|
* });
|
|
959
955
|
*
|
|
960
|
-
* //
|
|
961
|
-
* const
|
|
962
|
-
* console.log(`Stocks with >10% losses: ${bigLosers.length}`);
|
|
963
|
-
*
|
|
964
|
-
* // Check for potential oversold conditions
|
|
965
|
-
* const highVolumeLosers = losers.data.filter(stock => stock.volume > 1000000);
|
|
966
|
-
* console.log(`High volume losers (>1M shares): ${highVolumeLosers.length}`);
|
|
967
|
-
*
|
|
968
|
-
* // Look for potential bounce candidates
|
|
969
|
-
* const oversoldStocks = losers.data.filter(stock =>
|
|
970
|
-
* stock.changesPercentage < -5 && stock.volume > 500000
|
|
971
|
-
* );
|
|
956
|
+
* // Get quarterly enterprise value for Microsoft
|
|
957
|
+
* const quarterlyEV = await fmp.financial.getEnterpriseValue({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
972
958
|
* ```
|
|
973
959
|
*
|
|
974
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
960
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#enterprise-values|FMP Enterprise Value Documentation}
|
|
975
961
|
*/
|
|
976
|
-
|
|
962
|
+
getEnterpriseValue(params: {
|
|
963
|
+
symbol: string;
|
|
964
|
+
period?: 'annual' | 'quarter';
|
|
965
|
+
limit?: number;
|
|
966
|
+
}): Promise<APIResponse<EnterpriseValue[]>>;
|
|
977
967
|
/**
|
|
978
|
-
* Get
|
|
968
|
+
* Get cash flow growth data
|
|
979
969
|
*
|
|
980
|
-
* Provides
|
|
981
|
-
*
|
|
982
|
-
*
|
|
983
|
-
* significant trading activity. Useful for day trading and liquidity analysis.
|
|
970
|
+
* Provides cash flow growth rates showing how quickly a company's
|
|
971
|
+
* cash flows are growing over time. Essential for analyzing cash
|
|
972
|
+
* generation trends and financial sustainability.
|
|
984
973
|
*
|
|
985
|
-
* @
|
|
974
|
+
* @param params - Cash flow growth request parameters
|
|
975
|
+
* @param params.symbol - The stock symbol to get cash flow growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
976
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
977
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
978
|
+
*
|
|
979
|
+
* @returns Promise resolving to array of cash flow growth data with growth metrics
|
|
986
980
|
*
|
|
987
981
|
* @example
|
|
988
982
|
* ```typescript
|
|
989
|
-
* // Get
|
|
990
|
-
* const
|
|
991
|
-
*
|
|
992
|
-
*
|
|
993
|
-
* mostActive.data.forEach((stock, index) => {
|
|
994
|
-
* console.log(`${index + 1}. ${stock.symbol} (${stock.name})`);
|
|
995
|
-
* console.log(` Volume: ${stock.volume.toLocaleString()} shares`);
|
|
996
|
-
* console.log(` Price: $${stock.price} | Change: ${stock.change} (${stock.changesPercentage}%)`);
|
|
997
|
-
* console.log(` Avg Volume: ${stock.avgVolume?.toLocaleString() || 'N/A'}`);
|
|
983
|
+
* // Get cash flow growth for Apple
|
|
984
|
+
* const cashFlowGrowth = await fmp.financial.getCashflowGrowth({ symbol: 'AAPL' });
|
|
985
|
+
* cashFlowGrowth.data.forEach(growth => {
|
|
986
|
+
* console.log(`${growth.date}: Operating CF Growth ${growth.operatingCashFlowGrowth}%`);
|
|
998
987
|
* });
|
|
999
988
|
*
|
|
1000
|
-
* //
|
|
1001
|
-
* const
|
|
1002
|
-
*
|
|
1003
|
-
* );
|
|
1004
|
-
* console.log(`Stocks with unusual volume: ${unusualVolume.length}`);
|
|
989
|
+
* // Get quarterly cash flow growth for Microsoft
|
|
990
|
+
* const quarterlyGrowth = await fmp.financial.getCashflowGrowth({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
991
|
+
* ```
|
|
1005
992
|
*
|
|
1006
|
-
*
|
|
1007
|
-
* const highVolumeGainers = mostActive.data.filter(stock =>
|
|
1008
|
-
* stock.changesPercentage > 0 && stock.volume > 1000000
|
|
1009
|
-
* );
|
|
1010
|
-
* console.log(`High volume gainers: ${highVolumeGainers.length}`);
|
|
1011
|
-
*
|
|
1012
|
-
* // Find penny stocks with high volume
|
|
1013
|
-
* const pennyStocks = mostActive.data.filter(stock =>
|
|
1014
|
-
* stock.price < 5 && stock.volume > 500000
|
|
1015
|
-
* );
|
|
1016
|
-
* ```
|
|
1017
|
-
*
|
|
1018
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#market-most-actives|FMP Market Most Actives Documentation}
|
|
993
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#cashflow-statement-growth|FMP Cash Flow Growth Documentation}
|
|
1019
994
|
*/
|
|
1020
|
-
|
|
995
|
+
getCashflowGrowth(params: {
|
|
996
|
+
symbol: string;
|
|
997
|
+
period?: 'annual' | 'quarter';
|
|
998
|
+
limit?: number;
|
|
999
|
+
}): Promise<APIResponse<CashflowGrowth[]>>;
|
|
1021
1000
|
/**
|
|
1022
|
-
* Get
|
|
1001
|
+
* Get income growth data
|
|
1023
1002
|
*
|
|
1024
|
-
* Provides
|
|
1025
|
-
*
|
|
1026
|
-
*
|
|
1027
|
-
* understanding market breadth and sector-specific trends.
|
|
1003
|
+
* Provides income growth rates showing how quickly a company's
|
|
1004
|
+
* revenue and net income are growing over time. Essential for
|
|
1005
|
+
* analyzing profitability trends and business momentum.
|
|
1028
1006
|
*
|
|
1029
|
-
* @
|
|
1007
|
+
* @param params - Income growth request parameters
|
|
1008
|
+
* @param params.symbol - The stock symbol to get income growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
1009
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
1010
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
1011
|
+
*
|
|
1012
|
+
* @returns Promise resolving to array of income growth data with growth metrics
|
|
1030
1013
|
*
|
|
1031
1014
|
* @example
|
|
1032
1015
|
* ```typescript
|
|
1033
|
-
* // Get
|
|
1034
|
-
* const
|
|
1035
|
-
*
|
|
1036
|
-
*
|
|
1037
|
-
* sectorPerformance.data.forEach(sector => {
|
|
1038
|
-
* const changeColor = sector.changesPercentage >= 0 ? 'green' : 'red';
|
|
1039
|
-
* console.log(`${sector.sector}: ${sector.changesPercentage}%`);
|
|
1040
|
-
* console.log(` Change: ${sector.changesPercentage >= 0 ? '+' : ''}${sector.changesPercentage}%`);
|
|
1041
|
-
* });
|
|
1042
|
-
*
|
|
1043
|
-
* // Find best performing sectors
|
|
1044
|
-
* const topSectors = sectorPerformance.data
|
|
1045
|
-
* .sort((a, b) => b.changesPercentage - a.changesPercentage)
|
|
1046
|
-
* .slice(0, 3);
|
|
1047
|
-
* console.log('Top 3 performing sectors:');
|
|
1048
|
-
* topSectors.forEach((sector, index) => {
|
|
1049
|
-
* console.log(`${index + 1}. ${sector.sector}: ${sector.changesPercentage}%`);
|
|
1050
|
-
* });
|
|
1051
|
-
*
|
|
1052
|
-
* // Find worst performing sectors
|
|
1053
|
-
* const bottomSectors = sectorPerformance.data
|
|
1054
|
-
* .sort((a, b) => a.changesPercentage - b.changesPercentage)
|
|
1055
|
-
* .slice(0, 3);
|
|
1056
|
-
* console.log('Bottom 3 performing sectors:');
|
|
1057
|
-
* bottomSectors.forEach((sector, index) => {
|
|
1058
|
-
* console.log(`${index + 1}. ${sector.sector}: ${sector.changesPercentage}%`);
|
|
1016
|
+
* // Get income growth for Apple
|
|
1017
|
+
* const incomeGrowth = await fmp.financial.getIncomeGrowth({ symbol: 'AAPL' });
|
|
1018
|
+
* incomeGrowth.data.forEach(growth => {
|
|
1019
|
+
* console.log(`${growth.date}: Revenue Growth ${growth.revenueGrowth}%, Net Income Growth ${growth.netIncomeGrowth}%`);
|
|
1059
1020
|
* });
|
|
1060
1021
|
*
|
|
1061
|
-
* //
|
|
1062
|
-
* const
|
|
1063
|
-
* const losingSectors = sectorPerformance.data.filter(sector => sector.changesPercentage < 0);
|
|
1064
|
-
* console.log(`Sectors gaining: ${gainingSectors.length}, Sectors losing: ${losingSectors.length}`);
|
|
1022
|
+
* // Get quarterly income growth for Microsoft
|
|
1023
|
+
* const quarterlyGrowth = await fmp.financial.getIncomeGrowth({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
1065
1024
|
* ```
|
|
1066
1025
|
*
|
|
1067
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1026
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#income-statement-growth|FMP Income Growth Documentation}
|
|
1068
1027
|
*/
|
|
1069
|
-
|
|
1028
|
+
getIncomeGrowth(params: {
|
|
1029
|
+
symbol: string;
|
|
1030
|
+
period?: 'annual' | 'quarter';
|
|
1031
|
+
limit?: number;
|
|
1032
|
+
}): Promise<APIResponse<IncomeGrowth[]>>;
|
|
1070
1033
|
/**
|
|
1071
|
-
* Get
|
|
1034
|
+
* Get balance sheet growth data
|
|
1072
1035
|
*
|
|
1073
|
-
* Provides
|
|
1074
|
-
*
|
|
1075
|
-
*
|
|
1076
|
-
* market sentiment, and identifying broad market trends.
|
|
1036
|
+
* Provides balance sheet growth rates showing how quickly a company's
|
|
1037
|
+
* assets, liabilities, and equity are growing over time. Essential for
|
|
1038
|
+
* analyzing capital structure trends and financial position changes.
|
|
1077
1039
|
*
|
|
1078
|
-
* @
|
|
1040
|
+
* @param params - Balance sheet growth request parameters
|
|
1041
|
+
* @param params.symbol - The stock symbol to get balance sheet growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
1042
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
1043
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
1044
|
+
*
|
|
1045
|
+
* @returns Promise resolving to array of balance sheet growth data with growth metrics
|
|
1079
1046
|
*
|
|
1080
1047
|
* @example
|
|
1081
1048
|
* ```typescript
|
|
1082
|
-
* // Get
|
|
1083
|
-
* const
|
|
1084
|
-
*
|
|
1085
|
-
*
|
|
1086
|
-
* marketIndices.data.forEach(index => {
|
|
1087
|
-
* console.log(`${index.symbol} (${index.name}):`);
|
|
1088
|
-
* console.log(` Price: $${index.price}`);
|
|
1089
|
-
* console.log(` Change: ${index.change} (${index.changesPercentage}%)`);
|
|
1090
|
-
* console.log(` Day Range: $${index.dayLow} - $${index.dayHigh}`);
|
|
1091
|
-
* console.log(` Volume: ${index.volume?.toLocaleString() || 'N/A'}`);
|
|
1049
|
+
* // Get balance sheet growth for Apple
|
|
1050
|
+
* const balanceSheetGrowth = await fmp.financial.getBalanceSheetGrowth({ symbol: 'AAPL' });
|
|
1051
|
+
* balanceSheetGrowth.data.forEach(growth => {
|
|
1052
|
+
* console.log(`${growth.date}: Assets Growth ${growth.totalAssetsGrowth}%, Equity Growth ${growth.totalStockholdersEquityGrowth}%`);
|
|
1092
1053
|
* });
|
|
1093
1054
|
*
|
|
1094
|
-
* //
|
|
1095
|
-
* const
|
|
1096
|
-
* const nasdaq = marketIndices.data.find(index => index.symbol === '^IXIC');
|
|
1097
|
-
* const dowJones = marketIndices.data.find(index => index.symbol === '^DJI');
|
|
1098
|
-
*
|
|
1099
|
-
* console.log(`S&P 500: ${sp500?.price} (${sp500?.changesPercentage}%)`);
|
|
1100
|
-
* console.log(`NASDAQ: ${nasdaq?.price} (${nasdaq?.changesPercentage}%)`);
|
|
1101
|
-
* console.log(`Dow Jones: ${dowJones?.price} (${dowJones?.changesPercentage}%)`);
|
|
1102
|
-
*
|
|
1103
|
-
* // Check market breadth
|
|
1104
|
-
* const gainingIndices = marketIndices.data.filter(index => index.changesPercentage > 0);
|
|
1105
|
-
* const losingIndices = marketIndices.data.filter(index => index.changesPercentage < 0);
|
|
1106
|
-
* console.log(`Indices gaining: ${gainingIndices.length}, Indices losing: ${losingIndices.length}`);
|
|
1107
|
-
*
|
|
1108
|
-
* // Find international indices
|
|
1109
|
-
* const internationalIndices = marketIndices.data.filter(index =>
|
|
1110
|
-
* !index.symbol.startsWith('^') ||
|
|
1111
|
-
* index.name.toLowerCase().includes('europe') ||
|
|
1112
|
-
* index.name.toLowerCase().includes('asia')
|
|
1113
|
-
* );
|
|
1055
|
+
* // Get quarterly balance sheet growth for Microsoft
|
|
1056
|
+
* const quarterlyGrowth = await fmp.financial.getBalanceSheetGrowth({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
1114
1057
|
* ```
|
|
1115
1058
|
*
|
|
1116
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1059
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#balance-sheet-statement-growth|FMP Balance Sheet Growth Documentation}
|
|
1117
1060
|
*/
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
constructor(client: FMPClient);
|
|
1061
|
+
getBalanceSheetGrowth(params: {
|
|
1062
|
+
symbol: string;
|
|
1063
|
+
period?: 'annual' | 'quarter';
|
|
1064
|
+
limit?: number;
|
|
1065
|
+
}): Promise<APIResponse<BalanceSheetGrowth[]>>;
|
|
1124
1066
|
/**
|
|
1125
|
-
* Get
|
|
1067
|
+
* Get financial growth data
|
|
1126
1068
|
*
|
|
1127
|
-
* Provides
|
|
1128
|
-
*
|
|
1129
|
-
*
|
|
1069
|
+
* Provides comprehensive financial growth rates across all key
|
|
1070
|
+
* financial metrics. Essential for analyzing overall financial
|
|
1071
|
+
* performance trends and business momentum.
|
|
1130
1072
|
*
|
|
1131
|
-
* @
|
|
1073
|
+
* @param params - Financial growth request parameters
|
|
1074
|
+
* @param params.symbol - The stock symbol to get financial growth for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
1075
|
+
* @param params.period - The reporting period: 'annual' or 'quarter' (default: 'annual')
|
|
1076
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
1077
|
+
*
|
|
1078
|
+
* @returns Promise resolving to array of financial growth data with comprehensive growth metrics
|
|
1132
1079
|
*
|
|
1133
1080
|
* @example
|
|
1134
1081
|
* ```typescript
|
|
1135
|
-
* // Get
|
|
1136
|
-
* const
|
|
1137
|
-
*
|
|
1138
|
-
*
|
|
1139
|
-
*
|
|
1140
|
-
* const appleStock = stocks.data.find(stock => stock.symbol === 'AAPL');
|
|
1141
|
-
* console.log(`Apple: ${appleStock?.name} (${appleStock?.exchange})`);
|
|
1082
|
+
* // Get financial growth for Apple
|
|
1083
|
+
* const financialGrowth = await fmp.financial.getFinancialGrowth({ symbol: 'AAPL' });
|
|
1084
|
+
* financialGrowth.data.forEach(growth => {
|
|
1085
|
+
* console.log(`${growth.date}: Revenue Growth ${growth.revenueGrowth}%, EPS Growth ${growth.epsGrowth}%`);
|
|
1086
|
+
* });
|
|
1142
1087
|
*
|
|
1143
|
-
* //
|
|
1144
|
-
* const
|
|
1145
|
-
* console.log(`NASDAQ stocks: ${nasdaqStocks.length}`);
|
|
1088
|
+
* // Get quarterly financial growth for Microsoft
|
|
1089
|
+
* const quarterlyGrowth = await fmp.financial.getFinancialGrowth({ symbol: 'MSFT', period: 'quarter', limit: 8 });
|
|
1146
1090
|
* ```
|
|
1147
1091
|
*
|
|
1148
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1092
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#financial-statement-growth|FMP Financial Growth Documentation}
|
|
1149
1093
|
*/
|
|
1150
|
-
|
|
1094
|
+
getFinancialGrowth(params: {
|
|
1095
|
+
symbol: string;
|
|
1096
|
+
period?: 'annual' | 'quarter';
|
|
1097
|
+
limit?: number;
|
|
1098
|
+
}): Promise<APIResponse<FinancialGrowth[]>>;
|
|
1151
1099
|
/**
|
|
1152
|
-
* Get
|
|
1100
|
+
* Get historical earnings data
|
|
1153
1101
|
*
|
|
1154
|
-
* Provides
|
|
1155
|
-
*
|
|
1156
|
-
*
|
|
1102
|
+
* Provides historical and upcoming earnings announcements including
|
|
1103
|
+
* dates, estimated EPS, and actual EPS. Essential for analyzing
|
|
1104
|
+
* earnings trends and tracking company performance.
|
|
1157
1105
|
*
|
|
1158
|
-
* @
|
|
1106
|
+
* @param params - Earnings historical request parameters
|
|
1107
|
+
* @param params.symbol - The stock symbol to get earnings history for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
1108
|
+
* @param params.limit - Number of periods to retrieve (default: 5)
|
|
1109
|
+
*
|
|
1110
|
+
* @returns Promise resolving to array of historical earnings data with announcement details
|
|
1159
1111
|
*
|
|
1160
1112
|
* @example
|
|
1161
1113
|
* ```typescript
|
|
1162
|
-
* // Get
|
|
1163
|
-
* const
|
|
1164
|
-
*
|
|
1165
|
-
*
|
|
1166
|
-
*
|
|
1167
|
-
* const spyETF = etfs.data.find(etf => etf.symbol === 'SPY');
|
|
1168
|
-
* console.log(`SPY: ${spyETF?.name} (${spyETF?.assetClass})`);
|
|
1169
|
-
*
|
|
1170
|
-
* // Filter by asset class
|
|
1171
|
-
* const equityETFs = etfs.data.filter(etf => etf.assetClass === 'Equity');
|
|
1172
|
-
* console.log(`Equity ETFs: ${equityETFs.length}`);
|
|
1114
|
+
* // Get earnings history for Apple
|
|
1115
|
+
* const earningsHistory = await fmp.financial.getEarningsHistorical({ symbol: 'AAPL', limit: 10 });
|
|
1116
|
+
* earningsHistory.data.forEach(earning => {
|
|
1117
|
+
* console.log(`${earning.date}: Est. ${earning.estimatedEps}, Actual ${earning.actualEps}`);
|
|
1118
|
+
* });
|
|
1173
1119
|
*
|
|
1174
|
-
* //
|
|
1175
|
-
* const
|
|
1176
|
-
* etf.name.toLowerCase().includes('technology') ||
|
|
1177
|
-
* etf.name.toLowerCase().includes('tech')
|
|
1178
|
-
* );
|
|
1120
|
+
* // Get earnings history for Microsoft
|
|
1121
|
+
* const msftEarnings = await fmp.financial.getEarningsHistorical({ symbol: 'MSFT', limit: 8 });
|
|
1179
1122
|
* ```
|
|
1180
1123
|
*
|
|
1181
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1124
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#earnings-company|FMP Earnings Historical Documentation}
|
|
1182
1125
|
*/
|
|
1183
|
-
|
|
1126
|
+
getEarningsHistorical(params: {
|
|
1127
|
+
symbol: string;
|
|
1128
|
+
limit?: number;
|
|
1129
|
+
}): Promise<APIResponse<EarningsHistorical[]>>;
|
|
1184
1130
|
/**
|
|
1185
|
-
* Get
|
|
1131
|
+
* Get earnings surprises data
|
|
1186
1132
|
*
|
|
1187
|
-
* Provides
|
|
1188
|
-
*
|
|
1189
|
-
*
|
|
1133
|
+
* Provides earnings announcements that exceeded or fell short of
|
|
1134
|
+
* analyst estimates. Essential for analyzing earnings quality and
|
|
1135
|
+
* market reactions to earnings releases.
|
|
1190
1136
|
*
|
|
1191
|
-
* @
|
|
1137
|
+
* @param symbol - The stock symbol to get earnings surprises for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
1138
|
+
*
|
|
1139
|
+
* @returns Promise resolving to array of earnings surprises data with surprise details
|
|
1192
1140
|
*
|
|
1193
1141
|
* @example
|
|
1194
1142
|
* ```typescript
|
|
1195
|
-
* // Get
|
|
1196
|
-
* const
|
|
1197
|
-
*
|
|
1198
|
-
*
|
|
1199
|
-
*
|
|
1200
|
-
* const bitcoin = cryptos.data.find(crypto => crypto.symbol === 'BTCUSD');
|
|
1201
|
-
* console.log(`Bitcoin: ${bitcoin?.name} (${bitcoin?.exchange})`);
|
|
1143
|
+
* // Get earnings surprises for Apple
|
|
1144
|
+
* const earningsSurprises = await fmp.financial.getEarningsSurprises('AAPL');
|
|
1145
|
+
* earningsSurprises.data.forEach(surprise => {
|
|
1146
|
+
* console.log(`${surprise.date}: Est. ${surprise.estimatedEps}, Actual ${surprise.actualEps}, Surprise ${surprise.surprisePercentage}%`);
|
|
1147
|
+
* });
|
|
1202
1148
|
*
|
|
1203
|
-
*
|
|
1204
|
-
*
|
|
1149
|
+
* // Get earnings surprises for Microsoft
|
|
1150
|
+
* const msftSurprises = await fmp.financial.getEarningsSurprises('MSFT');
|
|
1151
|
+
* ```
|
|
1205
1152
|
*
|
|
1206
|
-
*
|
|
1207
|
-
|
|
1208
|
-
|
|
1153
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#earnings-surprises-earnings|FMP Earnings Surprises Documentation}
|
|
1154
|
+
*/
|
|
1155
|
+
getEarningsSurprises(symbol: string): Promise<APIResponse<EarningsSurprises[]>>;
|
|
1156
|
+
}
|
|
1157
|
+
|
|
1158
|
+
declare class InsiderEndpoints {
|
|
1159
|
+
private client;
|
|
1160
|
+
constructor(client: FMPClient);
|
|
1161
|
+
/**
|
|
1162
|
+
* Get insider trading RSS feed data
|
|
1209
1163
|
*
|
|
1210
|
-
*
|
|
1211
|
-
*
|
|
1212
|
-
*
|
|
1213
|
-
*
|
|
1164
|
+
* Provides real-time RSS feed of insider trading activities across all
|
|
1165
|
+
* publicly traded companies. Essential for monitoring insider trading
|
|
1166
|
+
* patterns, corporate governance, and potential market-moving events.
|
|
1167
|
+
*
|
|
1168
|
+
* @param params - RSS feed request parameters
|
|
1169
|
+
* @param params.page - Page number for pagination (default: 0)
|
|
1170
|
+
*
|
|
1171
|
+
* @returns Promise resolving to array of insider trading RSS feed data
|
|
1172
|
+
*
|
|
1173
|
+
* @example
|
|
1174
|
+
* ```typescript
|
|
1175
|
+
* // Get first page of insider trading RSS feed
|
|
1176
|
+
* const rssFeed = await fmp.insider.getInsiderTradingRSS({ page: 0 });
|
|
1177
|
+
* rssFeed.data.forEach(trade => {
|
|
1178
|
+
* console.log(`${trade.date}: ${trade.symbol} - ${trade.insiderName} ${trade.transactionType}`);
|
|
1179
|
+
* });
|
|
1180
|
+
*
|
|
1181
|
+
* // Get second page of RSS feed
|
|
1182
|
+
* const nextPage = await fmp.insider.getInsiderTradingRSS({ page: 1 });
|
|
1214
1183
|
* ```
|
|
1215
1184
|
*
|
|
1216
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1185
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#insider-trades-rss-insider-trading|FMP Insider Trading RSS Documentation}
|
|
1186
|
+
*/
|
|
1187
|
+
getInsiderTradingRSS(params: {
|
|
1188
|
+
page?: number;
|
|
1189
|
+
}): Promise<APIResponse<InsiderTradingRSSResponse[]>>;
|
|
1190
|
+
/**
|
|
1191
|
+
* Search for insider trades with advanced filtering
|
|
1192
|
+
*
|
|
1193
|
+
* Provides comprehensive insider trading data with multiple filtering options
|
|
1194
|
+
* including symbol, CIK numbers, and transaction types. Essential for detailed
|
|
1195
|
+
* analysis of insider trading patterns and corporate governance.
|
|
1196
|
+
*
|
|
1197
|
+
* @param params - Insider trading search parameters
|
|
1198
|
+
* @param params.symbol - Stock symbol to filter by (optional)
|
|
1199
|
+
* @param params.reportingCik - Reporting CIK to filter by (optional)
|
|
1200
|
+
* @param params.companyCik - Company CIK to filter by (optional)
|
|
1201
|
+
* @param params.transactionType - Transaction type to filter by (optional)
|
|
1202
|
+
* @param params.page - Page number for pagination (default: 0)
|
|
1203
|
+
*
|
|
1204
|
+
* @returns Promise resolving to array of insider trading search results
|
|
1205
|
+
*
|
|
1206
|
+
* @example
|
|
1207
|
+
* ```typescript
|
|
1208
|
+
* // Search for Apple insider trades
|
|
1209
|
+
* const appleTrades = await fmp.insider.searchInsiderTrading({
|
|
1210
|
+
* symbol: 'AAPL',
|
|
1211
|
+
* page: 0
|
|
1212
|
+
* });
|
|
1213
|
+
* appleTrades.data.forEach(trade => {
|
|
1214
|
+
* console.log(`${trade.date}: ${trade.insiderName} - ${trade.transactionType} ${trade.sharesTraded} shares`);
|
|
1215
|
+
* });
|
|
1216
|
+
*
|
|
1217
|
+
* // Search by transaction type
|
|
1218
|
+
* const purchases = await fmp.insider.searchInsiderTrading({
|
|
1219
|
+
* transactionType: 'P-Purchase',
|
|
1220
|
+
* page: 0
|
|
1221
|
+
* });
|
|
1222
|
+
*
|
|
1223
|
+
* // Search by CIK
|
|
1224
|
+
* const cikTrades = await fmp.insider.searchInsiderTrading({
|
|
1225
|
+
* companyCik: '0000320193',
|
|
1226
|
+
* page: 0
|
|
1227
|
+
* });
|
|
1228
|
+
* ```
|
|
1229
|
+
*
|
|
1230
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#insider-trades-search-insider-trading|FMP Insider Trading Search Documentation}
|
|
1231
|
+
*/
|
|
1232
|
+
searchInsiderTrading(params: {
|
|
1233
|
+
symbol?: string;
|
|
1234
|
+
reportingCik?: string;
|
|
1235
|
+
companyCik?: string;
|
|
1236
|
+
transactionType?: string;
|
|
1237
|
+
page?: number;
|
|
1238
|
+
}): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
1239
|
+
/**
|
|
1240
|
+
* Get all available transaction types
|
|
1241
|
+
*
|
|
1242
|
+
* Provides a comprehensive list of all insider trading transaction types
|
|
1243
|
+
* used in SEC filings. Essential for understanding different types of
|
|
1244
|
+
* insider trading activities and filtering search results.
|
|
1245
|
+
*
|
|
1246
|
+
* @returns Promise resolving to array of transaction types with descriptions
|
|
1247
|
+
*
|
|
1248
|
+
* @example
|
|
1249
|
+
* ```typescript
|
|
1250
|
+
* // Get all transaction types
|
|
1251
|
+
* const transactionTypes = await fmp.insider.getTransactionTypes();
|
|
1252
|
+
* transactionTypes.data.forEach(type => {
|
|
1253
|
+
* console.log(`${type.code}: ${type.description}`);
|
|
1254
|
+
* });
|
|
1255
|
+
* ```
|
|
1256
|
+
*
|
|
1257
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#transaction-types-insider-trading|FMP Transaction Types Documentation}
|
|
1258
|
+
*/
|
|
1259
|
+
getTransactionTypes(): Promise<APIResponse<TransactionTypesResponse>>;
|
|
1260
|
+
/**
|
|
1261
|
+
* Get insiders roster for a specific company
|
|
1262
|
+
*
|
|
1263
|
+
* Provides a list of all insiders (officers, directors, and beneficial owners)
|
|
1264
|
+
* for a specific company. Essential for understanding corporate governance
|
|
1265
|
+
* structure and identifying key personnel.
|
|
1266
|
+
*
|
|
1267
|
+
* @param params - Insiders request parameters
|
|
1268
|
+
* @param params.symbol - Stock symbol to get insiders for
|
|
1269
|
+
*
|
|
1270
|
+
* @returns Promise resolving to array of insiders data for the company
|
|
1271
|
+
*
|
|
1272
|
+
* @example
|
|
1273
|
+
* ```typescript
|
|
1274
|
+
* // Get Apple's insiders roster
|
|
1275
|
+
* const appleInsiders = await fmp.insider.getInsidersBySymbol({ symbol: 'AAPL' });
|
|
1276
|
+
* appleInsiders.data.forEach(insider => {
|
|
1277
|
+
* console.log(`${insider.name} - ${insider.title} (${insider.cik})`);
|
|
1278
|
+
* });
|
|
1279
|
+
*
|
|
1280
|
+
* // Get Microsoft's insiders
|
|
1281
|
+
* const msftInsiders = await fmp.insider.getInsidersBySymbol({ symbol: 'MSFT' });
|
|
1282
|
+
* ```
|
|
1283
|
+
*
|
|
1284
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#insiders-by-symbol-insider-trading|FMP Insiders by Symbol Documentation}
|
|
1285
|
+
*/
|
|
1286
|
+
getInsidersBySymbol(params: {
|
|
1287
|
+
symbol: string;
|
|
1288
|
+
}): Promise<APIResponse<InsidersBySymbolResponse[]>>;
|
|
1289
|
+
/**
|
|
1290
|
+
* Get insider trade statistics for a company
|
|
1291
|
+
*
|
|
1292
|
+
* Provides comprehensive statistics on insider trading activity for a
|
|
1293
|
+
* specific company including total trades, volume, and value metrics.
|
|
1294
|
+
* Essential for analyzing insider trading patterns and sentiment.
|
|
1295
|
+
*
|
|
1296
|
+
* @param params - Statistics request parameters
|
|
1297
|
+
* @param params.symbol - Stock symbol to get statistics for
|
|
1298
|
+
*
|
|
1299
|
+
* @returns Promise resolving to array of insider trade statistics data
|
|
1300
|
+
*
|
|
1301
|
+
* @example
|
|
1302
|
+
* ```typescript
|
|
1303
|
+
* // Get Apple's insider trade statistics
|
|
1304
|
+
* const appleStats = await fmp.insider.getInsiderTradeStatistics({ symbol: 'AAPL' });
|
|
1305
|
+
* appleStats.data.forEach(stat => {
|
|
1306
|
+
* console.log(`${stat.insiderName}: ${stat.totalTrades} trades, ${stat.totalShares} shares`);
|
|
1307
|
+
* });
|
|
1308
|
+
*
|
|
1309
|
+
* // Get Microsoft's statistics
|
|
1310
|
+
* const msftStats = await fmp.insider.getInsiderTradeStatistics({ symbol: 'MSFT' });
|
|
1311
|
+
* ```
|
|
1312
|
+
*
|
|
1313
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#insider-trade-statistics-insider-trading|FMP Insider Trade Statistics Documentation}
|
|
1314
|
+
*/
|
|
1315
|
+
getInsiderTradeStatistics(params: {
|
|
1316
|
+
symbol: string;
|
|
1317
|
+
}): Promise<APIResponse<InsiderTradeStatisticsResponse[]>>;
|
|
1318
|
+
/**
|
|
1319
|
+
* Get CIK mapper data
|
|
1320
|
+
*
|
|
1321
|
+
* Provides a mapping between CIK (Central Index Key) numbers and company
|
|
1322
|
+
* names. Essential for converting between CIK numbers and company
|
|
1323
|
+
* identifiers in insider trading analysis.
|
|
1324
|
+
*
|
|
1325
|
+
* @param params - CIK mapper request parameters
|
|
1326
|
+
* @param params.page - Page number for pagination (default: 0)
|
|
1327
|
+
*
|
|
1328
|
+
* @returns Promise resolving to array of CIK mapper data
|
|
1329
|
+
*
|
|
1330
|
+
* @example
|
|
1331
|
+
* ```typescript
|
|
1332
|
+
* // Get first page of CIK mapper
|
|
1333
|
+
* const cikMapper = await fmp.insider.getCikMapper({ page: 0 });
|
|
1334
|
+
* cikMapper.data.forEach(mapping => {
|
|
1335
|
+
* console.log(`CIK: ${mapping.cik} - Company: ${mapping.name}`);
|
|
1336
|
+
* });
|
|
1337
|
+
*
|
|
1338
|
+
* // Get second page
|
|
1339
|
+
* const nextPage = await fmp.insider.getCikMapper({ page: 1 });
|
|
1340
|
+
* ```
|
|
1341
|
+
*
|
|
1342
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#cik-mapper-insider-trading|FMP CIK Mapper Documentation}
|
|
1343
|
+
*/
|
|
1344
|
+
getCikMapper(params: {
|
|
1345
|
+
page?: number;
|
|
1346
|
+
}): Promise<APIResponse<CikMapperResponse[]>>;
|
|
1347
|
+
/**
|
|
1348
|
+
* Get CIK mapper by name search
|
|
1349
|
+
*
|
|
1350
|
+
* Provides CIK numbers and company names matching a search term.
|
|
1351
|
+
* Useful for finding companies by partial name matches and
|
|
1352
|
+
* converting company names to CIK numbers.
|
|
1353
|
+
*
|
|
1354
|
+
* @param params - CIK mapper by name request parameters
|
|
1355
|
+
* @param params.name - Company name or partial name to search for
|
|
1356
|
+
* @param params.page - Page number for pagination (default: 0)
|
|
1357
|
+
*
|
|
1358
|
+
* @returns Promise resolving to array of CIK mapper data matching the search
|
|
1359
|
+
*
|
|
1360
|
+
* @example
|
|
1361
|
+
* ```typescript
|
|
1362
|
+
* // Search for Apple by name
|
|
1363
|
+
* const appleCik = await fmp.insider.getCikMapperByName({
|
|
1364
|
+
* name: 'Apple',
|
|
1365
|
+
* page: 0
|
|
1366
|
+
* });
|
|
1367
|
+
* appleCik.data.forEach(mapping => {
|
|
1368
|
+
* console.log(`CIK: ${mapping.cik} - Company: ${mapping.name}`);
|
|
1369
|
+
* });
|
|
1370
|
+
*
|
|
1371
|
+
* // Search for Microsoft
|
|
1372
|
+
* const msftCik = await fmp.insider.getCikMapperByName({
|
|
1373
|
+
* name: 'Microsoft',
|
|
1374
|
+
* page: 0
|
|
1375
|
+
* });
|
|
1376
|
+
* ```
|
|
1377
|
+
*
|
|
1378
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#cik-mapper-by-name-insider-trading|FMP CIK Mapper by Name Documentation}
|
|
1379
|
+
*/
|
|
1380
|
+
getCikMapperByName(params: {
|
|
1381
|
+
name: string;
|
|
1382
|
+
page?: number;
|
|
1383
|
+
}): Promise<APIResponse<CikMapperResponse[]>>;
|
|
1384
|
+
/**
|
|
1385
|
+
* Get CIK mapper by symbol
|
|
1386
|
+
*
|
|
1387
|
+
* Provides CIK number and company name for a specific stock symbol.
|
|
1388
|
+
* Essential for converting stock symbols to CIK numbers for use
|
|
1389
|
+
* in insider trading searches and analysis.
|
|
1390
|
+
*
|
|
1391
|
+
* @param params - CIK mapper by symbol request parameters
|
|
1392
|
+
* @param params.symbol - Stock symbol to get CIK for
|
|
1393
|
+
*
|
|
1394
|
+
* @returns Promise resolving to CIK mapper data for the symbol
|
|
1395
|
+
*
|
|
1396
|
+
* @example
|
|
1397
|
+
* ```typescript
|
|
1398
|
+
* // Get Apple's CIK by symbol
|
|
1399
|
+
* const appleCik = await fmp.insider.getCikMapperBySymbol({ symbol: 'AAPL' });
|
|
1400
|
+
* console.log(`Apple CIK: ${appleCik.data.cik} - ${appleCik.data.name}`);
|
|
1401
|
+
*
|
|
1402
|
+
* // Get Microsoft's CIK
|
|
1403
|
+
* const msftCik = await fmp.insider.getCikMapperBySymbol({ symbol: 'MSFT' });
|
|
1404
|
+
* ```
|
|
1405
|
+
*
|
|
1406
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#cik-mapper-company-insider-trading|FMP CIK Mapper by Symbol Documentation}
|
|
1407
|
+
*/
|
|
1408
|
+
getCikMapperBySymbol(params: {
|
|
1409
|
+
symbol: string;
|
|
1410
|
+
}): Promise<APIResponse<CikMapperBySymbolResponse>>;
|
|
1411
|
+
/**
|
|
1412
|
+
* Get beneficial ownership acquisitions
|
|
1413
|
+
*
|
|
1414
|
+
* Provides data on acquisitions of beneficial ownership for a specific
|
|
1415
|
+
* company. Essential for tracking significant ownership changes and
|
|
1416
|
+
* corporate governance events.
|
|
1417
|
+
*
|
|
1418
|
+
* @param params - Beneficial ownership request parameters
|
|
1419
|
+
* @param params.symbol - Stock symbol to get beneficial ownership data for
|
|
1420
|
+
*
|
|
1421
|
+
* @returns Promise resolving to array of beneficial ownership acquisition data
|
|
1422
|
+
*
|
|
1423
|
+
* @example
|
|
1424
|
+
* ```typescript
|
|
1425
|
+
* // Get Apple's beneficial ownership acquisitions
|
|
1426
|
+
* const appleOwnership = await fmp.insider.getBeneficialOwnership({ symbol: 'AAPL' });
|
|
1427
|
+
* appleOwnership.data.forEach(acquisition => {
|
|
1428
|
+
* console.log(`${acquisition.date}: ${acquisition.insiderName} acquired ${acquisition.sharesAcquired} shares`);
|
|
1429
|
+
* });
|
|
1430
|
+
*
|
|
1431
|
+
* // Get Microsoft's beneficial ownership
|
|
1432
|
+
* const msftOwnership = await fmp.insider.getBeneficialOwnership({ symbol: 'MSFT' });
|
|
1433
|
+
* ```
|
|
1434
|
+
*
|
|
1435
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#acquisition-of-beneficial-ownership|FMP Beneficial Ownership Documentation}
|
|
1436
|
+
*/
|
|
1437
|
+
getBeneficialOwnership(params: {
|
|
1438
|
+
symbol: string;
|
|
1439
|
+
}): Promise<APIResponse<BeneficialOwnershipResponse[]>>;
|
|
1440
|
+
/**
|
|
1441
|
+
* Get fail to deliver data
|
|
1442
|
+
*
|
|
1443
|
+
* Provides fail to deliver data for a specific company, which indicates
|
|
1444
|
+
* when market participants fail to deliver securities on settlement date.
|
|
1445
|
+
* Important for understanding market mechanics and potential short interest.
|
|
1446
|
+
*
|
|
1447
|
+
* @param params - Fail to deliver request parameters
|
|
1448
|
+
* @param params.symbol - Stock symbol to get fail to deliver data for
|
|
1449
|
+
* @param params.page - Page number for pagination (default: 0)
|
|
1450
|
+
*
|
|
1451
|
+
* @returns Promise resolving to array of fail to deliver data
|
|
1452
|
+
*
|
|
1453
|
+
* @example
|
|
1454
|
+
* ```typescript
|
|
1455
|
+
* // Get Apple's fail to deliver data
|
|
1456
|
+
* const appleFailToDeliver = await fmp.insider.getFailToDeliver({
|
|
1457
|
+
* symbol: 'AAPL',
|
|
1458
|
+
* page: 0
|
|
1459
|
+
* });
|
|
1460
|
+
* appleFailToDeliver.data.forEach(entry => {
|
|
1461
|
+
* console.log(`${entry.date}: ${entry.shares} shares failed to deliver`);
|
|
1462
|
+
* });
|
|
1463
|
+
*
|
|
1464
|
+
* // Get Microsoft's fail to deliver data
|
|
1465
|
+
* const msftFailToDeliver = await fmp.insider.getFailToDeliver({
|
|
1466
|
+
* symbol: 'MSFT',
|
|
1467
|
+
* page: 0
|
|
1468
|
+
* });
|
|
1469
|
+
* ```
|
|
1470
|
+
*
|
|
1471
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#fail-to-deliver|FMP Fail to Deliver Documentation}
|
|
1472
|
+
*/
|
|
1473
|
+
getFailToDeliver(params: {
|
|
1474
|
+
symbol: string;
|
|
1475
|
+
page?: number;
|
|
1476
|
+
}): Promise<APIResponse<FailToDeliverResponse[]>>;
|
|
1477
|
+
/**
|
|
1478
|
+
* Get all insider trades for a symbol (convenience method)
|
|
1479
|
+
* @param symbol - The stock symbol to get insider trades for
|
|
1480
|
+
* @param page - Page number for pagination (default: 0)
|
|
1481
|
+
* @returns A list of insider trades for the specified symbol
|
|
1482
|
+
*/
|
|
1483
|
+
getInsiderTradesBySymbol(symbol: string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
1484
|
+
/**
|
|
1485
|
+
* Get insider trades by transaction type (convenience method)
|
|
1486
|
+
* @param transactionType - The transaction type to filter by
|
|
1487
|
+
* @param page - Page number for pagination (default: 0)
|
|
1488
|
+
* @returns A list of insider trades filtered by transaction type
|
|
1217
1489
|
*/
|
|
1218
|
-
|
|
1490
|
+
getInsiderTradesByType(transactionType: TransactionType | string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
1219
1491
|
/**
|
|
1220
|
-
* Get
|
|
1492
|
+
* Get insider trades by reporting CIK (convenience method)
|
|
1493
|
+
* @param reportingCik - The reporting CIK to filter by
|
|
1494
|
+
* @param page - Page number for pagination (default: 0)
|
|
1495
|
+
* @returns A list of insider trades filtered by reporting CIK
|
|
1496
|
+
*/
|
|
1497
|
+
getInsiderTradesByReportingCik(reportingCik: string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
1498
|
+
/**
|
|
1499
|
+
* Get insider trades by company CIK (convenience method)
|
|
1500
|
+
* @param companyCik - The company CIK to filter by
|
|
1501
|
+
* @param page - Page number for pagination (default: 0)
|
|
1502
|
+
* @returns A list of insider trades filtered by company CIK
|
|
1503
|
+
*/
|
|
1504
|
+
getInsiderTradesByCompanyCik(companyCik: string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
1505
|
+
}
|
|
1506
|
+
|
|
1507
|
+
declare class InstitutionalEndpoints {
|
|
1508
|
+
private client;
|
|
1509
|
+
constructor(client: FMPClient);
|
|
1510
|
+
/**
|
|
1511
|
+
* Get Form 13F institutional stock ownership data
|
|
1221
1512
|
*
|
|
1222
|
-
* Provides
|
|
1223
|
-
*
|
|
1224
|
-
*
|
|
1513
|
+
* Provides Form 13F institutional stock ownership data for investment
|
|
1514
|
+
* managers with over $100 million in assets under management. Essential
|
|
1515
|
+
* for analyzing institutional investment patterns and holdings.
|
|
1225
1516
|
*
|
|
1226
|
-
* @
|
|
1517
|
+
* @param params - Form 13F request parameters
|
|
1518
|
+
* @param params.cik - Central Index Key (CIK) of the investment manager
|
|
1519
|
+
* @param params.date - Specific date in YYYY-MM-DD format (optional, defaults to most recent filing)
|
|
1520
|
+
*
|
|
1521
|
+
* @returns Promise resolving to array of Form 13F institutional ownership data
|
|
1227
1522
|
*
|
|
1228
1523
|
* @example
|
|
1229
1524
|
* ```typescript
|
|
1230
|
-
* // Get
|
|
1231
|
-
* const
|
|
1232
|
-
*
|
|
1233
|
-
*
|
|
1234
|
-
*
|
|
1235
|
-
*
|
|
1236
|
-
*
|
|
1237
|
-
*
|
|
1238
|
-
* const gbpUsd = forexPairs.data.find(pair => pair.symbol === 'GBPUSD');
|
|
1239
|
-
* console.log(`GBP/USD: ${gbpUsd?.name} (${gbpUsd?.exchange})`);
|
|
1525
|
+
* // Get Berkshire Hathaway's Form 13F data
|
|
1526
|
+
* const berkshire13F = await fmp.institutional.getForm13F({
|
|
1527
|
+
* cik: '0001067983'
|
|
1528
|
+
* });
|
|
1529
|
+
* berkshire13F.data.forEach(holding => {
|
|
1530
|
+
* console.log(`${holding.issuerName}: ${holding.value.toLocaleString()} shares, $${holding.value.toLocaleString()}`);
|
|
1531
|
+
* });
|
|
1240
1532
|
*
|
|
1241
|
-
* //
|
|
1242
|
-
* const
|
|
1243
|
-
*
|
|
1244
|
-
*
|
|
1245
|
-
*
|
|
1533
|
+
* // Get Form 13F data for specific date
|
|
1534
|
+
* const historical13F = await fmp.institutional.getForm13F({
|
|
1535
|
+
* cik: '0001067983',
|
|
1536
|
+
* date: '2023-12-31'
|
|
1537
|
+
* });
|
|
1246
1538
|
*
|
|
1247
|
-
* //
|
|
1248
|
-
* const
|
|
1249
|
-
*
|
|
1250
|
-
* );
|
|
1539
|
+
* // Get BlackRock's Form 13F data
|
|
1540
|
+
* const blackrock13F = await fmp.institutional.getForm13F({
|
|
1541
|
+
* cik: '0001364742'
|
|
1542
|
+
* });
|
|
1251
1543
|
* ```
|
|
1252
1544
|
*
|
|
1253
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1545
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#form-13f-13f---institutional-stock-ownership|FMP Form 13F Documentation}
|
|
1254
1546
|
*/
|
|
1255
|
-
|
|
1547
|
+
getForm13F(params: {
|
|
1548
|
+
cik: string;
|
|
1549
|
+
date?: string;
|
|
1550
|
+
}): Promise<APIResponse<Form13FResponse[]>>;
|
|
1256
1551
|
/**
|
|
1257
|
-
* Get
|
|
1552
|
+
* Get Form 13F filing dates for an investment manager
|
|
1258
1553
|
*
|
|
1259
|
-
* Provides
|
|
1260
|
-
*
|
|
1261
|
-
*
|
|
1554
|
+
* Provides available filing dates for Form 13F submissions by a specific
|
|
1555
|
+
* investment manager. Essential for discovering historical filing dates
|
|
1556
|
+
* before requesting detailed Form 13F data.
|
|
1262
1557
|
*
|
|
1263
|
-
* @
|
|
1558
|
+
* @param params - Form 13F dates request parameters
|
|
1559
|
+
* @param params.cik - Central Index Key (CIK) of the investment manager
|
|
1560
|
+
*
|
|
1561
|
+
* @returns Promise resolving to array of available Form 13F filing dates
|
|
1264
1562
|
*
|
|
1265
1563
|
* @example
|
|
1266
1564
|
* ```typescript
|
|
1267
|
-
* // Get
|
|
1268
|
-
* const
|
|
1269
|
-
*
|
|
1270
|
-
*
|
|
1271
|
-
*
|
|
1272
|
-
*
|
|
1273
|
-
*
|
|
1274
|
-
*
|
|
1275
|
-
* const nasdaq = indexes.data.find(index => index.symbol === '^IXIC');
|
|
1276
|
-
* console.log(`NASDAQ: ${nasdaq?.name} (${nasdaq?.exchange})`);
|
|
1277
|
-
*
|
|
1278
|
-
* const dowJones = indexes.data.find(index => index.symbol === '^DJI');
|
|
1279
|
-
* console.log(`Dow Jones: ${dowJones?.name} (${dowJones?.exchange})`);
|
|
1280
|
-
*
|
|
1281
|
-
* // Filter by exchange
|
|
1282
|
-
* const nyseIndexes = indexes.data.filter(index => index.exchange === 'NYSE');
|
|
1283
|
-
* console.log(`NYSE indexes: ${nyseIndexes.length}`);
|
|
1565
|
+
* // Get Berkshire Hathaway's Form 13F filing dates
|
|
1566
|
+
* const berkshireDates = await fmp.institutional.getForm13FDates({
|
|
1567
|
+
* cik: '0001067983'
|
|
1568
|
+
* });
|
|
1569
|
+
* berkshireDates.data.forEach(date => {
|
|
1570
|
+
* console.log(`Filing date: ${date}`);
|
|
1571
|
+
* });
|
|
1284
1572
|
*
|
|
1285
|
-
* //
|
|
1286
|
-
* const
|
|
1287
|
-
*
|
|
1288
|
-
*
|
|
1289
|
-
* );
|
|
1573
|
+
* // Get BlackRock's filing dates
|
|
1574
|
+
* const blackrockDates = await fmp.institutional.getForm13FDates({
|
|
1575
|
+
* cik: '0001364742'
|
|
1576
|
+
* });
|
|
1290
1577
|
* ```
|
|
1291
1578
|
*
|
|
1292
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1579
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#form-13f-dates-13f---institutional-stock-ownership|FMP Form 13F Dates Documentation}
|
|
1293
1580
|
*/
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
declare class CalendarEndpoints {
|
|
1298
|
-
private _client;
|
|
1299
|
-
constructor(_client: FMPClient);
|
|
1581
|
+
getForm13FDates(params: {
|
|
1582
|
+
cik: string;
|
|
1583
|
+
}): Promise<APIResponse<string[]>>;
|
|
1300
1584
|
/**
|
|
1301
|
-
* Get
|
|
1585
|
+
* Get institutional holders for a company
|
|
1302
1586
|
*
|
|
1303
|
-
* Provides
|
|
1304
|
-
*
|
|
1305
|
-
*
|
|
1587
|
+
* Provides data on institutional investors holding shares in a specific
|
|
1588
|
+
* company. Essential for understanding institutional ownership patterns,
|
|
1589
|
+
* major shareholders, and investment sentiment.
|
|
1306
1590
|
*
|
|
1307
|
-
* @param params -
|
|
1308
|
-
* @param params.
|
|
1309
|
-
* @param params.to - End date in YYYY-MM-DD format (optional, defaults to 30 days from today)
|
|
1591
|
+
* @param params - Institutional holders request parameters
|
|
1592
|
+
* @param params.symbol - Stock symbol to get institutional holders for
|
|
1310
1593
|
*
|
|
1311
|
-
* @returns Promise resolving to array of
|
|
1594
|
+
* @returns Promise resolving to array of institutional holders data
|
|
1312
1595
|
*
|
|
1313
1596
|
* @example
|
|
1314
1597
|
* ```typescript
|
|
1315
|
-
* // Get
|
|
1316
|
-
* const
|
|
1317
|
-
*
|
|
1318
|
-
* to: '2024-01-22'
|
|
1598
|
+
* // Get Apple's institutional holders
|
|
1599
|
+
* const appleHolders = await fmp.institutional.getInstitutionalHolders({
|
|
1600
|
+
* symbol: 'AAPL'
|
|
1319
1601
|
* });
|
|
1320
|
-
*
|
|
1321
|
-
* console.log(`${
|
|
1602
|
+
* appleHolders.data.forEach(holder => {
|
|
1603
|
+
* console.log(`${holder.holder}: ${holder.shares.toLocaleString()} shares (${holder.weight}%)`);
|
|
1322
1604
|
* });
|
|
1323
1605
|
*
|
|
1324
|
-
* // Get
|
|
1325
|
-
* const
|
|
1326
|
-
*
|
|
1327
|
-
*
|
|
1606
|
+
* // Get Microsoft's institutional holders
|
|
1607
|
+
* const msftHolders = await fmp.institutional.getInstitutionalHolders({
|
|
1608
|
+
* symbol: 'MSFT'
|
|
1609
|
+
* });
|
|
1610
|
+
*
|
|
1611
|
+
* // Get Tesla's institutional holders
|
|
1612
|
+
* const teslaHolders = await fmp.institutional.getInstitutionalHolders({
|
|
1613
|
+
* symbol: 'TSLA'
|
|
1328
1614
|
* });
|
|
1329
1615
|
* ```
|
|
1330
1616
|
*
|
|
1331
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1617
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#institutional-holder-13f---institutional-stock-ownership|FMP Institutional Holders Documentation}
|
|
1332
1618
|
*/
|
|
1333
|
-
|
|
1334
|
-
|
|
1335
|
-
|
|
1336
|
-
|
|
1619
|
+
getInstitutionalHolders(params: {
|
|
1620
|
+
symbol: string;
|
|
1621
|
+
}): Promise<APIResponse<InstitutionalHolderResponse[]>>;
|
|
1622
|
+
}
|
|
1623
|
+
|
|
1624
|
+
declare class ListEndpoints {
|
|
1625
|
+
private client;
|
|
1626
|
+
constructor(client: FMPClient);
|
|
1337
1627
|
/**
|
|
1338
|
-
* Get
|
|
1339
|
-
*
|
|
1340
|
-
* Provides confirmed earnings announcements with verified dates and times.
|
|
1341
|
-
* These are earnings announcements that have been officially confirmed
|
|
1342
|
-
* by companies, providing more reliable scheduling information.
|
|
1628
|
+
* Get comprehensive list of all available stocks
|
|
1343
1629
|
*
|
|
1344
|
-
*
|
|
1345
|
-
*
|
|
1346
|
-
*
|
|
1630
|
+
* Provides a complete list of all stocks available on major exchanges including
|
|
1631
|
+
* NYSE, NASDAQ, and other global markets. Essential for discovering available
|
|
1632
|
+
* symbols, building watchlists, or creating stock screening applications.
|
|
1347
1633
|
*
|
|
1348
|
-
* @returns Promise resolving to array of
|
|
1634
|
+
* @returns Promise resolving to array of stock data with symbol, name, exchange, and price information
|
|
1349
1635
|
*
|
|
1350
1636
|
* @example
|
|
1351
1637
|
* ```typescript
|
|
1352
|
-
* // Get
|
|
1353
|
-
* const
|
|
1354
|
-
*
|
|
1355
|
-
* to: '2024-01-22'
|
|
1356
|
-
* });
|
|
1357
|
-
* confirmedEarnings.data.forEach(earning => {
|
|
1358
|
-
* console.log(`${earning.date}: ${earning.symbol} - Confirmed: ${earning.time}`);
|
|
1359
|
-
* });
|
|
1638
|
+
* // Get all available stocks
|
|
1639
|
+
* const stocks = await fmp.list.getStockList();
|
|
1640
|
+
* console.log(`Total stocks available: ${stocks.data.length}`);
|
|
1360
1641
|
*
|
|
1361
|
-
* //
|
|
1362
|
-
* const
|
|
1363
|
-
*
|
|
1364
|
-
*
|
|
1365
|
-
*
|
|
1642
|
+
* // Find specific stocks
|
|
1643
|
+
* const appleStock = stocks.data.find(stock => stock.symbol === 'AAPL');
|
|
1644
|
+
* console.log(`Apple: ${appleStock?.name} (${appleStock?.exchange})`);
|
|
1645
|
+
*
|
|
1646
|
+
* // Filter by exchange
|
|
1647
|
+
* const nasdaqStocks = stocks.data.filter(stock => stock.exchange === 'NASDAQ');
|
|
1648
|
+
* console.log(`NASDAQ stocks: ${nasdaqStocks.length}`);
|
|
1366
1649
|
* ```
|
|
1367
1650
|
*
|
|
1368
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1651
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#symbol-list-stock-list|FMP Stock List Documentation}
|
|
1369
1652
|
*/
|
|
1370
|
-
|
|
1371
|
-
from?: string;
|
|
1372
|
-
to?: string;
|
|
1373
|
-
}): Promise<APIResponse<EarningsConfirmed[]>>;
|
|
1653
|
+
getStockList(): Promise<APIResponse<StockList[]>>;
|
|
1374
1654
|
/**
|
|
1375
|
-
* Get
|
|
1376
|
-
*
|
|
1377
|
-
* Provides upcoming dividend payments and ex-dividend dates for all
|
|
1378
|
-
* publicly traded companies within a specified date range. Essential
|
|
1379
|
-
* for dividend investors and income-focused strategies.
|
|
1655
|
+
* Get comprehensive list of all available ETFs
|
|
1380
1656
|
*
|
|
1381
|
-
*
|
|
1382
|
-
*
|
|
1383
|
-
*
|
|
1657
|
+
* Provides a complete list of all Exchange-Traded Funds (ETFs) available for trading.
|
|
1658
|
+
* Includes ETFs from various asset classes including equity, bond, commodity, and
|
|
1659
|
+
* sector-specific funds. Essential for ETF research and portfolio construction.
|
|
1384
1660
|
*
|
|
1385
|
-
* @returns Promise resolving to array of
|
|
1661
|
+
* @returns Promise resolving to array of ETF data with symbol, name, exchange, and asset class information
|
|
1386
1662
|
*
|
|
1387
1663
|
* @example
|
|
1388
1664
|
* ```typescript
|
|
1389
|
-
* // Get
|
|
1390
|
-
* const
|
|
1391
|
-
*
|
|
1392
|
-
* to: '2024-01-22'
|
|
1393
|
-
* });
|
|
1394
|
-
* dividendsCalendar.data.forEach(dividend => {
|
|
1395
|
-
* console.log(`${dividend.date}: ${dividend.symbol} - Amount: $${dividend.amount}`);
|
|
1396
|
-
* });
|
|
1665
|
+
* // Get all available ETFs
|
|
1666
|
+
* const etfs = await fmp.list.getETFList();
|
|
1667
|
+
* console.log(`Total ETFs available: ${etfs.data.length}`);
|
|
1397
1668
|
*
|
|
1398
|
-
* //
|
|
1399
|
-
* const
|
|
1400
|
-
*
|
|
1401
|
-
*
|
|
1402
|
-
*
|
|
1669
|
+
* // Find specific ETFs
|
|
1670
|
+
* const spyETF = etfs.data.find(etf => etf.symbol === 'SPY');
|
|
1671
|
+
* console.log(`SPY: ${spyETF?.name} (${spyETF?.assetClass})`);
|
|
1672
|
+
*
|
|
1673
|
+
* // Filter by asset class
|
|
1674
|
+
* const equityETFs = etfs.data.filter(etf => etf.assetClass === 'Equity');
|
|
1675
|
+
* console.log(`Equity ETFs: ${equityETFs.length}`);
|
|
1676
|
+
*
|
|
1677
|
+
* // Find sector ETFs
|
|
1678
|
+
* const techETFs = etfs.data.filter(etf =>
|
|
1679
|
+
* etf.name.toLowerCase().includes('technology') ||
|
|
1680
|
+
* etf.name.toLowerCase().includes('tech')
|
|
1681
|
+
* );
|
|
1403
1682
|
* ```
|
|
1404
1683
|
*
|
|
1405
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1684
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#exchange-traded-fund-search-stock-list|FMP ETF List Documentation}
|
|
1406
1685
|
*/
|
|
1407
|
-
|
|
1408
|
-
from?: string;
|
|
1409
|
-
to?: string;
|
|
1410
|
-
}): Promise<APIResponse<DividendsCalendar[]>>;
|
|
1686
|
+
getETFList(): Promise<APIResponse<ETFList[]>>;
|
|
1411
1687
|
/**
|
|
1412
|
-
* Get
|
|
1413
|
-
*
|
|
1414
|
-
* Provides upcoming economic events, indicators, and data releases
|
|
1415
|
-
* that can impact financial markets. Essential for understanding
|
|
1416
|
-
* market-moving events and economic trends.
|
|
1688
|
+
* Get comprehensive list of all available cryptocurrencies
|
|
1417
1689
|
*
|
|
1418
|
-
*
|
|
1419
|
-
*
|
|
1420
|
-
*
|
|
1690
|
+
* Provides a complete list of all cryptocurrencies available for trading.
|
|
1691
|
+
* Includes major cryptocurrencies like Bitcoin, Ethereum, and thousands of altcoins
|
|
1692
|
+
* with their trading pairs against USD and other major currencies.
|
|
1421
1693
|
*
|
|
1422
|
-
* @returns Promise resolving to array of
|
|
1694
|
+
* @returns Promise resolving to array of cryptocurrency data with symbol, name, and exchange information
|
|
1423
1695
|
*
|
|
1424
1696
|
* @example
|
|
1425
1697
|
* ```typescript
|
|
1426
|
-
* // Get
|
|
1427
|
-
* const
|
|
1428
|
-
*
|
|
1429
|
-
* to: '2024-01-22'
|
|
1430
|
-
* });
|
|
1431
|
-
* economicCalendar.data.forEach(event => {
|
|
1432
|
-
* console.log(`${event.date}: ${event.event} - Country: ${event.country}`);
|
|
1433
|
-
* });
|
|
1698
|
+
* // Get all available cryptocurrencies
|
|
1699
|
+
* const cryptos = await fmp.list.getCryptoList();
|
|
1700
|
+
* console.log(`Total cryptocurrencies available: ${cryptos.data.length}`);
|
|
1434
1701
|
*
|
|
1435
|
-
* //
|
|
1436
|
-
* const
|
|
1437
|
-
*
|
|
1438
|
-
*
|
|
1439
|
-
*
|
|
1702
|
+
* // Find major cryptocurrencies
|
|
1703
|
+
* const bitcoin = cryptos.data.find(crypto => crypto.symbol === 'BTCUSD');
|
|
1704
|
+
* console.log(`Bitcoin: ${bitcoin?.name} (${bitcoin?.exchange})`);
|
|
1705
|
+
*
|
|
1706
|
+
* const ethereum = cryptos.data.find(crypto => crypto.symbol === 'ETHUSD');
|
|
1707
|
+
* console.log(`Ethereum: ${ethereum?.name} (${ethereum?.exchange})`);
|
|
1708
|
+
*
|
|
1709
|
+
* // Filter by exchange
|
|
1710
|
+
* const binanceCryptos = cryptos.data.filter(crypto => crypto.exchange === 'Binance');
|
|
1711
|
+
* console.log(`Binance cryptocurrencies: ${binanceCryptos.length}`);
|
|
1712
|
+
*
|
|
1713
|
+
* // Find altcoins
|
|
1714
|
+
* const altcoins = cryptos.data.filter(crypto =>
|
|
1715
|
+
* !['BTCUSD', 'ETHUSD', 'USDTUSD', 'USDCUSD'].includes(crypto.symbol)
|
|
1716
|
+
* );
|
|
1440
1717
|
* ```
|
|
1441
1718
|
*
|
|
1442
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1719
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#cryptocurrencies-list-crypto|FMP Cryptocurrency List Documentation}
|
|
1443
1720
|
*/
|
|
1444
|
-
|
|
1445
|
-
from?: string;
|
|
1446
|
-
to?: string;
|
|
1447
|
-
}): Promise<APIResponse<EconomicsCalendar[]>>;
|
|
1721
|
+
getCryptoList(): Promise<APIResponse<CryptoList[]>>;
|
|
1448
1722
|
/**
|
|
1449
|
-
* Get
|
|
1450
|
-
*
|
|
1451
|
-
* Provides upcoming initial public offerings (IPOs) and their details
|
|
1452
|
-
* within a specified date range. Essential for tracking new market
|
|
1453
|
-
* entrants and investment opportunities in newly public companies.
|
|
1723
|
+
* Get comprehensive list of all available forex currency pairs
|
|
1454
1724
|
*
|
|
1455
|
-
*
|
|
1456
|
-
*
|
|
1457
|
-
*
|
|
1725
|
+
* Provides a complete list of all foreign exchange currency pairs available for trading.
|
|
1726
|
+
* Includes major, minor, and exotic currency pairs with their base and quote currencies.
|
|
1727
|
+
* Essential for forex trading, currency analysis, and international market research.
|
|
1458
1728
|
*
|
|
1459
|
-
* @returns Promise resolving to array of
|
|
1729
|
+
* @returns Promise resolving to array of forex data with currency pair symbols and exchange information
|
|
1460
1730
|
*
|
|
1461
1731
|
* @example
|
|
1462
1732
|
* ```typescript
|
|
1463
|
-
* // Get
|
|
1464
|
-
* const
|
|
1465
|
-
*
|
|
1466
|
-
* to: '2024-01-22'
|
|
1467
|
-
* });
|
|
1468
|
-
* ipoCalendar.data.forEach(ipo => {
|
|
1469
|
-
* console.log(`${ipo.date}: ${ipo.symbol} - Price: $${ipo.price}, Shares: ${ipo.shares.toLocaleString()}`);
|
|
1470
|
-
* });
|
|
1733
|
+
* // Get all available forex pairs
|
|
1734
|
+
* const forexPairs = await fmp.list.getForexList();
|
|
1735
|
+
* console.log(`Total forex pairs available: ${forexPairs.data.length}`);
|
|
1471
1736
|
*
|
|
1472
|
-
* //
|
|
1473
|
-
* const
|
|
1474
|
-
*
|
|
1475
|
-
*
|
|
1476
|
-
*
|
|
1737
|
+
* // Find major currency pairs
|
|
1738
|
+
* const eurUsd = forexPairs.data.find(pair => pair.symbol === 'EURUSD');
|
|
1739
|
+
* console.log(`EUR/USD: ${eurUsd?.name} (${eurUsd?.exchange})`);
|
|
1740
|
+
*
|
|
1741
|
+
* const gbpUsd = forexPairs.data.find(pair => pair.symbol === 'GBPUSD');
|
|
1742
|
+
* console.log(`GBP/USD: ${gbpUsd?.name} (${gbpUsd?.exchange})`);
|
|
1743
|
+
*
|
|
1744
|
+
* // Filter major pairs (USD as quote currency)
|
|
1745
|
+
* const majorPairs = forexPairs.data.filter(pair =>
|
|
1746
|
+
* pair.symbol.endsWith('USD') && pair.symbol.length === 6
|
|
1747
|
+
* );
|
|
1748
|
+
* console.log(`Major pairs: ${majorPairs.length}`);
|
|
1749
|
+
*
|
|
1750
|
+
* // Find exotic pairs
|
|
1751
|
+
* const exoticPairs = forexPairs.data.filter(pair =>
|
|
1752
|
+
* pair.symbol.includes('ZAR') || pair.symbol.includes('TRY') || pair.symbol.includes('BRL')
|
|
1753
|
+
* );
|
|
1477
1754
|
* ```
|
|
1478
1755
|
*
|
|
1479
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1756
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#forex-list-forex|FMP Forex List Documentation}
|
|
1480
1757
|
*/
|
|
1481
|
-
|
|
1482
|
-
from?: string;
|
|
1483
|
-
to?: string;
|
|
1484
|
-
}): Promise<APIResponse<IPOCalendar[]>>;
|
|
1758
|
+
getForexList(): Promise<APIResponse<ForexList[]>>;
|
|
1485
1759
|
/**
|
|
1486
|
-
* Get
|
|
1487
|
-
*
|
|
1488
|
-
* Provides upcoming stock splits for publicly traded companies within
|
|
1489
|
-
* a specified date range. Essential for understanding corporate actions
|
|
1490
|
-
* that affect share prices and trading dynamics.
|
|
1760
|
+
* Get comprehensive list of all available market indexes
|
|
1491
1761
|
*
|
|
1492
|
-
*
|
|
1493
|
-
*
|
|
1494
|
-
*
|
|
1762
|
+
* Provides a complete list of all market indexes available for tracking and analysis.
|
|
1763
|
+
* Includes major global indexes like S&P 500, NASDAQ, Dow Jones, as well as
|
|
1764
|
+
* international indexes, sector indexes, and specialized market benchmarks.
|
|
1495
1765
|
*
|
|
1496
|
-
* @returns Promise resolving to array of
|
|
1766
|
+
* @returns Promise resolving to array of index data with symbol, name, and exchange information
|
|
1497
1767
|
*
|
|
1498
1768
|
* @example
|
|
1499
1769
|
* ```typescript
|
|
1500
|
-
* // Get
|
|
1501
|
-
* const
|
|
1502
|
-
*
|
|
1503
|
-
* to: '2024-01-22'
|
|
1504
|
-
* });
|
|
1505
|
-
* splitsCalendar.data.forEach(split => {
|
|
1506
|
-
* console.log(`${split.date}: ${split.symbol} - Ratio: ${split.numerator}:${split.denominator}`);
|
|
1507
|
-
* });
|
|
1770
|
+
* // Get all available indexes
|
|
1771
|
+
* const indexes = await fmp.list.getAvailableIndexes();
|
|
1772
|
+
* console.log(`Total indexes available: ${indexes.data.length}`);
|
|
1508
1773
|
*
|
|
1509
|
-
* //
|
|
1510
|
-
* const
|
|
1511
|
-
*
|
|
1512
|
-
*
|
|
1513
|
-
*
|
|
1774
|
+
* // Find major US indexes
|
|
1775
|
+
* const sp500 = indexes.data.find(index => index.symbol === '^GSPC');
|
|
1776
|
+
* console.log(`S&P 500: ${sp500?.name} (${sp500?.exchange})`);
|
|
1777
|
+
*
|
|
1778
|
+
* const nasdaq = indexes.data.find(index => index.symbol === '^IXIC');
|
|
1779
|
+
* console.log(`NASDAQ: ${nasdaq?.name} (${nasdaq?.exchange})`);
|
|
1780
|
+
*
|
|
1781
|
+
* const dowJones = indexes.data.find(index => index.symbol === '^DJI');
|
|
1782
|
+
* console.log(`Dow Jones: ${dowJones?.name} (${dowJones?.exchange})`);
|
|
1783
|
+
*
|
|
1784
|
+
* // Filter by exchange
|
|
1785
|
+
* const nyseIndexes = indexes.data.filter(index => index.exchange === 'NYSE');
|
|
1786
|
+
* console.log(`NYSE indexes: ${nyseIndexes.length}`);
|
|
1787
|
+
*
|
|
1788
|
+
* // Find sector indexes
|
|
1789
|
+
* const techIndexes = indexes.data.filter(index =>
|
|
1790
|
+
* index.name.toLowerCase().includes('technology') ||
|
|
1791
|
+
* index.name.toLowerCase().includes('tech')
|
|
1792
|
+
* );
|
|
1514
1793
|
* ```
|
|
1515
1794
|
*
|
|
1516
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
1795
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#available-indexes|FMP Available Indexes Documentation}
|
|
1517
1796
|
*/
|
|
1518
|
-
|
|
1519
|
-
from?: string;
|
|
1520
|
-
to?: string;
|
|
1521
|
-
}): Promise<APIResponse<SplitsCalendar[]>>;
|
|
1797
|
+
getAvailableIndexes(): Promise<APIResponse<AvailableIndexesList[]>>;
|
|
1522
1798
|
}
|
|
1523
1799
|
|
|
1524
|
-
declare class
|
|
1800
|
+
declare class MarketEndpoints {
|
|
1525
1801
|
private client;
|
|
1526
1802
|
constructor(client: FMPClient);
|
|
1527
1803
|
/**
|
|
1528
|
-
* Get
|
|
1529
|
-
*
|
|
1530
|
-
* Provides detailed company information including financial metrics, business description,
|
|
1531
|
-
* headquarters location, and key performance indicators. Essential for fundamental analysis
|
|
1532
|
-
* and understanding a company's business model and market position.
|
|
1804
|
+
* Get current market hours and trading status
|
|
1533
1805
|
*
|
|
1534
|
-
*
|
|
1806
|
+
* Provides real-time information about market trading hours, including
|
|
1807
|
+
* whether markets are currently open or closed, trading session times,
|
|
1808
|
+
* and upcoming market holidays. Essential for determining trading
|
|
1809
|
+
* availability and market status.
|
|
1535
1810
|
*
|
|
1536
|
-
* @returns Promise resolving to
|
|
1811
|
+
* @returns Promise resolving to market hours data with trading status and session information
|
|
1537
1812
|
*
|
|
1538
1813
|
* @example
|
|
1539
1814
|
* ```typescript
|
|
1540
|
-
* // Get
|
|
1541
|
-
* const
|
|
1542
|
-
* console.log(`
|
|
1543
|
-
* console.log(`
|
|
1544
|
-
* console.log(`
|
|
1545
|
-
* console.log(`Description: ${profile.data.description.substring(0, 100)}...`);
|
|
1815
|
+
* // Get current market status
|
|
1816
|
+
* const marketHours = await fmp.market.getMarketHours();
|
|
1817
|
+
* console.log(`Market is ${marketHours.data.isTheStockMarketOpen ? 'OPEN' : 'CLOSED'}`);
|
|
1818
|
+
* console.log(`Current time: ${marketHours.data.currentTime}`);
|
|
1819
|
+
* console.log(`Next trading day: ${marketHours.data.nextTradingDay}`);
|
|
1546
1820
|
*
|
|
1547
|
-
* //
|
|
1548
|
-
*
|
|
1821
|
+
* // Check if it's a trading day
|
|
1822
|
+
* if (marketHours.data.isTheStockMarketOpen) {
|
|
1823
|
+
* console.log('Markets are currently open for trading');
|
|
1824
|
+
* } else {
|
|
1825
|
+
* console.log('Markets are closed');
|
|
1826
|
+
* }
|
|
1549
1827
|
* ```
|
|
1550
1828
|
*
|
|
1551
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs
|
|
1829
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#market-hours|FMP Market Hours Documentation}
|
|
1552
1830
|
*/
|
|
1553
|
-
|
|
1831
|
+
getMarketHours(): Promise<APIResponse<MarketHours>>;
|
|
1554
1832
|
/**
|
|
1555
|
-
* Get
|
|
1556
|
-
*
|
|
1557
|
-
* Provides detailed compensation data for company executives including salary, bonuses,
|
|
1558
|
-
* stock options, and other benefits. Essential for governance analysis and understanding
|
|
1559
|
-
* executive pay structures and alignment with shareholder interests.
|
|
1833
|
+
* Get overall market performance data
|
|
1560
1834
|
*
|
|
1561
|
-
*
|
|
1835
|
+
* Provides comprehensive market performance data including major indices,
|
|
1836
|
+
* market breadth, and key performance metrics. Essential for understanding
|
|
1837
|
+
* overall market sentiment, trends, and daily market activity.
|
|
1562
1838
|
*
|
|
1563
|
-
* @returns Promise resolving to array of
|
|
1839
|
+
* @returns Promise resolving to array of market performance data with indices and metrics
|
|
1564
1840
|
*
|
|
1565
1841
|
* @example
|
|
1566
1842
|
* ```typescript
|
|
1567
|
-
* // Get
|
|
1568
|
-
* const
|
|
1569
|
-
*
|
|
1570
|
-
* console.log(`${
|
|
1571
|
-
* console.log(`
|
|
1572
|
-
* console.log(` Bonus: $${exec.bonus.toLocaleString()}`);
|
|
1573
|
-
* console.log(` Stock Options: $${exec.stockAwards.toLocaleString()}`);
|
|
1843
|
+
* // Get overall market performance
|
|
1844
|
+
* const marketPerformance = await fmp.market.getMarketPerformance();
|
|
1845
|
+
* marketPerformance.data.forEach(market => {
|
|
1846
|
+
* console.log(`${market.index}: ${market.change} (${market.changesPercentage}%)`);
|
|
1847
|
+
* console.log(` Open: $${market.open}, High: $${market.dayHigh}, Low: $${market.dayLow}`);
|
|
1574
1848
|
* });
|
|
1575
1849
|
*
|
|
1576
|
-
* //
|
|
1577
|
-
* const
|
|
1850
|
+
* // Find specific indices
|
|
1851
|
+
* const sp500 = marketPerformance.data.find(market => market.index === 'S&P 500');
|
|
1852
|
+
* console.log(`S&P 500 performance: ${sp500?.changesPercentage}%`);
|
|
1853
|
+
*
|
|
1854
|
+
* // Check market sentiment
|
|
1855
|
+
* const gainers = marketPerformance.data.filter(market => market.changesPercentage > 0);
|
|
1856
|
+
* const losers = marketPerformance.data.filter(market => market.changesPercentage < 0);
|
|
1857
|
+
* console.log(`Gaining indices: ${gainers.length}, Losing indices: ${losers.length}`);
|
|
1578
1858
|
* ```
|
|
1579
1859
|
*
|
|
1580
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs
|
|
1860
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#market-index-market-overview|FMP Market Performance Documentation}
|
|
1581
1861
|
*/
|
|
1582
|
-
|
|
1862
|
+
getMarketPerformance(): Promise<APIResponse<MarketPerformance[]>>;
|
|
1583
1863
|
/**
|
|
1584
|
-
* Get
|
|
1585
|
-
*
|
|
1586
|
-
* Provides important notes and disclosures from company financial statements.
|
|
1587
|
-
* These notes contain critical information about accounting policies, risks,
|
|
1588
|
-
* contingencies, and other material information that affects financial analysis.
|
|
1864
|
+
* Get top gaining stocks for the current trading day
|
|
1589
1865
|
*
|
|
1590
|
-
*
|
|
1866
|
+
* Provides a list of stocks that have gained the most value during the
|
|
1867
|
+
* current trading session. Essential for identifying momentum stocks,
|
|
1868
|
+
* tracking market movers, and discovering potential investment opportunities.
|
|
1869
|
+
* Useful for day trading, momentum strategies, and market analysis.
|
|
1591
1870
|
*
|
|
1592
|
-
* @returns Promise resolving to array of
|
|
1871
|
+
* @returns Promise resolving to array of top gaining stocks with price and percentage change data
|
|
1593
1872
|
*
|
|
1594
1873
|
* @example
|
|
1595
1874
|
* ```typescript
|
|
1596
|
-
* // Get
|
|
1597
|
-
* const
|
|
1598
|
-
*
|
|
1599
|
-
*
|
|
1600
|
-
*
|
|
1875
|
+
* // Get top gainers for the day
|
|
1876
|
+
* const gainers = await fmp.market.getGainers();
|
|
1877
|
+
* console.log(`Top ${gainers.data.length} gaining stocks today:`);
|
|
1878
|
+
*
|
|
1879
|
+
* gainers.data.forEach((stock, index) => {
|
|
1880
|
+
* console.log(`${index + 1}. ${stock.symbol} (${stock.name})`);
|
|
1881
|
+
* console.log(` Price: $${stock.price} | Change: +${stock.change} (${stock.changesPercentage}%)`);
|
|
1882
|
+
* console.log(` Volume: ${stock.volume.toLocaleString()}`);
|
|
1601
1883
|
* });
|
|
1602
1884
|
*
|
|
1603
|
-
* //
|
|
1604
|
-
* const
|
|
1885
|
+
* // Find stocks with >10% gains
|
|
1886
|
+
* const bigGainers = gainers.data.filter(stock => stock.changesPercentage > 10);
|
|
1887
|
+
* console.log(`Stocks with >10% gains: ${bigGainers.length}`);
|
|
1888
|
+
*
|
|
1889
|
+
* // Check volume leaders among gainers
|
|
1890
|
+
* const highVolumeGainers = gainers.data.filter(stock => stock.volume > 1000000);
|
|
1891
|
+
* console.log(`High volume gainers (>1M shares): ${highVolumeGainers.length}`);
|
|
1605
1892
|
* ```
|
|
1606
1893
|
*
|
|
1607
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
1894
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#biggest-gainers|FMP Market Biggest Gainers Documentation}
|
|
1608
1895
|
*/
|
|
1609
|
-
|
|
1896
|
+
getGainers(): Promise<APIResponse<MarketPerformance[]>>;
|
|
1610
1897
|
/**
|
|
1611
|
-
* Get
|
|
1612
|
-
*
|
|
1613
|
-
* Provides historical data on company employee counts over time.
|
|
1614
|
-
* Useful for analyzing company growth, operational efficiency, and workforce trends.
|
|
1615
|
-
* Employee count is often a key indicator of company expansion or contraction.
|
|
1898
|
+
* Get top losing stocks for the current trading day
|
|
1616
1899
|
*
|
|
1617
|
-
*
|
|
1900
|
+
* Provides a list of stocks that have lost the most value during the
|
|
1901
|
+
* current trading session. Essential for identifying underperforming stocks,
|
|
1902
|
+
* tracking market decliners, and discovering potential contrarian opportunities.
|
|
1903
|
+
* Useful for risk management, short selling strategies, and market analysis.
|
|
1618
1904
|
*
|
|
1619
|
-
* @returns Promise resolving to array of
|
|
1905
|
+
* @returns Promise resolving to array of top losing stocks with price and percentage change data
|
|
1620
1906
|
*
|
|
1621
1907
|
* @example
|
|
1622
1908
|
* ```typescript
|
|
1623
|
-
* // Get
|
|
1624
|
-
* const
|
|
1625
|
-
*
|
|
1626
|
-
*
|
|
1909
|
+
* // Get top losers for the day
|
|
1910
|
+
* const losers = await fmp.market.getLosers();
|
|
1911
|
+
* console.log(`Top ${losers.data.length} losing stocks today:`);
|
|
1912
|
+
*
|
|
1913
|
+
* losers.data.forEach((stock, index) => {
|
|
1914
|
+
* console.log(`${index + 1}. ${stock.symbol} (${stock.name})`);
|
|
1915
|
+
* console.log(` Price: $${stock.price} | Change: ${stock.change} (${stock.changesPercentage}%)`);
|
|
1916
|
+
* console.log(` Volume: ${stock.volume.toLocaleString()}`);
|
|
1627
1917
|
* });
|
|
1628
1918
|
*
|
|
1629
|
-
* //
|
|
1630
|
-
* const
|
|
1919
|
+
* // Find stocks with >10% losses
|
|
1920
|
+
* const bigLosers = losers.data.filter(stock => stock.changesPercentage < -10);
|
|
1921
|
+
* console.log(`Stocks with >10% losses: ${bigLosers.length}`);
|
|
1922
|
+
*
|
|
1923
|
+
* // Check for potential oversold conditions
|
|
1924
|
+
* const highVolumeLosers = losers.data.filter(stock => stock.volume > 1000000);
|
|
1925
|
+
* console.log(`High volume losers (>1M shares): ${highVolumeLosers.length}`);
|
|
1926
|
+
*
|
|
1927
|
+
* // Look for potential bounce candidates
|
|
1928
|
+
* const oversoldStocks = losers.data.filter(stock =>
|
|
1929
|
+
* stock.changesPercentage < -5 && stock.volume > 500000
|
|
1930
|
+
* );
|
|
1631
1931
|
* ```
|
|
1632
1932
|
*
|
|
1633
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
1933
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#biggest-losers|FMP Market Biggest Losers Documentation}
|
|
1634
1934
|
*/
|
|
1635
|
-
|
|
1935
|
+
getLosers(): Promise<APIResponse<MarketPerformance[]>>;
|
|
1636
1936
|
/**
|
|
1637
|
-
* Get current
|
|
1638
|
-
*
|
|
1639
|
-
* Provides the total number of shares that are publicly traded (float) for a company.
|
|
1640
|
-
* The float is calculated by subtracting restricted shares from total outstanding shares.
|
|
1641
|
-
* Important for understanding liquidity, volatility, and trading dynamics.
|
|
1937
|
+
* Get most actively traded stocks for the current trading day
|
|
1642
1938
|
*
|
|
1643
|
-
*
|
|
1939
|
+
* Provides a list of stocks with the highest trading volume during the
|
|
1940
|
+
* current trading session. Essential for identifying stocks with high
|
|
1941
|
+
* liquidity, tracking market interest, and discovering stocks with
|
|
1942
|
+
* significant trading activity. Useful for day trading and liquidity analysis.
|
|
1644
1943
|
*
|
|
1645
|
-
* @returns Promise resolving to
|
|
1944
|
+
* @returns Promise resolving to array of most active stocks with volume and price data
|
|
1646
1945
|
*
|
|
1647
1946
|
* @example
|
|
1648
1947
|
* ```typescript
|
|
1649
|
-
* // Get
|
|
1650
|
-
* const
|
|
1651
|
-
* console.log(`
|
|
1652
|
-
* console.log(`Outstanding: ${float.data.sharesOutstanding.toLocaleString()} shares`);
|
|
1653
|
-
* console.log(`Restricted: ${float.data.restrictedShares.toLocaleString()} shares`);
|
|
1948
|
+
* // Get most active stocks for the day
|
|
1949
|
+
* const mostActive = await fmp.market.getMostActive();
|
|
1950
|
+
* console.log(`Top ${mostActive.data.length} most active stocks today:`);
|
|
1654
1951
|
*
|
|
1655
|
-
*
|
|
1656
|
-
*
|
|
1952
|
+
* mostActive.data.forEach((stock, index) => {
|
|
1953
|
+
* console.log(`${index + 1}. ${stock.symbol} (${stock.name})`);
|
|
1954
|
+
* console.log(` Volume: ${stock.volume.toLocaleString()} shares`);
|
|
1955
|
+
* console.log(` Price: $${stock.price} | Change: ${stock.change} (${stock.changesPercentage}%)`);
|
|
1956
|
+
* console.log(` Avg Volume: ${stock.avgVolume?.toLocaleString() || 'N/A'}`);
|
|
1957
|
+
* });
|
|
1958
|
+
*
|
|
1959
|
+
* // Find stocks with unusual volume (>2x average)
|
|
1960
|
+
* const unusualVolume = mostActive.data.filter(stock =>
|
|
1961
|
+
* stock.avgVolume && stock.volume > stock.avgVolume * 2
|
|
1962
|
+
* );
|
|
1963
|
+
* console.log(`Stocks with unusual volume: ${unusualVolume.length}`);
|
|
1964
|
+
*
|
|
1965
|
+
* // Check for high volume gainers
|
|
1966
|
+
* const highVolumeGainers = mostActive.data.filter(stock =>
|
|
1967
|
+
* stock.changesPercentage > 0 && stock.volume > 1000000
|
|
1968
|
+
* );
|
|
1969
|
+
* console.log(`High volume gainers: ${highVolumeGainers.length}`);
|
|
1970
|
+
*
|
|
1971
|
+
* // Find penny stocks with high volume
|
|
1972
|
+
* const pennyStocks = mostActive.data.filter(stock =>
|
|
1973
|
+
* stock.price < 5 && stock.volume > 500000
|
|
1974
|
+
* );
|
|
1657
1975
|
* ```
|
|
1658
1976
|
*
|
|
1659
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#
|
|
1977
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#most-active|FMP Market Most Actives Documentation}
|
|
1660
1978
|
*/
|
|
1661
|
-
|
|
1979
|
+
getMostActive(): Promise<APIResponse<MarketPerformance[]>>;
|
|
1662
1980
|
/**
|
|
1663
|
-
* Get
|
|
1664
|
-
*
|
|
1665
|
-
* Provides historical data on company shares float over time.
|
|
1666
|
-
* Useful for analyzing changes in liquidity, share issuance, and corporate actions
|
|
1667
|
-
* that affect the number of publicly traded shares.
|
|
1981
|
+
* Get sector performance data for the current trading day
|
|
1668
1982
|
*
|
|
1669
|
-
*
|
|
1983
|
+
* Provides performance data for all major market sectors including
|
|
1984
|
+
* technology, healthcare, financials, energy, and others. Essential for
|
|
1985
|
+
* sector rotation analysis, identifying leading/lagging sectors, and
|
|
1986
|
+
* understanding market breadth and sector-specific trends.
|
|
1670
1987
|
*
|
|
1671
|
-
* @returns Promise resolving to array of
|
|
1988
|
+
* @returns Promise resolving to array of sector performance data with percentage changes
|
|
1672
1989
|
*
|
|
1673
1990
|
* @example
|
|
1674
1991
|
* ```typescript
|
|
1675
|
-
* // Get
|
|
1676
|
-
* const
|
|
1677
|
-
*
|
|
1678
|
-
*
|
|
1992
|
+
* // Get sector performance for the day
|
|
1993
|
+
* const sectorPerformance = await fmp.market.getSectorPerformance();
|
|
1994
|
+
* console.log(`Sector performance for ${sectorPerformance.data.length} sectors:`);
|
|
1995
|
+
*
|
|
1996
|
+
* sectorPerformance.data.forEach(sector => {
|
|
1997
|
+
* const changeColor = sector.changesPercentage >= 0 ? 'green' : 'red';
|
|
1998
|
+
* console.log(`${sector.sector}: ${sector.changesPercentage}%`);
|
|
1999
|
+
* console.log(` Change: ${sector.changesPercentage >= 0 ? '+' : ''}${sector.changesPercentage}%`);
|
|
1679
2000
|
* });
|
|
1680
2001
|
*
|
|
1681
|
-
* //
|
|
1682
|
-
* const
|
|
2002
|
+
* // Find best performing sectors
|
|
2003
|
+
* const topSectors = sectorPerformance.data
|
|
2004
|
+
* .sort((a, b) => b.changesPercentage - a.changesPercentage)
|
|
2005
|
+
* .slice(0, 3);
|
|
2006
|
+
* console.log('Top 3 performing sectors:');
|
|
2007
|
+
* topSectors.forEach((sector, index) => {
|
|
2008
|
+
* console.log(`${index + 1}. ${sector.sector}: ${sector.changesPercentage}%`);
|
|
2009
|
+
* });
|
|
2010
|
+
*
|
|
2011
|
+
* // Find worst performing sectors
|
|
2012
|
+
* const bottomSectors = sectorPerformance.data
|
|
2013
|
+
* .sort((a, b) => a.changesPercentage - b.changesPercentage)
|
|
2014
|
+
* .slice(0, 3);
|
|
2015
|
+
* console.log('Bottom 3 performing sectors:');
|
|
2016
|
+
* bottomSectors.forEach((sector, index) => {
|
|
2017
|
+
* console.log(`${index + 1}. ${sector.sector}: ${sector.changesPercentage}%`);
|
|
2018
|
+
* });
|
|
2019
|
+
*
|
|
2020
|
+
* // Check for sector rotation
|
|
2021
|
+
* const gainingSectors = sectorPerformance.data.filter(sector => sector.changesPercentage > 0);
|
|
2022
|
+
* const losingSectors = sectorPerformance.data.filter(sector => sector.changesPercentage < 0);
|
|
2023
|
+
* console.log(`Sectors gaining: ${gainingSectors.length}, Sectors losing: ${losingSectors.length}`);
|
|
1683
2024
|
* ```
|
|
1684
2025
|
*
|
|
1685
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2026
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#sector-performance-market-overview|FMP Sector Performance Documentation}
|
|
1686
2027
|
*/
|
|
1687
|
-
|
|
2028
|
+
getSectorPerformance(): Promise<APIResponse<MarketSectorPerformance[]>>;
|
|
1688
2029
|
/**
|
|
1689
|
-
* Get
|
|
1690
|
-
*
|
|
1691
|
-
* Provides the full transcript of a company's earnings conference call.
|
|
1692
|
-
* Contains detailed Q&A sessions, management commentary, and insights into
|
|
1693
|
-
* company performance, strategy, and future outlook.
|
|
2030
|
+
* Get real-time data for major market indices
|
|
1694
2031
|
*
|
|
1695
|
-
*
|
|
1696
|
-
*
|
|
1697
|
-
*
|
|
1698
|
-
*
|
|
2032
|
+
* Provides real-time quote data for all major stock market indices including
|
|
2033
|
+
* S&P 500, Dow Jones Industrial Average, NASDAQ Composite, and other global
|
|
2034
|
+
* indices. Essential for tracking overall market performance, understanding
|
|
2035
|
+
* market sentiment, and identifying broad market trends.
|
|
1699
2036
|
*
|
|
1700
|
-
* @returns Promise resolving to
|
|
2037
|
+
* @returns Promise resolving to array of market index data with real-time quotes
|
|
1701
2038
|
*
|
|
1702
2039
|
* @example
|
|
1703
2040
|
* ```typescript
|
|
1704
|
-
* // Get
|
|
1705
|
-
* const
|
|
1706
|
-
*
|
|
1707
|
-
* year: 2024,
|
|
1708
|
-
* quarter: 1
|
|
1709
|
-
* });
|
|
1710
|
-
* console.log(`Transcript: ${transcript.data[0].content.substring(0, 200)}...`);
|
|
2041
|
+
* // Get real-time market indices
|
|
2042
|
+
* const marketIndices = await fmp.market.getMarketIndex();
|
|
2043
|
+
* console.log(`Real-time data for ${marketIndices.data.length} major indices:`);
|
|
1711
2044
|
*
|
|
1712
|
-
*
|
|
1713
|
-
*
|
|
1714
|
-
*
|
|
1715
|
-
*
|
|
1716
|
-
*
|
|
2045
|
+
* marketIndices.data.forEach(index => {
|
|
2046
|
+
* console.log(`${index.symbol} (${index.name}):`);
|
|
2047
|
+
* console.log(` Price: $${index.price}`);
|
|
2048
|
+
* console.log(` Change: ${index.change} (${index.changesPercentage}%)`);
|
|
2049
|
+
* console.log(` Day Range: $${index.dayLow} - $${index.dayHigh}`);
|
|
2050
|
+
* console.log(` Volume: ${index.volume?.toLocaleString() || 'N/A'}`);
|
|
1717
2051
|
* });
|
|
2052
|
+
*
|
|
2053
|
+
* // Find specific major indices
|
|
2054
|
+
* const sp500 = marketIndices.data.find(index => index.symbol === '^GSPC');
|
|
2055
|
+
* const nasdaq = marketIndices.data.find(index => index.symbol === '^IXIC');
|
|
2056
|
+
* const dowJones = marketIndices.data.find(index => index.symbol === '^DJI');
|
|
2057
|
+
*
|
|
2058
|
+
* console.log(`S&P 500: ${sp500?.price} (${sp500?.changesPercentage}%)`);
|
|
2059
|
+
* console.log(`NASDAQ: ${nasdaq?.price} (${nasdaq?.changesPercentage}%)`);
|
|
2060
|
+
* console.log(`Dow Jones: ${dowJones?.price} (${dowJones?.changesPercentage}%)`);
|
|
2061
|
+
*
|
|
2062
|
+
* // Check market breadth
|
|
2063
|
+
* const gainingIndices = marketIndices.data.filter(index => index.changesPercentage > 0);
|
|
2064
|
+
* const losingIndices = marketIndices.data.filter(index => index.changesPercentage < 0);
|
|
2065
|
+
* console.log(`Indices gaining: ${gainingIndices.length}, Indices losing: ${losingIndices.length}`);
|
|
2066
|
+
*
|
|
2067
|
+
* // Find international indices
|
|
2068
|
+
* const internationalIndices = marketIndices.data.filter(index =>
|
|
2069
|
+
* !index.symbol.startsWith('^') ||
|
|
2070
|
+
* index.name.toLowerCase().includes('europe') ||
|
|
2071
|
+
* index.name.toLowerCase().includes('asia')
|
|
2072
|
+
* );
|
|
1718
2073
|
* ```
|
|
1719
2074
|
*
|
|
1720
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2075
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#market-index-market-overview|FMP Market Index Documentation}
|
|
1721
2076
|
*/
|
|
1722
|
-
|
|
1723
|
-
|
|
1724
|
-
|
|
1725
|
-
|
|
1726
|
-
|
|
2077
|
+
getMarketIndex(): Promise<APIResponse<MarketIndex[]>>;
|
|
2078
|
+
}
|
|
2079
|
+
|
|
2080
|
+
declare class MutualFundEndpoints {
|
|
2081
|
+
private client;
|
|
2082
|
+
constructor(client: FMPClient);
|
|
1727
2083
|
/**
|
|
1728
|
-
* Get
|
|
2084
|
+
* Get mutual fund holders of a specific stock
|
|
1729
2085
|
*
|
|
1730
|
-
* Provides
|
|
1731
|
-
*
|
|
1732
|
-
*
|
|
2086
|
+
* Provides data on mutual funds that hold shares in a specific stock.
|
|
2087
|
+
* Essential for understanding mutual fund ownership patterns and
|
|
2088
|
+
* which mutual funds are invested in particular companies.
|
|
1733
2089
|
*
|
|
1734
|
-
* @param symbol - The stock symbol to get
|
|
2090
|
+
* @param symbol - The stock symbol to get mutual fund holders for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
1735
2091
|
*
|
|
1736
|
-
* @returns Promise resolving to array of
|
|
2092
|
+
* @returns Promise resolving to array of mutual fund holders with position details
|
|
1737
2093
|
*
|
|
1738
2094
|
* @example
|
|
1739
2095
|
* ```typescript
|
|
1740
|
-
* // Get
|
|
1741
|
-
* const
|
|
1742
|
-
*
|
|
1743
|
-
*
|
|
2096
|
+
* // Get mutual funds that hold Apple stock
|
|
2097
|
+
* const appleHolders = await fmp.mutualFund.getHolders('AAPL');
|
|
2098
|
+
* console.log(`${appleHolders.data.length} mutual funds hold AAPL`);
|
|
2099
|
+
*
|
|
2100
|
+
* appleHolders.data.forEach((holder, index) => {
|
|
2101
|
+
* console.log(`${index + 1}. ${holder.holder}`);
|
|
2102
|
+
* console.log(` Shares: ${holder.shares?.toLocaleString() || 'N/A'}`);
|
|
2103
|
+
* console.log(` Weight: ${holder.weightPercent}% | Change: ${holder.change}`);
|
|
1744
2104
|
* });
|
|
1745
2105
|
*
|
|
1746
|
-
* // Get Microsoft
|
|
1747
|
-
* const
|
|
2106
|
+
* // Get mutual funds that hold Microsoft stock
|
|
2107
|
+
* const msftHolders = await fmp.mutualFund.getHolders('MSFT');
|
|
2108
|
+
*
|
|
2109
|
+
* // Find top mutual fund holders by shares
|
|
2110
|
+
* const topHolders = msftHolders.data
|
|
2111
|
+
* .sort((a, b) => (b.shares || 0) - (a.shares || 0))
|
|
2112
|
+
* .slice(0, 10);
|
|
2113
|
+
* console.log('Top 10 mutual fund holders by shares:');
|
|
2114
|
+
* topHolders.forEach((holder, index) => {
|
|
2115
|
+
* console.log(`${index + 1}. ${holder.holder}: ${holder.shares.toLocaleString()} shares`);
|
|
2116
|
+
* });
|
|
2117
|
+
*
|
|
2118
|
+
* // Get mutual funds that hold Google stock
|
|
2119
|
+
* const googlHolders = await fmp.mutualFund.getHolders('GOOGL');
|
|
2120
|
+
*
|
|
2121
|
+
* // Analyze mutual fund concentration
|
|
2122
|
+
* const totalShares = googlHolders.data.reduce((sum, holder) => sum + (holder.shares || 0), 0);
|
|
2123
|
+
* console.log(`Total shares held by mutual funds: ${totalShares.toLocaleString()}`);
|
|
2124
|
+
*
|
|
2125
|
+
* googlHolders.data.forEach(holder => {
|
|
2126
|
+
* const percentage = ((holder.shares || 0) / totalShares * 100).toFixed(2);
|
|
2127
|
+
* console.log(`${holder.holder}: ${percentage}% of total mutual fund holdings`);
|
|
2128
|
+
* });
|
|
1748
2129
|
* ```
|
|
1749
2130
|
*
|
|
1750
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2131
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#mutual-fund-holder-mutual-funds-holdings|FMP Mutual Fund Holders Documentation}
|
|
1751
2132
|
*/
|
|
1752
|
-
|
|
2133
|
+
getHolders(symbol: string): Promise<APIResponse<MutualFundHolding[]>>;
|
|
1753
2134
|
}
|
|
1754
2135
|
|
|
1755
2136
|
declare class QuoteEndpoints {
|
|
@@ -1865,1021 +2246,797 @@ declare class QuoteEndpoints {
|
|
|
1865
2246
|
* // Get 1-hour data for crypto
|
|
1866
2247
|
* const cryptoIntraday = await fmp.quote.getIntraday({
|
|
1867
2248
|
* symbol: 'BTCUSD',
|
|
1868
|
-
* interval: '1hour',
|
|
1869
|
-
* from: '2024-01-10',
|
|
1870
|
-
* to: '2024-01-15'
|
|
1871
|
-
* });
|
|
1872
|
-
* ```
|
|
1873
|
-
*/
|
|
1874
|
-
getIntraday(params: {
|
|
1875
|
-
symbol: string;
|
|
1876
|
-
interval: '1min' | '5min' | '15min' | '30min' | '1hour' | '4hour';
|
|
1877
|
-
from?: string;
|
|
1878
|
-
to?: string;
|
|
1879
|
-
}): Promise<APIResponse<HistoricalPriceData[]>>;
|
|
1880
|
-
}
|
|
1881
|
-
|
|
1882
|
-
declare class SenateHouseEndpoints {
|
|
1883
|
-
private client;
|
|
1884
|
-
constructor(client: FMPClient);
|
|
1885
|
-
/**
|
|
1886
|
-
* Get senate trading data for a specific stock symbol
|
|
1887
|
-
*
|
|
1888
|
-
* Provides detailed information about senate members' trading activities for a specific stock.
|
|
1889
|
-
* Includes transaction details, amounts, dates, and ownership information for transparency
|
|
1890
|
-
* and compliance with the STOCK Act (Stop Trading on Congressional Knowledge).
|
|
1891
|
-
*
|
|
1892
|
-
* @param params - Senate trading request parameters
|
|
1893
|
-
* @param params.symbol - The stock symbol to get senate trading data for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
1894
|
-
*
|
|
1895
|
-
* @returns Promise resolving to array of senate trading data with transaction details
|
|
1896
|
-
*
|
|
1897
|
-
* @example
|
|
1898
|
-
* ```typescript
|
|
1899
|
-
* // Get senate trading data for Apple
|
|
1900
|
-
* const appleSenateTrading = await fmp.senateHouse.getSenateTrading({ symbol: 'AAPL' });
|
|
1901
|
-
* appleSenateTrading.data.forEach(trade => {
|
|
1902
|
-
* console.log(`${trade.firstName} ${trade.lastName} (${trade.office}):`);
|
|
1903
|
-
* console.log(` ${trade.type} ${trade.amount} of ${trade.assetDescription}`);
|
|
1904
|
-
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
1905
|
-
* });
|
|
1906
|
-
*
|
|
1907
|
-
* // Get senate trading data for Tesla
|
|
1908
|
-
* const teslaSenateTrading = await fmp.senateHouse.getSenateTrading({ symbol: 'TSLA' });
|
|
1909
|
-
* ```
|
|
1910
|
-
*
|
|
1911
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#senate-trading|FMP Senate Trading Documentation}
|
|
1912
|
-
*/
|
|
1913
|
-
getSenateTrading(params: {
|
|
1914
|
-
symbol: string;
|
|
1915
|
-
}): Promise<APIResponse<SenateTradingResponse[]>>;
|
|
1916
|
-
/**
|
|
1917
|
-
* Get senate trading RSS feed with pagination
|
|
1918
|
-
*
|
|
1919
|
-
* Provides a paginated RSS feed of all senate trading activities across all stocks.
|
|
1920
|
-
* Useful for monitoring congressional trading activities, compliance tracking,
|
|
1921
|
-
* and transparency reporting. Returns recent trading disclosures from senate members.
|
|
1922
|
-
*
|
|
1923
|
-
* @param params - Senate trading RSS feed request parameters
|
|
1924
|
-
* @param params.page - The page number to retrieve (starts from 0)
|
|
1925
|
-
*
|
|
1926
|
-
* @returns Promise resolving to array of senate trading data from RSS feed
|
|
1927
|
-
*
|
|
1928
|
-
* @example
|
|
1929
|
-
* ```typescript
|
|
1930
|
-
* // Get first page of senate trading RSS feed
|
|
1931
|
-
* const firstPage = await fmp.senateHouse.getSenateTradingRSSFeed({ page: 0 });
|
|
1932
|
-
* console.log(`First page: ${firstPage.data.length} trading activities`);
|
|
1933
|
-
*
|
|
1934
|
-
* // Get second page of senate trading RSS feed
|
|
1935
|
-
* const secondPage = await fmp.senateHouse.getSenateTradingRSSFeed({ page: 1 });
|
|
1936
|
-
* console.log(`Second page: ${secondPage.data.length} trading activities`);
|
|
1937
|
-
*
|
|
1938
|
-
* // Get recent senate trading activities
|
|
1939
|
-
* const recentTrades = await fmp.senateHouse.getSenateTradingRSSFeed({ page: 0 });
|
|
1940
|
-
* recentTrades.data.forEach(trade => {
|
|
1941
|
-
* console.log(`${trade.firstName} ${trade.lastName}: ${trade.type} ${trade.amount}`);
|
|
1942
|
-
* });
|
|
1943
|
-
* ```
|
|
1944
|
-
*
|
|
1945
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#senate-trading-rss-feed-senate|FMP Senate Trading RSS Feed Documentation}
|
|
1946
|
-
*/
|
|
1947
|
-
getSenateTradingRSSFeed(params: {
|
|
1948
|
-
page: number;
|
|
1949
|
-
}): Promise<APIResponse<SenateTradingResponse[]>>;
|
|
1950
|
-
/**
|
|
1951
|
-
* Get senate trading data for a specific senator by name
|
|
1952
|
-
*
|
|
1953
|
-
* Provides detailed trading activities for a specific senate member across all stocks.
|
|
1954
|
-
* Useful for tracking individual senator's trading patterns, compliance monitoring,
|
|
1955
|
-
* and transparency reporting. Returns all trading disclosures for the specified senator.
|
|
1956
|
-
*
|
|
1957
|
-
* @param params - Senate trading by name request parameters
|
|
1958
|
-
* @param params.name - The name of the senator to get trading data for (e.g., 'John Smith', 'Jane Doe')
|
|
1959
|
-
*
|
|
1960
|
-
* @returns Promise resolving to array of senate trading data for the specified senator
|
|
1961
|
-
*
|
|
1962
|
-
* @example
|
|
1963
|
-
* ```typescript
|
|
1964
|
-
* // Get trading data for Senator John Smith
|
|
1965
|
-
* const johnSmithTrades = await fmp.senateHouse.getSenateTradingByName({ name: 'John Smith' });
|
|
1966
|
-
* johnSmithTrades.data.forEach(trade => {
|
|
1967
|
-
* console.log(`${trade.symbol}: ${trade.type} ${trade.amount}`);
|
|
1968
|
-
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
1969
|
-
* console.log(` Asset: ${trade.assetDescription}`);
|
|
1970
|
-
* });
|
|
1971
|
-
*
|
|
1972
|
-
* // Get trading data for Senator Jane Doe
|
|
1973
|
-
* const janeDoeTrades = await fmp.senateHouse.getSenateTradingByName({ name: 'Jane Doe' });
|
|
1974
|
-
* console.log(`Jane Doe has ${janeDoeTrades.data.length} trading activities`);
|
|
1975
|
-
* ```
|
|
1976
|
-
*
|
|
1977
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#senate-trading-by-name|FMP Senate Trading by Name Documentation}
|
|
1978
|
-
*/
|
|
1979
|
-
getSenateTradingByName(params: {
|
|
1980
|
-
name: string;
|
|
1981
|
-
}): Promise<APIResponse<SenateHouseTradingByNameResponse[]>>;
|
|
1982
|
-
/**
|
|
1983
|
-
* Get house trading data for a specific stock symbol
|
|
1984
|
-
*
|
|
1985
|
-
* Provides detailed information about house representatives' trading activities for a specific stock.
|
|
1986
|
-
* Includes transaction details, amounts, dates, and district information for transparency
|
|
1987
|
-
* and compliance with the STOCK Act (Stop Trading on Congressional Knowledge).
|
|
1988
|
-
*
|
|
1989
|
-
* @param params - House trading request parameters
|
|
1990
|
-
* @param params.symbol - The stock symbol to get house trading data for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
1991
|
-
*
|
|
1992
|
-
* @returns Promise resolving to array of house trading data with transaction details
|
|
1993
|
-
*
|
|
1994
|
-
* @example
|
|
1995
|
-
* ```typescript
|
|
1996
|
-
* // Get house trading data for Apple
|
|
1997
|
-
* const appleHouseTrading = await fmp.senateHouse.getHouseTrading({ symbol: 'AAPL' });
|
|
1998
|
-
* appleHouseTrading.data.forEach(trade => {
|
|
1999
|
-
* console.log(`${trade.representative} (District ${trade.district}):`);
|
|
2000
|
-
* console.log(` ${trade.type} ${trade.amount} of ${trade.assetDescription}`);
|
|
2001
|
-
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
2002
|
-
* });
|
|
2003
|
-
*
|
|
2004
|
-
* // Get house trading data for Microsoft
|
|
2005
|
-
* const msftHouseTrading = await fmp.senateHouse.getHouseTrading({ symbol: 'MSFT' });
|
|
2006
|
-
* console.log(`Microsoft house trading activities: ${msftHouseTrading.data.length}`);
|
|
2007
|
-
* ```
|
|
2008
|
-
*
|
|
2009
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#house-disclosure|FMP House Trading Documentation}
|
|
2010
|
-
*/
|
|
2011
|
-
getHouseTrading(params: {
|
|
2012
|
-
symbol: string;
|
|
2013
|
-
}): Promise<APIResponse<HouseTradingResponse[]>>;
|
|
2014
|
-
/**
|
|
2015
|
-
* Get house trading RSS feed with pagination
|
|
2016
|
-
*
|
|
2017
|
-
* Provides a paginated RSS feed of all house trading activities across all stocks.
|
|
2018
|
-
* Useful for monitoring congressional trading activities, compliance tracking,
|
|
2019
|
-
* and transparency reporting. Returns recent trading disclosures from house representatives.
|
|
2020
|
-
*
|
|
2021
|
-
* @param params - House trading RSS feed request parameters
|
|
2022
|
-
* @param params.page - The page number to retrieve (starts from 0)
|
|
2023
|
-
*
|
|
2024
|
-
* @returns Promise resolving to array of house trading data from RSS feed
|
|
2025
|
-
*
|
|
2026
|
-
* @example
|
|
2027
|
-
* ```typescript
|
|
2028
|
-
* // Get first page of house trading RSS feed
|
|
2029
|
-
* const firstPage = await fmp.senateHouse.getHouseTradingRSSFeed({ page: 0 });
|
|
2030
|
-
* console.log(`First page: ${firstPage.data.length} trading activities`);
|
|
2031
|
-
*
|
|
2032
|
-
* // Get second page of house trading RSS feed
|
|
2033
|
-
* const secondPage = await fmp.senateHouse.getHouseTradingRSSFeed({ page: 1 });
|
|
2034
|
-
* console.log(`Second page: ${secondPage.data.length} trading activities`);
|
|
2035
|
-
*
|
|
2036
|
-
* // Get recent house trading activities
|
|
2037
|
-
* const recentTrades = await fmp.senateHouse.getHouseTradingRSSFeed({ page: 0 });
|
|
2038
|
-
* recentTrades.data.forEach(trade => {
|
|
2039
|
-
* console.log(`${trade.representative} (District ${trade.district}): ${trade.type} ${trade.amount}`);
|
|
2040
|
-
* });
|
|
2041
|
-
* ```
|
|
2042
|
-
*
|
|
2043
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#house-disclosure-rss-feed-senate|FMP House Trading RSS Feed Documentation}
|
|
2044
|
-
*/
|
|
2045
|
-
getHouseTradingRSSFeed(params: {
|
|
2046
|
-
page: number;
|
|
2047
|
-
}): Promise<APIResponse<HouseTradingResponse[]>>;
|
|
2048
|
-
/**
|
|
2049
|
-
* Get house trading data for a specific representative by name
|
|
2050
|
-
*
|
|
2051
|
-
* Provides detailed trading activities for a specific house representative across all stocks.
|
|
2052
|
-
* Useful for tracking individual representative's trading patterns, compliance monitoring,
|
|
2053
|
-
* and transparency reporting. Returns all trading disclosures for the specified representative.
|
|
2054
|
-
*
|
|
2055
|
-
* @param params - House trading by name request parameters
|
|
2056
|
-
* @param params.name - The name of the representative to get trading data for (e.g., 'John Smith', 'Jane Doe')
|
|
2057
|
-
*
|
|
2058
|
-
* @returns Promise resolving to array of house trading data for the specified representative
|
|
2059
|
-
*
|
|
2060
|
-
* @example
|
|
2061
|
-
* ```typescript
|
|
2062
|
-
* // Get trading data for Representative John Smith
|
|
2063
|
-
* const johnSmithTrades = await fmp.senateHouse.getHouseTradingByName({ name: 'John Smith' });
|
|
2064
|
-
* johnSmithTrades.data.forEach(trade => {
|
|
2065
|
-
* console.log(`${trade.symbol}: ${trade.type} ${trade.amount}`);
|
|
2066
|
-
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
2067
|
-
* console.log(` Asset: ${trade.assetDescription}`);
|
|
2068
|
-
* console.log(` District: ${trade.district}`);
|
|
2249
|
+
* interval: '1hour',
|
|
2250
|
+
* from: '2024-01-10',
|
|
2251
|
+
* to: '2024-01-15'
|
|
2069
2252
|
* });
|
|
2070
|
-
*
|
|
2071
|
-
* // Get trading data for Representative Jane Doe
|
|
2072
|
-
* const janeDoeTrades = await fmp.senateHouse.getHouseTradingByName({ name: 'Jane Doe' });
|
|
2073
|
-
* console.log(`Jane Doe has ${janeDoeTrades.data.length} trading activities`);
|
|
2074
2253
|
* ```
|
|
2075
|
-
*
|
|
2076
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#house-trading-by-name|FMP House Trading by Name Documentation}
|
|
2077
2254
|
*/
|
|
2078
|
-
|
|
2079
|
-
|
|
2080
|
-
|
|
2255
|
+
getIntraday(params: {
|
|
2256
|
+
symbol: string;
|
|
2257
|
+
interval: '1min' | '5min' | '15min' | '30min' | '1hour' | '4hour';
|
|
2258
|
+
from?: string;
|
|
2259
|
+
to?: string;
|
|
2260
|
+
}): Promise<APIResponse<HistoricalPriceData[]>>;
|
|
2081
2261
|
}
|
|
2082
2262
|
|
|
2083
|
-
declare class
|
|
2263
|
+
declare class ScreenerEndpoints {
|
|
2084
2264
|
private client;
|
|
2085
2265
|
constructor(client: FMPClient);
|
|
2086
2266
|
/**
|
|
2087
|
-
*
|
|
2267
|
+
* Screen companies based on customizable financial criteria
|
|
2088
2268
|
*
|
|
2089
|
-
*
|
|
2090
|
-
*
|
|
2091
|
-
*
|
|
2269
|
+
* This endpoint allows you to filter and search for companies based on various financial metrics,
|
|
2270
|
+
* market data, and company characteristics. Perfect for finding investment opportunities,
|
|
2271
|
+
* conducting market research, or building custom stock filters.
|
|
2092
2272
|
*
|
|
2093
|
-
* @param params -
|
|
2094
|
-
* @param params.
|
|
2095
|
-
* @param params.
|
|
2273
|
+
* @param params - Screening criteria and filters
|
|
2274
|
+
* @param params.marketCapMoreThan - Minimum market capitalization
|
|
2275
|
+
* @param params.marketCapLowerThan - Maximum market capitalization
|
|
2276
|
+
* @param params.priceMoreThan - Minimum stock price
|
|
2277
|
+
* @param params.priceLowerThan - Maximum stock price
|
|
2278
|
+
* @param params.betaMoreThan - Minimum beta value
|
|
2279
|
+
* @param params.betaLowerThan - Maximum beta value
|
|
2280
|
+
* @param params.volumeMoreThan - Minimum trading volume
|
|
2281
|
+
* @param params.volumeLowerThan - Maximum trading volume
|
|
2282
|
+
* @param params.dividendMoreThan - Minimum dividend yield
|
|
2283
|
+
* @param params.dividendLowerThan - Maximum dividend yield
|
|
2284
|
+
* @param params.isEtf - Filter for ETFs only
|
|
2285
|
+
* @param params.isActivelyTrading - Filter for actively trading stocks
|
|
2286
|
+
* @param params.sector - Filter by specific sector
|
|
2287
|
+
* @param params.industry - Filter by specific industry
|
|
2288
|
+
* @param params.country - Filter by specific country
|
|
2289
|
+
* @param params.exchange - Filter by specific exchange
|
|
2290
|
+
* @param params.limit - Maximum number of results to return
|
|
2096
2291
|
*
|
|
2097
|
-
* @returns Promise resolving to array of
|
|
2292
|
+
* @returns Promise resolving to an array of companies matching the screening criteria
|
|
2098
2293
|
*
|
|
2099
2294
|
* @example
|
|
2100
2295
|
* ```typescript
|
|
2101
|
-
* //
|
|
2102
|
-
* const
|
|
2103
|
-
*
|
|
2104
|
-
*
|
|
2105
|
-
*
|
|
2106
|
-
*
|
|
2296
|
+
* // Find large-cap tech stocks
|
|
2297
|
+
* const techStocks = await fmp.screener.getScreener({
|
|
2298
|
+
* marketCapMoreThan: 10000000000, // $10B+
|
|
2299
|
+
* sector: 'Technology',
|
|
2300
|
+
* isActivelyTrading: true,
|
|
2301
|
+
* limit: 50
|
|
2107
2302
|
* });
|
|
2108
2303
|
*
|
|
2109
|
-
* //
|
|
2110
|
-
* const
|
|
2111
|
-
*
|
|
2112
|
-
*
|
|
2304
|
+
* // Find dividend-paying stocks
|
|
2305
|
+
* const dividendStocks = await fmp.screener.getScreener({
|
|
2306
|
+
* dividendMoreThan: 0.03, // 3%+ dividend yield
|
|
2307
|
+
* marketCapMoreThan: 1000000000, // $1B+ market cap
|
|
2308
|
+
* isActivelyTrading: true
|
|
2113
2309
|
* });
|
|
2114
2310
|
*
|
|
2115
|
-
* //
|
|
2116
|
-
* const
|
|
2117
|
-
*
|
|
2311
|
+
* // Find small-cap value stocks
|
|
2312
|
+
* const smallCapValue = await fmp.screener.getScreener({
|
|
2313
|
+
* marketCapLowerThan: 2000000000, // Under $2B
|
|
2314
|
+
* priceMoreThan: 5, // Above $5
|
|
2315
|
+
* betaLowerThan: 1.2, // Lower volatility
|
|
2316
|
+
* limit: 100
|
|
2118
2317
|
* });
|
|
2119
2318
|
* ```
|
|
2120
|
-
*
|
|
2121
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#form-13f-13f---institutional-stock-ownership|FMP Form 13F Documentation}
|
|
2319
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#search-company-screener|FMP Income Statement Documentation}
|
|
2122
2320
|
*/
|
|
2123
|
-
|
|
2124
|
-
cik: string;
|
|
2125
|
-
date?: string;
|
|
2126
|
-
}): Promise<APIResponse<Form13FResponse[]>>;
|
|
2321
|
+
getScreener(params: ScreenerParams): Promise<APIResponse<Screener[]>>;
|
|
2127
2322
|
/**
|
|
2128
|
-
* Get
|
|
2129
|
-
*
|
|
2130
|
-
* Provides available filing dates for Form 13F submissions by a specific
|
|
2131
|
-
* investment manager. Essential for discovering historical filing dates
|
|
2132
|
-
* before requesting detailed Form 13F data.
|
|
2323
|
+
* Get list of available stock exchanges for screening
|
|
2133
2324
|
*
|
|
2134
|
-
*
|
|
2135
|
-
*
|
|
2325
|
+
* Retrieves all supported stock exchanges that can be used as filters
|
|
2326
|
+
* in the company screener. Useful for building dynamic filter options
|
|
2327
|
+
* or validating exchange parameters.
|
|
2136
2328
|
*
|
|
2137
|
-
* @returns Promise resolving to array of available
|
|
2329
|
+
* @returns Promise resolving to an array of available exchanges with their details
|
|
2138
2330
|
*
|
|
2139
2331
|
* @example
|
|
2140
2332
|
* ```typescript
|
|
2141
|
-
* // Get
|
|
2142
|
-
* const
|
|
2143
|
-
* cik: '0001067983'
|
|
2144
|
-
* });
|
|
2145
|
-
* berkshireDates.data.forEach(date => {
|
|
2146
|
-
* console.log(`Filing date: ${date}`);
|
|
2147
|
-
* });
|
|
2333
|
+
* // Get all available exchanges
|
|
2334
|
+
* const exchanges = await fmp.screener.getAvailableExchanges();
|
|
2148
2335
|
*
|
|
2149
|
-
* //
|
|
2150
|
-
* const
|
|
2151
|
-
*
|
|
2336
|
+
* // Use in screener filter
|
|
2337
|
+
* const nasdaqStocks = await fmp.screener.getScreener({
|
|
2338
|
+
* exchange: 'NASDAQ',
|
|
2339
|
+
* marketCapMoreThan: 1000000000
|
|
2152
2340
|
* });
|
|
2153
2341
|
* ```
|
|
2154
|
-
*
|
|
2155
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#form-13f-dates-13f---institutional-stock-ownership|FMP Form 13F Dates Documentation}
|
|
2342
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#available-exchanges|FMP Income Statement Documentation}
|
|
2156
2343
|
*/
|
|
2157
|
-
|
|
2158
|
-
cik: string;
|
|
2159
|
-
}): Promise<APIResponse<string[]>>;
|
|
2344
|
+
getAvailableExchanges(): Promise<APIResponse<AvailableExchanges[]>>;
|
|
2160
2345
|
/**
|
|
2161
|
-
* Get
|
|
2162
|
-
*
|
|
2163
|
-
* Provides data on institutional investors holding shares in a specific
|
|
2164
|
-
* company. Essential for understanding institutional ownership patterns,
|
|
2165
|
-
* major shareholders, and investment sentiment.
|
|
2346
|
+
* Get list of available sectors for screening
|
|
2166
2347
|
*
|
|
2167
|
-
*
|
|
2168
|
-
*
|
|
2348
|
+
* Retrieves all supported business sectors that can be used as filters
|
|
2349
|
+
* in the company screener. Essential for sector-based analysis and
|
|
2350
|
+
* building comprehensive screening tools.
|
|
2169
2351
|
*
|
|
2170
|
-
* @returns Promise resolving to array of
|
|
2352
|
+
* @returns Promise resolving to an array of available sectors with their details
|
|
2171
2353
|
*
|
|
2172
2354
|
* @example
|
|
2173
2355
|
* ```typescript
|
|
2174
|
-
* // Get
|
|
2175
|
-
* const
|
|
2176
|
-
* symbol: 'AAPL'
|
|
2177
|
-
* });
|
|
2178
|
-
* appleHolders.data.forEach(holder => {
|
|
2179
|
-
* console.log(`${holder.holder}: ${holder.shares.toLocaleString()} shares (${holder.weight}%)`);
|
|
2180
|
-
* });
|
|
2356
|
+
* // Get all available sectors
|
|
2357
|
+
* const sectors = await fmp.screener.getAvailableSectors();
|
|
2181
2358
|
*
|
|
2182
|
-
* //
|
|
2183
|
-
* const
|
|
2184
|
-
*
|
|
2359
|
+
* // Screen by specific sector
|
|
2360
|
+
* const healthcareStocks = await fmp.screener.getScreener({
|
|
2361
|
+
* sector: 'Healthcare',
|
|
2362
|
+
* marketCapMoreThan: 5000000000
|
|
2185
2363
|
* });
|
|
2364
|
+
* ```
|
|
2365
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#available-sectors|FMP Income Statement Documentation}
|
|
2366
|
+
*/
|
|
2367
|
+
getAvailableSectors(): Promise<APIResponse<AvailableSectors[]>>;
|
|
2368
|
+
/**
|
|
2369
|
+
* Get list of available industries for screening
|
|
2186
2370
|
*
|
|
2187
|
-
*
|
|
2188
|
-
*
|
|
2189
|
-
*
|
|
2371
|
+
* Retrieves all supported industries that can be used as filters
|
|
2372
|
+
* in the company screener. Provides more granular filtering than
|
|
2373
|
+
* sectors for detailed industry analysis.
|
|
2374
|
+
*
|
|
2375
|
+
* @returns Promise resolving to an array of available industries with their details
|
|
2376
|
+
*
|
|
2377
|
+
* @example
|
|
2378
|
+
* ```typescript
|
|
2379
|
+
* // Get all available industries
|
|
2380
|
+
* const industries = await fmp.screener.getAvailableIndustries();
|
|
2381
|
+
*
|
|
2382
|
+
* // Screen by specific industry
|
|
2383
|
+
* const softwareStocks = await fmp.screener.getScreener({
|
|
2384
|
+
* industry: 'Software—Application',
|
|
2385
|
+
* isActivelyTrading: true,
|
|
2386
|
+
* limit: 25
|
|
2190
2387
|
* });
|
|
2191
2388
|
* ```
|
|
2192
|
-
*
|
|
2193
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#institutional-holder-13f---institutional-stock-ownership|FMP Institutional Holders Documentation}
|
|
2389
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#available-industries|FMP Income Statement Documentation}
|
|
2194
2390
|
*/
|
|
2195
|
-
|
|
2196
|
-
symbol: string;
|
|
2197
|
-
}): Promise<APIResponse<InstitutionalHolderResponse[]>>;
|
|
2198
|
-
}
|
|
2199
|
-
|
|
2200
|
-
declare class InsiderEndpoints {
|
|
2201
|
-
private client;
|
|
2202
|
-
constructor(client: FMPClient);
|
|
2391
|
+
getAvailableIndustries(): Promise<APIResponse<AvailableIndustries[]>>;
|
|
2203
2392
|
/**
|
|
2204
|
-
* Get
|
|
2205
|
-
*
|
|
2206
|
-
* Provides real-time RSS feed of insider trading activities across all
|
|
2207
|
-
* publicly traded companies. Essential for monitoring insider trading
|
|
2208
|
-
* patterns, corporate governance, and potential market-moving events.
|
|
2393
|
+
* Get list of available countries for screening
|
|
2209
2394
|
*
|
|
2210
|
-
*
|
|
2211
|
-
*
|
|
2395
|
+
* Retrieves all supported countries that can be used as filters
|
|
2396
|
+
* in the company screener. Useful for geographic analysis and
|
|
2397
|
+
* international market screening.
|
|
2212
2398
|
*
|
|
2213
|
-
* @returns Promise resolving to array of
|
|
2399
|
+
* @returns Promise resolving to an array of available countries with their details
|
|
2214
2400
|
*
|
|
2215
2401
|
* @example
|
|
2216
2402
|
* ```typescript
|
|
2217
|
-
* // Get
|
|
2218
|
-
* const
|
|
2219
|
-
* rssFeed.data.forEach(trade => {
|
|
2220
|
-
* console.log(`${trade.date}: ${trade.symbol} - ${trade.insiderName} ${trade.transactionType}`);
|
|
2221
|
-
* });
|
|
2403
|
+
* // Get all available countries
|
|
2404
|
+
* const countries = await fmp.screener.getAvailableCountries();
|
|
2222
2405
|
*
|
|
2223
|
-
* //
|
|
2224
|
-
* const
|
|
2406
|
+
* // Screen by specific country
|
|
2407
|
+
* const usStocks = await fmp.screener.getScreener({
|
|
2408
|
+
* country: 'US',
|
|
2409
|
+
* marketCapMoreThan: 1000000000,
|
|
2410
|
+
* isActivelyTrading: true
|
|
2411
|
+
* });
|
|
2225
2412
|
* ```
|
|
2226
|
-
*
|
|
2227
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#insider-trades-rss-insider-trading|FMP Insider Trading RSS Documentation}
|
|
2413
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#available-countries|FMP Income Statement Documentation}
|
|
2228
2414
|
*/
|
|
2229
|
-
|
|
2230
|
-
|
|
2231
|
-
|
|
2415
|
+
getAvailableCountries(): Promise<APIResponse<AvailableCountries[]>>;
|
|
2416
|
+
}
|
|
2417
|
+
|
|
2418
|
+
declare class SECEndpoints {
|
|
2419
|
+
private client;
|
|
2420
|
+
constructor(client: FMPClient);
|
|
2232
2421
|
/**
|
|
2233
|
-
*
|
|
2234
|
-
*
|
|
2235
|
-
* Provides comprehensive insider trading data with multiple filtering options
|
|
2236
|
-
* including symbol, CIK numbers, and transaction types. Essential for detailed
|
|
2237
|
-
* analysis of insider trading patterns and corporate governance.
|
|
2422
|
+
* Get RSS feed of SEC filings
|
|
2238
2423
|
*
|
|
2239
|
-
*
|
|
2240
|
-
*
|
|
2241
|
-
*
|
|
2242
|
-
*
|
|
2243
|
-
* @param params.transactionType - Transaction type to filter by (optional)
|
|
2244
|
-
* @param params.page - Page number for pagination (default: 0)
|
|
2424
|
+
* Provides a real-time feed of SEC filings from publicly traded companies,
|
|
2425
|
+
* including filing types, links to SEC pages, and direct links to filings.
|
|
2426
|
+
* Essential for staying up-to-date on the latest SEC filings for all companies
|
|
2427
|
+
* or for monitoring specific companies' regulatory activities.
|
|
2245
2428
|
*
|
|
2246
|
-
* @
|
|
2429
|
+
* @param params - RSS feed parameters (optional)
|
|
2430
|
+
* @returns Promise resolving to array of RSS feed items with SEC filing information
|
|
2247
2431
|
*
|
|
2248
2432
|
* @example
|
|
2249
2433
|
* ```typescript
|
|
2250
|
-
* //
|
|
2251
|
-
* const
|
|
2252
|
-
*
|
|
2253
|
-
* page: 0
|
|
2254
|
-
* });
|
|
2255
|
-
* appleTrades.data.forEach(trade => {
|
|
2256
|
-
* console.log(`${trade.date}: ${trade.insiderName} - ${trade.transactionType} ${trade.sharesTraded} shares`);
|
|
2257
|
-
* });
|
|
2434
|
+
* // Get all recent SEC filings
|
|
2435
|
+
* const allFilings = await fmp.sec.getRSSFeed();
|
|
2436
|
+
* console.log(`Recent SEC filings: ${allFilings.data.length}`);
|
|
2258
2437
|
*
|
|
2259
|
-
* //
|
|
2260
|
-
* const
|
|
2261
|
-
*
|
|
2262
|
-
* page: 0
|
|
2263
|
-
* });
|
|
2438
|
+
* // Get specific filing type
|
|
2439
|
+
* const form4Filings = await fmp.sec.getRSSFeed({ type: '4' });
|
|
2440
|
+
* console.log(`Form 4 filings: ${form4Filings.data.length}`);
|
|
2264
2441
|
*
|
|
2265
|
-
* //
|
|
2266
|
-
* const
|
|
2267
|
-
*
|
|
2268
|
-
*
|
|
2442
|
+
* // Get filings with date range
|
|
2443
|
+
* const recentFilings = await fmp.sec.getRSSFeed({
|
|
2444
|
+
* from: '2024-01-01',
|
|
2445
|
+
* to: '2024-01-31'
|
|
2269
2446
|
* });
|
|
2447
|
+
* console.log(`Recent filings: ${recentFilings.data.length}`);
|
|
2448
|
+
*
|
|
2449
|
+
* // Get limited results
|
|
2450
|
+
* const limitedFilings = await fmp.sec.getRSSFeed({ limit: 10 });
|
|
2451
|
+
* console.log(`Limited filings: ${limitedFilings.data.length}`);
|
|
2270
2452
|
* ```
|
|
2271
2453
|
*
|
|
2272
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2454
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#rss-feed-securities-and-exchange-commission-(s.e.c)|FMP RSS Feed Documentation}
|
|
2273
2455
|
*/
|
|
2274
|
-
|
|
2275
|
-
|
|
2276
|
-
|
|
2277
|
-
|
|
2278
|
-
|
|
2279
|
-
|
|
2280
|
-
}): Promise<APIResponse<
|
|
2456
|
+
getRSSFeed(params?: {
|
|
2457
|
+
limit?: number;
|
|
2458
|
+
type?: string;
|
|
2459
|
+
from?: string;
|
|
2460
|
+
to?: string;
|
|
2461
|
+
isDone?: boolean;
|
|
2462
|
+
}): Promise<APIResponse<RSSFeedItem[]>>;
|
|
2281
2463
|
/**
|
|
2282
|
-
* Get all
|
|
2464
|
+
* Get comprehensive RSS feed of all SEC filings
|
|
2283
2465
|
*
|
|
2284
|
-
* Provides a comprehensive
|
|
2285
|
-
*
|
|
2286
|
-
*
|
|
2466
|
+
* Provides a comprehensive real-time feed of all SEC filings from publicly
|
|
2467
|
+
* traded companies in the latest RSS feed format. This endpoint offers the
|
|
2468
|
+
* most complete overview of SEC filings with enhanced metadata and formatting.
|
|
2287
2469
|
*
|
|
2288
|
-
* @
|
|
2470
|
+
* @param params - RSS feed all parameters (optional)
|
|
2471
|
+
* @returns Promise resolving to array of comprehensive RSS feed items with enhanced SEC filing information
|
|
2289
2472
|
*
|
|
2290
2473
|
* @example
|
|
2291
2474
|
* ```typescript
|
|
2292
|
-
* // Get all
|
|
2293
|
-
* const
|
|
2294
|
-
*
|
|
2295
|
-
*
|
|
2296
|
-
*
|
|
2475
|
+
* // Get all comprehensive SEC filings
|
|
2476
|
+
* const allFilings = await fmp.sec.getRSSFeedAll();
|
|
2477
|
+
* console.log(`Comprehensive SEC filings: ${allFilings.data.length}`);
|
|
2478
|
+
*
|
|
2479
|
+
* // Get paginated results
|
|
2480
|
+
* const page2Filings = await fmp.sec.getRSSFeedAll({ page: 1 });
|
|
2481
|
+
* console.log(`Page 2 filings: ${page2Filings.data.length}`);
|
|
2482
|
+
*
|
|
2483
|
+
* // Get specific data type
|
|
2484
|
+
* const specificData = await fmp.sec.getRSSFeedAll({ datatype: 'json' });
|
|
2485
|
+
* console.log(`Specific data type filings: ${specificData.data.length}`);
|
|
2297
2486
|
* ```
|
|
2298
2487
|
*
|
|
2299
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2488
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#rss-feed-all-securities-and-exchange-commission-(s.e.c)|FMP RSS Feed All Documentation}
|
|
2300
2489
|
*/
|
|
2301
|
-
|
|
2490
|
+
getRSSFeedAll(params?: {
|
|
2491
|
+
page?: number;
|
|
2492
|
+
datatype?: string;
|
|
2493
|
+
}): Promise<APIResponse<RSSFeedAllItem[]>>;
|
|
2302
2494
|
/**
|
|
2303
|
-
* Get
|
|
2304
|
-
*
|
|
2305
|
-
* Provides a list of all insiders (officers, directors, and beneficial owners)
|
|
2306
|
-
* for a specific company. Essential for understanding corporate governance
|
|
2307
|
-
* structure and identifying key personnel.
|
|
2495
|
+
* Get RSS feed V3 of SEC filings
|
|
2308
2496
|
*
|
|
2309
|
-
*
|
|
2310
|
-
*
|
|
2497
|
+
* Provides a real-time feed of SEC filings from publicly traded companies
|
|
2498
|
+
* in the V3 RSS feed format. This version offers enhanced metadata and
|
|
2499
|
+
* improved structure for better parsing and analysis of SEC filings.
|
|
2311
2500
|
*
|
|
2312
|
-
* @
|
|
2501
|
+
* @param params - RSS feed V3 parameters (optional)
|
|
2502
|
+
* @returns Promise resolving to array of V3 RSS feed items with enhanced SEC filing information
|
|
2313
2503
|
*
|
|
2314
2504
|
* @example
|
|
2315
2505
|
* ```typescript
|
|
2316
|
-
* // Get
|
|
2317
|
-
* const
|
|
2318
|
-
*
|
|
2319
|
-
* console.log(`${insider.name} - ${insider.title} (${insider.cik})`);
|
|
2320
|
-
* });
|
|
2506
|
+
* // Get V3 format SEC filings
|
|
2507
|
+
* const v3Filings = await fmp.sec.getRSSFeedV3();
|
|
2508
|
+
* console.log(`V3 SEC filings: ${v3Filings.data.length}`);
|
|
2321
2509
|
*
|
|
2322
|
-
* // Get
|
|
2323
|
-
* const
|
|
2510
|
+
* // Get paginated V3 results
|
|
2511
|
+
* const page2V3 = await fmp.sec.getRSSFeedV3({ page: 1 });
|
|
2512
|
+
* console.log(`Page 2 V3 filings: ${page2V3.data.length}`);
|
|
2513
|
+
*
|
|
2514
|
+
* // Get specific data type
|
|
2515
|
+
* const specificV3 = await fmp.sec.getRSSFeedV3({ datatype: 'json' });
|
|
2516
|
+
* console.log(`Specific V3 data type: ${specificV3.data.length}`);
|
|
2324
2517
|
* ```
|
|
2325
2518
|
*
|
|
2326
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2519
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#rss-feed-v3-securities-and-exchange-commission-(s.e.c)|FMP RSS Feed V3 Documentation}
|
|
2327
2520
|
*/
|
|
2328
|
-
|
|
2329
|
-
|
|
2330
|
-
|
|
2521
|
+
getRSSFeedV3(params?: {
|
|
2522
|
+
page?: number;
|
|
2523
|
+
datatype?: string;
|
|
2524
|
+
}): Promise<APIResponse<RSSFeedV3Item[]>>;
|
|
2331
2525
|
/**
|
|
2332
|
-
* Get
|
|
2333
|
-
*
|
|
2334
|
-
* Provides comprehensive statistics on insider trading activity for a
|
|
2335
|
-
* specific company including total trades, volume, and value metrics.
|
|
2336
|
-
* Essential for analyzing insider trading patterns and sentiment.
|
|
2526
|
+
* Get RSS feed of 8-K SEC filings
|
|
2337
2527
|
*
|
|
2338
|
-
*
|
|
2339
|
-
*
|
|
2528
|
+
* Provides a real-time feed specifically for 8-K SEC filings from publicly
|
|
2529
|
+
* traded companies. 8-K filings are used to announce major events that
|
|
2530
|
+
* shareholders should know about, such as earnings releases, mergers,
|
|
2531
|
+
* acquisitions, and other material events.
|
|
2340
2532
|
*
|
|
2341
|
-
* @
|
|
2533
|
+
* @param params - RSS feed 8-K parameters (optional)
|
|
2534
|
+
* @returns Promise resolving to array of 8-K RSS feed items with material event information
|
|
2342
2535
|
*
|
|
2343
2536
|
* @example
|
|
2344
2537
|
* ```typescript
|
|
2345
|
-
* // Get
|
|
2346
|
-
* const
|
|
2347
|
-
*
|
|
2348
|
-
*
|
|
2538
|
+
* // Get all 8-K filings
|
|
2539
|
+
* const form8KFilings = await fmp.sec.getRSSFeed8K();
|
|
2540
|
+
* console.log(`8-K filings: ${form8KFilings.data.length}`);
|
|
2541
|
+
*
|
|
2542
|
+
* // Get 8-K filings with date range
|
|
2543
|
+
* const recent8K = await fmp.sec.getRSSFeed8K({
|
|
2544
|
+
* from: '2024-01-01',
|
|
2545
|
+
* to: '2024-01-31'
|
|
2349
2546
|
* });
|
|
2547
|
+
* console.log(`Recent 8-K filings: ${recent8K.data.length}`);
|
|
2350
2548
|
*
|
|
2351
|
-
* // Get
|
|
2352
|
-
* const
|
|
2549
|
+
* // Get 8-K filings with financials
|
|
2550
|
+
* const financial8K = await fmp.sec.getRSSFeed8K({ hasFinancial: true });
|
|
2551
|
+
* console.log(`8-K filings with financials: ${financial8K.data.length}`);
|
|
2552
|
+
*
|
|
2553
|
+
* // Get limited 8-K results
|
|
2554
|
+
* const limited8K = await fmp.sec.getRSSFeed8K({ limit: 10 });
|
|
2555
|
+
* console.log(`Limited 8-K filings: ${limited8K.data.length}`);
|
|
2353
2556
|
* ```
|
|
2354
2557
|
*
|
|
2355
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2558
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#rss-feed-8-k-securities-and-exchange-commission-(s.e.c)|FMP RSS Feed 8-K Documentation}
|
|
2356
2559
|
*/
|
|
2357
|
-
|
|
2358
|
-
|
|
2359
|
-
|
|
2560
|
+
getRSSFeed8K(params?: {
|
|
2561
|
+
page?: number;
|
|
2562
|
+
from?: string;
|
|
2563
|
+
to?: string;
|
|
2564
|
+
hasFinancial?: boolean;
|
|
2565
|
+
limit?: number;
|
|
2566
|
+
}): Promise<APIResponse<RSSFeed8KItem[]>>;
|
|
2360
2567
|
/**
|
|
2361
|
-
* Get
|
|
2362
|
-
*
|
|
2363
|
-
* Provides a mapping between CIK (Central Index Key) numbers and company
|
|
2364
|
-
* names. Essential for converting between CIK numbers and company
|
|
2365
|
-
* identifiers in insider trading analysis.
|
|
2568
|
+
* Get SEC filings for a specific company
|
|
2366
2569
|
*
|
|
2367
|
-
*
|
|
2368
|
-
*
|
|
2570
|
+
* Provides direct access to SEC filings for a specific company, including
|
|
2571
|
+
* filing types, links to SEC pages, and direct links to specific filings.
|
|
2572
|
+
* Essential for monitoring a company's regulatory compliance and staying
|
|
2573
|
+
* informed about important corporate events and disclosures.
|
|
2369
2574
|
*
|
|
2370
|
-
* @
|
|
2575
|
+
* @param symbol - The stock symbol to get SEC filings for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
2576
|
+
* @param params - SEC filings parameters (optional)
|
|
2577
|
+
* @returns Promise resolving to array of SEC filings with detailed filing information
|
|
2371
2578
|
*
|
|
2372
2579
|
* @example
|
|
2373
2580
|
* ```typescript
|
|
2374
|
-
* // Get
|
|
2375
|
-
* const
|
|
2376
|
-
*
|
|
2377
|
-
* console.log(`CIK: ${mapping.cik} - Company: ${mapping.name}`);
|
|
2378
|
-
* });
|
|
2581
|
+
* // Get all SEC filings for Apple
|
|
2582
|
+
* const appleFilings = await fmp.sec.getSECFilings({ symbol: 'AAPL' });
|
|
2583
|
+
* console.log(`Apple SEC filings: ${appleFilings.data.length}`);
|
|
2379
2584
|
*
|
|
2380
|
-
* // Get
|
|
2381
|
-
* const
|
|
2585
|
+
* // Get specific filing type for Microsoft
|
|
2586
|
+
* const msftForm4 = await fmp.sec.getSECFilings({
|
|
2587
|
+
* symbol: 'MSFT',
|
|
2588
|
+
* params: { type: '4' }
|
|
2589
|
+
* });
|
|
2590
|
+
* console.log(`Microsoft Form 4 filings: ${msftForm4.data.length}`);
|
|
2382
2591
|
* ```
|
|
2383
2592
|
*
|
|
2384
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2593
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#sec-filings-securities-and-exchange-commission-(s.e.c)|FMP SEC Filings Documentation}
|
|
2385
2594
|
*/
|
|
2386
|
-
|
|
2387
|
-
|
|
2388
|
-
|
|
2595
|
+
getSECFilings({ symbol, params, }: {
|
|
2596
|
+
symbol: string;
|
|
2597
|
+
params?: {
|
|
2598
|
+
type?: string;
|
|
2599
|
+
page?: number;
|
|
2600
|
+
};
|
|
2601
|
+
}): Promise<APIResponse<SECFiling[]>>;
|
|
2389
2602
|
/**
|
|
2390
|
-
* Get
|
|
2391
|
-
*
|
|
2392
|
-
* Provides CIK numbers and company names matching a search term.
|
|
2393
|
-
* Useful for finding companies by partial name matches and
|
|
2394
|
-
* converting company names to CIK numbers.
|
|
2603
|
+
* Get individual industry classification for a company
|
|
2395
2604
|
*
|
|
2396
|
-
*
|
|
2397
|
-
*
|
|
2398
|
-
*
|
|
2605
|
+
* Provides the industry classification for a specific company based on the
|
|
2606
|
+
* Standard Industrial Classification (SIC) system. Essential for understanding
|
|
2607
|
+
* a company's business sector, industry peers, and market positioning.
|
|
2399
2608
|
*
|
|
2400
|
-
* @
|
|
2609
|
+
* @param params - Industry classification parameters
|
|
2610
|
+
* @returns Promise resolving to industry classification data with SIC code and description
|
|
2401
2611
|
*
|
|
2402
2612
|
* @example
|
|
2403
2613
|
* ```typescript
|
|
2404
|
-
* //
|
|
2405
|
-
* const
|
|
2406
|
-
*
|
|
2407
|
-
*
|
|
2408
|
-
* });
|
|
2409
|
-
* appleCik.data.forEach(mapping => {
|
|
2410
|
-
* console.log(`CIK: ${mapping.cik} - Company: ${mapping.name}`);
|
|
2411
|
-
* });
|
|
2614
|
+
* // Get Apple's industry classification by symbol
|
|
2615
|
+
* const appleIndustry = await fmp.sec.getIndividualIndustryClassification({ symbol: 'AAPL' });
|
|
2616
|
+
* console.log(`Apple Industry: ${appleIndustry.data.industryTitle}`);
|
|
2617
|
+
* console.log(`SIC Code: ${appleIndustry.data.sicCode}`);
|
|
2412
2618
|
*
|
|
2413
|
-
* //
|
|
2414
|
-
* const
|
|
2415
|
-
*
|
|
2416
|
-
*
|
|
2417
|
-
*
|
|
2619
|
+
* // Get industry classification by CIK
|
|
2620
|
+
* const cikIndustry = await fmp.sec.getIndividualIndustryClassification({ cik: 320193 });
|
|
2621
|
+
* console.log(`CIK Industry: ${cikIndustry.data.industryTitle}`);
|
|
2622
|
+
*
|
|
2623
|
+
* // Get industry classification by SIC code
|
|
2624
|
+
* const sicIndustry = await fmp.sec.getIndividualIndustryClassification({ sicCode: 3571 });
|
|
2625
|
+
* console.log(`SIC Industry: ${sicIndustry.data.industryTitle}`);
|
|
2418
2626
|
* ```
|
|
2419
2627
|
*
|
|
2420
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2628
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#individual-industry-classification-standard-industrial-classification|FMP Individual Industry Classification Documentation}
|
|
2421
2629
|
*/
|
|
2422
|
-
|
|
2423
|
-
|
|
2424
|
-
|
|
2425
|
-
|
|
2630
|
+
getIndividualIndustryClassification(params: {
|
|
2631
|
+
symbol?: string;
|
|
2632
|
+
cik?: string;
|
|
2633
|
+
sicCode?: number;
|
|
2634
|
+
}): Promise<APIResponse<IndustryClassification>>;
|
|
2426
2635
|
/**
|
|
2427
|
-
* Get
|
|
2428
|
-
*
|
|
2429
|
-
* Provides CIK number and company name for a specific stock symbol.
|
|
2430
|
-
* Essential for converting stock symbols to CIK numbers for use
|
|
2431
|
-
* in insider trading searches and analysis.
|
|
2636
|
+
* Get all industry classifications
|
|
2432
2637
|
*
|
|
2433
|
-
*
|
|
2434
|
-
*
|
|
2638
|
+
* Provides a comprehensive overview of all industries classified according
|
|
2639
|
+
* to the Standard Industrial Classification (SIC) system. Essential for
|
|
2640
|
+
* understanding industry categories, sector analysis, and market research.
|
|
2435
2641
|
*
|
|
2436
|
-
* @returns Promise resolving to
|
|
2642
|
+
* @returns Promise resolving to array of all industry classifications with SIC codes and descriptions
|
|
2437
2643
|
*
|
|
2438
2644
|
* @example
|
|
2439
2645
|
* ```typescript
|
|
2440
|
-
* // Get
|
|
2441
|
-
* const
|
|
2442
|
-
* console.log(`
|
|
2646
|
+
* // Get all industry classifications
|
|
2647
|
+
* const allIndustries = await fmp.sec.getAllIndustryClassifications();
|
|
2648
|
+
* console.log(`Total industries: ${allIndustries.data.length}`);
|
|
2443
2649
|
*
|
|
2444
|
-
*
|
|
2445
|
-
*
|
|
2650
|
+
* allIndustries.data.forEach((industry, index) => {
|
|
2651
|
+
* console.log(`${index + 1}. ${industry.industryTitle}`);
|
|
2652
|
+
* console.log(` SIC Code: ${industry.sicCode}`);
|
|
2653
|
+
* });
|
|
2654
|
+
*
|
|
2655
|
+
* // Find specific industry
|
|
2656
|
+
* const techIndustry = allIndustries.data.find(industry =>
|
|
2657
|
+
* industry.industryTitle.toLowerCase().includes('computer')
|
|
2658
|
+
* );
|
|
2659
|
+
* console.log(`Tech Industry: ${techIndustry?.industryTitle}`);
|
|
2446
2660
|
* ```
|
|
2447
2661
|
*
|
|
2448
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2662
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#all-industry-classification-standard-industrial-classification|FMP All Industry Classifications Documentation}
|
|
2449
2663
|
*/
|
|
2450
|
-
|
|
2451
|
-
symbol: string;
|
|
2452
|
-
}): Promise<APIResponse<CikMapperBySymbolResponse>>;
|
|
2664
|
+
getAllIndustryClassifications(): Promise<APIResponse<IndustryClassification[]>>;
|
|
2453
2665
|
/**
|
|
2454
|
-
* Get
|
|
2455
|
-
*
|
|
2456
|
-
* Provides data on acquisitions of beneficial ownership for a specific
|
|
2457
|
-
* company. Essential for tracking significant ownership changes and
|
|
2458
|
-
* corporate governance events.
|
|
2666
|
+
* Get industry classification codes
|
|
2459
2667
|
*
|
|
2460
|
-
*
|
|
2461
|
-
*
|
|
2668
|
+
* Provides detailed information about the Standard Industrial Classification
|
|
2669
|
+
* (SIC) system and helps identify SIC codes for specific industries.
|
|
2670
|
+
* Essential for understanding industry categorization and sector analysis.
|
|
2462
2671
|
*
|
|
2463
|
-
* @
|
|
2672
|
+
* @param params - Industry classification codes parameters
|
|
2673
|
+
* @returns Promise resolving to array of industry classification codes with detailed information
|
|
2464
2674
|
*
|
|
2465
2675
|
* @example
|
|
2466
2676
|
* ```typescript
|
|
2467
|
-
* // Get
|
|
2468
|
-
* const
|
|
2469
|
-
*
|
|
2470
|
-
* console.log(`${acquisition.date}: ${acquisition.insiderName} acquired ${acquisition.sharesAcquired} shares`);
|
|
2471
|
-
* });
|
|
2677
|
+
* // Get all industry classification codes
|
|
2678
|
+
* const allCodes = await fmp.sec.getIndustryClassificationCodes({});
|
|
2679
|
+
* console.log(`Total SIC codes: ${allCodes.data.length}`);
|
|
2472
2680
|
*
|
|
2473
|
-
* //
|
|
2474
|
-
* const
|
|
2681
|
+
* // Search for specific SIC code
|
|
2682
|
+
* const code3571 = await fmp.sec.getIndustryClassificationCodes({ sicCode: 3571 });
|
|
2683
|
+
* console.log(`SIC 3571: ${code3571.data[0]?.industryTitle}`);
|
|
2684
|
+
*
|
|
2685
|
+
* // Search for industry by title
|
|
2686
|
+
* const computerIndustry = await fmp.sec.getIndustryClassificationCodes({ industryTitle: 'Computer' });
|
|
2687
|
+
* console.log(`Computer-related industries: ${computerIndustry.data.length}`);
|
|
2475
2688
|
* ```
|
|
2476
2689
|
*
|
|
2477
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2690
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#industry-classification-codes-standard-industrial-classification|FMP Industry Classification Codes Documentation}
|
|
2478
2691
|
*/
|
|
2479
|
-
|
|
2480
|
-
|
|
2481
|
-
|
|
2692
|
+
getIndustryClassificationCodes(params: {
|
|
2693
|
+
industryTitle?: string;
|
|
2694
|
+
sicCode?: number;
|
|
2695
|
+
}): Promise<APIResponse<IndustryClassificationCode[]>>;
|
|
2696
|
+
}
|
|
2697
|
+
|
|
2698
|
+
declare class SenateHouseEndpoints {
|
|
2699
|
+
private client;
|
|
2700
|
+
constructor(client: FMPClient);
|
|
2482
2701
|
/**
|
|
2483
|
-
* Get
|
|
2484
|
-
*
|
|
2485
|
-
* Provides fail to deliver data for a specific company, which indicates
|
|
2486
|
-
* when market participants fail to deliver securities on settlement date.
|
|
2487
|
-
* Important for understanding market mechanics and potential short interest.
|
|
2702
|
+
* Get senate trading data for a specific stock symbol
|
|
2488
2703
|
*
|
|
2489
|
-
*
|
|
2490
|
-
*
|
|
2491
|
-
*
|
|
2704
|
+
* Provides detailed information about senate members' trading activities for a specific stock.
|
|
2705
|
+
* Includes transaction details, amounts, dates, and ownership information for transparency
|
|
2706
|
+
* and compliance with the STOCK Act (Stop Trading on Congressional Knowledge).
|
|
2492
2707
|
*
|
|
2493
|
-
* @
|
|
2708
|
+
* @param params - Senate trading request parameters
|
|
2709
|
+
* @param params.symbol - The stock symbol to get senate trading data for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
2710
|
+
*
|
|
2711
|
+
* @returns Promise resolving to array of senate trading data with transaction details
|
|
2494
2712
|
*
|
|
2495
2713
|
* @example
|
|
2496
2714
|
* ```typescript
|
|
2497
|
-
* // Get
|
|
2498
|
-
* const
|
|
2499
|
-
*
|
|
2500
|
-
*
|
|
2501
|
-
* });
|
|
2502
|
-
*
|
|
2503
|
-
* console.log(`${entry.date}: ${entry.shares} shares failed to deliver`);
|
|
2715
|
+
* // Get senate trading data for Apple
|
|
2716
|
+
* const appleSenateTrading = await fmp.senateHouse.getSenateTrading({ symbol: 'AAPL' });
|
|
2717
|
+
* appleSenateTrading.data.forEach(trade => {
|
|
2718
|
+
* console.log(`${trade.firstName} ${trade.lastName} (${trade.office}):`);
|
|
2719
|
+
* console.log(` ${trade.type} ${trade.amount} of ${trade.assetDescription}`);
|
|
2720
|
+
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
2504
2721
|
* });
|
|
2505
2722
|
*
|
|
2506
|
-
* // Get
|
|
2507
|
-
* const
|
|
2508
|
-
* symbol: 'MSFT',
|
|
2509
|
-
* page: 0
|
|
2510
|
-
* });
|
|
2723
|
+
* // Get senate trading data for Tesla
|
|
2724
|
+
* const teslaSenateTrading = await fmp.senateHouse.getSenateTrading({ symbol: 'TSLA' });
|
|
2511
2725
|
* ```
|
|
2512
2726
|
*
|
|
2513
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2727
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#senate-trading|FMP Senate Trading Documentation}
|
|
2514
2728
|
*/
|
|
2515
|
-
|
|
2729
|
+
getSenateTrading(params: {
|
|
2516
2730
|
symbol: string;
|
|
2517
|
-
|
|
2518
|
-
}): Promise<APIResponse<FailToDeliverResponse[]>>;
|
|
2519
|
-
/**
|
|
2520
|
-
* Get all insider trades for a symbol (convenience method)
|
|
2521
|
-
* @param symbol - The stock symbol to get insider trades for
|
|
2522
|
-
* @param page - Page number for pagination (default: 0)
|
|
2523
|
-
* @returns A list of insider trades for the specified symbol
|
|
2524
|
-
*/
|
|
2525
|
-
getInsiderTradesBySymbol(symbol: string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
2526
|
-
/**
|
|
2527
|
-
* Get insider trades by transaction type (convenience method)
|
|
2528
|
-
* @param transactionType - The transaction type to filter by
|
|
2529
|
-
* @param page - Page number for pagination (default: 0)
|
|
2530
|
-
* @returns A list of insider trades filtered by transaction type
|
|
2531
|
-
*/
|
|
2532
|
-
getInsiderTradesByType(transactionType: TransactionType | string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
2533
|
-
/**
|
|
2534
|
-
* Get insider trades by reporting CIK (convenience method)
|
|
2535
|
-
* @param reportingCik - The reporting CIK to filter by
|
|
2536
|
-
* @param page - Page number for pagination (default: 0)
|
|
2537
|
-
* @returns A list of insider trades filtered by reporting CIK
|
|
2538
|
-
*/
|
|
2539
|
-
getInsiderTradesByReportingCik(reportingCik: string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
2540
|
-
/**
|
|
2541
|
-
* Get insider trades by company CIK (convenience method)
|
|
2542
|
-
* @param companyCik - The company CIK to filter by
|
|
2543
|
-
* @param page - Page number for pagination (default: 0)
|
|
2544
|
-
* @returns A list of insider trades filtered by company CIK
|
|
2545
|
-
*/
|
|
2546
|
-
getInsiderTradesByCompanyCik(companyCik: string, page?: number): Promise<APIResponse<InsiderTradingSearchResponse[]>>;
|
|
2547
|
-
}
|
|
2548
|
-
|
|
2549
|
-
declare class SECEndpoints {
|
|
2550
|
-
private client;
|
|
2551
|
-
constructor(client: FMPClient);
|
|
2731
|
+
}): Promise<APIResponse<SenateTradingResponse[]>>;
|
|
2552
2732
|
/**
|
|
2553
|
-
* Get RSS feed
|
|
2733
|
+
* Get senate trading RSS feed with pagination
|
|
2554
2734
|
*
|
|
2555
|
-
* Provides a
|
|
2556
|
-
*
|
|
2557
|
-
*
|
|
2558
|
-
* or for monitoring specific companies' regulatory activities.
|
|
2735
|
+
* Provides a paginated RSS feed of all senate trading activities across all stocks.
|
|
2736
|
+
* Useful for monitoring congressional trading activities, compliance tracking,
|
|
2737
|
+
* and transparency reporting. Returns recent trading disclosures from senate members.
|
|
2559
2738
|
*
|
|
2560
|
-
* @param params - RSS feed parameters
|
|
2561
|
-
* @
|
|
2739
|
+
* @param params - Senate trading RSS feed request parameters
|
|
2740
|
+
* @param params.page - The page number to retrieve (starts from 0)
|
|
2741
|
+
*
|
|
2742
|
+
* @returns Promise resolving to array of senate trading data from RSS feed
|
|
2562
2743
|
*
|
|
2563
2744
|
* @example
|
|
2564
2745
|
* ```typescript
|
|
2565
|
-
* // Get
|
|
2566
|
-
* const
|
|
2567
|
-
* console.log(`
|
|
2746
|
+
* // Get first page of senate trading RSS feed
|
|
2747
|
+
* const firstPage = await fmp.senateHouse.getSenateTradingRSSFeed({ page: 0 });
|
|
2748
|
+
* console.log(`First page: ${firstPage.data.length} trading activities`);
|
|
2568
2749
|
*
|
|
2569
|
-
* // Get
|
|
2570
|
-
* const
|
|
2571
|
-
* console.log(`
|
|
2750
|
+
* // Get second page of senate trading RSS feed
|
|
2751
|
+
* const secondPage = await fmp.senateHouse.getSenateTradingRSSFeed({ page: 1 });
|
|
2752
|
+
* console.log(`Second page: ${secondPage.data.length} trading activities`);
|
|
2572
2753
|
*
|
|
2573
|
-
* // Get
|
|
2574
|
-
* const
|
|
2575
|
-
*
|
|
2576
|
-
*
|
|
2754
|
+
* // Get recent senate trading activities
|
|
2755
|
+
* const recentTrades = await fmp.senateHouse.getSenateTradingRSSFeed({ page: 0 });
|
|
2756
|
+
* recentTrades.data.forEach(trade => {
|
|
2757
|
+
* console.log(`${trade.firstName} ${trade.lastName}: ${trade.type} ${trade.amount}`);
|
|
2577
2758
|
* });
|
|
2578
|
-
* console.log(`Recent filings: ${recentFilings.data.length}`);
|
|
2579
|
-
*
|
|
2580
|
-
* // Get limited results
|
|
2581
|
-
* const limitedFilings = await fmp.sec.getRSSFeed({ limit: 10 });
|
|
2582
|
-
* console.log(`Limited filings: ${limitedFilings.data.length}`);
|
|
2583
2759
|
* ```
|
|
2584
2760
|
*
|
|
2585
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2761
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#senate-latest|FMP Senate Trading RSS Feed Documentation}
|
|
2586
2762
|
*/
|
|
2587
|
-
|
|
2763
|
+
getSenateTradingRSSFeed(params: {
|
|
2764
|
+
page: number;
|
|
2588
2765
|
limit?: number;
|
|
2589
|
-
|
|
2590
|
-
from?: string;
|
|
2591
|
-
to?: string;
|
|
2592
|
-
isDone?: boolean;
|
|
2593
|
-
}): Promise<APIResponse<RSSFeedItem[]>>;
|
|
2766
|
+
}): Promise<APIResponse<SenateTradingResponse[]>>;
|
|
2594
2767
|
/**
|
|
2595
|
-
* Get
|
|
2768
|
+
* Get senate trading data for a specific senator by name
|
|
2596
2769
|
*
|
|
2597
|
-
* Provides
|
|
2598
|
-
*
|
|
2599
|
-
*
|
|
2770
|
+
* Provides detailed trading activities for a specific senate member across all stocks.
|
|
2771
|
+
* Useful for tracking individual senator's trading patterns, compliance monitoring,
|
|
2772
|
+
* and transparency reporting. Returns all trading disclosures for the specified senator.
|
|
2600
2773
|
*
|
|
2601
|
-
* @param params -
|
|
2602
|
-
* @
|
|
2774
|
+
* @param params - Senate trading by name request parameters
|
|
2775
|
+
* @param params.name - The name of the senator to get trading data for (e.g., 'John Smith', 'Jane Doe')
|
|
2776
|
+
*
|
|
2777
|
+
* @returns Promise resolving to array of senate trading data for the specified senator
|
|
2603
2778
|
*
|
|
2604
2779
|
* @example
|
|
2605
2780
|
* ```typescript
|
|
2606
|
-
* // Get
|
|
2607
|
-
* const
|
|
2608
|
-
*
|
|
2609
|
-
*
|
|
2610
|
-
*
|
|
2611
|
-
*
|
|
2612
|
-
*
|
|
2781
|
+
* // Get trading data for Senator John Smith
|
|
2782
|
+
* const johnSmithTrades = await fmp.senateHouse.getSenateTradingByName({ name: 'John Smith' });
|
|
2783
|
+
* johnSmithTrades.data.forEach(trade => {
|
|
2784
|
+
* console.log(`${trade.symbol}: ${trade.type} ${trade.amount}`);
|
|
2785
|
+
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
2786
|
+
* console.log(` Asset: ${trade.assetDescription}`);
|
|
2787
|
+
* });
|
|
2613
2788
|
*
|
|
2614
|
-
* // Get
|
|
2615
|
-
* const
|
|
2616
|
-
* console.log(`
|
|
2789
|
+
* // Get trading data for Senator Jane Doe
|
|
2790
|
+
* const janeDoeTrades = await fmp.senateHouse.getSenateTradingByName({ name: 'Jane Doe' });
|
|
2791
|
+
* console.log(`Jane Doe has ${janeDoeTrades.data.length} trading activities`);
|
|
2617
2792
|
* ```
|
|
2618
2793
|
*
|
|
2619
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2794
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#senate-trading-by-name|FMP Senate Trading by Name Documentation}
|
|
2620
2795
|
*/
|
|
2621
|
-
|
|
2622
|
-
|
|
2623
|
-
|
|
2624
|
-
}): Promise<APIResponse<RSSFeedAllItem[]>>;
|
|
2796
|
+
getSenateTradingByName(params: {
|
|
2797
|
+
name: string;
|
|
2798
|
+
}): Promise<APIResponse<SenateHouseTradingByNameResponse[]>>;
|
|
2625
2799
|
/**
|
|
2626
|
-
* Get
|
|
2800
|
+
* Get house trading data for a specific stock symbol
|
|
2627
2801
|
*
|
|
2628
|
-
* Provides
|
|
2629
|
-
*
|
|
2630
|
-
*
|
|
2802
|
+
* Provides detailed information about house representatives' trading activities for a specific stock.
|
|
2803
|
+
* Includes transaction details, amounts, dates, and district information for transparency
|
|
2804
|
+
* and compliance with the STOCK Act (Stop Trading on Congressional Knowledge).
|
|
2631
2805
|
*
|
|
2632
|
-
* @param params -
|
|
2633
|
-
* @
|
|
2806
|
+
* @param params - House trading request parameters
|
|
2807
|
+
* @param params.symbol - The stock symbol to get house trading data for (e.g., 'AAPL', 'MSFT', 'TSLA')
|
|
2808
|
+
*
|
|
2809
|
+
* @returns Promise resolving to array of house trading data with transaction details
|
|
2634
2810
|
*
|
|
2635
2811
|
* @example
|
|
2636
2812
|
* ```typescript
|
|
2637
|
-
* // Get
|
|
2638
|
-
* const
|
|
2639
|
-
*
|
|
2640
|
-
*
|
|
2641
|
-
*
|
|
2642
|
-
*
|
|
2643
|
-
*
|
|
2813
|
+
* // Get house trading data for Apple
|
|
2814
|
+
* const appleHouseTrading = await fmp.senateHouse.getHouseTrading({ symbol: 'AAPL' });
|
|
2815
|
+
* appleHouseTrading.data.forEach(trade => {
|
|
2816
|
+
* console.log(`${trade.representative} (District ${trade.district}):`);
|
|
2817
|
+
* console.log(` ${trade.type} ${trade.amount} of ${trade.assetDescription}`);
|
|
2818
|
+
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
2819
|
+
* });
|
|
2644
2820
|
*
|
|
2645
|
-
* // Get
|
|
2646
|
-
* const
|
|
2647
|
-
* console.log(`
|
|
2821
|
+
* // Get house trading data for Microsoft
|
|
2822
|
+
* const msftHouseTrading = await fmp.senateHouse.getHouseTrading({ symbol: 'MSFT' });
|
|
2823
|
+
* console.log(`Microsoft house trading activities: ${msftHouseTrading.data.length}`);
|
|
2648
2824
|
* ```
|
|
2649
2825
|
*
|
|
2650
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2826
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#house-trading|FMP House Trading Documentation}
|
|
2651
2827
|
*/
|
|
2652
|
-
|
|
2653
|
-
|
|
2654
|
-
|
|
2655
|
-
}): Promise<APIResponse<RSSFeedV3Item[]>>;
|
|
2828
|
+
getHouseTrading(params: {
|
|
2829
|
+
symbol: string;
|
|
2830
|
+
}): Promise<APIResponse<HouseTradingResponse[]>>;
|
|
2656
2831
|
/**
|
|
2657
|
-
* Get RSS feed
|
|
2832
|
+
* Get house trading RSS feed with pagination
|
|
2658
2833
|
*
|
|
2659
|
-
* Provides a
|
|
2660
|
-
*
|
|
2661
|
-
*
|
|
2662
|
-
* acquisitions, and other material events.
|
|
2834
|
+
* Provides a paginated RSS feed of all house trading activities across all stocks.
|
|
2835
|
+
* Useful for monitoring congressional trading activities, compliance tracking,
|
|
2836
|
+
* and transparency reporting. Returns recent trading disclosures from house representatives.
|
|
2663
2837
|
*
|
|
2664
|
-
* @param params - RSS feed
|
|
2665
|
-
* @
|
|
2838
|
+
* @param params - House trading RSS feed request parameters
|
|
2839
|
+
* @param params.page - The page number to retrieve (starts from 0)
|
|
2840
|
+
*
|
|
2841
|
+
* @returns Promise resolving to array of house trading data from RSS feed
|
|
2666
2842
|
*
|
|
2667
2843
|
* @example
|
|
2668
2844
|
* ```typescript
|
|
2669
|
-
* // Get
|
|
2670
|
-
* const
|
|
2671
|
-
* console.log(`
|
|
2672
|
-
*
|
|
2673
|
-
* // Get 8-K filings with date range
|
|
2674
|
-
* const recent8K = await fmp.sec.getRSSFeed8K({
|
|
2675
|
-
* from: '2024-01-01',
|
|
2676
|
-
* to: '2024-01-31'
|
|
2677
|
-
* });
|
|
2678
|
-
* console.log(`Recent 8-K filings: ${recent8K.data.length}`);
|
|
2845
|
+
* // Get first page of house trading RSS feed
|
|
2846
|
+
* const firstPage = await fmp.senateHouse.getHouseTradingRSSFeed({ page: 0 });
|
|
2847
|
+
* console.log(`First page: ${firstPage.data.length} trading activities`);
|
|
2679
2848
|
*
|
|
2680
|
-
* // Get
|
|
2681
|
-
* const
|
|
2682
|
-
* console.log(`
|
|
2849
|
+
* // Get second page of house trading RSS feed
|
|
2850
|
+
* const secondPage = await fmp.senateHouse.getHouseTradingRSSFeed({ page: 1 });
|
|
2851
|
+
* console.log(`Second page: ${secondPage.data.length} trading activities`);
|
|
2683
2852
|
*
|
|
2684
|
-
* // Get
|
|
2685
|
-
* const
|
|
2686
|
-
*
|
|
2853
|
+
* // Get recent house trading activities
|
|
2854
|
+
* const recentTrades = await fmp.senateHouse.getHouseTradingRSSFeed({ page: 0 });
|
|
2855
|
+
* recentTrades.data.forEach(trade => {
|
|
2856
|
+
* console.log(`${trade.representative} (District ${trade.district}): ${trade.type} ${trade.amount}`);
|
|
2857
|
+
* });
|
|
2687
2858
|
* ```
|
|
2688
2859
|
*
|
|
2689
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2860
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#house-latest|FMP House Trading RSS Feed Documentation}
|
|
2690
2861
|
*/
|
|
2691
|
-
|
|
2692
|
-
page
|
|
2693
|
-
from?: string;
|
|
2694
|
-
to?: string;
|
|
2695
|
-
hasFinancial?: boolean;
|
|
2862
|
+
getHouseTradingRSSFeed(params: {
|
|
2863
|
+
page: number;
|
|
2696
2864
|
limit?: number;
|
|
2697
|
-
}): Promise<APIResponse<
|
|
2865
|
+
}): Promise<APIResponse<HouseTradingResponse[]>>;
|
|
2698
2866
|
/**
|
|
2699
|
-
* Get
|
|
2867
|
+
* Get house trading data for a specific representative by name
|
|
2868
|
+
*
|
|
2869
|
+
* Provides detailed trading activities for a specific house representative across all stocks.
|
|
2870
|
+
* Useful for tracking individual representative's trading patterns, compliance monitoring,
|
|
2871
|
+
* and transparency reporting. Returns all trading disclosures for the specified representative.
|
|
2700
2872
|
*
|
|
2701
|
-
*
|
|
2702
|
-
*
|
|
2703
|
-
* Essential for monitoring a company's regulatory compliance and staying
|
|
2704
|
-
* informed about important corporate events and disclosures.
|
|
2873
|
+
* @param params - House trading by name request parameters
|
|
2874
|
+
* @param params.name - The name of the representative to get trading data for (e.g., 'John Smith', 'Jane Doe')
|
|
2705
2875
|
*
|
|
2706
|
-
* @
|
|
2707
|
-
* @param params - SEC filings parameters (optional)
|
|
2708
|
-
* @returns Promise resolving to array of SEC filings with detailed filing information
|
|
2876
|
+
* @returns Promise resolving to array of house trading data for the specified representative
|
|
2709
2877
|
*
|
|
2710
2878
|
* @example
|
|
2711
2879
|
* ```typescript
|
|
2712
|
-
* // Get
|
|
2713
|
-
* const
|
|
2714
|
-
*
|
|
2715
|
-
*
|
|
2716
|
-
*
|
|
2717
|
-
*
|
|
2718
|
-
*
|
|
2719
|
-
* params: { type: '4' }
|
|
2880
|
+
* // Get trading data for Representative John Smith
|
|
2881
|
+
* const johnSmithTrades = await fmp.senateHouse.getHouseTradingByName({ name: 'John Smith' });
|
|
2882
|
+
* johnSmithTrades.data.forEach(trade => {
|
|
2883
|
+
* console.log(`${trade.symbol}: ${trade.type} ${trade.amount}`);
|
|
2884
|
+
* console.log(` Transaction Date: ${trade.transactionDate}`);
|
|
2885
|
+
* console.log(` Asset: ${trade.assetDescription}`);
|
|
2886
|
+
* console.log(` District: ${trade.district}`);
|
|
2720
2887
|
* });
|
|
2721
|
-
*
|
|
2888
|
+
*
|
|
2889
|
+
* // Get trading data for Representative Jane Doe
|
|
2890
|
+
* const janeDoeTrades = await fmp.senateHouse.getHouseTradingByName({ name: 'Jane Doe' });
|
|
2891
|
+
* console.log(`Jane Doe has ${janeDoeTrades.data.length} trading activities`);
|
|
2722
2892
|
* ```
|
|
2723
2893
|
*
|
|
2724
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2894
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs/stable#house-trading-by-name|FMP House Trading by Name Documentation}
|
|
2725
2895
|
*/
|
|
2726
|
-
|
|
2727
|
-
|
|
2728
|
-
|
|
2729
|
-
|
|
2730
|
-
|
|
2731
|
-
|
|
2732
|
-
|
|
2896
|
+
getHouseTradingByName(params: {
|
|
2897
|
+
name: string;
|
|
2898
|
+
}): Promise<APIResponse<SenateHouseTradingByNameResponse[]>>;
|
|
2899
|
+
}
|
|
2900
|
+
|
|
2901
|
+
declare class StockEndpoints {
|
|
2902
|
+
private client;
|
|
2903
|
+
constructor(client: FMPClient);
|
|
2733
2904
|
/**
|
|
2734
|
-
* Get
|
|
2905
|
+
* Get current market capitalization for a stock
|
|
2735
2906
|
*
|
|
2736
|
-
*
|
|
2737
|
-
*
|
|
2738
|
-
* a company's
|
|
2907
|
+
* Market capitalization represents the total value of a company's outstanding shares.
|
|
2908
|
+
* Calculated by multiplying the current share price by the number of outstanding shares.
|
|
2909
|
+
* This metric is crucial for understanding a company's size and market position.
|
|
2739
2910
|
*
|
|
2740
|
-
* @param
|
|
2741
|
-
*
|
|
2911
|
+
* @param symbol - The stock symbol to get market cap for (e.g., 'AAPL', 'MSFT', 'GOOGL')
|
|
2912
|
+
*
|
|
2913
|
+
* @returns Promise resolving to market cap data including symbol, date, and market cap value
|
|
2742
2914
|
*
|
|
2743
2915
|
* @example
|
|
2744
2916
|
* ```typescript
|
|
2745
|
-
* // Get
|
|
2746
|
-
* const
|
|
2747
|
-
* console.log(`Apple
|
|
2748
|
-
* console.log(`SIC Code: ${appleIndustry.data.sicCode}`);
|
|
2749
|
-
*
|
|
2750
|
-
* // Get industry classification by CIK
|
|
2751
|
-
* const cikIndustry = await fmp.sec.getIndividualIndustryClassification({ cik: 320193 });
|
|
2752
|
-
* console.log(`CIK Industry: ${cikIndustry.data.industryTitle}`);
|
|
2917
|
+
* // Get market cap for Apple
|
|
2918
|
+
* const marketCap = await fmp.stock.getMarketCap('AAPL');
|
|
2919
|
+
* console.log(`Apple's market cap: $${marketCap.data.marketCap.toLocaleString()}`);
|
|
2753
2920
|
*
|
|
2754
|
-
* // Get
|
|
2755
|
-
* const
|
|
2756
|
-
* console.log(`SIC Industry: ${sicIndustry.data.industryTitle}`);
|
|
2921
|
+
* // Get market cap for Microsoft
|
|
2922
|
+
* const msftCap = await fmp.stock.getMarketCap('MSFT');
|
|
2757
2923
|
* ```
|
|
2758
2924
|
*
|
|
2759
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2925
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#market-cap-company-information|FMP Market Cap Documentation}
|
|
2760
2926
|
*/
|
|
2761
|
-
|
|
2762
|
-
symbol?: string;
|
|
2763
|
-
cik?: string;
|
|
2764
|
-
sicCode?: number;
|
|
2765
|
-
}): Promise<APIResponse<IndustryClassification>>;
|
|
2927
|
+
getMarketCap(symbol: string): Promise<APIResponse<MarketCap>>;
|
|
2766
2928
|
/**
|
|
2767
|
-
* Get
|
|
2929
|
+
* Get historical stock splits for a company
|
|
2768
2930
|
*
|
|
2769
|
-
*
|
|
2770
|
-
*
|
|
2771
|
-
*
|
|
2931
|
+
* Stock splits occur when a company increases the number of shares by dividing existing shares.
|
|
2932
|
+
* This endpoint provides the complete history of stock splits including dates, ratios, and split types.
|
|
2933
|
+
* Useful for adjusting historical price data and understanding corporate actions.
|
|
2772
2934
|
*
|
|
2773
|
-
* @
|
|
2935
|
+
* @param symbol - The stock symbol to get split history for (e.g., 'AAPL', 'TSLA', 'NVDA')
|
|
2936
|
+
*
|
|
2937
|
+
* @returns Promise resolving to historical stock splits with dates, labels, and split ratios
|
|
2774
2938
|
*
|
|
2775
2939
|
* @example
|
|
2776
2940
|
* ```typescript
|
|
2777
|
-
* // Get
|
|
2778
|
-
* const
|
|
2779
|
-
*
|
|
2780
|
-
*
|
|
2781
|
-
* allIndustries.data.forEach((industry, index) => {
|
|
2782
|
-
* console.log(`${index + 1}. ${industry.industryTitle}`);
|
|
2783
|
-
* console.log(` SIC Code: ${industry.sicCode}`);
|
|
2941
|
+
* // Get Apple's split history
|
|
2942
|
+
* const splits = await fmp.stock.getStockSplits('AAPL');
|
|
2943
|
+
* splits.data.historical.forEach(split => {
|
|
2944
|
+
* console.log(`${split.date}: ${split.numerator}:${split.denominator} split`);
|
|
2784
2945
|
* });
|
|
2785
2946
|
*
|
|
2786
|
-
* //
|
|
2787
|
-
* const
|
|
2788
|
-
* industry.industryTitle.toLowerCase().includes('computer')
|
|
2789
|
-
* );
|
|
2790
|
-
* console.log(`Tech Industry: ${techIndustry?.industryTitle}`);
|
|
2947
|
+
* // Get Tesla's split history
|
|
2948
|
+
* const teslaSplits = await fmp.stock.getStockSplits('TSLA');
|
|
2791
2949
|
* ```
|
|
2792
2950
|
*
|
|
2793
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2951
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#splits-historical-splits|FMP Stock Splits Documentation}
|
|
2794
2952
|
*/
|
|
2795
|
-
|
|
2953
|
+
getStockSplits(symbol: string): Promise<APIResponse<StockSplitResponse>>;
|
|
2796
2954
|
/**
|
|
2797
|
-
* Get
|
|
2955
|
+
* Get historical dividend payments for a stock
|
|
2798
2956
|
*
|
|
2799
|
-
*
|
|
2800
|
-
*
|
|
2801
|
-
*
|
|
2957
|
+
* Dividends are periodic payments made by companies to shareholders from profits.
|
|
2958
|
+
* This endpoint provides the complete dividend history including payment dates, amounts,
|
|
2959
|
+
* and important dates like ex-dividend, record, and declaration dates.
|
|
2802
2960
|
*
|
|
2803
|
-
* @param
|
|
2804
|
-
*
|
|
2961
|
+
* @param symbol - The stock symbol to get dividend history for (e.g., 'KO', 'JNJ', 'PG')
|
|
2962
|
+
*
|
|
2963
|
+
* @returns Promise resolving to dividend history with payment details and important dates
|
|
2805
2964
|
*
|
|
2806
2965
|
* @example
|
|
2807
2966
|
* ```typescript
|
|
2808
|
-
* // Get
|
|
2809
|
-
* const
|
|
2810
|
-
*
|
|
2811
|
-
*
|
|
2812
|
-
*
|
|
2813
|
-
* const code3571 = await fmp.sec.getIndustryClassificationCodes({ sicCode: 3571 });
|
|
2814
|
-
* console.log(`SIC 3571: ${code3571.data[0]?.industryTitle}`);
|
|
2967
|
+
* // Get Coca-Cola's dividend history
|
|
2968
|
+
* const dividends = await fmp.stock.getDividendHistory('KO');
|
|
2969
|
+
* dividends.data.historical.forEach(dividend => {
|
|
2970
|
+
* console.log(`${dividend.date}: $${dividend.dividend} per share`);
|
|
2971
|
+
* });
|
|
2815
2972
|
*
|
|
2816
|
-
* //
|
|
2817
|
-
* const
|
|
2818
|
-
* console.log(`Computer-related industries: ${computerIndustry.data.length}`);
|
|
2973
|
+
* // Get Johnson & Johnson's dividend history
|
|
2974
|
+
* const jnjDividends = await fmp.stock.getDividendHistory('JNJ');
|
|
2819
2975
|
* ```
|
|
2820
2976
|
*
|
|
2821
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
2977
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#dividends-historical-dividends|FMP Dividends Documentation}
|
|
2822
2978
|
*/
|
|
2823
|
-
|
|
2824
|
-
industryTitle?: string;
|
|
2825
|
-
sicCode?: number;
|
|
2826
|
-
}): Promise<APIResponse<IndustryClassificationCode[]>>;
|
|
2827
|
-
}
|
|
2828
|
-
|
|
2829
|
-
declare class MutualFundEndpoints {
|
|
2830
|
-
private client;
|
|
2831
|
-
constructor(client: FMPClient);
|
|
2979
|
+
getDividendHistory(symbol: string): Promise<APIResponse<StockDividendResponse>>;
|
|
2832
2980
|
/**
|
|
2833
|
-
* Get
|
|
2981
|
+
* Get real-time stock prices for multiple symbols
|
|
2834
2982
|
*
|
|
2835
|
-
* Provides
|
|
2836
|
-
*
|
|
2837
|
-
*
|
|
2983
|
+
* Provides current market prices for stocks with minimal data overhead.
|
|
2984
|
+
* Returns basic price information including symbol and current price.
|
|
2985
|
+
* Ideal for quick price checks and portfolio monitoring.
|
|
2838
2986
|
*
|
|
2839
|
-
* @param
|
|
2987
|
+
* @param symbols - Array of stock symbols to get real-time prices for
|
|
2840
2988
|
*
|
|
2841
|
-
* @returns Promise resolving to array of
|
|
2989
|
+
* @returns Promise resolving to array of real-time price data with symbol and price
|
|
2842
2990
|
*
|
|
2843
2991
|
* @example
|
|
2844
2992
|
* ```typescript
|
|
2845
|
-
* // Get
|
|
2846
|
-
* const
|
|
2847
|
-
*
|
|
2993
|
+
* // Get prices for multiple tech stocks
|
|
2994
|
+
* const prices = await fmp.stock.getRealTimePrice([
|
|
2995
|
+
* 'AAPL', 'MSFT', 'GOOGL', 'AMZN', 'TSLA'
|
|
2996
|
+
* ]);
|
|
2848
2997
|
*
|
|
2849
|
-
*
|
|
2850
|
-
* console.log(`${
|
|
2851
|
-
* console.log(` Shares: ${holder.shares?.toLocaleString() || 'N/A'}`);
|
|
2852
|
-
* console.log(` Weight: ${holder.weightPercent}% | Change: ${holder.change}`);
|
|
2998
|
+
* prices.data.forEach(stock => {
|
|
2999
|
+
* console.log(`${stock.symbol}: $${stock.price}`);
|
|
2853
3000
|
* });
|
|
2854
3001
|
*
|
|
2855
|
-
* // Get
|
|
2856
|
-
* const
|
|
3002
|
+
* // Get price for single stock
|
|
3003
|
+
* const aaplPrice = await fmp.stock.getRealTimePrice(['AAPL']);
|
|
3004
|
+
* ```
|
|
3005
|
+
*/
|
|
3006
|
+
getRealTimePrice(symbols: string[]): Promise<APIResponse<StockRealTimePrice[]>>;
|
|
3007
|
+
/**
|
|
3008
|
+
* Get comprehensive real-time stock data for multiple symbols
|
|
2857
3009
|
*
|
|
2858
|
-
*
|
|
2859
|
-
*
|
|
2860
|
-
*
|
|
2861
|
-
* .slice(0, 10);
|
|
2862
|
-
* console.log('Top 10 mutual fund holders by shares:');
|
|
2863
|
-
* topHolders.forEach((holder, index) => {
|
|
2864
|
-
* console.log(`${index + 1}. ${holder.holder}: ${holder.shares.toLocaleString()} shares`);
|
|
2865
|
-
* });
|
|
3010
|
+
* Provides detailed real-time market data including bid/ask prices, volume, trade sizes,
|
|
3011
|
+
* and timestamps. This endpoint offers much more information than the basic real-time price.
|
|
3012
|
+
* Perfect for trading applications, market analysis, and detailed price monitoring.
|
|
2866
3013
|
*
|
|
2867
|
-
*
|
|
2868
|
-
* const googlHolders = await fmp.mutualFund.getHolders('GOOGL');
|
|
3014
|
+
* @param symbols - Array of stock symbols to get detailed real-time data for
|
|
2869
3015
|
*
|
|
2870
|
-
*
|
|
2871
|
-
* const totalShares = googlHolders.data.reduce((sum, holder) => sum + (holder.shares || 0), 0);
|
|
2872
|
-
* console.log(`Total shares held by mutual funds: ${totalShares.toLocaleString()}`);
|
|
3016
|
+
* @returns Promise resolving to array of detailed real-time data including bid/ask, volume, and timestamps
|
|
2873
3017
|
*
|
|
2874
|
-
*
|
|
2875
|
-
*
|
|
2876
|
-
*
|
|
3018
|
+
* @example
|
|
3019
|
+
* ```typescript
|
|
3020
|
+
* // Get detailed data for multiple stocks
|
|
3021
|
+
* const detailedData = await fmp.stock.getRealTimePriceForMultipleStocks([
|
|
3022
|
+
* 'AAPL', 'MSFT', 'GOOGL'
|
|
3023
|
+
* ]);
|
|
3024
|
+
*
|
|
3025
|
+
* detailedData.data.forEach(stock => {
|
|
3026
|
+
* console.log(`${stock.symbol}:`);
|
|
3027
|
+
* console.log(` Bid: $${stock.bidPrice} (${stock.bidSize} shares)`);
|
|
3028
|
+
* console.log(` Ask: $${stock.askPrice} (${stock.askSize} shares)`);
|
|
3029
|
+
* console.log(` Last: $${stock.lastSalePrice} (${stock.lastSaleSize} shares)`);
|
|
3030
|
+
* console.log(` Volume: ${stock.volume.toLocaleString()}`);
|
|
2877
3031
|
* });
|
|
3032
|
+
*
|
|
3033
|
+
* // Get detailed data for single stock
|
|
3034
|
+
* const aaplDetailed = await fmp.stock.getRealTimePriceForMultipleStocks(['AAPL']);
|
|
2878
3035
|
* ```
|
|
2879
3036
|
*
|
|
2880
|
-
* @see {@link https://site.financialmodelingprep.com/developer/docs#
|
|
3037
|
+
* @see {@link https://site.financialmodelingprep.com/developer/docs#real-time-full-price-quote|FMP Real-Time Full Price Documentation}
|
|
2881
3038
|
*/
|
|
2882
|
-
|
|
3039
|
+
getRealTimePriceForMultipleStocks(symbols: string[]): Promise<APIResponse<StockRealTimePriceFull[]>>;
|
|
2883
3040
|
}
|
|
2884
3041
|
|
|
2885
3042
|
/**
|
|
@@ -2913,20 +3070,21 @@ declare class MutualFundEndpoints {
|
|
|
2913
3070
|
* ```
|
|
2914
3071
|
*/
|
|
2915
3072
|
declare class FMP {
|
|
2916
|
-
readonly stock: StockEndpoints;
|
|
2917
|
-
readonly financial: FinancialEndpoints;
|
|
2918
|
-
readonly etf: ETFEndpoints;
|
|
2919
|
-
readonly economic: EconomicEndpoints;
|
|
2920
|
-
readonly market: MarketEndpoints;
|
|
2921
|
-
readonly list: ListEndpoints;
|
|
2922
3073
|
readonly calendar: CalendarEndpoints;
|
|
2923
3074
|
readonly company: CompanyEndpoints;
|
|
2924
|
-
readonly
|
|
2925
|
-
readonly
|
|
2926
|
-
readonly
|
|
3075
|
+
readonly economic: EconomicEndpoints;
|
|
3076
|
+
readonly etf: ETFEndpoints;
|
|
3077
|
+
readonly financial: FinancialEndpoints;
|
|
2927
3078
|
readonly insider: InsiderEndpoints;
|
|
2928
|
-
readonly
|
|
3079
|
+
readonly institutional: InstitutionalEndpoints;
|
|
3080
|
+
readonly list: ListEndpoints;
|
|
3081
|
+
readonly market: MarketEndpoints;
|
|
2929
3082
|
readonly mutualFund: MutualFundEndpoints;
|
|
3083
|
+
readonly quote: QuoteEndpoints;
|
|
3084
|
+
readonly screener: ScreenerEndpoints;
|
|
3085
|
+
readonly sec: SECEndpoints;
|
|
3086
|
+
readonly senateHouse: SenateHouseEndpoints;
|
|
3087
|
+
readonly stock: StockEndpoints;
|
|
2930
3088
|
constructor(config?: FMPConfig);
|
|
2931
3089
|
/**
|
|
2932
3090
|
* Get the underlying client instance for advanced usage
|
|
@@ -2986,4 +3144,4 @@ declare const SECTORS: {
|
|
|
2986
3144
|
readonly COMMUNICATION_SERVICES: "Communication Services";
|
|
2987
3145
|
};
|
|
2988
3146
|
|
|
2989
|
-
export { APIResponse, AvailableIndexesList, BalanceSheet, BalanceSheetGrowth, BeneficialOwnershipResponse, CalendarEndpoints, CashFlowStatement, CashflowGrowth, CikMapperBySymbolResponse, CikMapperResponse, CompanyEndpoints, CompanyNotes, CompanyProfile, CompanyTranscriptData, CryptoList, DEFAULT_LIMIT, DEFAULT_TIMEOUT, DividendsCalendar, ETFCountryWeighting, ETFEndpoints, ETFHolder, ETFHolding, ETFHoldingDates, ETFList, ETFProfile, ETFStockExposure, ETFWeighting, EXCHANGES, EarningsCalendar, EarningsCallTranscript, EarningsConfirmed, EarningsHistorical, EarningsSurprises, EconomicEndpoints, EconomicIndicator, EconomicsCalendar, EnterpriseValue, ExecutiveCompensation, FMP, FMPClient, FMPConfig, FailToDeliverResponse, FinancialEndpoints, FinancialGrowth, FinancialRatios, ForexList, Form13FResponse, HistoricalEmployeeCount, HistoricalPriceData, HistoricalPriceResponse, HistoricalSharesFloat, HouseTradingResponse, IPOCalendar, IncomeGrowth, IncomeStatement, IndustryClassification, IndustryClassificationCode, InsiderEndpoints, InsiderTradeStatisticsResponse, InsiderTradingRSSResponse, InsiderTradingSearchResponse, InsidersBySymbolResponse, InstitutionalEndpoints, InstitutionalHolderResponse, KeyMetrics, ListEndpoints, MAX_LIMIT, MarketCap, MarketEndpoints, MarketHours, MarketIndex, MarketPerformance, MarketSectorPerformance, MutualFundEndpoints, MutualFundHolding, PERIODS, Quote, QuoteEndpoints, RSSFeed8KItem, RSSFeedAllItem, RSSFeedItem, RSSFeedV3Item, SECEndpoints, SECFiling, SECTORS, SenateHouseEndpoints, SenateHouseTradingByNameResponse, SenateTradingResponse, SharesFloat, SplitsCalendar, StockDividendResponse, StockEndpoints, StockList, StockRealTimePrice, StockRealTimePriceFull, StockSplitResponse, TransactionType, TransactionTypesResponse, TreasuryRate, formatCurrency, formatDate, formatLargeNumber, formatPercentage, formatVolume };
|
|
3147
|
+
export { APIResponse, AvailableCountries, AvailableExchanges, AvailableIndexesList, AvailableIndustries, AvailableSectors, BalanceSheet, BalanceSheetGrowth, BeneficialOwnershipResponse, CalendarEndpoints, CashFlowStatement, CashflowGrowth, CikMapperBySymbolResponse, CikMapperResponse, CompanyEndpoints, CompanyNotes, CompanyProfile, CompanyTranscriptData, CryptoList, DEFAULT_LIMIT, DEFAULT_TIMEOUT, DividendsCalendar, ETFCountryWeighting, ETFEndpoints, ETFHolder, ETFHolding, ETFHoldingDates, ETFList, ETFProfile, ETFStockExposure, ETFWeighting, EXCHANGES, EarningsCalendar, EarningsCallTranscript, EarningsConfirmed, EarningsHistorical, EarningsSurprises, EconomicEndpoints, EconomicIndicator, EconomicsCalendar, EnterpriseValue, ExecutiveCompensation, FMP, FMPClient, FMPConfig, FailToDeliverResponse, FinancialEndpoints, FinancialGrowth, FinancialRatios, ForexList, Form13FResponse, HistoricalEmployeeCount, HistoricalPriceData, HistoricalPriceResponse, HistoricalSharesFloat, HouseTradingResponse, IPOCalendar, IncomeGrowth, IncomeStatement, IndustryClassification, IndustryClassificationCode, InsiderEndpoints, InsiderTradeStatisticsResponse, InsiderTradingRSSResponse, InsiderTradingSearchResponse, InsidersBySymbolResponse, InstitutionalEndpoints, InstitutionalHolderResponse, KeyMetrics, ListEndpoints, MAX_LIMIT, MarketCap, MarketEndpoints, MarketHours, MarketIndex, MarketPerformance, MarketSectorPerformance, MutualFundEndpoints, MutualFundHolding, PERIODS, Quote, QuoteEndpoints, RSSFeed8KItem, RSSFeedAllItem, RSSFeedItem, RSSFeedV3Item, SECEndpoints, SECFiling, SECTORS, Screener, ScreenerParams, SenateHouseEndpoints, SenateHouseTradingByNameResponse, SenateTradingResponse, SharesFloat, SplitsCalendar, StockDividendResponse, StockEndpoints, StockList, StockRealTimePrice, StockRealTimePriceFull, StockSplitResponse, TransactionType, TransactionTypesResponse, TreasuryRate, formatCurrency, formatDate, formatLargeNumber, formatPercentage, formatVolume };
|