#I'm getting 404 on production with api dynamic routes but it works on local

4 messages · Page 1 of 1 (latest)

stuck citrus
#

Hi! I've a proxy api in /api/proxy/[...path].ts that works perfectly on local, but once I deploy it on vercel I'm getting 404 from the same route.

Could you help me please with this?

round crypt
#

It's because API routes are not created while using next export - trying to find a fix as well at the moment. - In development mode i have no problem using API, problem starts when i want to deploy and using them....

agile oak
#

Omg I can’t, why are you replying here, it literally has nothing to do with the issue. The export command is not something that vercel runs in their build pipeline so I really don’t see why you keep commenting about it

round crypt
# agile oak Omg I can’t, why are you replying here, it literally has nothing to do with the ...

well, because it breaks my 'next-auth' authentication process. which is in '/api/auth/[...nextauth].js' - i have no problems on localhost:3000 and i am able to sign in/sign out with OAuth2 .. but as soon as i deploy it to Vercel instead of my selfhost server, i get the same problems. - I am not able to get to the Sign-in Page anymore that Next-Auth is providing. on my selfhost server AND Vercel.