I don't think I'm getting it,
1. Frontend generates a new code with POST
/auth/signinup/code
2. Backend sends email to user -> URL contains preAuthSessionId andlinkCode
Are these two steps correct? If yes, what is the user supposed to do with the email?
n
nkshah2
03/29/2022, 1:16 PM
@User Can add more detail here, but the general idea is that the email will contain the
urlWithLinkCode
to login the user. The user would click on the link which would open the
/verify
route on your frontend (this route is added by the SuperTokens frontend SDK when you initialise the Passwordless recipe)
The SDK then uses the query and such to continue with the flow
1. This is not on the FDI, this is a route on the frontend. Whatever page this link opens is supposed to parse the queryparam and the fragment and make a request to /auth/signinup/code/consume
porcellus
03/29/2022, 1:25 PM
2. You are not supposed to be handling this url on the backend. The linkCode is intentionally added as a fragment, # is not a separator in this sense. This is intended to be consumed by the browser.
SuperTokens is an open source authentication solution offering features like: Different types of login: Email / password, Passwordless (OTP or Magic link based).