HomeDev GuideAPI Reference
Dev GuideAPI ReferenceUser GuideLegal TermsGitHubNuGetDev CommunityOptimizely AcademySubmit a ticketLog In
Dev Guide

Notifications

Describes how you can use Optimizely Commerce Connect 13 to send notifications and transactional emails to customers.

Transactional emails include welcome, order confirmation, and order shipped confirmation. The notification and transactional email template generates templated content and creates personalized emails for customers regarding orders.

There are multiple ways to send notifications and transactional emails. The following section uses Optimizely Content Management System (CMS) to store email templates as page types and then rendering them with personalized content before sending. You can reference QuickSilver to see how to implement this approach. There are also third party services like SendGrid and MailChimp that allows you to send customized emails to your customers.

  1. Create a page in CMS and corresponding view template for the email. See Quicksilver OrderConfirmationMailPage

  2. When sending the email, download the CMS page contents in the background, using http client. See Quicksilver HtmlDownloader, MailService

  3. Use the rendered content as the email body.

You can store your email provider settings in appsettings.json.

//appsettings.json
    {
      "Smtp": {
        "Server": "mail.whatever.com",
        "Port": 25,
        "FromAddress": "[email protected]"
      },
    }