hello, I'm trying to implement SuperTokens to my app and I'm unsure which guide should I follow. I'...
f
hello, I'm trying to implement SuperTokens to my app and I'm unsure which guide should I follow. I'm using NextJS, express and GraphQL. The goal would of course be to have access to user data on the backend. I'm not sure what would be the best way to do that here. I'm kind of new to NextJS so I am unsure how exactly the API routes work, is it possible to manage the auth in NextJS and then send all of the data to my backend through a mutation? Or should the auth be managed on the backend? I haven't been able to make that work.
r
Hey @User which recipe do you want to use? In each recipe, there is a section for NextJS that you can follow.
f
Hi, I'm trying to use ThirdPartyEmailPassword Recipe. I have been able to follow the NextJS section, but I am stuck on how to get the session info. How do I get the user info and send it to my backend to store it?
r
Do you want to do this when the user signs up? Like a post sign up hook?
f
yeah, basically
See "On the backend" section
f
thanks
c
Hi fila, your use case is similar to what i want to implement. Where my architecture is graphql + nextjs. With nextjs app router, im having a bit of trouble implementing protected routes. Do you mind sharing if you manage to do so?