🧪 Experimental KB — Official knowledge hub: community.kaptio.com

Emails Not Sending in Sandbox Environment

Emails are not being sent from a sandbox or UAT environment. Emails may remain in 'Rendered' status in the email queue, or supplier booking emails do not generate. This commonly occurs after a sandbox

sandbox email configuration app-settings sendgrid email-queue

Problem

Emails are not being sent from a sandbox or UAT environment. Emails may remain in ‘Rendered’ status in the email queue, or supplier booking emails do not generate. This commonly occurs after a sandbox refresh or when setting up a new sandbox.

What We Found

By default, email sending is disabled in sandbox environments to prevent accidental emails to real customers. The ‘Enable Emails in Sandbox’ setting in App Settings must be explicitly enabled for emails to be sent from non-production environments.

Solution

  1. Navigate to Setup > Custom Settings
  2. Find ‘App Settings’ in the list and click ‘Manage’
  3. Click ‘Edit’ on the App Settings record
  4. Check the box for ‘Enable Emails in Sandbox’
  5. Click ‘Save’
  6. Test by sending a new email - it should now send successfully

Notes

  • This setting is automatically reset to unchecked after a sandbox refresh from production
  • Setting ‘Enable Emails in Sandbox’ to true does NOT automatically send previously rendered emails that are queued
  • Previously rendered emails will be sent when a new email is triggered, unless ‘Disable Asynchronous Emails’ is also set to true
  • To prevent queued emails from sending to real addresses, consider running the GlobalDataScrubberBatch to replace email addresses with ‘example@example.com’
  • Alternatively, update Email Queue records in ‘Rendered’ status by setting Status Id to a number greater than 4 to prevent them from being picked up

Warnings

⚠️ Be cautious when enabling emails in sandbox if there are many ‘Rendered’ emails in the queue - they may be sent to real recipients when the next email is triggered ⚠️ If testing in sandbox with production data, scrub email addresses first to avoid sending test emails to real customers


Source: KHELP-12292

Was this article helpful?