Data.com APIs in Action ? Bringing Data to Life in Salesforce

Post on 31-Oct-2014

635 views 1 download

description

Join us to learn more about the Data.com APIs as we dive deep into a couple of use cases. We'll show you how you can automate pulling in the right Contacts for your Accounts, filling in white spaces. We'll also explore strategies for automating cleaning your data using triggers and Apex code.

Transcript of Data.com APIs in Action ? Bringing Data to Life in Salesforce

Data.com APIs In Action

Alan Dray, Lead Sales Engineer Data.com@AlanDrayDDCSE

Ali Sadat, Sr. Director Prod Management – Data.com API & Data Platform@alisadat

#APInation

Pilot

Safe HarborSafe harbor statement under the Private Securities Litigation Reform Act of 1995: This presentation may contain forward-looking statements that involve risks, uncertainties, and assumptions. If any such uncertainties materialize or if any of the assumptions proves incorrect, the results of salesforce.com, inc. could differ materially from the results expressed or implied by the forward-looking statements we make. All statements other than statements of historical fact could be deemed forward-looking, including any projections of product or service availability, subscriber growth, earnings, revenues, or other financial items and any statements regarding strategies or plans of management for future operations, statements of belief, any statements concerning new, planned, or upgraded services or technology developments and customer contracts or use of our services. The risks and uncertainties referred to above include – but are not limited to – risks associated with developing and delivering new functionality for our service, new products and services, our new business model, our past operating losses, possible fluctuations in our operating results and rate of growth, interruptions or delays in our Web hosting, breach of our security measures, the outcome of any litigation, risks associated with completed and any possible mergers and acquisitions, the immature market in which we operate, our relatively limited operating history, our ability to expand, retain, and motivate our employees and manage our growth, new releases of our service and successful customer deployment, our limited history reselling non-salesforce.com products, and utilization and selling to larger enterprise customers. Further information on potential factors that could affect the financial results of salesforce.com, inc. is included in our annual report on Form 10-K for the most recent fiscal year and in our quarterly report on Form 10-Q for the most recent fiscal quarter. These documents and others containing important disclosures are available on the SEC Filings section of the Investor Information section of our Web site. Any unreleased services or features referenced in this or other presentations, press releases or public statements are not currently available and may not be delivered on time or at all. Customers who purchase our services should make the purchase decisions based upon features that are currently available. Salesforce.com, inc. assumes no obligation and does not intend to update these forward-looking statements.

