You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 
 
 

16 lines
493 B

from config import app, mail
from flask_mail import Mail, Message
@app.route("/send_mail")
def index():
mail_message = Message('Hi ! Don’t forget to follow me for more article!',
sender='celestino_rey@ymail.com',
recipients = ['celestino.rey@gmail.com'])
mail_message.body = "This is a test"
mail.send(mail_message)
return "hola mundo. Mensaje enviado"
if __name__ == '__main__':
app.run(debug = True)