pip install kpireport-smtp
This plugin utilizes
premailer for CSS inlining, which in turn
cssutils, which is licensed under LGPL 3.0. A copy of this
license is included in
LGPL-3.0.md in the plugin source.
- class kpireport_smtp.SMTPOutputDriver(report: kpireport.report.Report, **kwargs)¶
Email a report’s contents via SMTP to one or more recipients.
From email address.
Email addresses to send to.
SMTP server to relay mail through. Defaults to “localhost”.
SMTP port to use. Defaults to 25.
Strategy to use for including images in the mail contents. Two options are available:
embed: embed the image directly in the mail using Content-ID (RFC2392) linked resources. These should be compatible with most modern desktop and web mail clients.
remote: link the image to a remote resource. For this strategy to work, the image assets must exist on a server reachable via the public Internet (and not require authentication). Consider using the SMTP plugin in conjunction with e.g., the S3 or SCP plugins to accomplish this entirely within KPI reporter.
No tracking information is included when rendering remote image URLs; if for some reason you need to track open rates, consider using the SendGrid plugin to send the report instead.
When using the “remote” image strategy, the base URL for the image assets. Image blobs generated by Views are placed in folders named after the View ID; this base URL should point to the root path for all of these folders.