问题描述
我正在使用 Firebase Auth Rest API 为我的 Flutter 应用程序进行身份验证。当用户注册时,我想发送一封验证电子邮件,我已经在做,但是我如何查询用户是否已经点击了验证链接,因为如果他们已经验证,他们应该能够登录,如果没有他们应该收到一条消息,指出他们尚未通过验证,需要先验证。
有谁知道我如何解决这个问题?
这是我的代码:
Future<void> verifyEmail(String OobCode) async {
final url = 'https://identitytoolkit.googleapis.com/v1/accounts:update?key=[Here is my key]';
final response = await http.post(url,body: json.encode({'oobCode': OobCode}));
final responseData = json.decode(response.body);
_emailVerified = responseData['emailVerified']; //In this line I want to set my bool _emialVerified to the value of emailVerified.
}
解决方法
暂无找到可以解决该程序问题的有效方法,小编努力寻找整理中!
如果你已经找到好的解决方法,欢迎将解决方案带上本链接一起发送给小编。
小编邮箱:dio#foxmail.com (将#修改为@)