Unclear how to call phoneNumber signup from frontend
I'm using phone-number for sign-up, my authClient looks like ..
my auth backend is properly configured, but in my register page I'm unsure what to call, should it be -
There is no
authClient.signUp.phoneNumber()
functionSolution:Jump to solution
You have to send the otp for the verification and make sure to pass signUpOnVerification to set up a temporary email since right better auth requires an email fields and also the same for name. And you can sign in back with signin.phoneNumber .
7 Replies
I'm following these docs: https://www.better-auth.com/docs/plugins/phone-number#allow-sign-up-with-phone-number
Phone Number | Better Auth
Phone number plugin
Yes, I'm following those docs but still not sure how to call the actual sign up method. should I call it with email? or is there some arbitrary call? there is no phoneNumber call
Solution
You have to send the otp for the verification and make sure to pass signUpOnVerification to set up a temporary email since right better auth requires an email fields and also the same for name. And you can sign in back with signin.phoneNumber .
ok - yes i have the backend configured properly for the temp name/email.
So I just send the OTP and the user account is created? I'll try that

Yeah and make sure to verify it
Works. Thanks!