Secure Email

Troubleshooting

Troubleshooting reference covering the full Secure Email lifecycle — sending, bulk sending, delivery status, and replying. Each row follows Symptom → Likely Cause → Solution, grouped by category so you can jump straight to the relevant area.

Common Issues Across Send, Bulk Send & Reply

These four issues show up in more than one flow with the same root cause — documented once here instead of three times below.

Symptom

Likely Cause

Solution

"License not assigned" / "Email not entitled" message; Reply icons missing; bulk send blocked

  • Package license (cmsecureemail) missing on the user

  • Features Entitlement Secure_Email__c is off

  • Component not on the page layout (Reply only)

  • Assign the cmsecureemail license

  • Enable Secure Email under Features Entitlement

  • For Reply, confirm the Secure Email LWC/Aura component is on the record page

Opt-out banner blocks compose or send

Parent record's opt-out field (mapped via Email_Configuration__mdt → Email Opt Out Field) is true

  • Clear/update the opt-out field on the parent record if appropriate

  • Fix the mapping if the wrong field is configured

  • Message text comes from SE_OptOutMessage if it needs updating

From / Reply-To dropdown empty, missing addresses, read-only, or BCC not shown

  • Missing Email_Configuration__mdt for the object

  • Invalid Record_Type_Mapping__c JSON (Only when From and Reply are getting based on `the record type)

  • Domain filtered by SecureEmail_AllowedDomains

  • OWD disabled (ShowOWDFromAddress / ShowOWDReplyToAddress)

  • Defaults not set (DefaultFromAddress, DefaultReplyToAddress)

  • SE_DynamicUserFromAddress misconfigured

  • SE_FromAddress_ReadOnly / SE_ReplyAddress_ReadOnly = true

  • SE_HideBCCOption hiding BCC

  • Validate Email_Configuration__mdt for the object

  • Fix/minify the mapping JSON (no raw line breaks in strings)

  • Check SecureEmail_AllowedDomains (semicolon-separated)

  • Enable OWD settings if Org-Wide Emails should appear

  • Set Default From/Reply-To as fallback

  • Set ReadOnly settings to false if fields should be editable

  • Disable SE_HideBCCOption if BCC should show

Component fails to load with a JSON error (JSONException / CTRL-CHAR code 13)

Invalid JSON in cmsecureemail__Record_Type_Mapping__c on Email Configuration metadata

  • Edit the metadata JSON, remove carriage returns/newlines inside quoted values

  • Validate and save as minified JSON, then retest

Sending Secure Email (Single Compose)

Validation Errors

Symptom

Likely Cause

Solution

"To Address cannot be null"

To is blank, or multi-select returned nothing

Enter/select a To address; if using multi-To, confirm EnableMultipleToAddress and MultipleToAddressMapping__c

"Email Subject or Body cannot be null"

Template mode with no template selected; or Custom mode with empty subject/body

Select a template, or switch to Custom and fill subject/body; check SecureEmail_TemplateOrCustom / SecureEmail_DefaultTemplate

Template/Custom radio not selected, or the wrong body section shows

SecureEmail_TemplateOrCustom isn't set to a valid value

Set the value to template or custom-body

Attachments

Symptom

Likely Cause

Solution

No upload control, or file type rejected

SecureEmail_EnableFileUplaod = false, or format not in AccepetedFileFormat_SecureEmail

Enable the upload setting; update the accepted formats list

"Total File size cannot exceed 8.5 MB"

Combined attachments over the limit

Remove files until under 8.5 MB

Scheduling & Delivery

Symptom

Likely Cause

Solution

No schedule toggle, or a scheduled email stays in "Created"

SE_HideScheduleFeature = true; or BatchSendSecureEmail isn't running, or the record falls outside SecureEmailBatch_LastNDays

Unhide the schedule feature if needed; confirm Schedule Time is ≤ now and the batch job is scheduled (NextBatchProcessSecureEmail)

Error toast after Send (API/integration failure)

Paubox credentials wrong; ApiConnection Test vs Production mismatch; domain credentials missing

Check ApiConnection, PauboxCredentials__c, the From domain, and Integration Status on the record

Bulk Send Secure Email

Symptom

Likely Cause

Solution

Bulk screen opens with no recipients loaded

List-view record IDs not passed (listObjectIds empty)

Launch bulk send from a list view with records selected; confirm the list-view action passes IDs

"Please fill up the required fields"

Missing From, Reply-To, email field column, subject, or body

Complete From, Reply-To, To email field, Subject, and Message/Template

No Validation of Emails Happens

Missing Email_Configuration__mdt--> Bulk Fields mapping

Update Bulk FirstName and Bulk Last name fields in the metadata for that Object.

Many "Records with Missing Emails"

Selected email field is blank on those records, or the wrong field API name was chosen

Choose the correct email field; backfill missing emails — only valid records are sent

Bulk send "succeeds" but few or no Secure Email records are created

Only record IDs with a valid email are included in the create step

Compare "Records with Emails" vs. missing; fix the invalid set and resend

Attachment upload fails in bulk

The bulk LWC enforces a smaller ~3 MB client-side limit (MAX_FILE_SIZE); format restrictions also apply

Use smaller files; check the accepted formats setting

Emails created but not delivered yet

Outbound records are Created / flagged Process via Batch, waiting on BatchSendSecureEmail

Confirm the batch scheduler and NextBatchProcessSecureEmail / SecureEmailBatch_LastNDays

Delivery Status

Status Not Updating

Symptom

Likely Cause

Solution

Status stays "Created" / Delivery Status blank after send

Status batch not running; email not in the batch WHERE clause; missing Source_TrackingId__c

  • Run/schedule BatchPullSecureEmailStatus, or use the Invocable refresh

  • Check BatchStatus_WhereClause and the GetBatchStatusQuery label

  • Confirm tracking Id populated after a successful API send

  • Set NextScheduleBatchStatusTime (> 0) if auto-reschedule is expected

New outbound email never gets an early status refresh

NextRefreshSecureEmailStatus not set, or the trigger path isn't firing

Set NextRefreshSecureEmailStatus (in seconds); confirm the Secure Email trigger/handler runs on insert

No parent status update while Paubox still reports "processing"

The code intentionally skips the parent update while delivery status is processing

Wait for the next status batch run; confirm the batch is scheduled

Batch status job runs once and never reschedules

NextScheduleBatchStatusTime is 0 or blank

Set it to a value > 0 (install default is typically 60)

Status batch fails to start, or returns 0 records unexpectedly

Invalid BatchStatus_WhereClause, or label query issues

Fix the SOQL fragment in BatchStatus_WhereClause; test the query manually; adjust BatchStatus_BatchSize if callout limits are hit

Status Accuracy Issues

Symptom

Likely Cause

Solution

Email stuck or marked Failed after a transient error (e.g. 503/504)

Transient error codes incorrectly treated as permanent, or not on the skip list

Ensure SecureEmail_InvalidStatusErrorCode includes codes to skip (default 503, 504) — transient codes shouldn't force Failed

Paubox shows Delivered, but Salesforce shows Failed

Delivery status text matches a value in Possible_Error_Status; or multi-recipient partial/fail logic

Review Possible_Error_Status values for exact match/casing; check the Email Recipient rows; trim CSV entries if stray spaces break matching

"Partially Delivered" vs Failed vs Delivered is unclear on multi-recipient sends

Overall status aggregates individual recipient deliveries

Inspect Email_Recipient__c delivery statuses: all delivered → Delivered; a mix → Partially Delivered; none → Failed

Manual Refresh & Environment

Symptom

Likely Cause

Solution

Manual "Refresh status" (Invocable/Flow) has no effect

Blank tracking Id or From address; callout error; status payload empty

Verify Source_TrackingId__c and From; check debug logs for WSSecureEmail.getSecureEmailStatus; confirm Paubox credentials for that From domain

Status/send failures only in certain orgs

ApiConnection = Test in a production org (or an invalid value defaulting to Test)

In production orgs, set ApiConnection = Production with matching PauboxCredentials__c; sandboxes always use Test

Replying to Secure Email

Access, opt-out, From/Reply-To, and JSON errors for Reply are covered in Common Issues above. The items below are specific to reply threading and routing.

Symptom

Likely Cause

Solution

To address is empty or wrong after Reply / Reply All

  • Original email has blank From / Recipients

  • SecureEmail_RoutingAddressToSkip removed the only remaining addresses

  • Reply All expected CC but the original had none

  • Open the original Secure_EmailMessage__c and verify From, Recipients, CC

  • Review SecureEmail_RoutingAddressToSkip and remove unintended addresses

  • Manually add To/CC before sending

Reply All still includes routing / no-reply addresses

Address not listed in SecureEmail_RoutingAddressToSkip, or a typo/case/spacing mismatch

Add exact addresses to SecureEmail_RoutingAddressToSkip, comma-separated (matching is case-insensitive after trim, but avoid typos)

Expected CC recipients missing on Reply All

Original email's CCRecipients__c was blank; BCC is never included in Reply All by design

Add CC manually if needed; verify the original message actually had CC values

Reply quick action won't open / spinner runs forever

  • Missing access to Secure Email record fields

  • getSecureEmailRecord or config call failed

  • Parent Record Id blank on the email

  • Confirm Parent_Record_Id__c, From, Recipients, Subject, and HtmlBody are populated and readable

  • Check browser console / Apex debug logs for the failing call

  • Ensure the user has CRUD/FLS on Secure Email Message fields

Quick Admin Checklist

Check

Where

License + feature entitlement

User + Features Entitlement

Email Configuration metadata

Email_Configuration__mdt for the object

Valid mapping JSON

Record_Type_Mapping__c

Routing skip list

SecureEmail_RoutingAddressToSkip

Allowed domains

SecureEmail_AllowedDomains

API credentials & environment

ApiConnection + PauboxCredentials__c

Send batch scheduling

BatchSendSecureEmail, NextBatchProcessSecureEmail, SecureEmailBatch_LastNDays

Status batch scheduling

BatchPullSecureEmailStatus, NextScheduleBatchStatusTime, BatchStatus_WhereClause, BatchStatus_BatchSize

Status accuracy settings

SecureEmail_InvalidStatusErrorCode, Possible_Error_Status

Tracking ID populated

Source_TrackingId__c

Original email data (for Reply)

From / To / CC / Parent Id / Body