{ "agenda": [ { "topic": "Data.com Overview", "who": "Ali" }, { "topic": "API Overview", "who": "Ali" }, { "topic": ”Data Use Cases", "who": ”Alan" }, { "topic": ”Demo", "who": ”Alan" }, { "topic": "Q&A", "who": ”Alan and Ali" } ]}

Ali SadatSr. Dir. Product Management – Data.com API & Data Platform@alisadat

Built Together: The Best Data, The #1 Sales App

Clean

Leading account and contact data right inside Sales Cloud

SellMarket

World’s Premier Sources of Accounts & Contacts Directly in Sales Cloud

▪ Company Information From D&B▪ Millions of Crowd-Sourced

Contacts▪ Clean your Sales Cloud With One

Click▪ Instant Access and Real-time

Updates In the Cloud

API Overview

Data.com API Goals and Motivation

Allow customers to create rich custom Data.com experiences that can be integrated into their

processes.

Possible Use Cases Enabled by Data.com APIUse Cases Search/Purchase API Match API

Fill-in White Space ✓

Selective Automated Cleaning ✓

On-Demand Automated Cleaning ✓

Search in DDC before Create ✓

Custom Build a List ✓

Web2Lead (Clean) ✓

Lookup by DUNS Future ✓

Build Visual Account Hierarchy Future

Mobile Experience ✓ ✓

Data.com APIs generally act and feel like other Force.com APIs

How does Data.com data show up in your org?

Accounts Contacts Leads

DatacloudCompany

DatacloudContact

Force.com OrgDatacloud (External) sObjects

Datacloud sObjects and APIs (Pilot)

Force Technology DDC API DatacloudCompany DatacloudContact

sObject ✔ ✔

REST

Search ✔ ✔

Purchase* ✔ ✔

Retrieve ✔ ✔

Match ✔ ✔

APEX

Search ✔ ✔

Purchase ✔ ✔

Retrieve ✔ ✔

Match Future Future

* Purchase is a process that involves inserting into multiple objects

Searching Contacts / Companies

Search: SOQL

SELECT

ContactId, FirstName, LastName, Title, Email, CompanyName, Street, City, CompanyId, Country, State, Zip, Phone, IsInactive, IsOwned

FROM DatacloudContact

WHERE CompanyName Like 'salesforce.com'

AND City = 'San Francisco'

AND FirstName Like 'Ali'

Order by LastName

Contact Search: ResultContactId FirstName LastName Title Email CompanyName Street City State Zip Phone IsInactive IsOwned

55280504Alisa Distaso Principal Sales Engineer

adistaso@salesforce.com

Salesforce.com, Inc. 1 Market San

Francisco CA 94105-1596

+1.703.463.3168

FALSE TRUE

34436669A****** G****** ****** ******@salesforce.com

Salesforce.com, Inc. ****** San

Francisco CA 9****** +*.***.***.**** FALSE FALSE

61751292Alison Guzenski Campus Recruiter Non-technical

aguzenski@salesforce.com

Salesforce.com, Inc. 1 Market San

Francisco CA 94105-1596

+1.415.547.8637

FALSE TRUE

9041336A****** H****** ****** ******@salesforce.com

Salesforce.com, Inc. ****** San

Francisco CA 9****** +*.***.***.**** FALSE FALSE

50285112A****** K****** ****** ******@jigsaw.com Salesforce.com, Inc. ****** San

Francisco CA 9****** +*.***.***.**** FALSE FALSE

31487887A****** L****** ****** ******@salesforce.com

Salesforce.com, Inc. ****** San

Francisco CA 9****** +*.***.***.**** FALSE FALSE

53554176A****** N****** ****** ******@salesforce.com

Salesforce.com, Inc. ****** San

Francisco CA 9****** +*.***.***.**** FALSE FALSE

45003056Ali Sadat

Senior Director Product Management Data com

asadat@salesforce.com

Salesforce.com, Inc.

1 Market Ste 300

San Francisco CA 94105-

5102

+1.415.778.3357

FALSE TRUE

Masked fields if Not Owned (purchased).

Search: Masked Fields in Result• Some fields masked if IsOwned = false• Purchase via API or Data.com tab to see all fields

Company Search

SELECT AnnualRevenue,City,Industry,Name,NumberOfEmployees,Street,Website,YearStarted

FROM DatacloudCompany

WHERE Country = 'United States'

AND Name Like 'Salesforce'

ORDER BY City

LIMIT 50

Just Like Contact Search

Purchasing Records

Search•• SOQL - Filters

Get Transaction Id•• Create

DatacloudPurchaseUsage

Buy Records•• Create

DatacloudOwnedEntity

Get Details•• SOQL – record Id

Purchasing Data is a Multi-Step Process

Purchase Object Relationships

DatacloudOwnedEntity

• DatacloudEntityType• DataDotComKey• PurchaseUsageId

DatacloudContact

• ContactId

DatacloudCompany

• CompanyId

DatacloudPurchaseUsage

• Id• DatacloudEntityType• Description

EntityType=0

EntityType=1

Note: Create only. Purchase is FINAL.

Match returns Single High Confidence result.

Match ≠ Search

Match APIStyle: RESTURLs:

▪ /services/data/v29.0/match/DatacloudMatchEngine/DatacloudCompany

▪ /services/data/v29.0/match/DatacloudMatchEngine/DatacloudContact

2. GET List of available fields and Max Batch Size3. POST Match request

Match Response: Get List of Fields

{

"fieldSets":

"[IsInactive, Country, FirstName, Zip, LastName, IsOwned,

Phone, CompanyId, Email, ContactId, Street, CompanyName,

City, Title, State]",

"maxBatchSize": "30"

}

Contact Match: RequestPost …/services/data/v29.

0/match/DatacloudMatchEngine/DatacloudContact

Body:{ "entities":[ { "attributes":{ "type":"DatacloudContact" }, "FirstName":"Ali", "LastName":"Sadat", "Email":"asadat@salesforce.com", "CompanyName":"Sale" } ], "fields":[ "FirstName", "LastName", "Email", "Phone", "CompanyName", "CompanyId", "Title", "Street", "City", "State", "Country", "Zip" ]}

Input to Match

List of Fields to include in Result

Contact Match: Result[ { "errorMessage": null, "errorCode": 0, "matchRecords": [ { "entity": { "attributes": { "type": "DatacloudContact" }, "Phone": "+1.415.778.3357", "Street": "1 Market Ste 300", "Email": "asadat@salesforce.com", "State": "CA", "CompanyId": "159110", "FirstName": "Ali", "Zip": "94105-5102", "CompanyName": "Salesforce.com, Inc.", "Country": "United States", "LastName": "Sadat", "City": "San Francisco", "Title": "Senior Director Product Management Data com" }, "matchDiffs": [ "CompanyName" ] } ] }]

Match ResultsSame order as

Request

Fields that were different from

Request

Company MatchWorks just like Contact Match.GET…/services/data/v29.

0/match/DatacloudMatchEngine/DatacloudCompany

{ "fieldSets" : "[Site, Description, Sic, Country, YearStarted, CompanyId, NaicsCode, DunsNumber, Street, TickerSymbol,

NumberOfEmployees, Phone, Ownership, IsInactive, SicDesc, Zip,

Name, Website, NaicsDesc, State, City, TradeStyle, AnnualRevenue,

Fax, IsOwned, Industry]",

"maxBatchSize" : "30" }

Data.com API Availability by ProductProspector Clean

API Object Corporate Premium Corporate Premium

Search1Contact ✔ ✔

Company ✔ ✔

Purchase1Contact ✔ ✔

Company ✔ ✔

Retrieve2 DnB Company ✔ ✔

Match1Contact ✔ ✔

Company ✔ ✔

1. Available at Pilot 2.Available at GA

Daily API Requests Quota LimitAPI sObject Org Level Daily Limit*

SearchContact

Max Calls = 1000/user * # Lic users; Max 100 results / pageCompany

PurchaseContact

No LimitCompany

Retrieve DnB Company No Limit

MatchContact Max Calls = 1000/user * # Lic users; Max 30 Match

Requests / callCompany

Alan DrayLead Sales Engineer, Data.com@AlanDrayDDCSE

Demo

Search & Match API (PILOT)Search API (Prospector)

▪ DataCloudContact

▪ DataCloudCompany

Match API (Clean)

▪ DataCloudContact

▪ DataCloudCompany

Purchase

▪ PurchaseUsage

▪ OwnedEntity

Use Cases Enabled by Data.com API

Use Cases Search API Match API

Search in DDC before Create ✓

Search to Clean ✓

Contacts for Account ✓

Web2Lead Fill Before Create ✓

Firmagraphics for Unmatched Leads ✓

Note: Purchase API used in all cases when a selection is made to add to Salesforce.

Data.com API – Considerations/Limitations

Feature Consideration/Limitation Recommendation

APEX Purchase▪ Known issue – Have to retrieve purchased

records after transaction has been fully committed.

Use REST purchase. Completion of REST transaction commits.

Search via SOQL ▪ QueryMore() not supported. Need to use LIMIT and OFFSET

External API Calls▪ @future annotation required when executing

from triggers.Use AFTER triggers when performing look-ups for auto-fill.

Filter by Email▪ API does not support '=' so can't search for

email = 'asadat@blah.com' Use "Like 'asadat@blah.com'"

Filter by Email

▪ When using 'Like' to do wildcard search, you can only search on a string before the '@'. You cannot search for example '%@salesforce.com'

Use "CompanyName Like 'salesforce.com'" Only issue is that if there are other email domains in the same company, those will be included too.

Resources Used

•Technical Libraries, Tools, Discussion Boards, Cookbooks, Blogs, …And much more•http://developer.force.com/

•For those that choose REST over XML/SOAP•A tool to help generate strongly typed Apex code for parsing a JSON structure given an example of the JSON.•http://json2apex.herokuapp.com/ - Built on Heroku

Online JSON Viewer•Format and View JSON requests and response.•There are many this one is simple•http://jsonviewer.stack.hu/

REST Explorer by Salesforce Labs•Discover and Explore the Force.com REST API.•https://appexchange.salesforce.com/listingDetail?listingId=a0N30000003IjwLEAS

Ali Sadat

Sr. Dir PM Data.com,@alisadat

Alan Dray

Lead Sales Engineer Data.com,@AlanDrayDDCSE

We want to hear from YOU!

Please take a moment to complete our session survey

Surveys can be found in the “My Agenda” portion of the Dreamforce app