Setup the email API at Postmark.
- Select Servers > Create Server. In the popup, enter the domain. You can use a 2- or 3-part domain name (or even more), for example, company.com or engineering.company.com. Then select a color and click “Create Server”.
- Select Sender Signatures > Add Domain or Signature. On the next page, click “Add Domain”. In the popup, enter the domain name you used in the previous step and click “Verify Domain”.
- On the DNS Settings page that follows, use the information presented to create the DKIM TXT record and Return-Path CNAME record by hand in Cloudflare DNS. When you create the Return-Path CNAME record in Cloudflare, make sure you de-select the Proxy Status icon so that it is set to DNS Only (the gray cloud).
- Click the “Verify” buttons for each record. You should receive a green balloon indicating successful creation for each of them.
- Go to https://dmarc.postmarkapp.com/. In the email address, enter “support@webmagic.studio”, and enter the domain name in the next field. Click the blue “Get Started for Free” button.
- On the page that follows, you are provided with the info you need to create another TXT record in Cloudflare DNS. First you’ll copy the value
_dmarc.company.com.
(including the dot at the end) from the Postmark page into the Name field of the Cloudflare TXT record. Next, copy all the text in the black box from the Postmark page into the Content field of the Cloudflare TXT record. Save the TXT record. - Back on the Postmark page, click the “Verify _dmarc.company.com” button. You should get a confirmation that says “You’re all set”.
- You can verify that all this worked by going to https://account.postmarkapp.com/signature_domains, then select the “DNS Settings” link for the domain. On the page that follows, scroll to the bottom. If everything worked, there will be a row of three boxes, and each of them should have a green checkmark and “Active” badge.
Now you need to setup the Postmark plugin withing the WordPress back-end of your site:
- Go to https://account.postmarkapp.com/servers, select the domain, and click the “API Tokens” tab. Click to copy the Server API Tokens to the clipboard.
- Select Plugins > Add New. On the page that follows, search for “Postmark for WordPress”.
- Install and activate the plugin.
- Select Settings > Postmark.
- Paste the token into the API Key field.
- Enter the “from” email address that should be used to send emails from the site. The address must be on the same domain as the site.
- Check to enable the Enabled, Force HTML, Track Opens, and Enable Logs options, then click “Save Changes”.
- Click the “Send Test Email” tab.
- Enter your email address in the To field, check to enable the “Send test as HTML…” option, and click the “Send Test Email” button.
- If the test worked, you’ll see a message saying “Test sent”. If it didn’t work, you’ll get a dump of debugging output that will contain a message indicating why the test failed.