# Python Email API
Aspose.Email for Python via .NET is a suite of flexible and easy to use class libraries brought together to produce the most powerful Email Programming Component available today. The Python Email API implements a number of network protocols including SMTP, MIME, POP3, IMAP for creating, sending & receiving messages without needing to have any other component. It can also manipulate, extract & convert message files & message archives.
Aspose.Email for Python via .NET also provides classes and algorithms that are useful for time-oriented recurrence patterns, or schedules. The central concepts are coherent with the iCalendar RFC (2445), so it is easy to incorporate iCalendar features into your own python applications.
## Email Features
- Open or save emails in a variety of formats.
- Parse, read and save Microsoft Outlook messages and message archives.
- Comprehensive Object Model for MIME messages.
- Embed objects to email messages.
- Send individual or bulk emails.
- Create emails using Mail Merge while incorporating data from different types of sources.
- Create & consume iCalendar compliant recurrence patterns.
- [Connect to POP3 server for message management](https://docs.aspose.com/display/emailpythonnet/Connect+to+POP3+Server).
- [Access and manage emails, folders & filters using IMAP](https://docs.aspose.com/display/emailpythonnet/Connecting+to+IMAP+Server).
- [Send or forward messages via SMTP](https://docs.aspose.com/display/emailpythonnet/Sending+and+Forwarding+Messages).
- Verify email addresses, processing bounced messages, analyze spam via Bayesian & more.
## Read & Write Email Formats
**Microsoft Outlook:** MSG, PST, OST, OFT
**Email:** EML, EMLX, MBOX
**Others:** ICS, HTML, MHTML
## Getting Started with Aspose.Email for Python via .NET
Are you ready to give Aspose.Email for Python via .NET a try? Simply execute `pip install Aspose.Email-for-Python-via-NET` to get the latest version & try any of the following code snippets. You may also check the detailed [Developer's Guide](https://docs.aspose.com/display/emailpythonnet/Developer+Guide) for all possible usage scenarios.
## Inspect PST Structure & Items via Python
```python
personalStorage = PersonalStorage.from_file(dataDir + "template.pst")
folderInfoCollection = personalStorage.root_folder.get_sub_folders()
for folderInfo in folderInfoCollection:
print("Folder: " + folderInfo.display_name)
print("Total Items: " + str(folderInfo.content_count))
print("Total Unread Items: " + str(folderInfo.content_unread_count))
print("----------------------")
```
## Send Bulk Emails via SMTP using Python
```python
message1 = MailMessage("from@gmail.com", "to@gmail.com", "Sending Bulk Emails using Aspose.Email", "message1, how are you?")
message2 = MailMessage("from@gmail.com", "to@gmail.com", "Sending Bulk Emails using Aspose.Email", "message2, how are you?")
message3 = MailMessage("from@gmail.com", "to@gmail.com", "Sending Bulk Emails using Aspose.Email", "message3, how are you?")
manyMsg = MailMessageCollection()
manyMsg.append(message1)
manyMsg.append(message2)
manyMsg.append(message3)
#Send using Smtp Client
client = SmtpClient("smtp.gmail.com", 995, "username", "password")
client.security_options = SecurityOptions.AUTO
client.send(manyMsg)
```
Raw data
{
"_id": null,
"home_page": "https://products.aspose.com/email/python-net",
"name": "Aspose.Email-for-Python-via-NET",
"maintainer": null,
"docs_url": null,
"requires_python": "<3.14,>=3.5",
"maintainer_email": null,
"keywords": "Email, eml, msg, pst, ost, outlook, exchange, imap, smtp, pop3, thef, mht, mbo",
"author": "Aspose",
"author_email": null,
"download_url": null,
"platform": "macos_x86_64",
"description": "# Python Email API\n\nAspose.Email for Python via .NET is a suite of flexible and easy to use class libraries brought together to produce the most powerful Email Programming Component available today. The Python Email API implements a number of network protocols including SMTP, MIME, POP3, IMAP for creating, sending & receiving messages without needing to have any other component. It can also manipulate, extract & convert message files & message archives.\n\nAspose.Email for Python via .NET also provides classes and algorithms that are useful for time-oriented recurrence patterns, or schedules. The central concepts are coherent with the iCalendar RFC (2445), so it is easy to incorporate iCalendar features into your own python applications.\n\n## Email Features\n\n- Open or save emails in a variety of formats.\n- Parse, read and save Microsoft Outlook messages and message archives.\n- Comprehensive Object Model for MIME messages.\n- Embed objects to email messages.\n- Send individual or bulk emails.\n- Create emails using Mail Merge while incorporating data from different types of sources.\n- Create & consume iCalendar compliant recurrence patterns.\n- [Connect to POP3 server for message management](https://docs.aspose.com/display/emailpythonnet/Connect+to+POP3+Server).\n- [Access and manage emails, folders & filters using IMAP](https://docs.aspose.com/display/emailpythonnet/Connecting+to+IMAP+Server).\n- [Send or forward messages via SMTP](https://docs.aspose.com/display/emailpythonnet/Sending+and+Forwarding+Messages).\n- Verify email addresses, processing bounced messages, analyze spam via Bayesian & more.\n\n\n## Read & Write Email Formats\n\n**Microsoft Outlook:** MSG, PST, OST, OFT\n**Email:** EML, EMLX, MBOX\n**Others:** ICS, HTML, MHTML\n\n## Getting Started with Aspose.Email for Python via .NET\n\nAre you ready to give Aspose.Email for Python via .NET a try? Simply execute `pip install Aspose.Email-for-Python-via-NET` to get the latest version & try any of the following code snippets. You may also check the detailed [Developer's Guide](https://docs.aspose.com/display/emailpythonnet/Developer+Guide) for all possible usage scenarios.\n\n## Inspect PST Structure & Items via Python\n\n```python\npersonalStorage = PersonalStorage.from_file(dataDir + \"template.pst\")\nfolderInfoCollection = personalStorage.root_folder.get_sub_folders()\nfor folderInfo in folderInfoCollection:\n\tprint(\"Folder: \" + folderInfo.display_name)\n\tprint(\"Total Items: \" + str(folderInfo.content_count))\n\tprint(\"Total Unread Items: \" + str(folderInfo.content_unread_count))\n\tprint(\"----------------------\")\n```\n\n## Send Bulk Emails via SMTP using Python\n\n```python\nmessage1 = MailMessage(\"from@gmail.com\", \"to@gmail.com\", \"Sending Bulk Emails using Aspose.Email\", \"message1, how are you?\")\nmessage2 = MailMessage(\"from@gmail.com\", \"to@gmail.com\", \"Sending Bulk Emails using Aspose.Email\", \"message2, how are you?\")\nmessage3 = MailMessage(\"from@gmail.com\", \"to@gmail.com\", \"Sending Bulk Emails using Aspose.Email\", \"message3, how are you?\")\n\nmanyMsg = MailMessageCollection()\nmanyMsg.append(message1)\nmanyMsg.append(message2)\nmanyMsg.append(message3)\n\n#Send using Smtp Client\nclient = SmtpClient(\"smtp.gmail.com\", 995, \"username\", \"password\")\nclient.security_options = SecurityOptions.AUTO\n\nclient.send(manyMsg)\n```\n",
"bugtrack_url": null,
"license": "https://company.aspose.com/legal/eula",
"summary": "A collection of components for working with email. It makes it easy to work with Outlook PST, EML, MSG and MHT files.",
"version": "24.11",
"project_urls": {
"Homepage": "https://products.aspose.com/email/python-net"
},
"split_keywords": [
"email",
" eml",
" msg",
" pst",
" ost",
" outlook",
" exchange",
" imap",
" smtp",
" pop3",
" thef",
" mht",
" mbo"
],
"urls": [
{
"comment_text": "",
"digests": {
"blake2b_256": "93dbe72c540e83bf088d7c8499b4780b17c4e288d158b4763cf58849cce8cca9",
"md5": "b6f81198b74c66a9f3040ca3d1318737",
"sha256": "e706daae2478ea84287f575e092d252dfd2ed931f4cb1e72fe817a65b97b54bc"
},
"downloads": -1,
"filename": "Aspose.Email_for_Python_via_NET-24.11-py3-none-macosx_10_14_x86_64.whl",
"has_sig": false,
"md5_digest": "b6f81198b74c66a9f3040ca3d1318737",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.14,>=3.5",
"size": 77328948,
"upload_time": "2024-11-11T17:01:20",
"upload_time_iso_8601": "2024-11-11T17:01:20.327127Z",
"url": "https://files.pythonhosted.org/packages/93/db/e72c540e83bf088d7c8499b4780b17c4e288d158b4763cf58849cce8cca9/Aspose.Email_for_Python_via_NET-24.11-py3-none-macosx_10_14_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "f14c2051da08f355363130a399f886ffb199b0f79d47b2f7da179e685dc4e8d7",
"md5": "cc2f727866f98fa8c6e71dd4a06bed7d",
"sha256": "14d16b5269a429a44c24a4b33a826fd422e772e8211039131f7ef0bb2d7ae3aa"
},
"downloads": -1,
"filename": "Aspose.Email_for_Python_via_NET-24.11-py3-none-macosx_11_0_arm64.whl",
"has_sig": false,
"md5_digest": "cc2f727866f98fa8c6e71dd4a06bed7d",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.14,>=3.5",
"size": 56873969,
"upload_time": "2024-11-11T17:01:48",
"upload_time_iso_8601": "2024-11-11T17:01:48.756623Z",
"url": "https://files.pythonhosted.org/packages/f1/4c/2051da08f355363130a399f886ffb199b0f79d47b2f7da179e685dc4e8d7/Aspose.Email_for_Python_via_NET-24.11-py3-none-macosx_11_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "852b67c12cc8c8aecd5c49ff636b8b564514a4c92b3d959c45aa383e2d48a5da",
"md5": "f642d7dbbddceea04fe041afc73423fb",
"sha256": "cdfa2ff906365de89fb1b6e25b180cfda951556f4900b7e0fbaa26b7911d24af"
},
"downloads": -1,
"filename": "Aspose.Email_for_Python_via_NET-24.11-py3-none-manylinux1_x86_64.whl",
"has_sig": false,
"md5_digest": "f642d7dbbddceea04fe041afc73423fb",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.14,>=3.5",
"size": 87737087,
"upload_time": "2024-11-11T17:02:34",
"upload_time_iso_8601": "2024-11-11T17:02:34.222776Z",
"url": "https://files.pythonhosted.org/packages/85/2b/67c12cc8c8aecd5c49ff636b8b564514a4c92b3d959c45aa383e2d48a5da/Aspose.Email_for_Python_via_NET-24.11-py3-none-manylinux1_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": "",
"digests": {
"blake2b_256": "5869e8c1a0bb1a7f609cd7d11665625fd6218861cc1adf2140529d41473d2a33",
"md5": "d1e0fa9d07077ec0bca77dd5cadeeed6",
"sha256": "e6a885de1565d655c2954aa16b08c921f5e015086674d5350f9fdf77651c9fc4"
},
"downloads": -1,
"filename": "Aspose.Email_for_Python_via_NET-24.11-py3-none-win_amd64.whl",
"has_sig": false,
"md5_digest": "d1e0fa9d07077ec0bca77dd5cadeeed6",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "<3.14,>=3.5",
"size": 58294207,
"upload_time": "2024-11-11T17:03:02",
"upload_time_iso_8601": "2024-11-11T17:03:02.407020Z",
"url": "https://files.pythonhosted.org/packages/58/69/e8c1a0bb1a7f609cd7d11665625fd6218861cc1adf2140529d41473d2a33/Aspose.Email_for_Python_via_NET-24.11-py3-none-win_amd64.whl",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2024-11-11 17:01:20",
"github": false,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"lcname": "aspose.email-for-python-via-net"
}