Flask-Mailing


NameFlask-Mailing JSON
Version 0.2.3 PyPI version JSON
download
home_pagehttps://github.com/marktennyson/flask-mailing
SummaryFlask mail system sending mails(individual, bulk) attachments(individual, bulk) fully asynchroniously
upload_time2023-09-19 06:44:39
maintainer
docs_urlNone
authorAniket Sarkar
requires_python>=3.6,<4
licenseMIT
keywords flask flask-mail flask-mailing async-flask asynchroniously-send-email-in-flask async-mailer flask-email flask-mailman
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # ✉️ Flask-Mailing
![Flask mail logo](https://github.com/marktennyson/flask-mailing/blob/main/logo/flask-mailing-logo-cropped.png?raw=true)

__Flask-Mailing__ is a highly efficient and user-friendly package that enables `Asynchronous` email messaging in Flask applications. Asynchronous email messaging is becoming increasingly popular because it allows applications to continue running while emails are being sent in the background. This makes it an ideal solution for time-sensitive applications that require a fast and responsive user experience.

With Flask-Mailing, developers can easily integrate asynchronous email messaging capabilities into their Flask applications without the need for complex configurations or additional dependencies. The package offers a variety of features, including support for multiple email providers, email templates, and error handling. It also supports common email protocols, such as `SMTP`, `SSL`, and `TLS`.

Moreover, Flask-Mailing offers a simple and intuitive API that allows developers to easily send emails in the background. It also provides advanced features, such as email tracking and reporting, which enable developers to monitor email performance and user engagement.

Whether you're building a small-scale application or a large-scale enterprise system, Flask-Mailing provides a reliable and scalable solution for Asynchronous email messaging in Flask applications.

## Star History

[![Star History Chart](https://api.star-history.com/svg?repos=marktennyson/flask-mailing&type=Date)](https://star-history.com/#marktennyson/flask-mailing&Date)



### Key Features :sparkles:

1. :arrows_counterclockwise: Supports asynchronous email sending using the built-in `asyncio` library in Python 3.5+.

2. :link: Easily integrates with Flask applications using the provided `Mail` extension.

3. :gear: Offers simple and intuitive configuration options for email providers such as SMTP, Sendgrid, and Mailgun.

4. :envelope: Supports HTML and plain-text message formats, as well as the option to send both formats in a multi-part message.

5. :paperclip: Provides support for file attachments in emails.

6. :art: Includes customizable email templates and support for Jinja2 templates.

7. :rocket: Offers a simple API for sending email messages, allowing for quick and easy implementation in any Flask project.

8. :email: Supports bulk email sending, allowing for the efficient delivery of messages to large email lists.

9. :bookmark_tabs: Provides options for customizing email headers and message priority levels.

10. :chart_with_upwards_trend: Supports email tracking through message IDs and delivery status notifications.

11. :microscope: Includes a comprehensive testing suite for ensuring the correct configuration and behavior of the email sending functionality.

12. :lock: Supports email encryption and authentication using TLS and SSL protocols.

13. :warning: Offers error handling and logging functionality for tracking and resolving email sending issues.

14. :book: Provides detailed documentation and active community support for resolving any issues or questions related to the package.


More information on [Getting-Started](https://marktennyson.github.io/flask-mailing/getting-started)

# 📥 Downloads
[![Downloads](https://pepy.tech/badge/flask-mailing)](https://pepy.tech/project/flask-mailing) [![Downloads](https://pepy.tech/badge/flask-mailing/month)](https://pepy.tech/project/flask-mailing) [![Downloads](https://pepy.tech/badge/flask-mailing/week)](https://pepy.tech/project/flask-mailing)
<br>

# 🚑 Package health score by [snyk.io](https://snyk.io)
[![Flask-Mailing](https://snyk.io/advisor/python/Flask-Mailing/badge.svg)](https://snyk.io/advisor/python/Flask-Mailing)

# 🔗 Important Links
#### ❤️ [Github](https://github.com/marktennyson/flask-mailing)    
#### 📄 [Documentation](https://marktennyson.github.io/flask-mailing)    
#### 🐍 [PYPI](https://pypi.org/project/flask-mailing)    

# 🔨 Installation ###

```bash
 pip install flask-mailing
```
or install from the source code
```bash
git clone https://github.com/marktennyson/flask-mailing.git && cd flask-mailing
python -m pip install .
```

# 🦮 Guide


```python

from flask import Flask, jsonify
from flask_mailing import Mail, Message

app = Flask(__name__)

app.config['MAIL_USERNAME'] = "YourUserName"
app.config['MAIL_PASSWORD'] = "strong_password"
app.config['MAIL_PORT'] = 587
app.config['MAIL_SERVER'] = "your mail server"
app.config['MAIL_USE_TLS'] = True
app.config['MAIL_USE_SSL'] = False
app.config['USE_CREDENTIALS'] = True
app.config['VALIDATE_CERTS'] = True
app.config['MAIL_DEFAULT_SENDER'] = "youremailid@doaminname.com"

mail = Mail(app)

html = """
<p>Thanks for using Flask-Mailing</p> 
"""


@app.post("/email")
async def simple_send():
    message = Message(
        subject="Flask-Mailing module",
        recipients=["recipients@email-domain.com"],  # List of recipients, as many as you can pass 
        body=html,
        subtype="html"
        )
    await mail.send_message(message)
    return jsonify(status_code=200, content={"message": "email has been sent"})     
```

# 🪜 List of Examples

For more examples of using flask-mailing please check [example](https://marktennyson.github.io/flask-mailing/example/) section

# 👍 Contributing
Feel free to open issues and send pull requests.

## 😀 Contributors ✨

Thanks go to these wonderful people ([🚧]):


<table>
<tr>
    <td align="center"><a href="https://github.com/marktennyson"><img src="https://avatars.githubusercontent.com/u/46404058?v=4" width="100px;" alt=""/><br /><sub><b>Aniket Sarkar</b></sub></a><br /><a href="#maintenance-tbenning" title="Answering Questions">💬</a> <a href="https://github.com/marktennyson/flask-mailing" title="Reviewed Pull Requests">👀</a> <a href="#maintenance-jakebolam" title="Maintenance">🚧</a></td><br>
    <td align="center"><a href="https://github.com/jfkinslow"><img src="https://avatars.githubusercontent.com/u/4458739?v=4" width="100px;" alt=""/><br /><sub><b>Joshua Kinslow</b></sub></a><br /></td>
    <td align="center"><a href="https://github.com/agramfort"><img src="https://avatars.githubusercontent.com/u/161052?v=4" width="100px;" alt=""/><br /><sub><b>Alexandre Gramfort</b></sub></a><br /></td>
    <td align="center"><a href="https://github.com/ahmetkurukose"><img src="https://avatars.githubusercontent.com/u/1325263?v=4" width="100px;" alt=""/><br /><sub><b>
ahmetkurukose</b></sub></a><br /></td>
<td align="center"><a href="https://github.com/Sriram-bb63"><img src="https://avatars.githubusercontent.com/u/71959217?v=4" width="100px;" alt=""/><br /><sub><b>
Sriram</b></sub></a><br /></td>
<td align="center"><a href="https://github.com/CharlesTWood"><img src="https://avatars.githubusercontent.com/u/31315150?v=4" width="100px;" alt=""/><br/><sub><b>CharlesTWood</b></sub></a><br /></td>
</tr>
</table>

This project follows the [all-contributors](https://allcontributors.org) specification.
Contributions of any kind are welcome!

Before you start please read [CONTRIBUTING](https://github.com/marktennyson/flask-mailing/blob/main/CONTRIBUTING.md)



# 📝 LICENSE

[MIT](https://raw.githubusercontent.com/marktennyson/flask-mailing/development/LICENSE)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/marktennyson/flask-mailing",
    "name": "Flask-Mailing",
    "maintainer": "",
    "docs_url": null,
    "requires_python": ">=3.6,<4",
    "maintainer_email": "",
    "keywords": "flask,flask-mail,flask-mailing,async-flask,asynchroniously-send-email-in-flask,async-mailer,flask-email,flask-mailman",
    "author": "Aniket Sarkar",
    "author_email": "aniketsarkar@yahoo.com",
    "download_url": "https://files.pythonhosted.org/packages/56/2d/009a231147fdeb11f8c15babd8ead71d21111842333e0dd95a23b038b833/Flask-Mailing-0.2.3.tar.gz",
    "platform": "any",
    "description": "# \u2709\ufe0f Flask-Mailing\n![Flask mail logo](https://github.com/marktennyson/flask-mailing/blob/main/logo/flask-mailing-logo-cropped.png?raw=true)\n\n__Flask-Mailing__ is a highly efficient and user-friendly package that enables `Asynchronous` email messaging in Flask applications. Asynchronous email messaging is becoming increasingly popular because it allows applications to continue running while emails are being sent in the background. This makes it an ideal solution for time-sensitive applications that require a fast and responsive user experience.\n\nWith Flask-Mailing, developers can easily integrate asynchronous email messaging capabilities into their Flask applications without the need for complex configurations or additional dependencies. The package offers a variety of features, including support for multiple email providers, email templates, and error handling. It also supports common email protocols, such as `SMTP`, `SSL`, and `TLS`.\n\nMoreover, Flask-Mailing offers a simple and intuitive API that allows developers to easily send emails in the background. It also provides advanced features, such as email tracking and reporting, which enable developers to monitor email performance and user engagement.\n\nWhether you're building a small-scale application or a large-scale enterprise system, Flask-Mailing provides a reliable and scalable solution for Asynchronous email messaging in Flask applications.\n\n## Star History\n\n[![Star History Chart](https://api.star-history.com/svg?repos=marktennyson/flask-mailing&type=Date)](https://star-history.com/#marktennyson/flask-mailing&Date)\n\n\n\n### Key Features :sparkles:\n\n1. :arrows_counterclockwise: Supports asynchronous email sending using the built-in `asyncio` library in Python 3.5+.\n\n2. :link: Easily integrates with Flask applications using the provided `Mail` extension.\n\n3. :gear: Offers simple and intuitive configuration options for email providers such as SMTP, Sendgrid, and Mailgun.\n\n4. :envelope: Supports HTML and plain-text message formats, as well as the option to send both formats in a multi-part message.\n\n5. :paperclip: Provides support for file attachments in emails.\n\n6. :art: Includes customizable email templates and support for Jinja2 templates.\n\n7. :rocket: Offers a simple API for sending email messages, allowing for quick and easy implementation in any Flask project.\n\n8. :email: Supports bulk email sending, allowing for the efficient delivery of messages to large email lists.\n\n9. :bookmark_tabs: Provides options for customizing email headers and message priority levels.\n\n10. :chart_with_upwards_trend: Supports email tracking through message IDs and delivery status notifications.\n\n11. :microscope: Includes a comprehensive testing suite for ensuring the correct configuration and behavior of the email sending functionality.\n\n12. :lock: Supports email encryption and authentication using TLS and SSL protocols.\n\n13. :warning: Offers error handling and logging functionality for tracking and resolving email sending issues.\n\n14. :book: Provides detailed documentation and active community support for resolving any issues or questions related to the package.\n\n\nMore information on [Getting-Started](https://marktennyson.github.io/flask-mailing/getting-started)\n\n# \ud83d\udce5 Downloads\n[![Downloads](https://pepy.tech/badge/flask-mailing)](https://pepy.tech/project/flask-mailing) [![Downloads](https://pepy.tech/badge/flask-mailing/month)](https://pepy.tech/project/flask-mailing) [![Downloads](https://pepy.tech/badge/flask-mailing/week)](https://pepy.tech/project/flask-mailing)\n<br>\n\n# \ud83d\ude91 Package health score by [snyk.io](https://snyk.io)\n[![Flask-Mailing](https://snyk.io/advisor/python/Flask-Mailing/badge.svg)](https://snyk.io/advisor/python/Flask-Mailing)\n\n# \ud83d\udd17 Important Links\n#### \u2764\ufe0f [Github](https://github.com/marktennyson/flask-mailing)    \n#### \ud83d\udcc4 [Documentation](https://marktennyson.github.io/flask-mailing)    \n#### \ud83d\udc0d [PYPI](https://pypi.org/project/flask-mailing)    \n\n# \ud83d\udd28 Installation ###\n\n```bash\n pip install flask-mailing\n```\nor install from the source code\n```bash\ngit clone https://github.com/marktennyson/flask-mailing.git && cd flask-mailing\npython -m pip install .\n```\n\n# \ud83e\uddae Guide\n\n\n```python\n\nfrom flask import Flask, jsonify\nfrom flask_mailing import Mail, Message\n\napp = Flask(__name__)\n\napp.config['MAIL_USERNAME'] = \"YourUserName\"\napp.config['MAIL_PASSWORD'] = \"strong_password\"\napp.config['MAIL_PORT'] = 587\napp.config['MAIL_SERVER'] = \"your mail server\"\napp.config['MAIL_USE_TLS'] = True\napp.config['MAIL_USE_SSL'] = False\napp.config['USE_CREDENTIALS'] = True\napp.config['VALIDATE_CERTS'] = True\napp.config['MAIL_DEFAULT_SENDER'] = \"youremailid@doaminname.com\"\n\nmail = Mail(app)\n\nhtml = \"\"\"\n<p>Thanks for using Flask-Mailing</p> \n\"\"\"\n\n\n@app.post(\"/email\")\nasync def simple_send():\n    message = Message(\n        subject=\"Flask-Mailing module\",\n        recipients=[\"recipients@email-domain.com\"],  # List of recipients, as many as you can pass \n        body=html,\n        subtype=\"html\"\n        )\n    await mail.send_message(message)\n    return jsonify(status_code=200, content={\"message\": \"email has been sent\"})     \n```\n\n# \ud83e\ude9c List of Examples\n\nFor more examples of using flask-mailing please check [example](https://marktennyson.github.io/flask-mailing/example/) section\n\n# \ud83d\udc4d Contributing\nFeel free to open issues and send pull requests.\n\n## \ud83d\ude00 Contributors \u2728\n\nThanks go to these wonderful people ([\ud83d\udea7]):\n\n\n<table>\n<tr>\n    <td align=\"center\"><a href=\"https://github.com/marktennyson\"><img src=\"https://avatars.githubusercontent.com/u/46404058?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Aniket Sarkar</b></sub></a><br /><a href=\"#maintenance-tbenning\" title=\"Answering Questions\">\ud83d\udcac</a> <a href=\"https://github.com/marktennyson/flask-mailing\" title=\"Reviewed Pull Requests\">\ud83d\udc40</a> <a href=\"#maintenance-jakebolam\" title=\"Maintenance\">\ud83d\udea7</a></td><br>\n    <td align=\"center\"><a href=\"https://github.com/jfkinslow\"><img src=\"https://avatars.githubusercontent.com/u/4458739?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Joshua Kinslow</b></sub></a><br /></td>\n    <td align=\"center\"><a href=\"https://github.com/agramfort\"><img src=\"https://avatars.githubusercontent.com/u/161052?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>Alexandre Gramfort</b></sub></a><br /></td>\n    <td align=\"center\"><a href=\"https://github.com/ahmetkurukose\"><img src=\"https://avatars.githubusercontent.com/u/1325263?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>\nahmetkurukose</b></sub></a><br /></td>\n<td align=\"center\"><a href=\"https://github.com/Sriram-bb63\"><img src=\"https://avatars.githubusercontent.com/u/71959217?v=4\" width=\"100px;\" alt=\"\"/><br /><sub><b>\nSriram</b></sub></a><br /></td>\n<td align=\"center\"><a href=\"https://github.com/CharlesTWood\"><img src=\"https://avatars.githubusercontent.com/u/31315150?v=4\" width=\"100px;\" alt=\"\"/><br/><sub><b>CharlesTWood</b></sub></a><br /></td>\n</tr>\n</table>\n\nThis project follows the [all-contributors](https://allcontributors.org) specification.\nContributions of any kind are welcome!\n\nBefore you start please read [CONTRIBUTING](https://github.com/marktennyson/flask-mailing/blob/main/CONTRIBUTING.md)\n\n\n\n# \ud83d\udcdd LICENSE\n\n[MIT](https://raw.githubusercontent.com/marktennyson/flask-mailing/development/LICENSE)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "Flask mail system sending mails(individual, bulk) attachments(individual, bulk) fully asynchroniously",
    "version": "0.2.3",
    "project_urls": {
        "Homepage": "https://github.com/marktennyson/flask-mailing"
    },
    "split_keywords": [
        "flask",
        "flask-mail",
        "flask-mailing",
        "async-flask",
        "asynchroniously-send-email-in-flask",
        "async-mailer",
        "flask-email",
        "flask-mailman"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "084ce23b2870eb41eaf7e6265724a0662f886f630d62ba75e527a3566e5ff6b4",
                "md5": "ed25bb2bd124a1f5ba916a8e234aacf2",
                "sha256": "c3b98be3e24141d388701c9d9b8cf8f2e33ddef8ffa7c26a1f2efc61b9a68827"
            },
            "downloads": -1,
            "filename": "Flask_Mailing-0.2.3-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "ed25bb2bd124a1f5ba916a8e234aacf2",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": ">=3.6,<4",
            "size": 18982,
            "upload_time": "2023-09-19T06:44:37",
            "upload_time_iso_8601": "2023-09-19T06:44:37.068483Z",
            "url": "https://files.pythonhosted.org/packages/08/4c/e23b2870eb41eaf7e6265724a0662f886f630d62ba75e527a3566e5ff6b4/Flask_Mailing-0.2.3-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "562d009a231147fdeb11f8c15babd8ead71d21111842333e0dd95a23b038b833",
                "md5": "2791ef17b6f3dcf035469a052a2fff0d",
                "sha256": "e08df8db3caeec5602b1927ca8b56c6803bd420c1a85f37740c75b999945e0d8"
            },
            "downloads": -1,
            "filename": "Flask-Mailing-0.2.3.tar.gz",
            "has_sig": false,
            "md5_digest": "2791ef17b6f3dcf035469a052a2fff0d",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": ">=3.6,<4",
            "size": 18896,
            "upload_time": "2023-09-19T06:44:39",
            "upload_time_iso_8601": "2023-09-19T06:44:39.350354Z",
            "url": "https://files.pythonhosted.org/packages/56/2d/009a231147fdeb11f8c15babd8ead71d21111842333e0dd95a23b038b833/Flask-Mailing-0.2.3.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2023-09-19 06:44:39",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "marktennyson",
    "github_project": "flask-mailing",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "tox": true,
    "lcname": "flask-mailing"
}
        
Elapsed time: 0.15543s