finimpulse-mcp-server 1.1.0 → 1.2.1
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 +101 -15
- package/build/tools/index.js +8 -0
- package/build/tools/index.js.map +1 -1
- 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/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/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/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
|
|
@@ -238,9 +320,13 @@ API_TOKEN=your-api-token npx finimpulse-mcp-server
|
|
|
238
320
|
|
|
239
321
|
## Configuration
|
|
240
322
|
|
|
323
|
+
When using the **hosted** server (`https://mcp.finimpulse.com/mcp`) no environment variables are required — your MCP client handles OAuth automatically.
|
|
324
|
+
|
|
325
|
+
The variables below apply only when running the server **locally** (stdio via `npx` or your own deployment):
|
|
326
|
+
|
|
241
327
|
| Environment Variable | Required | Description |
|
|
242
328
|
|---------------------|----------|-------------|
|
|
243
|
-
| `API_TOKEN` | Yes | Your FinImpulse API token |
|
|
329
|
+
| `API_TOKEN` | Yes (local stdio) | Your FinImpulse API token |
|
|
244
330
|
|
|
245
331
|
## Development
|
|
246
332
|
|
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';
|
|
@@ -27,10 +31,14 @@ import { registerOptionsContractsTool } from './options/contracts/index.js';
|
|
|
27
31
|
import { registerOptionsExpirationsTool } from './options/expirations/index.js';
|
|
28
32
|
export function registerAllTools(server, client) {
|
|
29
33
|
registerSearchTool(server, client);
|
|
34
|
+
registerSearchLiteTool(server, client);
|
|
30
35
|
registerHistoriesTool(server, client);
|
|
31
36
|
registerSummaryTool(server, client);
|
|
37
|
+
registerSummaryLiteTool(server, client);
|
|
32
38
|
registerProfileTool(server, client);
|
|
33
39
|
registerNewsTool(server, client);
|
|
40
|
+
registerMarketPriceTool(server, client);
|
|
41
|
+
registerMetricsTool(server, client);
|
|
34
42
|
registerAnalysisAnalystsTool(server, client);
|
|
35
43
|
registerAnalysisEarningsTool(server, client);
|
|
36
44
|
registerAnalysisRecommendationsTool(server, client);
|
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,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,"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"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { marketPriceInputSchema } from './schema.js';
|
|
2
|
+
import { marketPriceHandler } from './handler.js';
|
|
3
|
+
export function registerMarketPriceTool(server, client) {
|
|
4
|
+
server.registerTool('get_market_price', { description: 'Returns the current market price snapshot for a single asset symbol. For US-listed assets the response includes pre-market, regular, and post-market session prices, as well as a current price field reflecting the most recent traded price. For non-US assets, only the regular session and current price are returned. Applicable to stocks, ETFs, and mutual funds.', inputSchema: marketPriceInputSchema }, (input) => marketPriceHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/market-price/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,0WAA0W,EAAE,WAAW,EAAE,sBAAsB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,kBAAkB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACzf,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/tools/market-price/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,QAAQ,CAAC,mCAAmC,CAAC;CACvE,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/tools/market-price/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../src/tools/metrics/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,cAAc,CAAC,KAAmB,EAAE,MAAiB;IAC1E,OAAO,MAAM,CAAC,OAAO,CAAkB,aAAa,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AACtE,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { metricsInputSchema } from './schema.js';
|
|
2
|
+
import { metricsHandler } from './handler.js';
|
|
3
|
+
export function registerMetricsTool(server, client) {
|
|
4
|
+
server.registerTool('get_metrics', { description: 'Returns dividend data, returns, profitability, growth, leverage, and business quality metrics for a single asset symbol. Retrieves a focused set of financial and market metrics covering dividend data, historical returns, profitability, growth, leverage, and business quality indicators. Primarily applicable to stocks.', inputSchema: metricsInputSchema }, (input) => metricsHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/metrics/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,kBAAkB,EAAC,MAAM,aAAa,CAAC;AAC/C,OAAO,EAAC,cAAc,EAAC,MAAM,cAAc,CAAC;AAG5C,MAAM,UAAU,mBAAmB,CAAC,MAAiB,EAAE,MAAiB;IACvE,MAAM,CAAC,YAAY,CAAC,aAAa,EAAE,EAAE,WAAW,EAAE,gUAAgU,EAAE,WAAW,EAAE,kBAAkB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,cAAc,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AAClc,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/tools/metrics/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,kBAAkB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC1C,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,mCAAmC,CAAC;IAChE,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kCAAkC,CAAC;CAChF,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/tools/metrics/types.ts"],"names":[],"mappings":""}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"handler.js","sourceRoot":"","sources":["../../../src/tools/search-lite/handler.ts"],"names":[],"mappings":"AAKA,MAAM,CAAC,KAAK,UAAU,iBAAiB,CAAC,KAAsB,EAAE,MAAiB;IAChF,OAAO,MAAM,CAAC,OAAO,CAAqB,iBAAiB,EAAE,MAAM,EAAE,KAAK,CAAC,CAAC;AAC7E,CAAC"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { searchLiteInputSchema } from './schema.js';
|
|
2
|
+
import { searchLiteHandler } from './handler.js';
|
|
3
|
+
export function registerSearchLiteTool(server, client) {
|
|
4
|
+
server.registerTool('get_search_lite', { description: 'Returns a unified, cross-asset search result for stocks, ETFs, and mutual funds with a focused field set covering core identification, current pricing, and key performance metrics. The response field set is fixed, but it is possible to control which fields are included through the select_identifiers parameter. For a comprehensive field set use the /v1/search endpoint.', inputSchema: searchLiteInputSchema }, (input) => searchLiteHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/search-lite/index.ts"],"names":[],"mappings":"AACA,OAAO,EAAC,qBAAqB,EAAC,MAAM,aAAa,CAAC;AAClD,OAAO,EAAC,iBAAiB,EAAC,MAAM,cAAc,CAAC;AAG/C,MAAM,UAAU,sBAAsB,CAAC,MAAiB,EAAE,MAAiB;IAC1E,MAAM,CAAC,YAAY,CAAC,iBAAiB,EAAE,EAAE,WAAW,EAAE,oXAAoX,EAAE,WAAW,EAAE,qBAAqB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,iBAAiB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AAChgB,CAAC"}
|
|
@@ -0,0 +1,63 @@
|
|
|
1
|
+
import { getFilterExpression } from '../../utils/filters.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
export const searchLiteInputSchema = z.object({
|
|
4
|
+
search_text: z.string().optional().describe('Free-text query (e.g., “NVDA”, “NVIDIA”, partial ticker, 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 in the response contains only the specified fields. When not provided or set to null, the full field set is returned. "symbol" and "logo" are always returned regardless of the value passed.`),
|
|
6
|
+
quote_types: z.array(z.enum(['mutualfund', 'etf', 'stock'])).optional().describe('Controls which asset types are included in the search. If none are provided, all supported asset types are returned.'),
|
|
7
|
+
symbols: z.array(z.string()).optional().describe(`A list of ticker symbols to retrieve. When provided, the response returns only the specified tickers. If a symbol does not exist, it is excluded from the results.`),
|
|
8
|
+
limit: z.number().min(1).max(5000).default(10).optional().describe('Maximum number of matched items returned.'),
|
|
9
|
+
offset: z.number().min(0).optional().describe('Pagination offset (0-based).'),
|
|
10
|
+
filters: getFilterExpression().optional().describe(`Optional filter expressions.
|
|
11
|
+
Each filter condition is defined as: [field, operator, value]. Conditions can be combined using logical operators and/or.
|
|
12
|
+
|
|
13
|
+
Supported operators:
|
|
14
|
+
|
|
15
|
+
Numeric fields:
|
|
16
|
+
|
|
17
|
+
> - greater than
|
|
18
|
+
>= - greater than or equal
|
|
19
|
+
< - less than
|
|
20
|
+
<= - less than or equal
|
|
21
|
+
= - equals
|
|
22
|
+
<> - not equal
|
|
23
|
+
String fields:
|
|
24
|
+
|
|
25
|
+
like – pattern match (requires % as a wildcard)
|
|
26
|
+
not_like - pattern does not match (requires % as a wildcard)
|
|
27
|
+
contains - value exists in string
|
|
28
|
+
not_contains - value does not exist in string
|
|
29
|
+
startswith - string starts with value
|
|
30
|
+
endswith - string ends with value
|
|
31
|
+
% usage examples:
|
|
32
|
+
|
|
33
|
+
%abc% - matches any string containing "abc"
|
|
34
|
+
abc% - matches any string starting with "abc"
|
|
35
|
+
%abc - matches any string ending with "abc"
|
|
36
|
+
Example:
|
|
37
|
+
|
|
38
|
+
"filters": [
|
|
39
|
+
"short_name", "contains", "Market"
|
|
40
|
+
]`),
|
|
41
|
+
sort_by: z.array(z.object({
|
|
42
|
+
selector: z.string().describe('Metric used for sorting (e.g., amount_usd)'),
|
|
43
|
+
desc: z.boolean().describe('Sorting direction (true for descending, false for ascending).'),
|
|
44
|
+
})).optional().describe(`Optional sorting configuration for result items. Each sorting setup is defined as [selector, desc]:
|
|
45
|
+
|
|
46
|
+
selector - Metric used for sorting (e.g., amount_usd).
|
|
47
|
+
desc - Sorting direction (true for descending, false for ascending).
|
|
48
|
+
Sortings can be combined using ,.
|
|
49
|
+
|
|
50
|
+
Example:
|
|
51
|
+
|
|
52
|
+
{
|
|
53
|
+
"selector": "amount_usd",
|
|
54
|
+
"desc": true
|
|
55
|
+
}
|
|
56
|
+
|
|
57
|
+
`),
|
|
58
|
+
has_public_financial_reports: z.boolean().optional().describe('Indicates whether the company provides public financial statements.'),
|
|
59
|
+
show_tickers_without_company_name: z.boolean().optional().describe('Include tickers with missing names. true - include tickers even if the company/fund name is missing; false - exclude tickers without a company/fund name.'),
|
|
60
|
+
hide_tickers_with_company_name: z.boolean().optional().describe('Exclude tickers with available names. true - exclude tickers with a company/fund name; false - include tickers with a company/fund name.'),
|
|
61
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier.'),
|
|
62
|
+
});
|
|
63
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/tools/search-lite/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,mBAAmB,EAAC,MAAM,wBAAwB,CAAC;AAC3D,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC7C,WAAW,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,yEAAyE,CAAC;IACtH,kBAAkB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC1D,0QAA0Q,CAC1Q;IACD,WAAW,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,IAAI,CAAC,CAAC,YAAY,EAAE,KAAK,EAAE,OAAO,CAAC,CAAC,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,sHAAsH,CAAC;IACxM,OAAO,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC/C,oKAAoK,CACpK;IACD,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC,GAAG,CAAC,IAAI,CAAC,CAAC,OAAO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../../../src/tools/summary-lite/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 { summaryLiteInputSchema } from './schema.js';
|
|
2
|
+
import { summaryLiteHandler } from './handler.js';
|
|
3
|
+
export function registerSummaryLiteTool(server, client) {
|
|
4
|
+
server.registerTool('get_summary_lite', { description: 'Returns a focused snapshot of key identification, market, and fundamental data for a single asset symbol. Retrieves core identification, current pricing, key valuation metrics, and fundamental data. The response field set is fixed, but it is possible to control which fields are included through the select_identifiers parameter. For a comprehensive field set use the /v1/summary endpoint.', inputSchema: summaryLiteInputSchema }, (input) => summaryLiteHandler(input, client));
|
|
5
|
+
}
|
|
6
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../../src/tools/summary-lite/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,uYAAuY,EAAE,WAAW,EAAE,sBAAsB,EAAE,EAAE,CAAC,KAAK,EAAE,EAAE,CAAC,kBAAkB,CAAC,KAAK,EAAE,MAAM,CAAC,CAAC,CAAC;AACthB,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { z } from 'zod';
|
|
2
|
+
export const summaryLiteInputSchema = z.object({
|
|
3
|
+
symbol: z.string().describe('Asset identifier (ticker symbol).'),
|
|
4
|
+
select_identifiers: z.array(z.string()).optional().describe(`A list of field names to include in the response. When provided, the response contains only the specified fields. When not provided or set to null, the full field set is returned. "symbol" and "logo" are always returned regardless of the value passed.`),
|
|
5
|
+
tag: z.string().max(255).optional().describe('User-defined request identifier.'),
|
|
6
|
+
});
|
|
7
|
+
//# sourceMappingURL=schema.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"schema.js","sourceRoot":"","sources":["../../../src/tools/summary-lite/schema.ts"],"names":[],"mappings":"AAAA,OAAO,EAAC,CAAC,EAAC,MAAM,KAAK,CAAC;AAEtB,MAAM,CAAC,MAAM,sBAAsB,GAAG,CAAC,CAAC,MAAM,CAAC;IAC9C,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,CAAC,mCAAmC,CAAC;IAChE,kBAAkB,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAC1D,6PAA6P,CAC7P;IACD,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,CAAC,GAAG,CAAC,CAAC,QAAQ,EAAE,CAAC,QAAQ,CAAC,kCAAkC,CAAC;CAChF,CAAC,CAAC"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../../src/tools/summary-lite/types.ts"],"names":[],"mappings":""}
|
package/build/transports/http.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import express from 'express';
|
|
2
2
|
import { StreamableHTTPServerTransport } from "@modelcontextprotocol/sdk/server/streamableHttp.js";
|
|
3
3
|
import { createServer } from '../server.js';
|
|
4
|
-
const AUTH_SERVER_URL = process.env.AUTH_SERVER_URL ?? '
|
|
4
|
+
const AUTH_SERVER_URL = process.env.AUTH_SERVER_URL ?? 'https://data.finimpulse.com';
|
|
5
5
|
const STATIC_API_TOKEN = process.env.API_TOKEN ?? '';
|
|
6
6
|
const apiTokenCache = new Map();
|
|
7
7
|
async function exchangeOAuthToken(oauthToken) {
|
|
@@ -53,6 +53,7 @@ export async function handleMcpRequest(req, res) {
|
|
|
53
53
|
}
|
|
54
54
|
export async function runHttp() {
|
|
55
55
|
const app = express();
|
|
56
|
+
app.set('trust proxy', true);
|
|
56
57
|
app.use(express.json());
|
|
57
58
|
if (!STATIC_API_TOKEN) {
|
|
58
59
|
app.get('/.well-known/oauth-protected-resource', (req, res) => {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"http.js","sourceRoot":"","sources":["../../src/transports/http.ts"],"names":[],"mappings":"AAAA,OAAO,OAA4C,MAAM,SAAS,CAAC;AACnE,OAAO,EAAE,6BAA6B,EAAE,MAAM,oDAAoD,CAAC;AACnG,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAE5C,MAAM,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,
|
|
1
|
+
{"version":3,"file":"http.js","sourceRoot":"","sources":["../../src/transports/http.ts"],"names":[],"mappings":"AAAA,OAAO,OAA4C,MAAM,SAAS,CAAC;AACnE,OAAO,EAAE,6BAA6B,EAAE,MAAM,oDAAoD,CAAC;AACnG,OAAO,EAAE,YAAY,EAAE,MAAM,cAAc,CAAC;AAE5C,MAAM,eAAe,GAAG,OAAO,CAAC,GAAG,CAAC,eAAe,IAAI,6BAA6B,CAAC;AACrF,MAAM,gBAAgB,GAAG,OAAO,CAAC,GAAG,CAAC,SAAS,IAAI,EAAE,CAAC;AACrD,MAAM,aAAa,GAAG,IAAI,GAAG,EAAkB,CAAC;AAEhD,KAAK,UAAU,kBAAkB,CAAC,UAAkB;IACnD,MAAM,MAAM,GAAG,aAAa,CAAC,GAAG,CAAC,UAAU,CAAC,CAAC;IAC7C,IAAI,MAAM;QAAE,OAAO,MAAM,CAAC;IAE1B,IAAI,CAAC;QACJ,MAAM,GAAG,GAAG,MAAM,KAAK,CAAC,GAAG,eAAe,gBAAgB,EAAE;YAC3D,M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,MAAM,CAAC,OAAO,CAAC,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,CAAC;IAC9C,GAAG,CAAC,MAAM,CAAC,IAAI,EAAE,GAAG,EAAE,CAAC,OAAO,CAAC,KAAK,CAAC,0CAA0C,IAAI,EAAE,CAAC,CAAC,CAAC;AACzF,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "finimpulse-mcp-server",
|
|
3
|
-
"version": "1.1
|
|
3
|
+
"version": "1.2.1",
|
|
4
4
|
"description": "MCP server for FinImpulse financial market data API",
|
|
5
5
|
"main": "build/index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -23,8 +23,20 @@
|
|
|
23
23
|
"type": "git",
|
|
24
24
|
"url": "git+https://github.com/finimpulse/mcp-server-typescript.git"
|
|
25
25
|
},
|
|
26
|
-
"keywords": [
|
|
27
|
-
|
|
26
|
+
"keywords": [
|
|
27
|
+
"mcp",
|
|
28
|
+
"model-context-protocol",
|
|
29
|
+
"finimpulse",
|
|
30
|
+
"finance",
|
|
31
|
+
"financial-data",
|
|
32
|
+
"stocks",
|
|
33
|
+
"etf",
|
|
34
|
+
"mutual-funds",
|
|
35
|
+
"market-data",
|
|
36
|
+
"ai",
|
|
37
|
+
"llm"
|
|
38
|
+
],
|
|
39
|
+
"author": "FinImpulse",
|
|
28
40
|
"license": "ISC",
|
|
29
41
|
"dependencies": {
|
|
30
42
|
"@modelcontextprotocol/sdk": "^1.26.0",
|