Namespace MailForge.Interfaces
Interfaces
- IEmailAuditSink
Receives a record of every send attempt. An audit sink is the recommended place to persist delivery history for retry and compliance purposes.
- IEmailMiddleware
A unit of the framework pipeline that wraps the delivery of an EmailMessage. Middleware can inspect and mutate the message, measure and log the attempt, apply retries, and short-circuit delivery by not invoking the next handler.
- IEmailProvider
A delivery channel that can transmit an EmailMessage to its recipients. Implementations wrap a concrete email service such as an SMTP server, an HTTP API (Resend, SendGrid), or a cloud SDK (Amazon SES).
- IEmailSender
The high-level entry point used by application code to send emails. The default implementation orchestrates rendering, validation, the middleware pipeline, and the configured IEmailProvider.
- IEmailValidator
Validates an EmailMessage before it is delivered. Validators are invoked by the framework pipeline; a failed validation prevents the message from being sent.
Delegates
- NextEmailHandler
Delegates to the next step of the pipeline.