Soenneker.Messages.Email 11.0.484

Prefix Reserved
dotnet add package Soenneker.Messages.Email --version 11.0.484
                    
NuGet\Install-Package Soenneker.Messages.Email -Version 11.0.484
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Soenneker.Messages.Email" Version="11.0.484" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Soenneker.Messages.Email" Version="11.0.484" />
                    
Directory.Packages.props
<PackageReference Include="Soenneker.Messages.Email" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Soenneker.Messages.Email --version 11.0.484
                    
#r "nuget: Soenneker.Messages.Email, 11.0.484"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Soenneker.Messages.Email@11.0.484
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Soenneker.Messages.Email&version=11.0.484
                    
Install as a Cake Addin
#tool nuget:?package=Soenneker.Messages.Email&version=11.0.484
                    
Install as a Cake Tool

Soenneker.Messages.Email

alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image alternate text is missing from this package README image

Defines an email-delivery message envelope with recipients, sender overrides, content references, rendering tokens, format, and priority.

Installation

dotnet add package Soenneker.Messages.Email

Create a message

using Soenneker.Enums.Email.Format;
using Soenneker.Enums.Email.Priority;
using Soenneker.Messages.Email;

var message = new EmailMessage
{
    Type = "email.delivery.v1",
    Id = Guid.NewGuid().ToString("N"),
    Queue = "email",
    Sender = "accounts-api",
    CreatedAt = DateTimeOffset.UtcNow,

    To = ["person@example.com"],
    ReplyTo = "support@example.com",
    Subject = "Welcome",
    ContentFileName = "welcome.html",
    TemplateFileName = "layout.html",
    Format = EmailFormat.Html,
    Priority = EmailPriority.Normal,
    Tokens = new Dictionary<string, string>
    {
        ["firstName"] = "Sam"
    }
};

Available formats are EmailFormat.Plaintext and EmailFormat.Html. Priorities are EmailPriority.Low, EmailPriority.Normal, and EmailPriority.High.

Cc, Bcc, ReplyTo, sender Name and Address, ContentFileName, TemplateFileName, Tokens, and Partials are optional. How missing sender or content fields are resolved is the responsibility of the receiving email service.

Consumer responsibilities

This package is a serializable contract. It does not read content files, render templates, send email, or validate the message automatically. The receiving service should:

  • validate every recipient and sender address;
  • require at least one non-empty To entry and a non-empty subject;
  • treat file names as untrusted input and constrain resolved paths to approved content directories;
  • define the token and partial syntax used by its template engine;
  • avoid logging recipient data, token values, or rendered bodies when they may contain personal or sensitive information.

The [Required] and [MinLength] attributes are metadata for a validation framework; serialization alone does not execute them.

Product Compatible and additional computed target framework versions.
.NET net11.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages (2)

Showing the top 2 NuGet packages that depend on Soenneker.Messages.Email:

Package Downloads
Soenneker.Extensions.Messages.Email

A collection of helpful EmailMessage extension methods

Soenneker.Email.Senders.Abstract

An interface describing EmailSenders

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
11.0.484 49 11/14/2026
11.0.483 41 11/14/2026
11.0.481 398 11/11/2026
11.0.480 121 11/11/2026
11.0.479 130 11/11/2026
11.0.478 68 11/11/2026
11.0.477 273 11/10/2026
11.0.476 886 11/3/2026
11.0.475 220 11/3/2026
11.0.474 680 10/27/2026
11.0.473 408 10/26/2026
11.0.472 172 10/26/2026
11.0.471 95 10/26/2026
11.0.470 249 10/26/2026
11.0.469 220 10/26/2026
11.0.468 99 10/26/2026
11.0.466 105 10/26/2026
4.0.465 1,229 10/15/2026
4.0.464 131 10/14/2026
4.0.463 219 10/14/2026
Loading failed

Update dependency Soenneker.Enums.Email.Priority to 11.0.134 (#1064)