Skip to main content

simple_module_mail

Outgoing mail for simple_module apps. The module owns the transport (SMTP via aiosmtplib, or a console backend that logs each message) and its settings, and installs a process-level sender that any module can use through simple_module_core.mailer.mail without knowing whether mail is configured.

The default backend is console: messages are logged, nothing is delivered. Switch to smtp and fill in the server details to deliver real email.

Install

Add the package to your host and re-sync. Discovery picks it up from the simple_module entry point, no host code changes:

# host/pyproject.toml
dependencies = ["simple_module_mail"]
uv sync --all-packages

Usage

  1. Sign in as an admin and open Settings -> Modules -> Mail.
  2. Set backend to smtp and fill smtp_host, smtp_port, smtp_username, smtp_password (masked in the UI), smtp_from, smtp_tls and smtp_tls_mode (auto, starttls or implicit). Use implicit for implicit TLS on custom ports; smtp_tls=false disables TLS in every mode. Saving rebuilds the sender live, no restart needed.
  3. Use Test connection to run the mail.mailer health check. It logs in to the server and hangs up without sending anything.

From code, send through the core interface:

from simple_module_core.mailer.mail import MailMessage, current_mail_sender

await current_mail_sender().send(
    MailMessage(to="a@example.com", subject="Hello", text="Plain body")
)

Code that may run in the outbox worker (no app) calls await resolve_mail_sender(db) instead; the module installs a resolver that builds the sender from the stored settings. sender.delivers_email is False for the console backend, so screens can fall back to showing a link.

Settings stored by earlier versions as users.mailer / users.smtp_* are moved to mail.backend / mail.smtp_* by a data migration.

Metadata

Release files for simple-module-mail 0.0.51

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for simple-module-mail 0.0.51
File Size Uploaded Provenance Actions
simple_module_mail-0.0.51.tar.gz 28.5 kB With provenance Details for simple_module_mail-0.0.51.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for simple-module-mail 0.0.51
File Interpreter ABI Platform Actions
simple_module_mail-0.0.51-py3-none-any.whl Python 3 none any Details for simple_module_mail-0.0.51-py3-none-any.whl

Total release size: 46.2 kB

Release files / simple_module_mail-0.0.51.tar.gz

Download URL simple_module_mail-0.0.51.tar.gz
Size 28.5 kB
Tags Source
SHA-256 checksum
How to use checksums
a734b8de944dfd53140c097a76d839dceee61cff7505c70ce2f0cb995e0ad131
BLAKE2b-256 checksum
How to use checksums
48c5ba4e443e35aaa193af8aae2875fd74548dc49a6af48a82cff8814c4198ba
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

Release files / simple_module_mail-0.0.51-py3-none-any.whl

Download URL simple_module_mail-0.0.51-py3-none-any.whl
Size 17.7 kB
Tags Python 3
SHA-256 checksum
How to use checksums
536459820256c2efdc1bdd6d84ed652cd727f2c5b287443a3c7fe963161dff12
BLAKE2b-256 checksum
How to use checksums
35292a7c9f86f5eaf341d340a8a447edac5105459e6d0930e33ce61f1827ff05
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.16

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.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

Security for simple-module-mail 0.0.51

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.

Full provenance

Both files in this release have been uploaded with provenance metadata.

Select from 2 files

Attestation for simple_module_mail-0.0.51.tar.gz

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Nov 29, 2026.

Transparency log

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.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page