How to Integrate TrueContext with Salesforce: A Step-by-Step Guide
In the world of field services, data is only as good as the speed at which it moves. If your field technicians are filling out forms but your Salesforce records aren't updating until the next day, you're losing valuable time.
In this guide, we'll walk through how to create a seamless, start-to-finish integration between TrueContext and Salesforce. By the end of this post, you'll know how to pull Work Orders into your mobile forms and automatically push completed inspection data back into Salesforce.
Step 1: Establish the Connection
Before you can move data, you need to build a bridge. TrueContext makes this easy by leveraging your existing browser sessions.
-
In the TrueContext portal, navigate to the Connections tab.
-
Select Create Connection and choose Salesforce.
-
Give your connection a descriptive name (e.g., "Salesforce Demo Connection").
-
Assign it to your specific Form Space.
-
Click Connect. If you are already logged into Salesforce in another tab, TrueContext will automatically use those credentials to authenticate.
Step 2: Pulling Data from Salesforce (Data Sources)
To make life easier for your field team, you want them to select from a list of existing Work Orders rather than typing in ID numbers manually.
-
Go to Data Sources and select Create Data Source > Salesforce Query.
-
Link it to the connection you just created.
-
Write a simple SOQL query to pull the necessary fields. For example:
SELECT Id, WorkOrderNumber FROM WorkOrder
-
Click Create. TrueContext will now fetch those records and store them as a selectable list.
Step 3: Setting the Destination
Once the form is submitted, where does the data go? We need to tell TrueContext to find the matching record in Salesforce and update it.
-
Navigate to Destinations and create a new Salesforce Standard and Custom Object destination.
-
Map the Object: Set the Object Name to WorkOrder.
-
Configure the Update Query:
-
Set the logic to "Update if it exists."
-
Match the record using the ID field.
-
Use DREL (Data Reference Expression Language) to pull the Work Order ID directly from your form submission.
Step 4: Building the Form
Now, let's tie the Data Source and the Destination together inside the form builder.
-
Work Order Selection: Add a Dropdown question. Instead of manual options, set it to use your Salesforce Data Source. Set the "Display" to the WorkOrderNumber and the "Value" to the ID.
-
The Hidden ID: It's a best practice to push the Salesforce ID into a separate, collected field. While you might keep this visible during testing, you can hide it in production to keep the UI clean for your techs.
-
Final Link: Go to the Destinations tab within the form settings and attach your Salesforce destination. This ensures that every time a tech hits "Send," the generated PDF or data points are attached directly to that specific Work Order.
The Result: Real-Time Field Updates
Once deployed, the workflow is effortless:
-
The tech opens the TrueContext app and reconciles.
-
They select Work Order 80 from the list (the ID pulls automatically in the background).
-
They complete the inspection, take photos, and sign.
-
Upon clicking Send, the Salesforce record is instantly updated with the inspection notes, pass/fail statuses, and the signature.
Ready to automate your field data?
Integrating your mobile forms with your CRM shouldn't require a degree in computer science. With TrueContext and Salesforce, you can turn a paper-heavy process into a real-time data engine in under ten minutes.
#TechTalkImplementation #Salesforce #SalesforceFieldService
------------------------------
Ian Chamberlain
Solutions Architect
TrueContext
------------------------------