Hi all, I'm thinking to use `prefect-email` to sen...
# ask-community
m
Hi all, I'm thinking to use
prefect-email
to send out email notifications through an STMP server. My question is, is it able to render HTML? E.g.
subject = "<p><b><u>Summary of ETL Job:</u></b></p>"
and body message might look like:
Copy code
detailed = f"""
    <p><b><u>Detailed Report:</u></b></p>
    <table style="border-collapse: collapse;">
    <thead>
        <tr>
        {" ".join([f"<th style=''border: 1px solid black; padding: 5px; width: {'220px' if header in ('Error Message', 'Last Updated') else '60px'};''>{html.escape(str(header))}</th>" for header in headers])}
        </tr>
    </thead>
    <tbody>
    {" ".join(rows)}
    </tbody>
    </table>
"""
Found it in SDK docs, it will render html by default using
msg
and there is message plain option for non html.