Skip to main content

Inbound (Email-to-Case)

Portal configuration

Before you proceed to the Portal part, you need to create a deterministic tokenization function in Salesforce org. Once it is completed, you can proceed to the Portal part.

Setting up the Inbound (Email-to-Case) feature in Salesforce

Activation of the Email-to-Case functionality in Salesforce is a multi-step process. Please follow the instructions for each step.

Adding information about the case owner

  1. From Setup, select Feature Settings, then select Service, finally, click Support Settings.

  2. Click Edit.

  3. Add information about the case owner. Created cases will be assigned to this user by default if no assignment rules are found.

  4. Click Save.

Activating the Email-to-Case feature

  1. From Setup, select Feature Settings, then select Service, finally, click Email-to-Case.

  2. Check the Enable On-Demand Service box to activate the Email-to-Case feature.

  3. Click Save.

Creating routing addresses

  1. From Setup, select Feature Settings, then select Service, finally, click Email-to-Case.

  2. On the Email-to-Case page, locate the Routing Addresses section.

  3. In the Routing Addresses section, click New.

  4. Configure the Email-to-Case routing address as follows:

    1. Routing Name - enter the name for the routing email address.

    2. Email Address - enter the inbound email address for this Email-to-Case routing address. Emails from this address will be routed to the allocated Salesforce email address for converting emails into cases.

    3. Save Email Headers - check the box to save email headers.

    4. Case Origin - select E-Mail.

  5. Click Save.

  6. On the Email-to-Case Routing Address page, locate the email address and click Verify.

    Once this step is complete, your email will be verified.

Creating protected fields for the Case object

  1. On the menu, select Settings.

  2. Select the Case object.

  3. Configure the protected fields as follows:

FieldHash functionSearchable
DescriptionuniqueHash(tick)
SubjectuniqueHash(tick)
Email Address (SuppliedEmail)formula

{"fn":"dtkSha256","transforms":["trim", "toLowerCase"],"format":".{64}@redacted.com"}

This formula applies the lower case to the input email address value, then applies the deterministic tokenization function to the email address, and finally trims the token to 64 characters and appends @redacted.com to it.
(tick)

Creating protected fields for the Email Message object

  1. On the menu, select Settings.

  2. Select the email message object.

  3. Add the following fields:

FieldHash functionSearchable
Html Body (HtmlBody)uniqueHash(tick)
SubjectuniqueHash(tick)
From Address (FromAddress)formula

{"fn":"dtkSha256","transforms":["trim", "toLowerCase"],"format":".{64}@redacted.com"}

This formula applies the lower case to the input email address value, then applies the deterministic tokenization function to the email address, and finally trims the token to 64 characters and appends @redacted.com to it.
(tick)
From NameuniqueHash(tick)
To Address (ToAddress)uniqueHash(tick)
Text Body (TextBody)uniqueHash(tick)

Creating protected fields for the Contact object

  1. On the menu, select Settings.

  2. Select the Contact object.

  3. Add the Email field, specifying the following parameters:

FieldHash functionSearchable
Emailformula

{"fn":"dtkSha256","transforms":["trim", "toLowerCase"],"format":".{64}@redacted.com"}

This formula applies the lower case to the input email address value, then applies the deterministic tokenization function to the email address, and finally trims the token to 64 characters and appends @redacted.com to it.
(tick)

note

For the details on linking contacts with a case, please check Salesforce documentation.

Configuring the InCountry Chatter web component

Configure the InCountry Chatter web component.

note

For the details, please check our documentation.

Deploying code

To link the case record and email messages with the InCountry platform, you need to deploy the following code to your Salesforce organization: https://github.com/incountry/salesforce-recipes/tree/main/email-to-case.