How to
Get Salesforce record
The Get record action allows you to bring in any data from SFDC to personalise customer experiences within a Pendula flow.
The Get record node supports the majority of standard, special and custom objects associated with the Connected Salesforce organisation.
Configuring the node
Select primary record
You can bring any record data into a Pendula flow by fetching the record by creating a query in this step.
The query builder supports merge fields and exact values. Enter a merge field from the trigger node (or any other node/integration previously used within the flow) associated with the selected object.
You can use the query builder to get records from Salesforce for the following common use cases:
- Get record by ID: using the ‘Contact ID’ from the triggering object (e.g. Opportunity or Case) to bring in all the contact details for a recipient into the flow.
- Get record by recipient ID (e.g. mobile or email address): you can use the ‘Get record’ node after the inbound message trigger to enrich the flow with information from your CRM to triage and handle inbound message enquiries. You can also bring in data from Salesforce if you are using a recipient ID as an identifier (e.g. email address) to make the flow more personalised and perform more actions in the customer journey.
Use case: get records by ID
How to add and find IDs for ID fields
For specific record IDs: Access the required record ID in your web browser. The URL displayed in the browser address bar contains both the Salesforce instance and the Record ID.
Salesforce Classic example
URL: http://na1.salesforce.com/5003000000D8cuI
Record ID: 5003000000D8cuI
Lightning Experience example:
URL: https://na1.lightning.force.com/lightning/r/Case/5003000000D8cuIQAA/view?0.source=alohaHeader
Record ID: 5003000000D8cuIQAA
How to find merge field ID
You can search for and find the correct merge field by clicking the green data explorer button on the field itself. If you want to make sure of the node your merge field is coming from, you can find it manually using the steps below.
Fields such as ID in SFDC will display as ID in the Object Manager, but will show in the Data Explorer view (merge field tab) in Pendula "AccountID".
From the trigger node (or a previous Get node) you can find the ID of the related record by using the data explorer under the ‘merge field’ tab. Navigate to This node > record > ContactID (or another lookup ID if required) and clicking ‘copy’. Copy this merge field into the Get record node.
Pendula does not validate the format or data for the referenced value in the query. If the format is incorrect, the experience will continue down the failed path.
Select related record(s)
You may select up to 5 related records from the primary record selected in the previous step.
You can use the fields and data from these records in subsequent nodes throughout the flow. The merge fields will follow the syntax {{nodeId.related#.fieldname}}
, eg. {{ comPendulaSfdcGetRecordV1_1.related2.CreatedById }}
You can add this data via the merge fields tab in subsequent nodes, or using the merge field button in supported fields.
It's important to note that the Get record node will progress through the flow only if ALL the records specified are retrieved. If one or more records fail to be retrieved, the experience will progress down the Not found outcome path (if configured) or end at that node. See below for more details on the outcomes for this node, and this article on configuring node outcomes for experiences.
Depending on your use case, you may want to:
- Allow the experience to fail if a record is missing by not configuring an outcome path;
- Configure an outcome path with a different message (without personalised data) or a fallback journey;
- Configure more than one Get record node in a sequence if you are more certain of some existing records than others.
Using Salesforce formulas
You can use SFDC Date Literals and Date Formulas in your query. Read more about using these formulas here.
Using the is null
operator
The Get Salesforce records trigger supports the use of the is null
operator. The value must be set to true
or false
, and is case-sensitive. This operator will only work on nullable fields in Salesforce.
Using the like
operator
You can use the like operator with supported formulas in your query. The like
operator matches single characters and patterns found anywhere in a string—beginning, ending, or somewhere in-between.
Use case | Formula |
Match any single character in the string. For example, to filter on a list of countries, a pattern of |
Underscore ( |
Match any pattern in the string. Starting a pattern with a percent sign returns all words that end with the specified characters. The percent sign indicates that any number of characters can precede the specified ones. Ending a pattern with a percent sign returns all the words that begin with the specified characters. Any number of characters can follow the specified ones. To match a pattern anywhere in a string, the pattern must start and end with a percent sign. For example, to filter on a list of countries, a pattern of |
Percent sign ( |
Include a literal percent sign or underscore in a pattern. |
Escape with a backwards slash ( |
Additional wildcard characters and regular expressions aren’t supported.
For picklist and boolean fields (apart from is null
), the value is not case-sensitive.
Formats returned by the Get record node
Date |
Returns in ISO date: 2024-06-01 Format in Salesforce: 1/6/2024 |
Time | Returns in epoch time: 1679338791000 |
Currency | Returns the value with no formatting "35000000" |
Outcome paths
Success path: the experience will continue down this path if all records are successfully retrieved.
Failed: the experience receives an unexpected failure from Salesforce. If this outcome path is switched OFF, the experience will end and be marked as ‘failed’ in History. If this path is switched ON the experience will continue down that path to the next configured node.
Not found: the experience fails to retrieve some or any of the specified records from Salesforce. If this outcome path is switched OFF, the experience will end and be marked as ‘failed’ in History. If this path is switched ON the experience will continue down that path to the next configured node.
Current known limitations & workarounds
Pendula is regularly releasing updates and fixes for limitations where possible and appropriate. We will continue to update the list below as more capability becomes available.
Limitation | Workaround (if applicable) |
Field validation: the update node currently does not support visualising system values associated with any fields (for example, picklist values). This means you must enter exactly the correct values when entering the desired update value otherwise the experience will fail. |
For picklist and boolean fields (apart from The format of the fields used in configuring criteria will need to adhere to the SFDC API formats: |
Attachments, files and rich media: We do not support adding attachments or images/videos to a record at this time. | |
Polymorphic fields: Polymorphic fields, e.g. Owner (User, Group), are not currently supported and won't be available as a field from Salesforce. | |
Parent-to-child relationships: You can only move from a child record to a parent record to ensure no arrays are returned to the flow. | |
Operators: the following operators are supported on the Get record action:
The type of field does not filter operators. The incorrect operator with field type (e.g. less than on a string) may error the flow or cause expected results. |
Note that is null is a boolean operator and supports true and false values. These are case-sensitive. |