I feel I’ve missed some vital piece of information here. I’m currently using the Username-Password-Authentication connection with custom database to auto-migrate users when they first login. I have the Login and GetUser scripts working great.
My login page uses the auth0.js library with the Username-Password-Authentication realm.
I’m struggling to understand how registering new or existing users (in my local DB due to unable to auto-migrate; forgotten password, bulk import etc). Is this possible using that same connection?
If I sign them up to a new connection, it will be different to the one I’m using for logging in and as I’m no longer storing password, they can’t migrate into that connection, behaviour I wouldn’t want anyway.
I understand that the GetUser scripts will execute each time, so if I first try to save to auth0, I get a 404 User not found. So I switch this and save locally first. I then get the user already exists error. I’m unable to register new users or manually migrate users to this connection.
How am I supposed to tackle this? Again, I’m sure I’ve missed something obvious.