[英]Getting a bad request bad request 400 when creating user(Firebase)
I am developing a web app and I'm using Firebase for that.我正在开发一个网络应用程序,我正在为此使用 Firebase。 Since I do not have a domain name yet, I'm trying to use my localhost.
由于我还没有域名,我正在尝试使用我的本地主机。 I can see localhost in
OAuth redirect domains
.我可以在
OAuth redirect domains
看到 localhost 。 Also the initializing part is working fine.初始化部分也工作正常。
But when I create a user using firebase.auth().signInWithEmailAndPassword
it shows [HTTP/2.0 400 Bad Request 447ms]
when posting to https://www.googleapis.com/identitytoolkit/v3/relyingparty/verifyPassword
.但是,当我使用
firebase.auth().signInWithEmailAndPassword
创建用户时,它会在发布到https://www.googleapis.com/identitytoolkit/v3/relyingparty/verifyPassword
时显示[HTTP/2.0 400 Bad Request 447ms]
。
I'm new to web app development and Firebase web as well.我也是网络应用程序开发和 Firebase 网络的新手。 Somebody please help me to do this using my localhost.
有人请帮助我使用我的本地主机做到这一点。
Thank you谢谢
You can create a user using firebase.auth().createUserWithEmailAndPassword(email, password)
.您可以使用
firebase.auth().createUserWithEmailAndPassword(email, password)
创建用户。 The email
must be in a valid format. email
必须采用有效格式。 Don't forget that the password
must be strong enough.不要忘记
password
必须足够强。 Firebase returns auth/weak-password
error code when using a weak password (less than 6 chars).使用弱密码(少于 6 个字符)时,Firebase 返回
auth/weak-password
错误代码。
See also: https://firebase.google.com/docs/reference/js/firebase.auth.Auth#createUserWithEmailAndPassword另请参阅: https : //firebase.google.com/docs/reference/js/firebase.auth.Auth#createUserWithEmailAndPassword
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.