fmp-node-api 0.0.6 → 0.0.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.mjs CHANGED
@@ -7,13 +7,22 @@ function unwrapSingleObject(data) {
7
7
  }
8
8
  return data;
9
9
  }
10
+ function normalizeArrayResponse(data) {
11
+ if (Array.isArray(data)) return data;
12
+ if (data == null) return [];
13
+ return data;
14
+ }
15
+ function normalizeObjectResponse(data) {
16
+ if (data == null) return {};
17
+ return data;
18
+ }
10
19
  var FMPClient = class {
11
20
  constructor(config) {
12
21
  this.apiKey = config.apiKey;
13
22
  this.v3Client = this.createClient("https://financialmodelingprep.com/api/v3", config.timeout);
14
23
  this.v4Client = this.createClient("https://financialmodelingprep.com/api/v4", config.timeout);
15
24
  this.stableClient = this.createClient(
16
- "https://financialmodelingprep.com/api/stable",
25
+ "https://financialmodelingprep.com/stable",
17
26
  config.timeout
18
27
  );
19
28
  }
@@ -29,37 +38,55 @@ var FMPClient = class {
29
38
  });
30
39
  return client;
31
40
  }
32
- // Standard get method - returns raw API response
41
+ /**
42
+ * Standard get method - returns raw API response
43
+ *
44
+ * For endpoints that return arrays, this will always return an array (possibly empty) for `data` when success is true.
45
+ * For endpoints that return objects, data is returned as-is.
46
+ */
33
47
  async get(endpoint, version = "v3", params) {
34
48
  const client = this.getClientForVersion(version);
35
49
  try {
36
50
  const response = await client.get(endpoint, { params });
51
+ let data = response.data;
52
+ if (Array.isArray(data) || data == null) {
53
+ data = normalizeArrayResponse(data);
54
+ }
37
55
  return {
38
56
  success: true,
39
- data: response.data,
57
+ data,
58
+ error: null,
40
59
  status: response.status
41
60
  };
42
61
  } catch (error) {
43
62
  return {
44
63
  success: false,
64
+ data: null,
45
65
  error: error.message || "Unknown error occurred",
46
66
  status: error.response?.status || 500
47
67
  };
48
68
  }
49
69
  }
