Table of Contents

Class SeznamMailbox

Namespace
SunamoMail
Assembly
SunamoMail.dll

Seznam.cz mailbox for sending emails. Working: does NOT save sent messages to outbox.

public class SeznamMailbox
Inheritance
SeznamMailbox
Inherited Members
Extension Methods

Constructors

SeznamMailbox()

Initializes a new instance for sending from noreply@sunamo.cz.

public SeznamMailbox()

SeznamMailbox(string, string, string, string, SmtpServerData?)

Initializes a new instance with full email configuration. Can be null, used to send mails to webmaster. Don't forget to set password or use parameterless constructor.

public SeznamMailbox(string fromName, string fromEmail, string mailOfAdmin, string password, SmtpServerData? smtpServer = null)

Parameters

fromName string

The sender's display name.

fromEmail string

The email address to send from.

mailOfAdmin string

The administrator's email address.

password string

The email account password.

smtpServer SmtpServerData

Optional SMTP server configuration.

Properties

FromEmail

Gets or sets the complete email address configured for sending.

public string? FromEmail { get; set; }

Property Value

string

FromName

Gets or sets the sender name that appears to recipients (does not need to be an email address).

public string? FromName { get; set; }

Property Value

string

MailOfAdmin

Gets or sets the administrator's email address for notifications.

public string? MailOfAdmin { get; set; }

Property Value

string

Methods

SendEmail(int, string, string, string, string, string, string, bool, params string[])

Sends an email message with retry attempts. Multiple addresses can be specified in to, cc, bcc separated by semicolons. Set replyTo to empty string to use the from address as reply-to.

public string SendEmail(int attempts, string to, string cc, string bcc, string replyTo, string subject, string body, bool isBodyHtml, params string[] attachments)

Parameters

attempts int

Number of send attempts to make before giving up.

to string

Recipient email address(es), semicolon-separated for multiple.

cc string

Carbon copy email address(es), semicolon-separated for multiple.

bcc string

Blind carbon copy email address(es), semicolon-separated for multiple.

replyTo string

Reply-to email address, or empty string to use the from address.

subject string

Email subject line.

body string

Email body content.

isBodyHtml bool

Whether the body content is HTML formatted.

attachments string[]

Optional file paths to attach to the email.

Returns

string

Returns "success" on successful send, or "error: [message]" on failure.