finimpulse-mcp-server 1.1.0 → 1.3.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +113 -15
- package/build/tools/events/tickers/handler.js +4 -0
- package/build/tools/events/tickers/handler.js.map +1 -0
- package/build/tools/events/tickers/index.js +6 -0
- package/build/tools/events/tickers/index.js.map +1 -0
- package/build/tools/events/tickers/schema.js +11 -0
- package/build/tools/events/tickers/schema.js.map +1 -0
- package/build/tools/events/tickers/types.js +2 -0
- package/build/tools/events/tickers/types.js.map +1 -0
- package/build/tools/historical/index.js +1 -1
- package/build/tools/historical/index.js.map +1 -1
- package/build/tools/holdings/history/handler.js +4 -0
- package/build/tools/holdings/history/handler.js.map +1 -0
- package/build/tools/holdings/history/index.js +6 -0
- package/build/tools/holdings/history/index.js.map +1 -0
- package/build/tools/holdings/history/schema.js +12 -0
- package/build/tools/holdings/history/schema.js.map +1 -0
- package/build/tools/holdings/history/types.js +2 -0
- package/build/tools/holdings/history/types.js.map +1 -0
- package/build/tools/holdings/history-dates/handler.js +5 -0
- package/build/tools/holdings/history-dates/handler.js.map +1 -0
- package/build/tools/holdings/history-dates/index.js +6 -0
- package/build/tools/holdings/history-dates/index.js.map +1 -0
- package/build/tools/holdings/history-dates/schema.js +9 -0
- package/build/tools/holdings/history-dates/schema.js.map +1 -0
- package/build/tools/holdings/history-dates/types.js +2 -0
- package/build/tools/holdings/history-dates/types.js.map +1 -0
- package/build/tools/index.js +22 -0
- package/build/tools/index.js.map +1 -1
- package/build/tools/macro-economics/handler.js +4 -0
- package/build/tools/macro-economics/handler.js.map +1 -0
- package/build/tools/macro-economics/index.js +6 -0
- package/build/tools/macro-economics/index.js.map +1 -0
- package/build/tools/macro-economics/schema.js +10 -0
- package/build/tools/macro-economics/schema.js.map +1 -0
- package/build/tools/macro-economics/types.js +2 -0
- package/build/tools/macro-economics/types.js.map +1 -0
- package/build/tools/market/calendars/handler.js +4 -0
- package/build/tools/market/calendars/handler.js.map +1 -0
- package/build/tools/market/calendars/index.js +6 -0
- package/build/tools/market/calendars/index.js.map +1 -0
- package/build/tools/market/calendars/schema.js +10 -0
- package/build/tools/market/calendars/schema.js.map +1 -0
- package/build/tools/market/calendars/types.js +2 -0
- package/build/tools/market/calendars/types.js.map +1 -0
- package/build/tools/market/index/handler.js +4 -0
- package/build/tools/market/index/handler.js.map +1 -0
- package/build/tools/market/index/index.js +6 -0
- package/build/tools/market/index/index.js.map +1 -0
- package/build/tools/market/index/schema.js +15 -0
- package/build/tools/market/index/schema.js.map +1 -0
- package/build/tools/market/index/types.js +2 -0
- package/build/tools/market/index/types.js.map +1 -0
- package/build/tools/market-price/handler.js +4 -0
- package/build/tools/market-price/handler.js.map +1 -0
- package/build/tools/market-price/index.js +6 -0
- package/build/tools/market-price/index.js.map +1 -0
- package/build/tools/market-price/schema.js +5 -0
- package/build/tools/market-price/schema.js.map +1 -0
- package/build/tools/market-price/types.js +2 -0
- package/build/tools/market-price/types.js.map +1 -0
- package/build/tools/metrics/handler.js +4 -0
- package/build/tools/metrics/handler.js.map +1 -0
- package/build/tools/metrics/index.js +6 -0
- package/build/tools/metrics/index.js.map +1 -0
- package/build/tools/metrics/schema.js +6 -0
- package/build/tools/metrics/schema.js.map +1 -0
- package/build/tools/metrics/types.js +2 -0
- package/build/tools/metrics/types.js.map +1 -0
- package/build/tools/news/index.js +1 -1
- package/build/tools/news/index.js.map +1 -1
- package/build/tools/news/schema.js +8 -46
- package/build/tools/news/schema.js.map +1 -1
- package/build/tools/search-lite/handler.js +4 -0
- package/build/tools/search-lite/handler.js.map +1 -0
- package/build/tools/search-lite/index.js +6 -0
- package/build/tools/search-lite/index.js.map +1 -0
- package/build/tools/search-lite/schema.js +63 -0
- package/build/tools/search-lite/schema.js.map +1 -0
- package/build/tools/search-lite/types.js +2 -0
- package/build/tools/search-lite/types.js.map +1 -0
- package/build/tools/sec-filings/events/handler.js +4 -0
- package/build/tools/sec-filings/events/handler.js.map +1 -0
- package/build/tools/sec-filings/events/index.js +6 -0
- package/build/tools/sec-filings/events/index.js.map +1 -0
- package/build/tools/sec-filings/events/schema.js +14 -0
- package/build/tools/sec-filings/events/schema.js.map +1 -0
- package/build/tools/sec-filings/events/types.js +2 -0
- package/build/tools/sec-filings/events/types.js.map +1 -0
- package/build/tools/summary-lite/handler.js +4 -0
- package/build/tools/summary-lite/handler.js.map +1 -0
- package/build/tools/summary-lite/index.js +6 -0
- package/build/tools/summary-lite/index.js.map +1 -0
- package/build/tools/summary-lite/schema.js +7 -0
- package/build/tools/summary-lite/schema.js.map +1 -0
- package/build/tools/summary-lite/types.js +2 -0
- package/build/tools/summary-lite/types.js.map +1 -0
- package/build/transports/http.js +2 -1
- package/build/transports/http.js.map +1 -1
- package/build/utils/filters.js +29 -0
- package/build/utils/filters.js.map +1 -1
- package/package.json +15 -3
package/README.md
CHANGED
|
@@ -4,6 +4,8 @@ A [Model Context Protocol (MCP)](https://modelcontextprotocol.io/) server that p
|
|
|
4
4
|
|
|
5
5
|
It allows AI systems to access FinImpulse data — including stocks, ETFs, mutual funds, fundamentals, and market indicators — using a standardized MCP interface. The server acts as a bridge between the FinImpulse API and any MCP-compatible client, enabling LLMs and automation tools to retrieve financial data in a consistent format without building custom integrations.
|
|
6
6
|
|
|
7
|
+
> **Hosted server available.** You can connect any Streamable HTTP MCP client directly to `https://mcp.finimpulse.com/mcp` and authenticate via OAuth — no API token setup required. See [Quick Start](#quick-start) below.
|
|
8
|
+
|
|
7
9
|
## How It Works
|
|
8
10
|
|
|
9
11
|
```
|
|
@@ -40,12 +42,96 @@ The MCP server translates tool calls from AI clients into FinImpulse API request
|
|
|
40
42
|
|
|
41
43
|
## Requirements
|
|
42
44
|
|
|
43
|
-
|
|
44
|
-
|
|
45
|
+
You can use FinImpulse MCP in two ways:
|
|
46
|
+
|
|
47
|
+
- **Hosted (recommended):** no requirements other than a [FinImpulse account](https://app.finimpulse.com). Authentication is handled via OAuth in the browser — no manual API token management.
|
|
48
|
+
- **Local (stdio):** [Node.js](https://nodejs.org/) 18+ and a FinImpulse API token (obtain it in the [FinImpulse Dashboard](https://app.finimpulse.com/developer/settings)).
|
|
45
49
|
|
|
46
50
|
## Quick Start
|
|
47
51
|
|
|
48
|
-
|
|
52
|
+
There are two ways to connect: use the hosted server at `https://mcp.finimpulse.com/mcp` (Streamable HTTP + OAuth), or run the server locally via `npx`.
|
|
53
|
+
|
|
54
|
+
---
|
|
55
|
+
|
|
56
|
+
### Option 1 — Hosted server (OAuth)
|
|
57
|
+
|
|
58
|
+
The FinImpulse-hosted MCP endpoint is available at:
|
|
59
|
+
|
|
60
|
+
```
|
|
61
|
+
https://mcp.finimpulse.com/mcp
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
It uses the [Streamable HTTP](https://modelcontextprotocol.io/specification/2025-03-26/basic/transports#streamable-http) transport and OAuth 2.0 — when you first connect, your MCP client will open a browser window to authorize access against your FinImpulse account. The client then stores the access token and forwards it automatically on every request. No API token needs to be configured by hand.
|
|
65
|
+
|
|
66
|
+
#### Cursor
|
|
67
|
+
|
|
68
|
+
Open `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project-level) and add:
|
|
69
|
+
|
|
70
|
+
```json
|
|
71
|
+
{
|
|
72
|
+
"mcpServers": {
|
|
73
|
+
"finimpulse": {
|
|
74
|
+
"url": "https://mcp.finimpulse.com/mcp"
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
```
|
|
79
|
+
|
|
80
|
+
#### VS Code (Copilot)
|
|
81
|
+
|
|
82
|
+
Open your VS Code `settings.json` and add:
|
|
83
|
+
|
|
84
|
+
```json
|
|
85
|
+
{
|
|
86
|
+
"mcp": {
|
|
87
|
+
"servers": {
|
|
88
|
+
"finimpulse": {
|
|
89
|
+
"url": "https://mcp.finimpulse.com/mcp"
|
|
90
|
+
}
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
|
+
}
|
|
94
|
+
```
|
|
95
|
+
|
|
96
|
+
#### Claude Desktop
|
|
97
|
+
|
|
98
|
+
Claude Desktop does not yet speak Streamable HTTP natively. Bridge through `mcp-remote`, which handles the OAuth flow in your browser and forwards requests over stdio:
|
|
99
|
+
|
|
100
|
+
```json
|
|
101
|
+
{
|
|
102
|
+
"mcpServers": {
|
|
103
|
+
"finimpulse": {
|
|
104
|
+
"command": "npx",
|
|
105
|
+
"args": ["-y", "mcp-remote", "https://mcp.finimpulse.com/mcp"]
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
#### ChatGPT
|
|
112
|
+
|
|
113
|
+
In the ChatGPT desktop app go to **Settings → Connectors → Add custom connector** and enter:
|
|
114
|
+
|
|
115
|
+
- URL: `https://mcp.finimpulse.com/mcp`
|
|
116
|
+
- Authentication: OAuth
|
|
117
|
+
|
|
118
|
+
#### Windsurf / Cline / other Streamable-HTTP clients
|
|
119
|
+
|
|
120
|
+
Any MCP client that supports the Streamable HTTP transport can use the URL directly:
|
|
121
|
+
|
|
122
|
+
```
|
|
123
|
+
https://mcp.finimpulse.com/mcp
|
|
124
|
+
```
|
|
125
|
+
|
|
126
|
+
For clients that only support stdio, use the `mcp-remote` bridge shown in the Claude Desktop example.
|
|
127
|
+
|
|
128
|
+
---
|
|
129
|
+
|
|
130
|
+
### Option 2 — Local (stdio via npx)
|
|
131
|
+
|
|
132
|
+
If you prefer to run the server in-process on your machine, use the npm package. You'll need a FinImpulse API token from the [FinImpulse Dashboard](https://app.finimpulse.com/developer/settings).
|
|
133
|
+
|
|
134
|
+
#### Claude Desktop
|
|
49
135
|
|
|
50
136
|
Open `claude_desktop_config.json`:
|
|
51
137
|
|
|
@@ -69,7 +155,7 @@ Add the server configuration:
|
|
|
69
155
|
}
|
|
70
156
|
```
|
|
71
157
|
|
|
72
|
-
|
|
158
|
+
#### Claude Code
|
|
73
159
|
|
|
74
160
|
```bash
|
|
75
161
|
claude mcp add finimpulse -- npx -y finimpulse-mcp-server
|
|
@@ -77,11 +163,7 @@ claude mcp add finimpulse -- npx -y finimpulse-mcp-server
|
|
|
77
163
|
|
|
78
164
|
Then set the `API_TOKEN` environment variable or pass it inline.
|
|
79
165
|
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
ChatGPT supports MCP via its desktop app. Add the server in **Settings → MCP Servers** with the same `npx` command.
|
|
83
|
-
|
|
84
|
-
### Cursor
|
|
166
|
+
#### Cursor
|
|
85
167
|
|
|
86
168
|
Open `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project-level) and add:
|
|
87
169
|
|
|
@@ -99,7 +181,7 @@ Open `~/.cursor/mcp.json` (global) or `.cursor/mcp.json` (project-level) and add
|
|
|
99
181
|
}
|
|
100
182
|
```
|
|
101
183
|
|
|
102
|
-
|
|
184
|
+
#### Windsurf
|
|
103
185
|
|
|
104
186
|
Open `~/.codeium/windsurf/mcp_config.json` and add:
|
|
105
187
|
|
|
@@ -117,7 +199,7 @@ Open `~/.codeium/windsurf/mcp_config.json` and add:
|
|
|
117
199
|
}
|
|
118
200
|
```
|
|
119
201
|
|
|
120
|
-
|
|
202
|
+
#### VS Code (Copilot)
|
|
121
203
|
|
|
122
204
|
Open your VS Code `settings.json` and add:
|
|
123
205
|
|
|
@@ -137,13 +219,13 @@ Open your VS Code `settings.json` and add:
|
|
|
137
219
|
}
|
|
138
220
|
```
|
|
139
221
|
|
|
140
|
-
|
|
222
|
+
#### Gemini CLI
|
|
141
223
|
|
|
142
224
|
```bash
|
|
143
225
|
gemini mcp add finimpulse -- npx -y finimpulse-mcp-server
|
|
144
226
|
```
|
|
145
227
|
|
|
146
|
-
|
|
228
|
+
#### Cline
|
|
147
229
|
|
|
148
230
|
Open Cline settings, go to **MCP Servers**, and add a new server with this config:
|
|
149
231
|
|
|
@@ -161,7 +243,7 @@ Open Cline settings, go to **MCP Servers**, and add a new server with this confi
|
|
|
161
243
|
}
|
|
162
244
|
```
|
|
163
245
|
|
|
164
|
-
|
|
246
|
+
#### Any MCP-Compatible Client (stdio)
|
|
165
247
|
|
|
166
248
|
```bash
|
|
167
249
|
API_TOKEN=your-api-token npx finimpulse-mcp-server
|
|
@@ -183,6 +265,8 @@ API_TOKEN=your-api-token npx finimpulse-mcp-server
|
|
|
183
265
|
| `get_histories` | Historical time-series: prices, dividends, splits, and capital gains with configurable date range and interval. |
|
|
184
266
|
| `get_profile` | Asset profile and descriptive metadata: identity, classification, governance, and fund-specific attributes. |
|
|
185
267
|
| `get_news` | Latest news and press releases with headlines, descriptions, related tickers, and provider info. |
|
|
268
|
+
| `get_market_index` | Search ~39,000 global market indices with latest close, daily change, 52-week range, and one-year return. |
|
|
269
|
+
| `get_sec_filings_events` | SEC filing events: filing dates, form types (10-K, 8-K, ...), document metadata, and source URLs. |
|
|
186
270
|
|
|
187
271
|
### Statistics & Performance
|
|
188
272
|
|
|
@@ -218,6 +302,8 @@ API_TOKEN=your-api-token npx finimpulse-mcp-server
|
|
|
218
302
|
|------|-------------|
|
|
219
303
|
| `get_holdings_general` | Portfolio composition and holdings-level aggregates: asset allocation, sector exposure. |
|
|
220
304
|
| `get_holdings_top_holdings` | Top holdings list with ticker, name, and weight as % of total net assets. |
|
|
305
|
+
| `get_holdings_history_dates` | Available historical holdings reporting dates for an ETF. Use before `get_holdings_history`. |
|
|
306
|
+
| `get_holdings_history` | Full ETF holdings composition (shares, weight, market value) on a historical reporting date. |
|
|
221
307
|
|
|
222
308
|
### Analyst Coverage & Ratings
|
|
223
309
|
|
|
@@ -236,11 +322,23 @@ API_TOKEN=your-api-token npx finimpulse-mcp-server
|
|
|
236
322
|
| `get_options_chain` | Full option chain for a given expiration: calls and puts with pricing, bid/ask, volume, open interest, and implied volatility. |
|
|
237
323
|
| `get_options_contracts` | Single option contract snapshot: pricing, bid/ask, volume, open interest, implied volatility, moneyness, and Greeks. |
|
|
238
324
|
|
|
325
|
+
### Events & Macroeconomics
|
|
326
|
+
|
|
327
|
+
| Tool | Description |
|
|
328
|
+
|------|-------------|
|
|
329
|
+
| `get_events_tickers` | Past and upcoming corporate events: earnings (EPS estimate/actual/surprise) and IPOs. |
|
|
330
|
+
| `get_market_calendars` | Macroeconomic release calendar: indicator releases by country with actual, prior, and originally reported values. |
|
|
331
|
+
| `get_macro_economics` | Annual country-level macroeconomic indicators (GDP, inflation, rates, trade, government finances). Source: OECD. |
|
|
332
|
+
|
|
239
333
|
## Configuration
|
|
240
334
|
|
|
335
|
+
When using the **hosted** server (`https://mcp.finimpulse.com/mcp`) no environment variables are required — your MCP client handles OAuth automatically.
|
|
336
|
+
|
|
337
|
+
The variables below apply only when running the server **locally** (stdio via `npx` or your own deployment):
|
|
338
|
+
|
|
241
339
|
| Environment Variable | Required | Description |
|
|
242
340
|
|---------------------|----------|-------------|
|
|
243
|
-
| `API_TOKEN` | Yes | Your FinImpulse API token |
|
|
341
|
+
| `API_TOKEN` | Yes (local stdio) | Your FinImpulse API token |
|
|
244
342
|
|
|
245
343
|
## Development
|
|
246
344
|
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../src/tools/events/tickers/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,oBAAoB,CAAC,KAAyB,EAAE,MAAiB;IACtF,OAAO,MAAM,CAAC,OAAO,CAAwB,oBAAoB,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AACnF,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { eventsTickersInputSchema } from './schema.js';
|
|
2
|
+
import { eventsTickersHandler } from './handler.js';
|
|
3
|
+
export function registerEventsTickersTool(server, client) {
|
|
4
|
+
server.registerTool('get_events_tickers', { description: 'Returns past and upcoming corporate events for ticker symbols: earnings announcements (EPS estimate, actual, surprise) and IPOs (deal status, listing exchange). Fields depend on the event type. Earnings are available up to ~14 months ahead, IPOs ~2-3 weeks ahead; data is updated weekly. Filter by event type, date, or symbol (e.g. filters ["symbol", "=", "AAPL"]). Use to build earnings/IPO calendars or alerts.', inputSchema: eventsTickersInputSchema }, (input) => eventsTickersHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/tools/events/tickers/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,wBAAwB,EAAC,MAAM,aAAa,CAAC;AACrD,OAAO,EAAC,oBAAoB,EAAC,MAAM,cAAc,CAAC;AAGlD,MAAM,UAAU,yBAAyB,CAAC,MAAiB,EAAE,MAAiB;IAC7E,MAAM,CAAC,YAAY,CAAC,oBAAoB,EAAE,EAAE,WAAW,EAAE,8ZAA8Z,EAAE,WAAW,EAAE,wBAAwB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,oBAAoB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACnjB,CAAC"}
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { getFilterDescription, getFilterExpression, getSortBySchema } from '../../../utils/filters.js';
|
|
3
|
+
export const eventsTickersInputSchema = z.object({
|
|
4
|
+
event_types: z.array(z.enum(['earnings', 'ipo'])).optional().describe('Types of corporate events to include. Supported values: earnings, ipo. If not specified, events of all types are returned.'),
|
|
5
|
+
filters: getFilterExpression().optional().describe(getFilterDescription('"filters": ["symbol", "=", "AAPL"]')),
|
|
6
|
+
sort_by: getSortBySchema('start_date_time', 'By default, results are sorted by start_date_time in descending order, then by symbol in alphabetical order.'),
|
|
7
|
+
limit: z.number().int().min(1).max(1000).optional().describe('Maximum number of matched items returned. Default: 100, maximum: 1000.'),
|
|
8
|
+
offset: z.number().int().min(0).optional().describe('Pagination offset (0-based).'),
|
|
9
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier (max 255 characters). Returned in the response; does not affect processing.'),
|
|
10
|
+
});
|
|
11
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../src/tools/events/tickers/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AACtB,OAAO,EAAC,oBAAoB,EAAE,mBAAmB,EAAE,eAAe,EAAC,MAAM,2BAA2B,CAAC;AAErG,MAAM,CAAC,MAAM,wBAAwB,GAAG,CAAC,CAAC,MAAM,CAAC;IAChD,WAAW,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,UAAU,EAAE,KAAK,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACpE,4HAA4H,CAC5H;IACD,OAAO,EAAE,mBAAmB,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACjD,oBAAoB,CAAC,oCAAoC,CAAC,CAC1D;IACD,OAAO,EAAE,eAAe,CAAC,iBAAiB,EAAE,8GAA8G,CAAC;IAC3J,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wEAAwE,CAAC;IACtI,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IACnF,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6GAA6G,CAAC;CAC3J,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/tools/events/tickers/types.ts"],"names":[],"mappings":""}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { historiesInputSchema } from './schema.js';
|
|
2
2
|
import { historiesHandler } from './handler.js';
|
|
3
3
|
export function registerHistoriesTool(server, client) {
|
|
4
|
-
server.registerTool('get_histories', { description: 'Returns time-series data for an asset in a single unified stream. This endpoint can return historical prices and, optionally, additional history “event” types such as dividends, splits, and capital gains (where available). It is a configurable endpoint that lets you control the date range, interval, included record types, sorting, and page size.', inputSchema: historiesInputSchema }, (input) => historiesHandler(input, client));
|
|
4
|
+
server.registerTool('get_histories', { description: 'Returns time-series data for an asset in a single unified stream. This endpoint can return historical prices and, optionally, additional history “event” types such as dividends, splits, and capital gains (where available). It is a configurable endpoint that lets you control the date range, interval, included record types, sorting, and page size. Each item is a price record for one interval or a single dividend, split, or capital gain event. Also covers indices.', inputSchema: historiesInputSchema }, (input) => historiesHandler(input, client));
|
|
5
5
|
}
|
|
6
6
|
//# sourceMappingURL=index.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/historical/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,oBAAoB,EAAC,MAAM,aAAa,CAAC;AACjD,OAAO,EAAC,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAE9C,MAAM,UAAU,qBAAqB,CAAC,MAAiB,EAAE,MAAiB;IACzE,MAAM,CAAC,YAAY,CAAC,eAAe,EAAE,EAAE,WAAW,EAAE,
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/historical/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,oBAAoB,EAAC,MAAM,aAAa,CAAC;AACjD,OAAO,EAAC,gBAAgB,EAAC,MAAM,cAAc,CAAC;AAE9C,MAAM,UAAU,qBAAqB,CAAC,MAAiB,EAAE,MAAiB;IACzE,MAAM,CAAC,YAAY,CAAC,eAAe,EAAE,EAAE,WAAW,EAAE,mdAAmd,EAAE,WAAW,EAAE,oBAAoB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,gBAAgB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AAC3lB,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,sBAAsB,CAAC,KAA2B,EAAE,MAAiB;IAC1F,OAAO,MAAM,CAAC,OAAO,CAA0B,sBAAsB,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AACvF,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { holdingsHistoryInputSchema } from './schema.js';
|
|
2
|
+
import { holdingsHistoryHandler } from './handler.js';
|
|
3
|
+
export function registerHoldingsHistoryTool(server, client) {
|
|
4
|
+
server.registerTool('get_holdings_history', { description: 'Returns the full holdings composition (asset, name, shares, weight %, market value) of an ETF on a specific historical reporting date. ETFs only; returns an empty result if no data exists for the symbol and date. Use get_holdings_history_dates first to get valid dates. Supports filtering and sorting (e.g. by weight_pct).', inputSchema: holdingsHistoryInputSchema }, (input) => holdingsHistoryHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,0BAA0B,EAAC,MAAM,aAAa,CAAC;AACvD,OAAO,EAAC,sBAAsB,EAAC,MAAM,cAAc,CAAC;AAGpD,MAAM,UAAU,2BAA2B,CAAC,MAAiB,EAAE,MAAiB;IAC/E,MAAM,CAAC,YAAY,CAAC,sBAAsB,EAAE,EAAE,WAAW,EAAE,oUAAoU,EAAE,WAAW,EAAE,0BAA0B,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,sBAAsB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AAC/d,CAAC"}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { getFilterDescription, getFilterExpression, getSortBySchema } from '../../../utils/filters.js';
|
|
3
|
+
export const holdingsHistoryInputSchema = z.object({
|
|
4
|
+
symbol: z.string().min(1).describe('ETF identifier (ticker symbol).'),
|
|
5
|
+
date: z.string().regex(/^\d{4}-\d{2}-\d{2}$/).describe('Holdings reporting date (YYYY-MM-DD). Must be a date available for the requested symbol; use get_holdings_history_dates to retrieve valid dates.'),
|
|
6
|
+
limit: z.number().int().min(1).optional().describe('Maximum number of matched records returned.'),
|
|
7
|
+
offset: z.number().int().min(0).optional().describe('Pagination offset (0-based).'),
|
|
8
|
+
filters: getFilterExpression().optional().describe(getFilterDescription('"filters": ["weight_pct", ">", 1]')),
|
|
9
|
+
sort_by: getSortBySchema('weight_pct'),
|
|
10
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier (max 255 characters). Returned in the response; does not affect processing.'),
|
|
11
|
+
});
|
|
12
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AACtB,OAAO,EAAC,oBAAoB,EAAE,mBAAmB,EAAE,eAAe,EAAC,MAAM,2BAA2B,CAAC;AAErG,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IAClD,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,iCAAiC,CAAC;IACrE,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,qBAAqB,CAAC,CAAC,QAAQ,CACrD,kJAAkJ,CAClJ;IACD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6CAA6C,CAAC;IACjG,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IACnF,OAAO,EAAE,mBAAmB,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACjD,oBAAoB,CAAC,mCAAmC,CAAC,CACzD;IACD,OAAO,EAAE,eAAe,CAAC,YAAY,CAAC;IACtC,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6GAA6G,CAAC;CAC3J,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history-dates/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,2BAA2B,CAAC,KAAgC,EAAE,MAAiB;IACpG,MAAM,EAAC,MAAM,EAAE,GAAG,IAAI,EAAC,GAAG,KAAK,CAAC;IAChC,OAAO,MAAM,CAAC,OAAO,CAA+B,8BAA8B,kBAAkB,CAAC,MAAM,CAAC,EAAE,EAAE,MAAM,EAAE,IAAI,CAAC,CAAC;AAC/H,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { holdingsHistoryDatesInputSchema } from './schema.js';
|
|
2
|
+
import { holdingsHistoryDatesHandler } from './handler.js';
|
|
3
|
+
export function registerHoldingsHistoryDatesTool(server, client) {
|
|
4
|
+
server.registerTool('get_holdings_history_dates', { description: 'Returns the list of available historical holdings reporting dates for an ETF. ETFs only (stocks and mutual funds are not supported); returns an empty result if no data exists. Call this first to get a valid date, then pass it to get_holdings_history.', inputSchema: holdingsHistoryDatesInputSchema }, (input) => holdingsHistoryDatesHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history-dates/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,+BAA+B,EAAC,MAAM,aAAa,CAAC;AAC5D,OAAO,EAAC,2BAA2B,EAAC,MAAM,cAAc,CAAC;AAGzD,MAAM,UAAU,gCAAgC,CAAC,MAAiB,EAAE,MAAiB;IACpF,MAAM,CAAC,YAAY,CAAC,4BAA4B,EAAE,EAAE,WAAW,EAAE,4PAA4P,EAAE,WAAW,EAAE,+BAA+B,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,2BAA2B,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACva,CAAC"}
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export const holdingsHistoryDatesInputSchema = z.object({
|
|
3
|
+
symbol: z.string().min(1).describe('ETF identifier (ticker symbol).'),
|
|
4
|
+
start_date: z.string().regex(/^\d{4}-\d{2}-\d{2}$/).optional().describe('Start of the date range filter (YYYY-MM-DD). Only dates on and after this value are returned. Coverage begins on 2026-01-01 for most ETFs (~500 ETFs go back to 2023-2025).'),
|
|
5
|
+
limit: z.number().int().min(1).optional().describe('Maximum number of matched records returned.'),
|
|
6
|
+
offset: z.number().int().min(0).optional().describe('Pagination offset (0-based).'),
|
|
7
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier (max 255 characters). Returned in the response; does not affect processing.'),
|
|
8
|
+
});
|
|
9
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history-dates/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,+BAA+B,GAAG,CAAC,CAAC,MAAM,CAAC;IACvD,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,iCAAiC,CAAC;IACrE,UAAU,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,KAAK,CAAC,qBAAqB,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACtE,6KAA6K,CAC7K;IACD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6CAA6C,CAAC;IACjG,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IACnF,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6GAA6G,CAAC;CAC3J,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/tools/holdings/history-dates/types.ts"],"names":[],"mappings":""}
|
package/build/tools/index.js
CHANGED
|
@@ -1,8 +1,12 @@
|
|
|
1
1
|
import { registerSearchTool } from './search/index.js';
|
|
2
|
+
import { registerSearchLiteTool } from './search-lite/index.js';
|
|
2
3
|
import { registerHistoriesTool } from './historical/index.js';
|
|
3
4
|
import { registerSummaryTool } from './summary/index.js';
|
|
5
|
+
import { registerSummaryLiteTool } from './summary-lite/index.js';
|
|
4
6
|
import { registerProfileTool } from './profile/index.js';
|
|
5
7
|
import { registerNewsTool } from './news/index.js';
|
|
8
|
+
import { registerMarketPriceTool } from './market-price/index.js';
|
|
9
|
+
import { registerMetricsTool } from './metrics/index.js';
|
|
6
10
|
import { registerAnalysisAnalystsTool } from './analysis/analysts/index.js';
|
|
7
11
|
import { registerAnalysisEarningsTool } from './analysis/earnings/index.js';
|
|
8
12
|
import { registerAnalysisRecommendationsTool } from './analysis/recommendations/index.js';
|
|
@@ -25,12 +29,23 @@ import { registerHoldingsTopHoldingsTool } from './holdings/top-holdings/index.j
|
|
|
25
29
|
import { registerOptionsChainTool } from './options/chain/index.js';
|
|
26
30
|
import { registerOptionsContractsTool } from './options/contracts/index.js';
|
|
27
31
|
import { registerOptionsExpirationsTool } from './options/expirations/index.js';
|
|
32
|
+
import { registerHoldingsHistoryTool } from './holdings/history/index.js';
|
|
33
|
+
import { registerHoldingsHistoryDatesTool } from './holdings/history-dates/index.js';
|
|
34
|
+
import { registerEventsTickersTool } from './events/tickers/index.js';
|
|
35
|
+
import { registerMacroEconomicsTool } from './macro-economics/index.js';
|
|
36
|
+
import { registerMarketCalendarsTool } from './market/calendars/index.js';
|
|
37
|
+
import { registerMarketIndexTool } from './market/index/index.js';
|
|
38
|
+
import { registerSecFilingsEventsTool } from './sec-filings/events/index.js';
|
|
28
39
|
export function registerAllTools(server, client) {
|
|
29
40
|
registerSearchTool(server, client);
|
|
41
|
+
registerSearchLiteTool(server, client);
|
|
30
42
|
registerHistoriesTool(server, client);
|
|
31
43
|
registerSummaryTool(server, client);
|
|
44
|
+
registerSummaryLiteTool(server, client);
|
|
32
45
|
registerProfileTool(server, client);
|
|
33
46
|
registerNewsTool(server, client);
|
|
47
|
+
registerMarketPriceTool(server, client);
|
|
48
|
+
registerMetricsTool(server, client);
|
|
34
49
|
registerAnalysisAnalystsTool(server, client);
|
|
35
50
|
registerAnalysisEarningsTool(server, client);
|
|
36
51
|
registerAnalysisRecommendationsTool(server, client);
|
|
@@ -50,8 +65,15 @@ export function registerAllTools(server, client) {
|
|
|
50
65
|
registerStatisticsAnnualReturnsTool(server, client);
|
|
51
66
|
registerHoldingsGeneralTool(server, client);
|
|
52
67
|
registerHoldingsTopHoldingsTool(server, client);
|
|
68
|
+
registerHoldingsHistoryDatesTool(server, client);
|
|
69
|
+
registerHoldingsHistoryTool(server, client);
|
|
53
70
|
registerOptionsChainTool(server, client);
|
|
54
71
|
registerOptionsContractsTool(server, client);
|
|
55
72
|
registerOptionsExpirationsTool(server, client);
|
|
73
|
+
registerEventsTickersTool(server, client);
|
|
74
|
+
registerMacroEconomicsTool(server, client);
|
|
75
|
+
registerMarketCalendarsTool(server, client);
|
|
76
|
+
registerMarketIndexTool(server, client);
|
|
77
|
+
registerSecFilingsEventsTool(server, client);
|
|
56
78
|
}
|
|
57
79
|
//# sourceMappingURL=index.js.map
|
package/build/tools/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAEA,OAAO,EAAC,kBAAkB,EAAC,MAAM,mBAAmB,CAAC;AACrD,OAAO,EAAC,qBAAqB,EAAC,MAAM,uBAAuB,CAAC;AAC5D,OAAO,EAAC,mBAAmB,EAAC,MAAM,oBAAoB,CAAC;AACvD,OAAO,EAAC,mBAAmB,EAAC,MAAM,oBAAoB,CAAC;AACvD,OAAO,EAAC,gBAAgB,EAAC,MAAM,iBAAiB,CAAC;AACjD,OAAO,EAAC,4BAA4B,EAAC,MAAM,8BAA8B,CAAC;AAC1E,OAAO,EAAC,4BAA4B,EAAC,MAAM,8BAA8B,CAAC;AAC1E,OAAO,EAAC,mCAAmC,EAAC,MAAM,qCAAqC,CAAC;AACxF,OAAO,EAAC,sCAAsC,EAAC,MAAM,yCAAyC,CAAC;AAC/F,OAAO,EAAC,0BAA0B,EAAC,MAAM,4BAA4B,CAAC;AACtE,OAAO,EAAC,gCAAgC,EAAC,MAAM,kCAAkC,CAAC;AAClF,OAAO,EAAC,8BAA8B,EAAC,MAAM,iCAAiC,CAAC;AAC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
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../src/tools/macro-economics/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,qBAAqB,CAAC,KAA0B,EAAE,MAAiB;IACxF,OAAO,MAAM,CAAC,OAAO,CAAyB,qBAAqB,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AACrF,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { macroEconomicsInputSchema } from './schema.js';
|
|
2
|
+
import { macroEconomicsHandler } from './handler.js';
|
|
3
|
+
export function registerMacroEconomicsTool(server, client) {
|
|
4
|
+
server.registerTool('get_macro_economics', { description: 'Returns annual macroeconomic indicators by country (50+ countries, 1970 to current year; current-year values are forecasts): GDP, inflation, unemployment, interest rates, trade, government finances, consumption. One record per country per year with 38 indicators. Updated quarterly. Filter by country_iso3 and year. Source: OECD Data Explorer; use and redistribution are subject to the OECD Terms and Conditions, including source attribution.', inputSchema: macroEconomicsInputSchema }, (input) => macroEconomicsHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/macro-economics/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,yBAAyB,EAAC,MAAM,aAAa,CAAC;AACtD,OAAO,EAAC,qBAAqB,EAAC,MAAM,cAAc,CAAC;AAGnD,MAAM,UAAU,0BAA0B,CAAC,MAAiB,EAAE,MAAiB;IAC9E,MAAM,CAAC,YAAY,CAAC,qBAAqB,EAAE,EAAE,WAAW,EAAE,4bAA4b,EAAE,WAAW,EAAE,yBAAyB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,qBAAqB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACplB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { getFilterDescription, getFilterExpression, getSortBySchema } from '../../utils/filters.js';
|
|
3
|
+
export const macroEconomicsInputSchema = z.object({
|
|
4
|
+
filters: getFilterExpression().optional().describe(getFilterDescription('"filters": ["country_iso3", "=", "CHE"]') + '\nFilterable fields include country_iso3 (ISO 3166-1 alpha-3) and year.'),
|
|
5
|
+
sort_by: getSortBySchema('year'),
|
|
6
|
+
limit: z.number().int().min(1).max(1000).optional().describe('Maximum number of matched items returned. Default: 100, maximum: 1000.'),
|
|
7
|
+
offset: z.number().int().min(0).optional().describe('Pagination offset (0-based).'),
|
|
8
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier (max 255 characters). Returned in the response; does not affect processing.'),
|
|
9
|
+
});
|
|
10
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/tools/macro-economics/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AACtB,OAAO,EAAC,oBAAoB,EAAE,mBAAmB,EAAE,eAAe,EAAC,MAAM,wBAAwB,CAAC;AAElG,MAAM,CAAC,MAAM,yBAAyB,GAAG,CAAC,CAAC,MAAM,CAAC;IACjD,OAAO,EAAE,mBAAmB,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACjD,oBAAoB,CAAC,yCAAyC,CAAC,GAAG,yEAAyE,CAC3I;IACD,OAAO,EAAE,eAAe,CAAC,MAAM,CAAC;IAChC,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wEAAwE,CAAC;IACtI,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IACnF,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6GAA6G,CAAC;CAC3J,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/tools/macro-economics/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../src/tools/market/calendars/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,sBAAsB,CAAC,KAA2B,EAAE,MAAiB;IAC1F,OAAO,MAAM,CAAC,OAAO,CAA0B,sBAAsB,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AACvF,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { marketCalendarsInputSchema } from './schema.js';
|
|
2
|
+
import { marketCalendarsHandler } from './handler.js';
|
|
3
|
+
export function registerMarketCalendarsTool(server, client) {
|
|
4
|
+
server.registerTool('get_market_calendars', { description: 'Returns the macroeconomic release calendar: scheduled data releases (e.g. Unemployment Rate, CPI, Retail Sales) for 71 countries and the euro area, covering recent releases and roughly the next 30 days. Each record has the release time, reference period, and actual, prior and originally reported values (after_release_actual is null until published). Updated weekly. Filter by country, date or indicator.', inputSchema: marketCalendarsInputSchema }, (input) => marketCalendarsHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/tools/market/calendars/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,0BAA0B,EAAC,MAAM,aAAa,CAAC;AACvD,OAAO,EAAC,sBAAsB,EAAC,MAAM,cAAc,CAAC;AAGpD,MAAM,UAAU,2BAA2B,CAAC,MAAiB,EAAE,MAAiB;IAC/E,MAAM,CAAC,YAAY,CAAC,sBAAsB,EAAE,EAAE,WAAW,EAAE,uZAAuZ,EAAE,WAAW,EAAE,0BAA0B,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,sBAAsB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACljB,CAAC"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { getFilterDescription, getFilterExpression, getSortBySchema } from '../../../utils/filters.js';
|
|
3
|
+
export const marketCalendarsInputSchema = z.object({
|
|
4
|
+
filters: getFilterExpression().optional().describe(getFilterDescription('"filters": ["country_code_iso3", "=", "USA"]') + '\nFilterable fields include country_code_iso3, economic_release, start_date_time and period.'),
|
|
5
|
+
sort_by: getSortBySchema('start_date_time', 'By default, results are sorted by start_date_time in descending order, then by economic_release in alphabetical order.'),
|
|
6
|
+
limit: z.number().int().min(1).max(1000).optional().describe('Maximum number of matched items returned. Default: 100, maximum: 1000.'),
|
|
7
|
+
offset: z.number().int().min(0).optional().describe('Pagination offset (0-based).'),
|
|
8
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier (max 255 characters). Returned in the response; does not affect processing.'),
|
|
9
|
+
});
|
|
10
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../src/tools/market/calendars/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AACtB,OAAO,EAAC,oBAAoB,EAAE,mBAAmB,EAAE,eAAe,EAAC,MAAM,2BAA2B,CAAC;AAErG,MAAM,CAAC,MAAM,0BAA0B,GAAG,CAAC,CAAC,MAAM,CAAC;IAClD,OAAO,EAAE,mBAAmB,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACjD,oBAAoB,CAAC,8CAA8C,CAAC,GAAG,8FAA8F,CACrK;IACD,OAAO,EAAE,eAAe,CAAC,iBAAiB,EAAE,wHAAwH,CAAC;IACrK,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wEAAwE,CAAC;IACtI,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IACnF,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6GAA6G,CAAC;CAC3J,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/tools/market/calendars/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../../src/tools/market/index/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,kBAAkB,CAAC,KAAuB,EAAE,MAAiB;IAClF,OAAO,MAAM,CAAC,OAAO,CAAsB,kBAAkB,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AAC/E,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { marketIndexInputSchema } from './schema.js';
|
|
2
|
+
import { marketIndexHandler } from './handler.js';
|
|
3
|
+
export function registerMarketIndexTool(server, client) {
|
|
4
|
+
server.registerTool('get_market_index', { description: 'Searches ~39,000 global market indices (e.g. S&P 500, Dow Jones, Nasdaq Composite, VIX, Treasury yield indices) and returns latest closing price, daily change, 52-week range and one-year return. Updated every 24 hours; no intraday prices. Use select_identifiers to reduce response size. For historical index prices use get_histories.', inputSchema: marketIndexInputSchema }, (input) => marketIndexHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../../src/tools/market/index/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,sBAAsB,EAAC,MAAM,aAAa,CAAC;AACnD,OAAO,EAAC,kBAAkB,EAAC,MAAM,cAAc,CAAC;AAGhD,MAAM,UAAU,uBAAuB,CAAC,MAAiB,EAAE,MAAiB;IAC3E,MAAM,CAAC,YAAY,CAAC,kBAAkB,EAAE,EAAE,WAAW,EAAE,+UAA+U,EAAE,WAAW,EAAE,sBAAsB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,kBAAkB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AAC9d,CAAC"}
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
import { getFilterDescription, getFilterExpression, getSortBySchema } from '../../../utils/filters.js';
|
|
3
|
+
export const marketIndexInputSchema = z.object({
|
|
4
|
+
search_text: z.string().optional().describe('Free-text query (e.g., "GSPC.INDX", "S&P 500", partial symbol, partial name).'),
|
|
5
|
+
select_identifiers: z.array(z.string()).optional().describe('A list of field names to include in the response. When provided, each item contains only the specified fields. When not provided or null, the full field set is returned. "symbol" and "logo" are always returned regardless of the value passed.'),
|
|
6
|
+
symbols: z.array(z.string()).optional().describe('A list of index symbols to retrieve (e.g., GSPC.INDX, DJI.INDX, 000001.SS). When provided, only the specified indices are returned. Symbols that do not exist are excluded; if none are found the result is empty.'),
|
|
7
|
+
show_tickers_without_company_name: z.boolean().optional().describe('Include indices without a name. true - include indices without a name; false - exclude them.'),
|
|
8
|
+
hide_tickers_with_company_name: z.boolean().optional().describe('Exclude indices with a name. true - exclude indices with a name; false - include them.'),
|
|
9
|
+
filters: getFilterExpression().optional().describe(getFilterDescription('"filters": ["regular_market_price_change_percent", ">", 1]')),
|
|
10
|
+
sort_by: getSortBySchema('regular_market_price_change_percent'),
|
|
11
|
+
limit: z.number().int().min(1).max(1000).optional().describe('Maximum number of matched items returned. Default: 100, maximum: 1000.'),
|
|
12
|
+
offset: z.number().int().min(0).optional().describe('Pagination offset (0-based).'),
|
|
13
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier (max 255 characters). Returned in the response; does not affect processing.'),
|
|
14
|
+
});
|
|
15
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../../src/tools/market/index/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AACtB,OAAO,EAAC,oBAAoB,EAAE,mBAAmB,EAAE,eAAe,EAAC,MAAM,2BAA2B,CAAC;AAErG,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,+EAA+E,CAAC;IAC5H,kBAAkB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC1D,mPAAmP,CACnP;IACD,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC/C,oNAAoN,CACpN;IACD,iCAAiC,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8FAA8F,CAAC;IAClK,8BAA8B,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wFAAwF,CAAC;IACzJ,OAAO,EAAE,mBAAmB,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CACjD,oBAAoB,CAAC,4DAA4D,CAAC,CAClF;IACD,OAAO,EAAE,eAAe,CAAC,qCAAqC,CAAC;IAC/D,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,wEAAwE,CAAC;IACtI,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,8BAA8B,CAAC;IACnF,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,6GAA6G,CAAC;CAC3J,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../../src/tools/market/index/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../src/tools/market-price/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,kBAAkB,CAAC,KAAuB,EAAE,MAAiB;IAClF,OAAO,MAAM,CAAC,OAAO,CAAsB,oBAAoB,kBAAkB,CAAC,KAAK,CAAC,MAAM,CAAC,EAAE,EAAE,KAAK,CAAC,CAAC;AAC3G,CAAC"}
|