aiosmtplib
Introduction
Aiosmtplib is an implementation of the python stdlib smtplib using asyncio, for use in asynchronous applications.
Basic usage:
import asyncio
import aiosmtplib
loop = asyncio.get_event_loop()
smtp = aiosmtplib.SMTP(hostname='localhost', port=25, loop=loop)
@asyncio.coroutine
def send_a_message():
sender = 'root@localhost'
recipient = 'somebody@localhost'
message = "Hello World"
yield from smtp.sendmail(sender, [recipient], message)
asyncio.async(send_a_message())
loop.run_forever()
Connecting to an SMTP server
Use an instance of the SMTP class to connect to a server. Note that if the event loop used to initialize the class is not currently running, it will be started in order to connect.
Sending messages
Use SMTP.sendmail to send raw messages. The method signature is the same as for standard smtplib.
Use SMTP.send_message to send email.message.Message objects. The method signature is the same as for standard smtplib.
Metadata
Release files for aiosmtplib 0.1.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| aiosmtplib-0.1.2.tar.gz | 10.2 kB | Without provenance | Details for aiosmtplib-0.1.2.tar.gz |
Release files / aiosmtplib-0.1.2.tar.gz
| Download URL | aiosmtplib-0.1.2.tar.gz |
|---|---|
| Size | 10.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
4f2f5f258d8f722e5d3de179a59d21583846986d1c5f6f358fbdfe2473baa630
|
|
BLAKE2b-256 checksum How to use checksums |
5a392b45ea9e1142fe832cf9a565911bd19c4731972dc6ea064f2ad4628d05b9
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
Security for aiosmtplib 0.1.2
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.