A free and open source app to manage email queues from any django project
Explore the documentation
Template Email Manager is a Django App that manages all the email communications of your Django project. You can create multiple sending accounts, HTML templates with attached images and email receivers. Everything is run-time customizable, since all the parameters are stored in DB. All messages are stored in a DB based queue.
- Allows you to use multiple source e-mail provider and address on the same Django project
- Each configured email provider has its own attributes (max send attempts, delay between retries, and so on...)
- You can add and edit TXT and HTML e-mail templates at run-time, without the need to change the code
- You can attach picture and/or other format attachment to the e-mails
- Automatic queue management using Django Background Tasks
- Storage of all added and processed e-mails with status and logs
-
Install it from PyPI inside your virtualenv:
pip install django-template-email-manager
-
Add
template_email_manager
to the list of installed app in your project (INSTALLED_APPS):INSTALLED_APPS = [ ... 'template_email_manager', ... ]
-
Run
python manage.py migrate
from your virtualenv to create the database structure. -
Create your template and save it on your DB and start using it or use the demo fixture
-
Where you want to send templated email add this import:
from template_email_manager.commands import add_email_to_queue
and add this code to add a mail to the send queue:
# context dict for the template variables replacement context = { 'var1': value1, 'var2': value2 } add_email_to_queue('template_name', context)
template_name
must much the name of a template stored in the modelHTMLTemplate
Please refer to the Docs for detailed info on how to install and use it.