## API Report File for "@eigenpal/docx-editor-agents"

> Do not edit this file. It is a report generated by [API Extractor](https://api-extractor.com/).

```ts

// @public
export function encodeFrame(message: JsonRpcMessage): string;

// @public
export const ErrorCode: {
    readonly ParseError: -32700;
    readonly InvalidRequest: -32600;
    readonly MethodNotFound: -32601;
    readonly InvalidParams: -32602;
    readonly InternalError: -32603;
};

// @public (undocumented)
export function isJsonRpcNotification(m: unknown): m is JsonRpcNotification;

// @public (undocumented)
export function isJsonRpcRequest(m: unknown): m is JsonRpcRequest;

// @public (undocumented)
export interface JsonRpcError {
    // (undocumented)
    error: {
        code: number;
        message: string;
        data?: unknown;
    };
    // (undocumented)
    id: JsonRpcId;
    // (undocumented)
    jsonrpc: '2.0';
}

// @public
export type JsonRpcId = string | number | null;

// @public (undocumented)
export type JsonRpcMessage = JsonRpcRequest | JsonRpcNotification | JsonRpcResponse;

// @public (undocumented)
export interface JsonRpcNotification {
    // (undocumented)
    jsonrpc: '2.0';
    // (undocumented)
    method: string;
    // (undocumented)
    params?: unknown;
}

// @public (undocumented)
export interface JsonRpcRequest {
    // (undocumented)
    id: JsonRpcId;
    // (undocumented)
    jsonrpc: '2.0';
    // (undocumented)
    method: string;
    // (undocumented)
    params?: unknown;
}

// @public (undocumented)
export type JsonRpcResponse = JsonRpcSuccess | JsonRpcError;

// @public (undocumented)
export interface JsonRpcSuccess {
    // (undocumented)
    id: JsonRpcId;
    // (undocumented)
    jsonrpc: '2.0';
    // (undocumented)
    result: unknown;
}

// @public (undocumented)
export function makeError(id: JsonRpcId, code: number, message: string, data?: unknown): JsonRpcError;

// @public (undocumented)
export function makeSuccess(id: JsonRpcId, result: unknown): JsonRpcSuccess;

// @public (undocumented)
export interface McpContent {
    // (undocumented)
    text: string;
    // (undocumented)
    type: 'text';
}

// @public (undocumented)
export interface McpInitializeResult {
    // (undocumented)
    capabilities: {
        tools?: Record<string, unknown>;
    };
    // (undocumented)
    protocolVersion: string;
    // (undocumented)
    serverInfo: {
        name: string;
        version: string;
    };
}

// @public (undocumented)
export class McpServer {
    constructor(bridge: EditorBridge, options?: McpServerOptions);
    handle(message: JsonRpcMessage): JsonRpcResponse | null;
}

// @public
export interface McpServerOptions {
    name?: string;
    protocolVersion?: string;
    version?: string;
}

// @public (undocumented)
export interface McpToolDescriptor {
    // (undocumented)
    description: string;
    // (undocumented)
    inputSchema: Record<string, unknown>;
    // (undocumented)
    name: string;
}

// @public (undocumented)
export interface McpToolsCallParams {
    // (undocumented)
    arguments?: Record<string, unknown>;
    // (undocumented)
    name: string;
}

// @public (undocumented)
export interface McpToolsCallResult {
    // (undocumented)
    content: McpContent[];
    // (undocumented)
    isError?: boolean;
}

// @public (undocumented)
export interface McpToolsListResult {
    // (undocumented)
    tools: McpToolDescriptor[];
}

// @public
export function parseFrames(buffer: string): ParseResult;

// @public
export function runStdioServer(bridge: EditorBridge, options?: StdioServerOptions): StdioServerHandle;

// @public (undocumented)
export interface StdioServerHandle {
    close: () => void;
    feed: (chunk: string | Buffer) => void;
    server: McpServer;
}

// @public (undocumented)
export interface StdioServerOptions extends McpServerOptions {
    // (undocumented)
    input?: InputStream;
    log?: (msg: string) => void;
    // (undocumented)
    output?: OutputStream;
}

```
