In Geovonic Connect, data sources provide connectivity to third-party business systems. The Salesforce data source allows you to fetch real-time data from your SalesForce instance to display in your ArcGIS web mapping applications using the Salesforce Object Query Language (SOQL).
Using SOQL you can configure queries that will bring back customer data based on features on your ArcGIS web map.
Below is an example query that will retrieve information about the latest sales for a customer to show alongside the map.
SELECT Amount, LastModifiedDate, Name
FROM Opportunity
WHERE Opportunity.Account.Name = '{{SF_ACCOUNT}}'
AND StageName = 'Closed Won'
ORDER BY LastModifiedDate DESC
In this example we have a map layer with an attribute called SF_ACCOUNT which is used to join the map features to the Salesforce opportunity records.
Data Source Configuration
The Salesforce data source configuration requires three fields: –
- Username – the username of the account that Geovonic Connect will use to login to your Salesforce instance.
- Password – the password for the account.
- Security token – the security tokens are created on the “My Personal Information” page in Salesforce and are used for machine-to-machine authentication.
It is important when configuring any integration service to follow the Principle of Least Privilege. Any credentials used for the data source should only be able to access the minimum amount of information to meet the needs of your Geovonic Connect application. For example, do not provide the admin credentials for your Salesforce if Geovonic Connect only needs to access a single object type. Best practice is to create a new user with the least required privileges.
Layer Link Configuration
The Salesforce layer link configuration requires two fields: –
- SOQL statement – a query statement using the SOQL syntax. Use the [+] button to include feature attributes as part of your query statement.
- Max record count – the maximum number of Salesforce records to be returned for each map feature.
An SOQL reference guide is available on the Salesforce website.
Salesforce also provides a Workbench tool that can be used to build and test your SOQL queries before adding them to Geovonic Connect.