fixparser-plugin-mcp 9.1.7-edd9ee17 → 9.1.7-eea80766

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.
@@ -1,5 +1,3 @@
1
- import type { CallToolResult } from '@modelcontextprotocol/sdk/types.js';
2
- export type { MarketDataEntry } from './marketData';
3
1
  export interface VerifiedOrder {
4
2
  clOrdID: string;
5
3
  handlInst: string;
@@ -10,7 +8,21 @@ export interface VerifiedOrder {
10
8
  symbol: string;
11
9
  timeInForce: string;
12
10
  }
13
- export type ToolHandler = (args: any) => Promise<CallToolResult>;
11
+ export interface PricePoint {
12
+ timestamp: number;
13
+ price: number;
14
+ }
15
+ export interface ToolResponse {
16
+ content: Array<{
17
+ type: 'text' | 'image';
18
+ text?: string;
19
+ uri?: string;
20
+ mimeType?: string;
21
+ data?: string;
22
+ }>;
23
+ isError?: boolean;
24
+ }
25
+ export type ToolHandler = (args: any) => Promise<ToolResponse>;
14
26
  export interface ToolHandlers {
15
27
  [key: string]: ToolHandler;
16
28
  }
@@ -1,8 +1,17 @@
1
1
  import type { IFIXParser, Message } from 'fixparser';
2
- import type { MarketDataEntry, ToolHandlers, VerifiedOrder } from '../schemas';
2
+ import type { ToolHandlers, VerifiedOrder } from '../schemas';
3
3
  export declare const createToolHandlers: (
4
4
  parser: IFIXParser,
5
5
  verifiedOrders: Map<string, VerifiedOrder>,
6
6
  pendingRequests: Map<string, (data: Message) => void>,
7
- marketDataPrices: Map<string, MarketDataEntry[]>,
7
+ marketDataPrices: Map<
8
+ string,
9
+ {
10
+ timestamp: number;
11
+ bid: number;
12
+ offer: number;
13
+ spread: number;
14
+ volume: number;
15
+ }[]
16
+ >,
8
17
  ) => ToolHandlers;
@@ -1,6 +1,5 @@
1
- import type { CallToolResult } from '@modelcontextprotocol/sdk/types.js';
2
1
  import { type IFIXParser, type Message } from 'fixparser';
3
- import type { MarketDataEntry } from '../schemas';
2
+ import type { ToolResponse } from '../schemas';
4
3
  export declare const createMarketDataRequestHandler: (
5
4
  parser: IFIXParser,
6
5
  pendingRequests: Map<string, (data: Message) => void>,
@@ -10,10 +9,32 @@ export declare const createMarketDataRequestHandler: (
10
9
  mdReqID: string;
11
10
  subscriptionRequestType: string;
12
11
  mdEntryTypes?: string[];
13
- }) => Promise<CallToolResult>;
14
- export declare const createGetStockGraphHandler: (marketDataPrices: Map<string, MarketDataEntry[]>) => (args: {
12
+ }) => Promise<ToolResponse>;
13
+ export declare const createGetStockGraphHandler: (
14
+ marketDataPrices: Map<
15
+ string,
16
+ Array<{
17
+ timestamp: number;
18
+ bid: number;
19
+ offer: number;
20
+ spread: number;
21
+ volume: number;
22
+ }>
23
+ >,
24
+ ) => (args: {
15
25
  symbol: string;
16
- }) => Promise<CallToolResult>;
17
- export declare const createGetStockPriceHistoryHandler: (marketDataPrices: Map<string, MarketDataEntry[]>) => (args: {
26
+ }) => Promise<ToolResponse>;
27
+ export declare const createGetStockPriceHistoryHandler: (
28
+ marketDataPrices: Map<
29
+ string,
30
+ Array<{
31
+ timestamp: number;
32
+ bid: number;
33
+ offer: number;
34
+ spread: number;
35
+ volume: number;
36
+ }>
37
+ >,
38
+ ) => (args: {
18
39
  symbol: string;
19
- }) => Promise<CallToolResult>;
40
+ }) => Promise<ToolResponse>;
@@ -1,12 +1,11 @@
1
- import type { CallToolResult } from '@modelcontextprotocol/sdk/types.js';
2
1
  import { type IFIXParser, type Message } from 'fixparser';
3
- import type { VerifiedOrder } from '../schemas';
2
+ import type { ToolResponse, VerifiedOrder } from '../schemas';
4
3
  export declare const createVerifyOrderHandler: (
5
4
  parser: IFIXParser,
6
5
  verifiedOrders: Map<string, VerifiedOrder>,
7
- ) => (args: VerifiedOrder) => Promise<CallToolResult>;
6
+ ) => (args: VerifiedOrder) => Promise<ToolResponse>;
8
7
  export declare const createExecuteOrderHandler: (
9
8
  parser: IFIXParser,
10
9
  verifiedOrders: Map<string, VerifiedOrder>,
11
10
  pendingRequests: Map<string, (data: Message) => void>,
12
- ) => (args: VerifiedOrder) => Promise<CallToolResult>;
11
+ ) => (args: VerifiedOrder) => Promise<ToolResponse>;
@@ -1,5 +1,5 @@
1
- import type { CallToolResult } from '@modelcontextprotocol/sdk/types.js';
2
1
  import type { IFIXParser } from 'fixparser';
2
+ import type { ToolResponse } from '../schemas';
3
3
  export declare const createParseHandler: (parser: IFIXParser) => (args: {
4
4
  fixString: string;
5
- }) => Promise<CallToolResult>;
5
+ }) => Promise<ToolResponse>;
@@ -1,5 +1,5 @@
1
- import type { CallToolResult } from '@modelcontextprotocol/sdk/types.js';
2
1
  import type { IFIXParser } from 'fixparser';
2
+ import type { ToolResponse } from '../schemas';
3
3
  export declare const createParseToJSONHandler: (parser: IFIXParser) => (args: {
4
4
  fixString: string;
5
- }) => Promise<CallToolResult>;
5
+ }) => Promise<ToolResponse>;