How to Install your Easy-SMTP .NET library


This .NET library is distributed via NuGet. Installation using the package manager console can be done by typing:

PM> Install-Package reachmail

http://www.nuget.org/packages/reachmail/ 
https://github.com/ReachmailInc/WebAPISamples/tree/master/dotnet

using System;
using Reachmail.Easysmtp.Post.Request;

public void Main() 
{
    var client = Reachmail.Api.Create("");

    var request = new Reachmail.EasySmtp.Post.Message {
        FromAddress = "from@from.com",
        Recipients = new Recipients { 
            new Recipient { 
                Address = "to@to.com"
            }
        },
        Subject = "Subject",
        BodyText = "Text",
        BodyHtml = "html",
        Headers = new Headers { 
            { "name", "value" }
        },
        Attachments = new Attachments { 
            new EmailAttachment { 
                Filename = "text.txt",
                Data = "b2ggaGFp", // Base64 encoded
                ContentType = "text/plain",
                ContentDisposition = "attachment",
                Cid = ""
            }
        },
        Tracking = true,
        FooterAddress = "footer@footer.com",
        SignatureDomain = "signature.net"
    };

    var accountId = client.Administration.Users.Current.Get();
    var result = client.EasySmtp.Post(request, accountId);
}
×

Contact Us

Support Resources

ReachMail is here to help. If you have any questions, please use the form below or contact us at:

Support Hours: 8am - 6pm (Central Time) Mon-Fri