📜  烧瓶发送电子邮件 gmail - Python 代码示例

📅  最后修改于: 2022-03-11 14:45:58.179000             🧑  作者: Mango

代码示例1
if __name__ == '__main__':
    with app.app_context():
        msg = Message(subject="Hello",
                      sender=app.config.get("MAIL_USERNAME"),
                      recipients=[""], # replace with your email for testing
                      body="This is a test email I sent with Gmail and Python!")
        mail.send(msg)