clinicaltrialsgov-mcp-server
Version:
ClinicalTrials.gov Model Context Protocol (MCP) Server that provides a suite of tools for interacting with the official ClinicalTrials.gov v2 API. Enables AI agents and LLMs to programmatically search, retrieve, and analyze clinical trial data.
24 lines (23 loc) • 1.27 kB
TypeScript
/**
* @fileoverview Provides a bridge between the MCP SDK's Node.js-style
* streamable HTTP transport and Hono's Web Standards-based streaming response.
* @module src/mcp-server/transports/core/honoNodeBridge
*/
import { PassThrough } from "stream";
/**
* A mock ServerResponse that pipes writes to a PassThrough stream.
* This is the bridge between Model Context Protocol's SDK's Node.js-style response handling
* and Hono's stream-based body. It captures status and headers.
*/
export declare class HonoStreamResponse extends PassThrough {
statusCode: number;
headers: Record<string, string | number | string[]>;
constructor();
writeHead(statusCode: number, headers?: Record<string, string | number | string[]>): this;
setHeader(name: string, value: string | number | string[]): this;
getHeader(name: string): string | number | string[] | undefined;
getHeaders(): Record<string, string | number | string[]>;
removeHeader(name: string): void;
write(chunk: unknown, encodingOrCallback?: BufferEncoding | ((error: Error | null | undefined) => void), callback?: (error: Error | null | undefined) => void): boolean;
end(chunk?: unknown, encodingOrCallback?: BufferEncoding | (() => void), callback?: () => void): this;
}