Sending Automated Emails from Workflows

Updated: 2026-08-20Reading time: 4 min

Choose between Gmail, a dedicated transactional provider, or SMTP for automated email sending, build dynamic templates with merge tags, and protect deliverability with SPF and DKIM.

Choosing an Email Provider

Cotonity supports three email sending methods, each suited to a different use case. For low-volume internal notifications (fewer than a few hundred emails per day), the Gmail integration is the easiest to set up and requires no additional accounts. For transactional emails to customers — order confirmations, password resets, welcome sequences — use a dedicated provider like SendGrid, Postmark, or Amazon SES, which offer high deliverability rates, bounce and click tracking, and managed IP reputation. For corporate environments where all outgoing email must route through your company's mail server, Cotonity's SMTP step accepts any SMTP server credentials. Add your chosen provider as a connection under Connections → Add Connection and select the appropriate type.

Building Dynamic Email Content

Once a connection is configured, add a Send Email step to your workflow. The 'To' field, subject line, and body all support Cotonity's double-curly-brace template syntax for injecting dynamic values. A welcome email subject might read 'Welcome to Cotonity, {{trigger.body.first_name}}!' and the body might include the user's plan name, their unique account ID, and a link generated by a previous step. For HTML emails, write your content in the HTML body field; the step also accepts a plain-text fallback body for email clients that do not render HTML. If you are sending similar emails across multiple workflows, consider creating an email template in your chosen provider's template library and using Cotonity's 'Send with Template' step variant, which accepts a template ID and a JSON object of variable values.

Handling Replies and Delivery Failures

Set a Reply-To address that is actually monitored by a human or a support tool — it is poor practice to send automated emails from 'noreply@' addresses, and many email clients flag them as suspicious. If your email provider supports webhooks for delivery events (bounces, spam complaints, unsubscribes), configure those webhooks to trigger a Cotonity workflow that updates the recipient's contact record in your CRM. This ensures your contact database stays accurate and that subsequent workflow runs do not attempt to email an address that has bounced or unsubscribed. Always include a visible unsubscribe link in marketing and notification emails — not only is this a legal requirement in many jurisdictions, it reduces spam complaints, which protects your sending domain's reputation.

Avoiding the Spam Folder

Even well-constructed automated emails can end up in spam if your sending infrastructure is not correctly configured. Ensure your sending domain has SPF, DKIM, and DMARC DNS records set up as specified by your email provider. Avoid spam trigger words in subject lines ('FREE', 'URGENT', excessive punctuation or capitalisation). Keep your sending volume consistent rather than sending thousands of emails suddenly after a long quiet period. If you are starting a new sending domain or IP address, use a warm-up schedule over two to four weeks, gradually increasing daily volume. Most dedicated email providers offer a domain reputation dashboard — check it weekly when you launch a new automated email flow to catch deliverability problems before they become entrenched.