在Python中,我正在尝试做‘发送密码重置电子邮件’,javascript参考(https://firebase.google.com/docs/reference/js/firebase.auth.Auth#sendPasswordResetEmail)。到目前为止(也只是最近),看起来像是添加了“生成密码重置链接”(https://github.com/firebase/firebase-admin-python/releases)。谁知道发送电子邮件的下一步是什么?我们自己发送电子邮件吗?如果是这样,有什么建议吗?有没有办法用python直接发送电子邮件?
提前感谢您的帮助!
发布于 2019-03-05 12:48:53
感谢Github上的(bojeil-google)提供的答案。显然,这样做的方法是为每个https://firebase.google.com/docs/reference/rest/auth/#section-send-password-reset-email发出一个POST请求。在python SDK中没有直接调用来完成此操作。再次感谢!
发布于 2019-10-12 10:16:25
Firebase-admin-sdk (python)缺乏处理用户身份验证的方法。您可以使用Pyrebase。它是firebase API的包装器。
发布于 2020-06-30 07:17:24
可能会迟到,但其他人会看到:
email = 'user@example.com'
link = auth.generate_password_reset_link(email, action_code_settings)
# Construct password reset email from a template embedding the link, and send
# using a custom SMTP server.
send_custom_email(email, link)更多信息请点击此处:https://firebase.google.com/docs/auth/admin/email-action-links#python_1
https://stackoverflow.com/questions/54995334
复制相似问题