fixparser-plugin-mcp
Version:
FIXParser MCP Plugin (Local/Remote)
58 lines (57 loc) • 1.63 kB
TypeScript
import type { IFIXParser, Message } from 'fixparser';
import { MCPBase } from './MCPBase.ts';
import type { PluginOptions } from './PluginOptions.ts';
import type { MarketDataEntry, VerifiedOrder } from './schemas/index.ts';
export type RemotePluginOptions = PluginOptions & {
port: number;
};
export declare class MCPRemote extends MCPBase {
/**
* Port number the server will listen on.
* @private
*/
private port;
/**
* Node.js HTTP server instance created internally.
* @private
*/
private httpServer;
/**
* MCP server instance handling MCP protocol logic.
* @private
*/
private mcpServer;
/**
* Optional name of the plugin/server instance.
* @private
*/
private serverName;
/**
* Optional version string of the plugin/server.
* @private
*/
private serverVersion;
/**
* Map to store verified orders before execution
* @private
*/
protected verifiedOrders: Map<string, VerifiedOrder>;
/**
* Map to store pending requests and their callbacks
* @private
*/
protected pendingRequests: Map<string, (data: Message) => void>;
/**
* Map to store market data prices for each symbol
* @private
*/
protected marketDataPrices: Map<string, MarketDataEntry[]>;
/**
* Maximum number of price history entries to keep per symbol
* @private
*/
protected readonly MAX_PRICE_HISTORY = 100000;
constructor({ port, logger, onReady }: RemotePluginOptions);
register(parser: IFIXParser): Promise<void>;
private setupTools;
}