import { handleMcp } from "@/lib/mcp"; export async function POST(req: Request) { let body: unknown; try { body = await req.json(); } catch { return Response.json( { jsonrpc: "2.0", id: null, error: { code: -32700, message: "Parse error" } }, { status: 400 } ); } return handleMcp(body); } export function GET() { return new Response("Method Not Allowed", { status: 405, headers: { Allow: "POST" } }); }