import { NextResponse } from "next/server"; export async function POST(req: Request) { try { const body = await req.json(); const response = await fetch( "http://localhost:3001/auth/register", { method: "POST", headers: { "Content-Type": "application/json" }, body: JSON.stringify(body), } ); const data = await response.json(); return NextResponse.json(data, { status: response.status }); } catch (error) { return NextResponse.json( { error: "Signup service not reachable" }, { status: 500 } ); } }