50
- // Get method for single-object endpoints - unwraps single-item arrays
70
+ /**
71
+ * Get method for single-object endpoints - unwraps single-item arrays
72
+ *
73
+ * For endpoints that return single objects, this will always return an object (possibly empty) for `data` when success is true.
74
+ */
51
75
  async getSingle(endpoint, version = "v3", params) {
52
76
  const client = this.getClientForVersion(version);
53
77
  try {
54
78
  const response = await client.get(endpoint, { params });
79
+ const data = normalizeObjectResponse(unwrapSingleObject(response.data));
55
80
  return {
56
81
  success: true,
57
- data: unwrapSingleObject(response.data),
82
+ data,
83
+ error: null,
58
84
  status: response.status
59
85
  };
60
86
  } catch (error) {
61
87
  return {
62
88
  success: false,
89
+ data: null,
63
90
  error: error.message || "Unknown error occurred",
64
91
  status: error.response?.status || 500
65
92
  };
@@ -202,6 +229,79 @@ var StockEndpoints = class {
202
229
  }) {
203
230
  return this.client.getSingle(`/historical-price-full/stock_dividend/${symbol}`, "v3");
204
231
  }
232
+ /**
233
+ * Get stock real time price
234
+ * @param symbol - The stock symbol to get the real time price for
235
+ * @returns The real time price for the stock
236
+ */
237
+ async getRealTimePrice({
238
+ symbols
239
+ }) {
240
+ const url = `stock/real-time-price/${symbols.join(",")}`;
241
+ const result = await this.client.get(url, "v3");
242
+ if (result.success && result.data && !Array.isArray(result.data)) {
243
+ const data = result.data;
244
+ if (typeof data === "object" && data !== null && "companiesPriceList" in data && Array.isArray(data.companiesPriceList)) {
245
+ const filteredData2 = data.companiesPriceList.filter((item) => item && item.symbol);
246
+ if (filteredData2.length > 0) {
247
+ return { ...result, data: filteredData2 };
248
+ }
249
+ }
250
+ if (typeof data === "object" && data !== null && "stockList" in data && Array.isArray(data.stockList)) {
251
+ const filteredData2 = data.stockList.filter((item) => item && item.symbol);
252
+ if (filteredData2.length > 0) {
253
+ return { ...result, data: filteredData2 };
254
+ }
255
+ }
256
+ if (data.symbol) {
257
+ return { ...result, data: [data] };
258
+ }
259
+ if (symbols.length === 1) {
260
+ console.warn(`No real-time price data found for symbol: ${symbols[0]}`);
261
+ }
262
+ return { ...result, data: [] };
263
+ }
264
+ const filteredData = result.data.filter((item) => item && item.symbol);
265
+ return { ...result, data: filteredData };
266
+ }
267
+ /**
268
+ * Get stock real time price full
269
+ * https://site.financialmodelingprep.com/developer/docs#real-time-full-price-quote
270
+ * @param symbols - The stock symbols to get the real time price for
271
+ * @returns The real time price for the stocks
272
+ */
273
+ async getRealTimePriceForMultipleStocks({
274
+ symbols
275
+ }) {
276
+ const url = `stock/full/real-time-price/${symbols.join(",")}`;
277
+ const result = await this.client.get(url, "v3");
278
+ if (result.success && result.data && !Array.isArray(result.data)) {
279
+ const data = result.data;
280
+ if (typeof data === "object" && data !== null && "companiesPriceList" in data && Array.isArray(data.companiesPriceList)) {
281
+ const filteredData2 = data.companiesPriceList.filter((item) => item && item.symbol);
282
+ if (filteredData2.length > 0) {
283
+ return { ...result, data: filteredData2 };
284
+ }
285
+ }
286
+ if (typeof data === "object" && data !== null && "stockList" in data && Array.isArray(data.stockList)) {
287
+ const filteredData2 = data.stockList.filter((item) => item && item.symbol);
288
+ if (filteredData2.length > 0) {
289
+ return { ...result, data: filteredData2 };
290
+ }
291
+ }
292
+ if (data.symbol) {
293
+ return { ...result, data: [data] };
294
+ }
295
+ if (symbols.length === 1) {
296
+ console.warn(`No full real-time price data found for symbol: ${symbols[0]}`);
297
+ }
298
+ return { ...result, data: [] };
299
+ }
300
+ const filteredData = result.data.filter(
301
+ (item) => item && item.symbol
302
+ );
303
+ return { ...result, data: filteredData };
304
+ }
205
305
  };
206
306
 
207
307
  // src/endpoints/financial.ts
@@ -742,6 +842,19 @@ var CalendarEndpoints = class {
742
842
  if (to) params.to = to;
743
843
  return this.client.get("/earning_calendar", "v3", params);
744
844
  }
845
+ /**
846
+ * Get earnings confirmed
847
+ * https://site.financialmodelingprep.com/developer/docs#earnings-confirmed-earnings
848
+ * @param from - The start date to get the earnings confirmed for
849
+ * @param to - The end date to get the earnings confirmed for
850
+ * @returns The earnings confirmed
851
+ */
852
+ async getEarningsConfirmed({ from, to } = {}) {
853
+ const params = {};
854
+ if (from) params.from = from;
855
+ if (to) params.to = to;
856
+ return this.client.get("/earning-calendar-confirmed", "v4", params);
857
+ }
745
858
  /**
746
859
  * Get dividends calendar
747
860
  * https://site.financialmodelingprep.com/developer/docs#dividends-calendar-dividends
@@ -807,9 +920,7 @@ var CompanyEndpoints = class {
807
920
  * @param symbol - The stock symbol to get the profile for
808
921
  * @returns Get a comprehensive overview of a company with our Company Profile endpoint. This endpoint provides key information such as price, beta, market capitalization, description, headquarters, and more.
809
922
  */
