Installation
Install AlmightyShogun.Mail.Resend in the application that sends email through Resend. The package targets net10.0, uses the official Resend client package, and registers its mail sender through Microsoft.Extensions.DependencyInjection.
sh
dotnet add package AlmightyShogun.Mail.ResendDependencies
Package references
Resend0.16.0— provides the Resend API client used to send email messages.Microsoft.Extensions.Http10.0.11— registers the Resend client throughIHttpClientFactory.Microsoft.Extensions.Http.Resilience10.9.0— adds retry, a circuit breaker, and a timeout to the send call.Microsoft.Extensions.DependencyInjection.Abstractions10.0.11— the service collection the mail service registers into.Microsoft.Extensions.Logging.Abstractions10.0.11—ILogger<T>, used to report a failed send.Microsoft.Extensions.Options10.0.11— reads the boundEmailsettings at runtime.
Project references
AlmightyShogun.Utils— provides the configuration binding helper used during startup registration.
Startup Registration
Register the package once during application startup. The registration binds email settings, configures the Resend API token, and exposes the mail sender through IResendMailService.
csharp
using AlmightyShogun.Mail.Resend;
builder.Services.AddResendEmail(builder.Configuration);