Requests and Responses
When your Data.com Prospector or Data.com Clean contract expires, Data.com features, objects, and fields will be removed from your org. To support customers’ needs around compliance and to remain a leader in trust and privacy, Salesforce removed all contact data from the Data.com service on February 1, 2021.
For more information, see Data.com Prospector and Clean Retirement.
There are two basic parts to a request.
- Entities
Entities contain attributes, and each attribute contains elements. The elements are the fields that are requested.
- Fields
Fields contain the values that are returned with the request.
The following table shows the difference between XML and JSON request formats.
XML Request Example for DatacloudContact | JSON Request Example for DatacloudContact |
---|---|
<fields>City</fields> <fields>CompanyId</fields> <fields>CompanyName</fields> <fields>ContactId</fields> <fields>Country</fields> <fields>Email</fields> <fields>FirstName</fields> <fields>IsInactive</fields> <fields>LastName</fields> <fields>Phone</fields> <fields>State</fields> <fields>Street</fields> <fields>Title</fields> <fields>Zip</fields> </DatacloudMatchInput> | ], "fields": [ "City" "CompanyId", "CompanyName", "ContactId", "Country", "Email", "FirstName", "IsInactive", "LastName", "Phone", "State", "Street", "Title", "Zip" ] } |
The Data.com Match API resources return a response body formatted in JSON or XML. Response bodies contain information about the fields that were included in the request.
There are three parts to a response.
- errorCode
The error code is typically a numeric value that indicates a specific type of error. Additional error information is contained in the “errorMessage” element.
- entities
Entities contain attributes, and each attribute contains elements. The elements contain information from Data.com about the requested fields.
- matchDiffs
The “matchDiffs” elements contain the names of fields in which the information in the request is different from the information in the matched Data.com record.
Access the Match API resources by using the URL for your company’s instance combined with the version and the URL for the resource.
For example if your instance is:
https://{yourInstance}.salesforce.com/
And the version information is:
/services/data/v55.0
And the resource is:
/match/DatacloudMatchEngine/DatacloudContact/
The Data.com Match API has two resources.
- DatacloudContact
- DatacloudCompany
Put together, the full URL for DatacloudContact is:
https://{yourInstance}.salesforce.com/services/data/v55.0/match/DatacloudMatchEngine/DatacloudContact/
Put together, the full URL for DatacloudCompany is:
https://{yourInstance}.salesforce.com/services/data/v55.0/match/DatacloudMatchEngine/DatacloudCompany/
For Match API GET requests, a list of fields is returned for companies or contacts. The batch size limit is also returned. There is no Data.com data returned in the GET request.
Use the URL and the POST command to send a match request.
https://{yourInstance}.salesforce.com/services/data/v55.0/match/DatacloudMatchEngine/DatacloudContact/
The attributes for Data.com are the field names in records.
The attributes or field names included in the match request are compared against records in the Data.com database.
The fields elements are a list of fields you want returned in a request.
Use any field listed under the “Properties” section.
Represents the contact fields you can match against Data.com records.
The more fields you include in the request element, the more accurate the match is.
Field | Type | Description | Since API Version |
---|---|---|---|
City | String | The name of the city where the company is located. | 30.0 |
CompanyId | Long integer (64–bit integer) | The unique numerical identifier for the company at which the contact works. | 30.0 |
CompanyName | String | The name of the company at which the contact works. | 30.0 |
ContactId | String | The unique numerical identifier for a contact. | 30.0 |
Country | String | A string that represents the standard abbreviation for the country where the contact works. | 30.0 |
Department | String | The name of the department to which the contact is assigned. You can’t query on this field. It is a return value only. Queries on this field are ignored and there is no “matchDiffs” returned. | 30.0 |
Email | String | An email address for this contact. | 30.0 |
FirstName | String | The first name of a contact. | 30.0 |
IsInactive | String | A true or false response. True means that the record is no longer active. False means that the contact is still valid and active. | 30.0 |
LastName | String | The last name of a contact. | 30.0 |
Level | String | A human resource label designating a person’s level in the company. You can’t query on this field. It is a return value only. Queries on this field are ignored and there is no “matchDiffs” returned. | 30.0 |
Phone | String | A numerical string that contains the direct-dial phone number for the contact. | 30.0 |
SocialHandles | String | A multi-field attribute associated with a contact. You can’t query on this field. It is a response only field. Type: DatacloudSocialHandle (a child attribute associated with a ContactId.). URL: http://example1.com/social.media.{userid} (a normalized URL and {userid} for the website of the social media provider.) Provider Name: EXAMPLE1 (the name of social media provider). SocialId: social.media.{userid} (the normalized {userid} for the user on this social media). | 30.0 |
State | String | The two-letter standard abbreviation for a state. | 30.0 |
Street | String | A postal address for the company where this contact works. | 30.0 |
Title | String | The job title for a contact. | 30.0 |
Zip | String | A numeric postal code designation for the address. | 30.0 |
- Include a list of fields in your request.
- Include more fields in the request to narrow or restrict the match.
- To improve match results, include as many of the key fields as possible in your request
- Include fewer fields in the request to broaden the match.
- For the best chance at matching your Salesforce records with Data.com data, be sure your records are accurate and complete.
- A successful response body returns the same fields included in the request.
Use the URL and the POST command to send a match request.
https://{yourInstance}.salesforce.com/services/data/v55.0/match/DatacloudMatchEngine/DatacloudCompany/
The attributes for Data.com are the names of fields in records. The attributes or field names included in the match request are compared against records in the Data.com database. The fields elements are a list of fields returned in a successful request. Use any field listed under the “Properties” section.
A list of the fields available for contact requests and responses.
Properties : Include fields in the request entities to indicate which company fields to match against the Data.com database.
Field | Type | Description | Since Version |
---|---|---|---|
AnnualRevenue | String | The amount of money that the company makes in one year. | 30.0 |
City | String | The name of the city where the company is located. | 30.0 |
CompanyId | Long integer (64–bit integer) | The unique numerical identifier for the company. | 30.0 |
Country | String | A string that represents the standard abbreviation for the country where the company is located. | 30.0 |
Description | Sting | A brief summary about the company. | 30.0 |
DunsNumber | String | A randomly generated nine-digit number that’s assigned by Dun & Bradstreet (D&B) to identify unique business establishments. | 30.0 |
Fax | String | The phone number that’s used for sending and receiving faxes. | 30.0 |
Industry | String | A description for the area of focus in which the company does business. | 30.0 |
IsInactive | String | A true or false response. True means that the record is no longer active. False indicates that the contact is still valid and active. | 30.0 |
NaicsCode | String | North American Industry Classification System (NAICS) codes were created to provide details about a business’s service orientation. The code descriptions are focused on what a business does. | 30.0 |
NaicsDesc | String | A description of the NAICS classification. | 30.0 |
Name | String | The company’s name. | 30.0 |
NumberOfEmployees | String | The number of employees who are working for the company. | 30.0 |
Ownership | String | The type of ownership of the company: Public , Private , Government , or Other . | 30.0 |
Phone | String | A numerical string that contains a corporate phone number for the company. | 30.0 |
Sic | Integer | Standard Industrial Codes (SIC) is a numbering convention that indicates what type of service a business provides. | 30.0 |
SicDesc | String | A description of the SIC classification. | 30.0 |
Site | String | The type of location of the company, such as “Headquarters.” | 30.0 |
State | String | The two-letter standard abbreviation for a state. | 30.0 |
Street | String | A postal address for the company. | 30.0 |
TickerSymbol | String | The symbol that uniquely identifies companies that are traded on public stock exchanges. | 30.0 |
TradeStyle | String | A legal name under which a company conducts business. | 30.0 |
Website | String | The standard URL for the company’s home page. | 30.0 |
YearStarted | Sting | The year when the company was founded. | 30.0 |
Zip | String | A numeric postal code designation for the address | 30.0 |