chore: get rid of connection factory (#362)

Drive-by User-Agent sniffing and disabling of image type in Cursor.
This commit is contained in:
Pavel Feldman
2025-05-06 14:27:28 -07:00
committed by GitHub
parent 23a2e5fee7
commit e95b5b1dd6
13 changed files with 181 additions and 154 deletions

10
index.d.ts vendored
View File

@@ -16,8 +16,14 @@
*/
import type { Server } from '@modelcontextprotocol/sdk/server/index.js';
import type { Config } from './config';
import type { Transport } from '@modelcontextprotocol/sdk/shared/transport.js';
export declare function createServer(config?: Config): Promise<Server>;
export type Connection = {
server: Server;
connect(transport: Transport): Promise<void>;
close(): Promise<void>;
};
export declare function createConnection(config?: Config): Promise<Connection>;
export {};