Table of Contents

Interface ISesClient

Namespace
Builvero.Application.Interfaces.Services
Assembly
Builvero.Application.dll

Interface for AWS SES email client operations.

public interface ISesClient

Remarks

This interface abstracts the AWS SES SDK to allow for testing and mocking.

Methods

SendEmailAsync(string, string?, List<string>, string, string, string?, List<string>?, string?, CancellationToken)

Sends an email using AWS SES.

Task<string> SendEmailAsync(string fromAddress, string? fromName, List<string> toAddresses, string subject, string htmlBody, string? textBody = null, List<string>? replyToAddresses = null, string? configurationSet = null, CancellationToken cancellationToken = default)

Parameters

fromAddress string

The sender email address (must be verified in SES).

fromName string

The sender display name.

toAddresses List<string>

List of recipient email addresses.

subject string

Email subject.

htmlBody string

HTML email body.

textBody string

Plain text email body (optional).

replyToAddresses List<string>

List of reply-to email addresses (optional).

configurationSet string

SES configuration set name (optional).

cancellationToken CancellationToken

Cancellation token.

Returns

Task<string>

The message ID from SES.

Exceptions

Exception

Thrown when SES API returns an error.