Just before a configurator appears on-screen, the Loaded Rule performs any tasks that must be performed before the user sees anything. It is in this context that extensive information about the Salesforce CPQ Quote Header and other objects is available. The information is stored in a map of key/value pairs, so it is easy to retrieve the specific data you want. Learn more about maps.
Best practice is to write this information into a multiline text field on a hidden admin page of the configurator, so later rules have access to the information and you can confirm you have the information you need. Using a multiline control allows you to stretch the text field as large as necessary to see the data inside.
Reading data from the Salesforce CPQ Quote Header
To read fields from the Salesforce CPQ Quote Header in Snap, use the "sfdcQuote" parameter in a configurator Loaded rule. For example, if you want to read the custom Salesforce field "BillingPostalCode__c" field on the Salesforce Quote Header, you can add a Snap rule such as this to your loaded rule:
Then use map functions to get the specific information you need.
Reading data from the Salesforce CPQ Quote Line, Product, and other objects related to the header
Sometimes a configurator needs information from Salesforce related to the Quote Header. This could be information stored on multiple different related Salesforce Objects, such as Quote Lines, Products, etc. Use this screenshot to see how to access this information found in the "sfdcQuote" and "sfdcQuoteLine" parameters. These parameters can be deep trees of maps within maps: writing them to a log statement or a multiline text field can be the best way to begin exploring them. See an example of drilling down into complex maps.
See Also
Learn more about the Snap blocks to read from and write to Salesforce.
See examples of Snap blocks to customize the integration with Salesforce CRM. Many of these techniques also apply to Salesforce CPQ.
Get familiar with all the map functions.