Skip to main content
System
Email

Definition

The email transformer can anonymize an existing email address or completely generate a new one. An email is made up of three parts:

<username>@<domain>.<top-level-domain>

By default, the transformer randomizes the username, domain and top-level domain while always preserving the email format by retaining the @ and . characters.

For example, the following input value: john@acme.com

Would produce the following ouput value: ytvub873@ksh0293.com

You can see we generated new privacy-safe values for the username and the domain. You can update this structure using the configurations below. Lastly, the email transformer takes in a string and returns a string.

Configurations

Depending on your validations, you may want to configure the output email. The email transformer has the following configurations:

NameDescriptionDefaultExample InputExample Output
PreserveDomainPreserve Domain carries over the input domain to the output email address. This includes the domain and top-level domain.falsejohn@gmail.comfjf2903@gmail.com
PreserveLengthPreserve Length will ensure that the output email address is the same length as the input email address. This includes the domain as well.falsejohn@gmail.comhw98@gmail.com

Examples

There are several ways you can mix-and-match configurations to get different potential email formats. Here are some possible combinations:

PreserveLengthPreserveDomainExample InputExample Output
falsetruejoe@gmail.comf98723uh@gmail.com
truefalsejoe@gmail.com9cd@ms0ej.com
truetruejoe@gmail.commDy@bdo3s.com
falsefalsejoe@gmail.comfweq23f@fheuiw78.edu