import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
export abstract class McpAgent {
abstract server: McpServer;
abstract init(): Promise<void>;
static serveSSE(path: string) {
return {
fetch: async (request: Request, env: any, ctx: any) => {
// SSE implementation would go here for Cloudflare Workers
return new Response("SSE not implemented", { status: 501 });
}
};
}
static serve(path: string) {
return {
fetch: async (request: Request, env: any, ctx: any) => {
// MCP serve implementation would go here for Cloudflare Workers
return new Response("MCP serve not implemented", { status: 501 });
}
};
}
}