【发布时间】:2021-06-14 09:47:55
【问题描述】:
我正在尝试使用 Sendgrid Python 包发送电子邮件。
Sendgrid 打包邮件功能:
class Mail(object):
"""Creates the response body for v3/mail/send"""
def __init__(
self,
from_email=None,
to_emails=None,
subject=None,
plain_text_content=None,
html_content=None,
amp_html_content=None,
global_substitutions=None,
is_multiple=False):
........
我们将其用作:
message = Mail(
from_email=self.current_from_email,
to_emails=self.current_to_emails,
subject=s_subject.format(...),
html_content=s_body.format(...)
)
邮件功能中无法设置发件人姓名。
那么,如何设置发件人姓名呢?
【问题讨论】:
标签: python sendgrid sendgrid-api-v3