top of page

Archived Email Message object

When the Email Scrubber Archive Records batch process runs, qualifying EmailMessage records are moved into the Archive Email Message object. These archived records retain the original EmailMessage fields and can be surfaced either by adding the archive object to the Case page layout or by using the Email Scrubber LWC, which displays both live and archived emails in a unified view.

image.png

Object Name

EmailScrubber__Redundant_EmailMessage_History__c

Email to Archive Mapping

Email Message to Archived Email Mapping

Email Scrubber ships with all standard EmailMessage fields pre‑mapped to their corresponding fields on the Archive Email Message object. This mapping is fully configurable. You can add custom fields or adjust existing mappings by creating entries in the Redundant EmailMessage History Field Map Custom Metadata Type (CMDT).

image.png

How field mapping works

Email Scrubber uses the Redundant EmailMessage History Field Map CMDT to determine which fields from the live EmailMessage record should be copied into the archive object during processing.

Out of the box, the package includes mappings for:

  • All standard EmailMessage fields

  • Commonly used metadata fields

  • Required internal processing fields

This ensures the archive object is immediately usable without configuration.

Customizing the mapping

​Admins can extend or modify the mapping by adding new CMDT rows. Each row defines:

  • Source Field API Name (on EmailMessage)

  • Target Field API Name (on the archive object)

  • Data type alignment (must match or be compatible)

  • Active flag (to enable/disable the mapping)

This allows you to:

  • Add custom EmailMessage fields to the archive

  • Exclude fields you don’t want copied

  • Map fields to differently named archive fields

  • Support org‑specific compliance or retention requirements

Which:

  • Keeps the archive object lightweight but complete

  • Ensures custom org‑specific email metadata is preserved

  • Allows you to evolve the archive schema without code changes

  • Maintains a predictable, auditable mapping layer

Additional Archive Email Message Object Fields

Email Scrubber Specific Fields

In addition to the fields populated through the CMDT‑driven field mapping, the Archived Email Message object also includes a set of Email Scrubber–specific fields. These fields store processing metadata, archive context, and diagnostic information used by the Scrubber engine to ensure accurate retention, traceability, and compliance.

​Net Savings

The net data storage (in bytes) saved by archiving this record. This value is the difference between the original message size and the cost to store the archived email message record.

Net Savings (GB)

The Net Savings calculation above, but expressed in GB instead of bytes.

Original Created By Id

The Created By Id from the original Email Message records. 

Original Created Date

The Created Date from the original Email Message record.

Original Message Size

The data storage cost (in bytes) from the original Email Message record.

Original Message Size (GB)

The Original Message Size value above, but expressed in GB instead of bytes.

Dynamic Record Page

Dynamic Archive Record Page 

By default, Email Scrubber displays archived emails on a standard record page. For a better experience, assign and activate the included dynamic Lightning page instead. The dynamic pages leverages a lightning component that renders the HTML body correctly. It provides a better user experience.

image.png
bottom of page