Skip to main content

Crate email_transport

Crate email_transport 

Source
Expand description

Core transport traits and per-send option types.

Transport models implementations that accept structured email_message::Message values, while RawTransport models implementations that send an explicit envelope plus RFC822 bytes. Provider-specific options are carried through TransportOptions so the core API stays transport-agnostic.

Terminology:

  • A transport is the Rust abstraction/implementation used to send mail.
  • A provider is the external service or protocol identity behind a transport, such as "resend", "postmark", or "smtp".
  • An instance is one configured use of a provider, such as "transactional" or "marketing".

§Adapter helpers (public API)

Several utility functions are deliberately public so adapter crates can share kernel logic without re-implementing it. They are part of the 1.0 semver surface:

Re-exports§

pub use string_newtype::STRING_NEWTYPE_MAX_BYTES;
pub use string_newtype::StringNewtypeError;
pub use tracing::TracingTransport;
pub use email_message;
pub use transport::*;

Modules§

options
Per-send options and provider-specific transport option storage.
string_newtype
Shared validation and macro support for string-backed newtypes.
tracing
tracing instrumentation for transport sends.
transport

Macros§

string_newtype
Generates a String-backed validated newtype with the standard derives and conversion impls.