Fix proxy path — prepend /api/ when forwarding to FastAPI

This commit is contained in:
2026-04-26 15:43:29 +00:00
parent 4c8556a3d2
commit 3b63e0076f
+1 -1
View File
@@ -7,7 +7,7 @@ async function handler(
{ params }: { params: Promise<{ slug: string[] }> } { params }: { params: Promise<{ slug: string[] }> }
) { ) {
const { slug } = await params; const { slug } = await params;
const path = '/' + slug.join('/'); const path = '/api/' + slug.join('/');
const url = `${API_BASE}${path}${request.nextUrl.search}`; const url = `${API_BASE}${path}${request.nextUrl.search}`;
const headers = new Headers(); const headers = new Headers();