# Salesforce

Storylane directly integrates with Saleforce (SFDC). With the integration, you can:

* Create new leads or contacts
* Update demo analytics for leads or contacts as custom objects

{% hint style="warning" %}

### **Capturing Leads**

There are few ways in which you can identify new leads. You can refer the article on [Lead Tracking](https://docs.storylane.io/hubs-docs/integrations/integrations/broken-reference) to learn more
{% endhint %}

{% hint style="info" %}
You can also access Storylane demos directly within Salesforce. [Read more.](https://docs.storylane.io/hubs-docs/integrations/integrations/salesforce/storylane-app-for-salesforce)
{% endhint %}

### How to Integrate

See below Storylane example on how to integrate with SFDC

{% @storylane/embed subdomain="renee" linkValue="w0hydldhat9s" url="<https://renee.storylane.io/demo/w0hydldhat9s>" %}

{% hint style="danger" %}
Verify the user connecting Salesforce <> Storylane has the required object permissions ↓&#x20;
{% endhint %}

{% @storylane/embed subdomain="app" linkValue="b6p4gssaom8d" url="<https://app.storylane.io/share/b6p4gssaom8d>" %}

### Storylane Custom Object

Upon successful integration, Storylane creates a custom object in Salesforce named `StorylaneDemoData__c` (label: Storylane Demo Data). This object stores data on viewed demos, providing valuable insights into engagement and interactions. The below-listed fields will appear on the contact:

`Demo Name` - viewed demo name

* type: Text
* *custom object’s Name field*

`Session Id` - External Session Id (used to reference Storylane record)

* type: Text (36)
* name: SessionId\_\_c

`Demo Viewed At` - when demo was viewed

* type: DateTime
* name: DemoLastViewedAt\_\_c

`Demo Time (secs)` - time spent viewing last demo (seconds)

* type: Number
* name: TimeSpent\_\_c

`Demo Complete (%)` - demo completion percentage

* type: Percent
* name: Completion\_\_c

`Demo Link` - link to the demo

* type: Url
* name: DemoLink\_\_c

`Demo Checklist Completed` - whether the checklist was completed

* type: Checkbox
* name: ChecklistCompleted\_\_c

`Demo CTA Clicked` - the URL of clicked CTA

* type: Url
* name: CtaClicked\_\_c

`Lead` - related Salesforce Lead

* type: Lookup
* name: LeadId\_\_c
* relationship\_name: StorylaneDemosData
* relationship\_label: Storylane Demos Data

`Contact` - related Salesforce Contact

* type: Lookup
* name: ContactId\_\_c
* relationship\_name: StorylaneDemosData
* relationship\_label: Storylane Demos Data