810
- async getCompanyProfile({
811
- symbol
812
- }) {
923
+ async getCompanyProfile({ symbol }) {
813
924
  return this.client.getSingle(`/profile/${symbol}`, "v3");
814
925
  }
815
926
  /**
@@ -830,9 +941,7 @@ var CompanyEndpoints = class {
830
941
  * @param symbol - The stock symbol to get the notes for
831
942
  * @returns Stay up-to-date on a company's financial condition, operations, and risks with our Company Notes endpoint. This endpoint provides information about notes reported by a company in their financial statements.
832
943
  */
833
- async getCompanyNotes({
834
- symbol
835
- }) {
944
+ async getCompanyNotes({ symbol }) {
836
945
  const params = { symbol };
837
946
  return this.client.get(`/company-notes`, "v4", params);
838
947
  }
@@ -886,6 +995,18 @@ var CompanyEndpoints = class {
886
995
  const params = { year, quarter };
887
996
  return this.client.getSingle(`/earning_call_transcript/${symbol}`, "v3", params);
888
997
  }
998
+ /**
999
+ * Get company transcript dates
1000
+ * https://site.financialmodelingprep.com/developer/docs#transcript-dates-earnings-transcripts
1001
+ * @param symbol - The stock symbol to get the transcript data for
1002
+ * @returns The FMP Company Transcript Data endpoint provides the transcript data for a company's earnings call.
1003
+ */
1004
+ async getCompanyTranscriptData({
1005
+ symbol
1006
+ }) {
1007
+ const params = { symbol };
1008
+ return this.client.getSingle(`/earning_call_transcript`, "v4", params);
1009
+ }
889
1010
  };
890
1011
 
891
1012
  // src/endpoints/quote.ts
@@ -961,6 +1082,15 @@ var SenateHouseEndpoints = class {
961
1082
  const { page } = params;
962
1083
  return this.client.get("/senate-trading-rss-feed", "v4", { page });
963
1084
  }
1085
+ /** Get Senate trades by name
1086
+ * https://site.financialmodelingprep.com/developer/docs/stable#senate-trading-by-name
1087
+ * @param name - The name of the senator to get the trades for
1088
+ * @returns Senate trades by name
1089
+ */
1090
+ async getSenateTradingByName(params) {
1091
+ const { name } = params;
1092
+ return this.client.get("/senate-trades-by-name", "stable", { name });
1093
+ }
964
1094
  /**
965
1095
  * Get house trading data only
966
1096
  * https://site.financialmodelingprep.com/developer/docs#house-disclosure
@@ -980,6 +1110,298 @@ var SenateHouseEndpoints = class {
980
1110
  const { page } = params;
981
1111
  return this.client.get("/senate-disclosure-rss-feed", "v4", { page });
982
1112
  }
1113
+ /** Get house trading by name
1114
+ * https://site.financialmodelingprep.com/developer/docs/stable#house-trading-by-name
1115
+ * @param name - The name of the representative to get the trades for
1116
+ * @returns House trading by name
1117
+ */
1118
+ async getHouseTradingByName(params) {
1119
+ const { name } = params;
1120
+ return this.client.get("/house-trades-by-name", "stable", { name });
1121
+ }
1122
+ };
1123
+
1124
+ // src/endpoints/institutional.ts
1125
+ var InstitutionalEndpoints = class {
1126
+ constructor(client) {
1127
+ this.client = client;
1128
+ }
1129
+ /**
1130
+ * Get Form 13F institutional stock ownership data
1131
+ * https://site.financialmodelingprep.com/developer/docs#form-13f-13f---institutional-stock-ownership
1132
+ * @param symbol - The stock symbol to get the Form 13F data for
1133
+ * @param date - The date to get the Form 13F data for (optional)
1134
+ * @returns Form 13F institutional stock ownership data
1135
+ */
1136
+ async getForm13F(params) {
1137
+ const { cik, date } = params;
1138
+ const queryParams = {};
1139
+ if (date) queryParams.date = date;
1140
+ return this.client.get(`/form-thirteen/${cik}`, "v3", queryParams);
1141
+ }
1142
+ /**
1143
+ * Get Form 13F dates for institutional stock ownership
1144
+ * https://site.financialmodelingprep.com/developer/docs#form-13f-dates-13f---institutional-stock-ownership
1145
+ * @param symbol - The stock symbol to get the Form 13F dates for
1146
+ * @returns Form 13F dates for institutional stock ownership
1147
+ */
1148
+ async getForm13FDates(params) {
1149
+ const { cik } = params;
1150
+ return this.client.get(`/form-thirteen-date/${cik}`, "v3");
1151
+ }
1152
+ /**
1153
+ * Get institutional holders data
1154
+ * https://site.financialmodelingprep.com/developer/docs#institutional-holder-13f---institutional-stock-ownership
1155
+ * @param symbol - The stock symbol to get the institutional holders for
1156
+ * @returns Institutional holders data
1157
+ */
1158
+ async getInstitutionalHolders(params) {
1159
+ const { symbol } = params;
1160
+ return this.client.get(`/institutional-holder/${symbol}`, "v3");
1161
+ }
1162
+ };
1163
+
1164
+ // src/endpoints/insider.ts
1165
+ var InsiderEndpoints = class {
1166
+ constructor(client) {
1167
+ this.client = client;
1168
+ }
1169
+ /**
1170
+ * Get insider trading RSS feed
1171
+ * https://site.financialmodelingprep.com/developer/docs#insider-trades-rss-insider-trading
1172
+ * @param params - Parameters for the RSS feed request
1173
+ * @returns An RSS feed of insider trades, updated in real time
1174
+ */
1175
+ async getInsiderTradingRSS({
1176
+ page
1177
+ }) {
1178
+ return this.client.get(`/insider-trading-rss-feed`, "v4", { page });
1179
+ }
1180
+ /**
1181
+ * Search for insider trades
1182
+ * https://site.financialmodelingprep.com/developer/docs#insider-trades-search-insider-trading
1183
+ * @param params - Parameters for the insider trading search
1184
+ * @returns A list of insider trades filtered by the provided parameters
1185
+ */
1186
+ async searchInsiderTrading({
1187
+ symbol,
1188
+ reportingCik,
1189
+ companyCik,
1190
+ transactionType,
1191
+ page
1192
+ }) {
1193
+ const params = { page };
1194
+ if (symbol) params.symbol = symbol;
1195
+ if (reportingCik) params.reportingCik = reportingCik;
1196
+ if (companyCik) params.companyCik = companyCik;
1197
+ if (transactionType) params.transactionType = transactionType;
1198
+ return this.client.get(`/insider-trading`, "v4", params);
1199
+ }
1200
+ /**
1201
+ * Get transaction types
1202
+ * https://site.financialmodelingprep.com/developer/docs#transaction-types-insider-trading
1203
+ * @returns A list of all insider transaction types
1204
+ */
1205
+ async getTransactionTypes() {
1206
+ return this.client.get(`/insider-trading-transaction-type`, "v4");
1207
+ }
1208
+ /**
1209
+ * Get insiders by symbol
1210
+ * https://site.financialmodelingprep.com/developer/docs#insiders-by-symbol-insider-trading
1211
+ * @param params - Parameters for the insiders request
1212
+ * @returns A list of insiders for a specific company
1213
+ */
1214
+ async getInsidersBySymbol({
1215
+ symbol
1216
+ }) {
1217
+ return this.client.get(`/insider-roaster`, "v4", { symbol });
1218
+ }
1219
+ /**
1220
+ * Get insider trade statistics
1221
+ * https://site.financialmodelingprep.com/developer/docs#insider-trade-statistics-insider-trading
1222
+ * @param params - Parameters for the statistics request
1223
+ * @returns Statistics on insider trading activity for a specific company
1224
+ */
1225
+ async getInsiderTradeStatistics({
1226
+ symbol
1227
+ }) {
1228
+ return this.client.get(`/insider-roaster-statistic`, "v4", { symbol });
1229
+ }
1230
+ /**
1231
+ * Get CIK mapper
1232
+ * https://site.financialmodelingprep.com/developer/docs#cik-mapper-insider-trading
1233
+ * @param params - Parameters for the CIK mapper request
1234
+ * @returns A list of CIK numbers and corresponding company names
1235
+ */
1236
+ async getCikMapper({ page }) {
1237
+ return this.client.get(`/mapper-cik-name`, "v4", { page });
1238
+ }
1239
+ /**
1240
+ * Get CIK mapper by name
1241
+ * https://site.financialmodelingprep.com/developer/docs#cik-mapper-by-name-insider-trading
1242
+ * @param params - Parameters for the CIK mapper by name request
1243
+ * @returns A list of CIK numbers and corresponding names matching the search term
1244
+ */
1245
+ async getCikMapperByName({
1246
+ name,
1247
+ page = 0
1248
+ }) {
1249
+ return this.client.get(`/mapper-cik-name`, "v4", { name, page });
1250
+ }
1251
+ /**
1252
+ * Get CIK mapper by symbol
1253
+ * https://site.financialmodelingprep.com/developer/docs#cik-mapper-company-insider-trading
1254
+ * @param params - Parameters for the CIK mapper by symbol request
1255
+ * @returns CIK number and corresponding company name for a specific symbol
1256
+ */
1257
+ async getCikMapperBySymbol({
1258
+ symbol
1259
+ }) {
1260
+ return this.client.getSingle(`/mapper-cik-company/${symbol}`, "v4");
1261
+ }
1262
+ /**
1263
+ * Get beneficial ownership acquisitions
1264
+ * https://site.financialmodelingprep.com/developer/docs#acquisition-of-beneficial-ownership
1265
+ * @param params - Parameters for the beneficial ownership request
1266
+ * @returns A list of acquisitions of beneficial ownership for a specific company
1267
+ */
1268
+ async getBeneficialOwnership({
1269
+ symbol
1270
+ }) {
1271
+ return this.client.get(`/insider/ownership/acquisition_of_beneficial_ownership`, "v4", {
1272
+ symbol
1273
+ });
1274
+ }
1275
+ /**
1276
+ * Get fail to deliver data
1277
+ * https://site.financialmodelingprep.com/developer/docs#fail-to-deliver
1278
+ * @param params - Parameters for the fail to deliver request
1279
+ * @returns A list of fail to deliver data for a specific company
1280
+ */
1281
+ async getFailToDeliver({
1282
+ symbol,
1283
+ page = 0
1284
+ }) {
1285
+ return this.client.get(`/fail_to_deliver`, "v4", { symbol, page });
1286
+ }
1287
+ /**
1288
+ * Get all insider trades for a symbol (convenience method)
1289
+ * @param symbol - The stock symbol to get insider trades for
1290
+ * @param page - Page number for pagination (default: 0)
1291
+ * @returns A list of insider trades for the specified symbol
1292
+ */
1293
+ async getInsiderTradesBySymbol(symbol, page = 0) {
1294
+ return this.searchInsiderTrading({ symbol, page });
1295
+ }
1296
+ /**
1297
+ * Get insider trades by transaction type (convenience method)
1298
+ * @param transactionType - The transaction type to filter by
1299
+ * @param page - Page number for pagination (default: 0)
1300
+ * @returns A list of insider trades filtered by transaction type
1301
+ */
1302
+ async getInsiderTradesByType(transactionType, page = 0) {
1303
+ return this.searchInsiderTrading({ transactionType, page });
1304
+ }
1305
+ /**
1306
+ * Get insider trades by reporting CIK (convenience method)
1307
+ * @param reportingCik - The reporting CIK to filter by
1308
+ * @param page - Page number for pagination (default: 0)
1309
+ * @returns A list of insider trades filtered by reporting CIK
1310
+ */
1311
+ async getInsiderTradesByReportingCik(reportingCik, page = 0) {
1312
+ return this.searchInsiderTrading({ reportingCik, page });
1313
+ }
1314
+ /**
1315
+ * Get insider trades by company CIK (convenience method)
1316
+ * @param companyCik - The company CIK to filter by
1317
+ * @param page - Page number for pagination (default: 0)
1318
+ * @returns A list of insider trades filtered by company CIK
1319
+ */
1320
+ async getInsiderTradesByCompanyCik(companyCik, page = 0) {
1321
+ return this.searchInsiderTrading({ companyCik, page });
1322
+ }
1323
+ };
1324
+
1325
+ // src/endpoints/sec.ts
1326
+ var SECEndpoints = class {
1327
+ constructor(client) {
1328
+ this.client = client;
1329
+ }
1330
+ /**
1331
+ * Get RSS feed of SEC filings
1332
+ * https://site.financialmodelingprep.com/developer/docs#rss-feed-securities-and-exchange-commission-(s.e.c)
1333
+ * @param params - RSS feed parameters
1334
+ * @returns A real-time feed of SEC filings from publicly traded companies, including the filing type, link to SEC page, and direct link to the filing. This endpoint can be used to stay up-to-date on the latest SEC filings for all companies or for a specific set of companies.
1335
+ */
1336
+ async getRSSFeed(params) {
1337
+ return this.client.get("/rss_feed", "v4", params);
1338
+ }
1339
+ /**
1340
+ * Get RSS feed of all SEC filings
1341
+ * https://site.financialmodelingprep.com/developer/docs#rss-feed-all-securities-and-exchange-commission-(s.e.c)
1342
+ * @param params - RSS feed all parameters
1343
+ * @returns A real-time feed of all SEC filings from publicly traded companies in the latest RSS feed format. This endpoint provides a comprehensive overview of all SEC filings, including the filing type, link to SEC page, and direct link to the filing.
1344
+ */
1345
+ async getRSSFeedAll(params) {
1346
+ return this.client.get("/rss_feed_all", "v4", params);
1347
+ }
1348
+ /**
1349
+ * Get RSS feed V3 of SEC filings
1350
+ * https://site.financialmodelingprep.com/developer/docs#rss-feed-v3-securities-and-exchange-commission-(s.e.c)
1351
+ * @param params - RSS feed V3 parameters
1352
+ * @returns A real-time feed of SEC filings from publicly traded companies in the latest RSS feed format (V3)
1353
+ */
1354
+ async getRSSFeedV3(params) {
1355
+ return this.client.get("/rss_feed", "v3", params);
1356
+ }
1357
+ /**
1358
+ * Get RSS feed of 8-K SEC filings
1359
+ * https://site.financialmodelingprep.com/developer/docs#rss-feed-8-k-securities-and-exchange-commission-(s.e.c)
1360
+ * @param params - RSS feed 8-K parameters
1361
+ * @returns A real-time feed of 8-K SEC filings from publicly traded companies
1362
+ */
1363
+ async getRSSFeed8K(params) {
1364
+ return this.client.get("/rss_feed_8k", "v4", params);
1365
+ }
1366
+ /**
1367
+ * Get SEC filings for a specific company
1368
+ * https://site.financialmodelingprep.com/developer/docs#sec-filings-securities-and-exchange-commission-(s.e.c)
1369
+ * @param symbol - The stock symbol to get SEC filings for
1370
+ * @param params - SEC filings parameters
1371
+ * @returns Access direct links to SEC filings, including the filing type, link to the SEC page, and direct link to the specific filing
1372
+ */
1373
+ async getSECFilings({
1374
+ symbol,
1375
+ params
1376
+ }) {
1377
+ return this.client.get(`/sec_filings/${symbol}`, "v3", params);
1378
+ }
1379
+ /**
1380
+ * Get individual industry classification
1381
+ * https://site.financialmodelingprep.com/developer/docs#individual-industry-classification-standard-industrial-classification
1382
+ * @param params - Industry classification parameters
1383
+ * @returns Identify the industry in which a particular company operates, based on the Standard Industrial Classification (SIC) system
1384
+ */
1385
+ async getIndividualIndustryClassification(params) {
1386
+ return this.client.getSingle("/standard_industrial_classification", "v4", params);
1387
+ }
1388
+ /**
1389
+ * Get all industry classifications
1390
+ * https://site.financialmodelingprep.com/developer/docs#all-industry-classification-standard-industrial-classification
1391
+ * @returns Get a comprehensive overview of all industries, classified according to the SIC system
1392
+ */
1393
+ async getAllIndustryClassifications() {
1394
+ return this.client.get("/standard_industrial_classification/all", "v4");
1395
+ }
1396
+ /**
1397
+ * Get industry classification codes
1398
+ * https://site.financialmodelingprep.com/developer/docs#industry-classification-codes-standard-industrial-classification
1399
+ * @param params - Industry classification codes parameters
1400
+ * @returns Learn more about the SIC system and identify the SIC code for a particular industry
1401
+ */
1402
+ async getIndustryClassificationCodes(params) {
1403
+ return this.client.get("/standard_industrial_classification_list", "v4", params);
1404
+ }
983
1405
  };
