LiveChatSensitiveDataRule

Represents a rule for masking or deleting data of a specified pattern. Written as a regular expression (regex).

Use this object to mask or delete data of specified patterns, such as credit card, social security, phone and account numbers, or even profanity. This type extends the Metadata metadata type and inherits its fullName field.

File Suffix and Directory Location

LiveChatSensitiveDataRule components have the suffix .liveChatSensitiveDataRule and are stored in the liveChatSensitiveDataRule folder.

Version

LiveChatSensitiveDataRule components are available in API version 35.0 and later.

Fields

Field Name Field Type Description
actionType SensitiveDataActionType (enumeration of type string) Required. The action to take on the text when the sensitive data rule is triggered. Possbile values are:
  • Remove
  • Replace
description string The description of the sensitive data rule—for example, “Block social security numbers.”
enforceOn int Required. Determines the roles on which the rule is enforced. The value is determined using bitwise OR operation. There are seven possible values:
  1. Rule enforced on Agent
  2. Rule enforced on Visitor
  3. Rule enforced on Agent and Visitor
  4. Rule enforced on Supervisor
  5. Rule enforced on Agent and Supervisor
  6. Rule enforced on Visitor and Supervisor
  7. Rule enforced on Agent, Visitor, and Supervisor
isEnabled boolean Required. Specifies whether a sensitive data rule is active (true) or not (false). Default value (if none is provided) is false.
pattern string Required. The pattern of text blocked by the rule. Written as a JavaScript regular expression (regex).
replacement string The string of characters that replaces the blocked text (if ActionType Replace is selected).

Declarative Metadata Sample Definition

The following is an example of a LiveChatSensitiveDataRule component.

1<LiveChatSensitiveDataRule xmlns="http://soap.sforce.com/2006/04/metadata">
2    <actionType>REPLACE</actionType>
3    <enforceOn>7</enforceOn> 
4    <isEnabled>true</isEnabled> 
5    <pattern>[aeiou]</pattern> 
6    <replacement>œ</replacement>
7</LiveChatSensitiveDataRule>

The following is an example package.xml that references the previous definition.

1<Package xmlns="http://soap.sforce.com/2006/04/metadata">
2    <!-- To be used from support.liveagent.testsuite.unifiedouting.testDeployButtonMDAPIWithExistingQueue -->
3    <apiAccessLevel>Unrestricted</apiAccessLevel>
4
5    <types>        
6        <members>Change_For_all</members>    
7        <name>LiveChatSensitiveDataRule</name>
8    </types>
9
10    <version>35.0</version>
11</Package>

Wildcard Support in the Manifest File

This metadata type supports the wildcard character * (asterisk) in the package.xml manifest file. For information about using the manifest file, see Deploying and Retrieving Metadata with the Zip File.