---
schema_version: "1"
id: 4928a7c826bf027488555c871ebd4311e3b0ce59f0d188cac241156d4bd7f40d
title: CleanRule
collection: legacydeveloper
version: current
locale: en-us
portal_url: https://docs.salesforce.com/legacydeveloper/current/en-us/api_tooling/tooling_api_objects_cleanrule.md
canonical_url: https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/tooling_api_objects_cleanrule.htm
source_site: developer.salesforce.com
content_type: documentation
content_hash: f80c0a866a2d52b304c5435523fbe40664d278644ad3b7330af07bbc777b4070
description: Represents a data integration rule that controls how a data service adds and updates data for existing records in an org.
---
# CleanRule

Represents a data integration rule that controls how a data service adds and updates data for existing records in an org.

This object is available in API version 38.0 and later.

## Supported SOAP Calls

create(), delete(), describeSObjects(), query(), retrieve(), update(), upsert()

## Supported REST HTTP Methods

GET

## Fields

| Field | Details |
| --- | --- |
| CleanDataServiceId | 
Type

reference

Properties

Create, Filter, Group, Sort

Description

A foreign key reference to the CleanDataService that processes this CleanRule.



 |
| DataAssessmentStatus | 

Type

picklist

Properties

Create, Defaulted on create, Filter, Group, Nillable

Description

The status of the data assessment. The following are valid values:

- Hidden (default)
- Not Started
- In Progress
- Pending Aggregation
- Aggregation Complete
- Failed Aggregation
- Aborted

This field is read only.



 |
| Description | 

Type

textarea

Properties

Create, Filter, Group, Nillable, Sort, Update

Description

User-friendly text that describes the data integration rule.



 |
| DeveloperName | 

Type

string

Properties

Create, Filter, Group, , Sort, Update

Description

This name can contain only underscores and alphanumeric characters, and must be unique in your org. It must begin with a letter, not include spaces, not end with an underscore, and not contain two consecutive underscores. This unique name prevents conflicts with rules from other packages that have the same MasterLabel.

![Note](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/images/icon_note.png)

#### Note

Only users with View DeveloperName OR View Setup and Configuration permission can view, group, sort, and filter this field.















 |
| IsBulkEnabled | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

If this flag is set to true, the system automatically applies the rule to existing records whenever the rule is updated or saved. If the flag is set to false, the system doesn’t automatically apply the rule to existing records. You can always apply the rule manually.



 |
| IsSilentSaveEnabled | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

If false, updates don’t modify LastModifiedDate and LastModifiedById when it applies this rule; otherwise, updates insert the current date and the current user.



 |
| Language | 

Type

picklist

Properties

Create, Defaulted on create, Filter, Group, Nillable, Restricted picklist, Sort, Update

Description

The language of the data integration rule. The following values are permitted:

- Chinese (Simplified): zh\_CN
- Chinese (Traditional): zh\_TW
- Danish: da
- Dutch: nl\_NL
- English: en\_US
- Finnish: fi
- French: fr
- German: de
- Italian: it
- Japanese: ja
- Korean: ko
- Norwegian: no
- Portuguese (Brazil): pt\_BR
- Russian: ru
- Spanish: es
- Spanish (Mexico): es\_MX Spanish (Mexico) defaults to Spanish for customer-defined translations.
- Swedish: sv
- Thai: th The Salesforce user interface is fully translated to Thai, but Help is in English.





 |
| MatchConfidence | 

Type

double

Properties

Create, Filter, Nillable, Sort, Update

Description

Indicates how closely a Lightning Data record matches a Salesforce record. The higher the minimum value is set, the more precise the matches. This field is used in packages that support match scores for third-party data. Valid values include an integer determined by the data service provider. If the value is null, the default value from the data service provider is used. Available in API version 45.0 and later.



 |
| MasterLabel | 

Type

string

Properties

Create, Filter, Group, Sort, Update

Description

Master label for this object. This display value is the internal label that is not translated.



 |
| MatchRule | 

Type

string

Properties

Create, Filter, Group, Nillable, Sort

Description

An internal label for the matching rule in the data service that’s associated with this CleanRule.



 |
| ShouldBypassTriggers | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

If true, indicates that the system does not apply triggers when it applies this rule; otherwise, the system applies the triggers.



 |
| ShouldBypassWorkflow | 

Type

boolean

Properties

Create, Defaulted on create, Filter, Group, Sort, Update

Description

If true, the system bypasses workflow rules when it applies the data integration rule; otherwise, the system applies workflow rules.



 |
| SobjectType | 

Type

picklist

Properties

Create, Filter, Group, Restricted picklist, Sort

Description

The standard or custom object in your org that’s acted on by this CleanRule. The possible values are:

- Account
- Address
- Contact
- CustomEntityDefinition
- Lead
- ResourceAbsence
- ServiceAppointment
- ServiceTerritory
- ServiceTerritoryMember
- WorkOrder
- WorkOrderLineItem

In addition, custom objects with data integration rules are possible.

![Note](https://developer.salesforce.com/docs/atlas.en-us.api_tooling.meta/api_tooling/images/icon_note.png)

#### Note

The standard objects are installed with default data integration rules, but only the default rules for account, contact, and lead can be modified.















 |
| SourceSobjectType | 

Type

picklist

Properties

Create, Filter, Group, Nillable, Restricted picklist, Sort

Description

A data service object associated with this CleanRule. The set of picklist values includes all the object types defined in the data service. However, if you specify a non-existent object, the API call returns an error. If you enable the Salesforce data services, the following values appear.

CustomEntityDefinition

Information retrieved from an external source in the form of an external object to enrich an account, contact, or lead. We map the external object fields to the account, contact, and lead lookup and details.

DataCloudAddress

Geolocation data service.

DatacloudDandBCompany

Data.com data service. This service is only available in the Professional, Enterprise, Unlimited, and Performance Editions, and only with a Premium Clean license. Your administrator must enable this data service by enabling the data integration rules for account and lead.

If you install Marketplace packages that contain data services, their object names also appear in the set of picklist values.



 |
| Status | 

Type

picklist

Properties

Create, Defaulted on create, Filter, Group, Nillable, Restricted picklist, Sort, Update

Description

Status of the data integration rule. Valid values are Active and Inactive.



 |