984
1406
 
985
1407
  // src/fmp.ts
@@ -997,6 +1419,9 @@ var FMP = class {
997
1419
  this.company = new CompanyEndpoints(client);
998
1420
  this.quote = new QuoteEndpoints(client);
999
1421
  this.senateHouse = new SenateHouseEndpoints(client);
1422
+ this.institutional = new InstitutionalEndpoints(client);
1423
+ this.insider = new InsiderEndpoints(client);
1424
+ this.sec = new SECEndpoints(client);
1000
1425
  this.forex = new ForexEndpoints(client);
1001
1426
  this.economic = new EconomicEndpoints(client);
1002
1427
  this.mutualFund = new MutualFundEndpoints(client);
@@ -1027,6 +1452,29 @@ var Exchange = /* @__PURE__ */ ((Exchange2) => {
1027
1452
  return Exchange2;
1028
1453
  })(Exchange || {});
1029
1454
 
1455
+ // src/types/insider.ts
1456
+ var TransactionType = /* @__PURE__ */ ((TransactionType2) => {
1457
+ TransactionType2["AWARD"] = "A-Award";
1458
+ TransactionType2["CONVERSION"] = "C-Conversion";
1459
+ TransactionType2["RETURN"] = "D-Return";
1460
+ TransactionType2["EXPIRE_SHORT"] = "E-ExpireShort";
1461
+ TransactionType2["IN_KIND"] = "F-InKind";
1462
+ TransactionType2["GIFT"] = "G-Gift";
1463
+ TransactionType2["EXPIRE_LONG"] = "H-ExpireLong";
1464
+ TransactionType2["DISCRETIONARY"] = "I-Discretionary";
1465
+ TransactionType2["OTHER"] = "J-Other";
1466
+ TransactionType2["SMALL"] = "L-Small";
1467
+ TransactionType2["EXEMPT"] = "M-Exempt";
1468
+ TransactionType2["OUT_OF_THE_MONEY"] = "O-OutOfTheMoney";
1469
+ TransactionType2["PURCHASE"] = "P-Purchase";
1470
+ TransactionType2["SALE"] = "S-Sale";
1471
+ TransactionType2["TENDER"] = "U-Tender";
1472
+ TransactionType2["WILL"] = "W-Will";
1473
+ TransactionType2["IN_THE_MONEY"] = "X-InTheMoney";
1474
+ TransactionType2["TRUST"] = "Z-Trust";
1475
+ return TransactionType2;
1476
+ })(TransactionType || {});
1477
+
1030
1478
  // src/utils/formatting.ts
1031
1479
  function formatCurrency(value, currency = "USD") {
1032
1480
  return new Intl.NumberFormat("en-US", {
@@ -1146,6 +1594,6 @@ var HTTP_STATUS = {
1146
1594
  INTERNAL_SERVER_ERROR: 500
1147
1595
  };
1148
1596
 
1149
- export { COUNTRIES, CalendarEndpoints, CompanyEndpoints, CryptoEndpoints, DEFAULT_LIMIT, DEFAULT_TIMEOUT, ERROR_MESSAGES, ETFEndpoints, EXCHANGES, EconomicEndpoints, Exchange, FMP, FMPClient, FinancialEndpoints, ForexEndpoints, HTTP_STATUS, ListEndpoints, MAX_LIMIT, MarketEndpoints, MutualFundEndpoints, PERIODS, Period, QuoteEndpoints, SECTORS, SenateHouseEndpoints, StockEndpoints, formatCurrency, formatDate, formatLargeNumber, formatNumber, formatPercentage, formatReadableDate, formatTimestamp, formatVolume, validateApiKey, validateDate, validateLimit, validatePage, validatePeriod, validateSymbol };
1597
+ export { COUNTRIES, CalendarEndpoints, CompanyEndpoints, CryptoEndpoints, DEFAULT_LIMIT, DEFAULT_TIMEOUT, ERROR_MESSAGES, ETFEndpoints, EXCHANGES, EconomicEndpoints, Exchange, FMP, FMPClient, FinancialEndpoints, ForexEndpoints, HTTP_STATUS, InsiderEndpoints, InstitutionalEndpoints, ListEndpoints, MAX_LIMIT, MarketEndpoints, MutualFundEndpoints, PERIODS, Period, QuoteEndpoints, SECEndpoints, SECTORS, SenateHouseEndpoints, StockEndpoints, TransactionType, formatCurrency, formatDate, formatLargeNumber, formatNumber, formatPercentage, formatReadableDate, formatTimestamp, formatVolume, validateApiKey, validateDate, validateLimit, validatePage, validatePeriod, validateSymbol };
1150
1598
  //# sourceMappingURL=index.mjs.map
1151
1599
  //# sourceMappingURL=index.mjs.map