Synchronizing Salesforce and Spotlight.ai data

Spotlight.ai supports uni- or bidirectional synchronization between Salesforce Opportunity fields and Spotlight.ai variables which are the storage behind questions and calculations.

Synchronization lifecycle


When a user navigates in Salesforce to an Opportunity Lightning Record Page that contains Spotlight.ai components and the user has the Spotlight.ai Connector User Permission Set and component visibility rules are true, all Opportunity fields in the Default synchronization section below are sent to Spotlight.ai. If the opportunity does not exist in Spotlight.ai, it will be created.


Additionally, when Salesforce Change Data Capture for the Opportunity object is turned on, any changes to Opportunity records will trigger synchronization with Spotlight.ai. These Platform Events can be triggered by end users changing opportunities or modifications made by System Administrators using tools that update multiple records like Dataloader.io.


As users interact with Spotlight.ai components on the Opportunity Lightning Record Page, if a question tied to a Salesforce Opportunity field is modified (or the Stage itself), Spotlight.ai will use the Salesforce REST API to write the change to the Opportunity using the security context of the logged in user. Each update takes 5-10 seconds.


Note: if the Salesforce Opportunity Lightning Record Page includes a synchronized field, it will only show the update from Spotlight.ai if the page is reloaded. For that reason, we recommend that any synchronized fields only be displayed in the Spotlight.ai components; otherwise, users may become confused about whether the update was performed.

Default synchronization


By default, these standard Opportunity fields are synchronized with Spotlight.ai. All are read-only except StageName. If your organization uses custom fields in place of any of these, Spotlight.ai Support can map the field.

  • Id
  • Name
  • Type
  • StageName
  • ForecastCategory
  • Amount
  • CloseDate
  • CreatedDate
  • IsClosed
  • OwnerId
  • Owner.FirstName
  • Owner.LastName
  • Owner.Email
  • Owner.Name
  • AccountId
  • Account.Name

Spotlight.ai also unidirectionally writes to the following fields that were added to your Opportunity object when our Salesforce Managed Package was installed:

  • Spotlight Score (spai__Spotlight_Score__c)
  • Discovery Score (spai__Discovery_Score__c)
  • Value Score (spai__Value_Score__c)
  • MEDDICC Status URL (spai__MEDDICC_Status_URL__c) - a formula field called MEDDICC Status (spai__MEDDICC_Status__c) converts this to an image for use in Salesforce Reports
  • At Risk (spai__At_Risk__c)
  • MEDDICC Score (spai__MEDDICC_Score__c) - deprecated

Adding fields and variables to synchronize


Additional Opportunity fields may be synchronized with Spotlight.ai variables. There are several points to consider:

  1. Decide what you actually need to synchronize. Usually, what is selected for synchronization to/from Salesforce is a subset of the questions in Spotlight. Typically, this is driven by reporting Salesforce reporting needs.
  2. Each Spotlight.ai question has an underlying variable name and data type. This is analogous to Salesforce Field API names and data types. For successful synchronization, both the Salesforce Opportunity field and Spotlight.ai variable need to have compatible data types. For example, a Text Area (512) in Salesforce should synchronize with a Text (512) variable in Spotlight.ai.
  3. If the Salesforce field to be synchronized is a picklist (single select or multiselect), the Salesforce list will become the source of truth for the Spotlight picklist. Edits to the list should be made in Salesforce and not Spotlight.ai. Changes in Salesforce to picklists or global value sets will be propagated down to Spotlight.ai.
  4. Whenever users navigate to an Opportunity in Salesforce and any of Spotlight.ai's components are visible on the page (subject to whether the user has the required Spotlight.ai Connector User Permission Set and any Visibility Rules that are in place), synchronization is triggered to ensure Spotlight.ai has a current view of the relevant data in Salesforce for that Opportunity.
  5. If an organization wants to add synchronization later down the line for a new field in Salesforce, it is critical that Spotlight.ai provide a CSV file to be upserted before synchronization is turned on. This is because synchronization reads the data from Salesforce first then writes to Spotlight.ai then reads Spotlight.ai and writes back to Salesforce. If new fields are added to Salesforce, these will initially be empty. If synchronization is turned on for the new fields, the blank values would be read into Spotlight.ai causing a loss of data. This is why synchronization can only be turned on administratively by Spotlight.ai Support.
  6. Synchronization must be tested in a Salesforce Sandbox organization before it can be enabled in production.
  7. To request synchronization, please open a ticket at support@spotlight.ai. In it, specify a list of Salesforce Field API names, Salesforce field data types, Spotlight.ai variables, and whether the synchronization is read, write or read/write.
Did this answer your question? Thanks for the feedback There was a problem submitting your feedback. Please try again later.

Still need help? Contact Us Contact Us