Open
Description
sp = SparkPost(settings.SPARKPOST_API_KEY)
try:
sp.transmission.send(
recipients=to,
bcc=bcc,
from_email=from_email, # I tried this, but still it's not working
template=template_id,
substitution_data=substitution_data,
transactional=True,
ip_pool=settings.SPARKPOST_IP_POOL,
content={"from": from_email} # Tried to override the from email like this, but this is not working
)
except SparkPostAPIException as e:
capture_exception(e)
This is how we send email, but I want to override the from email in place of default set in template settings.
Why? because we have different from email for different environments.
So How can I achieve that?
Maybe related to this: #161
Metadata
Metadata
Assignees
Labels
No labels