#Oauth error

9 messages · Page 1 of 1 (latest)

fathom stone
#

let me know i m missing something in env

kindred silo
#

I think you have not setup your middleware.ts so your application is treating your queries as if they are regular api endpoints.

make sure you import {
convexAuthNextjsMiddleware,
createRouteMatcher,
nextjsMiddlewareRedirect,
} from "@convex-dev/auth/nextjs/server";

and handle middleware with convexAuthNextjsMiddleware

fathom stone
#

https://github.com/arjunkambj/next-convex

The middleware is set up.

I even created a new Next.js project using the Convex command, which comes with pre-configured authentication, and matched every file. Still, I'm getting the error.

#

let me if this is correct

kindred silo
#

I don't know if that is the issue and as stupid as it may sound, stop the dev env and can you rename Middleware.ts to middleware.ts and restart the dev environment to see if that helped?

fathom stone
#

Mannn

#

you are legend

#

its working now