Back to Blog Archive

RESTful API connectivity with Salesforce cloud

Posted on: April 16, 2018
Author:
Kevin Jervis

Following the announcement of Salesforce’s acquisition of MuleSoft (pending deal closure), Salesforce were quick to announce that MuleSoft’s first class integration and connectivity capabilities will underpin a new Integration Cloud platform capability.

There is no doubt the Salesforce platform has revolutionised approaches to customer engagement experiences and the sales management lifecycle.  Yet, part of the reason for the acquisition stems from the recognition that, while “every digital transformation starts and ends with the customer” (Salesforce CEO Marc Benioff), not all customer data resides or is mastered on the Salesforce platform.  For customers to increase the value from their Salesforce adoption they often need to connect to information sources throughout their enterprise, across public and private clouds, as well as access legacy system data.

At Ricston we have witnessed first hand how adopters of Salesforce Sales, Service and Marketing Clouds perennially face challenges in how to source and leverage value-add data, which enhances and personalises the customer contact experience and provides increased opportunity generation, as well as up and cross sell opportunities.  The ability to source, integrate and act on external data, is a central tenet of building a mature and effective customer 360º view.

Two general approaches exist to making such data available in Salesforce:

  1. Data-synchronisation; extract, transform and load the data into custom or big objects (and periodically synchronise state change)
  2. On-demand request; make API requests for data against systems/service exposed using standardised data-sources

MuleSoft’s connectivity platform (Anypoint) is equally capable of helping organisations address integration needs through either approach. Traditionally, the former approach has been the more widely adopted; customers using MuleSoft’s Salesforce connector implemented integration processes to push data into Salesforce or poll and query to extract data on schedule. However two challenges inevitably arise with the first approach. The cost of storage to maintain the volumes of data in Salesforce can be prohibitive. Secondly, the complexity in the processing and transformation logic to consistently maintain the state of data in multiple places results in bloated integration applications, which the business is reluctant to evolve beyond version 1.0.

With the growth of public and private APIs, organisations are beginning to witness a critical mass of accessible data-sources. This means Salesforce acting as a direct consumer is a viable and attractive option.

Salesforce + MuleSoft Connectivity Diagram

For example, an airline that Ricston are currently working with rapidly discovered that the intention to synchronise passenger data in their Salesforce instance was untenable. The cost of duplicating historical volumes of data in Salesforce simply did not stack up.  Alternatively exposing an OData API that could provide a queryable view on top of their passenger reservation data, was far more effective and cost efficient. It also provided the consumer, Salesforce users, with a greater degree of autonomy and flexibility in how they utilise the data, yet the original source system retained its control and data mastership.

Using MuleSoft’s OData APIKit feature we were able to rapidly mock and connect them to Salesforce developer sandboxes.  This enabled end-users to demo the proposed user experience, while in parallel implementing the downstream connectivity to the on-premise passenger reservation data store.  Business changes were made in days and overall delivery within weeks.  The MuleSoft OData APIkit feature accelerates an organisations ability to expose data assets, whether on-premise or in the cloud, using Salesforce Lightning Connect.

Some of the key advantages of this approach include:

  • Rapidly connect data assets with new audiences that can monetise new opportunities or impact your customers experiences in meaningful ways.
  • By exposing data assets in this way Salesforce need not be the only beneficiary.  Other applications within your organisation may also wish to make use of the exposed data and are free to do so.
  • Data remains authored/mastered in the original system of record, reducing volumes of unnecessary data duplication.

Naturally this approach is not a silver bullet and should not be undertaken without some considerations.  The Salesforce documentation provides an extensive list of considerations for using external data via Salesforce Lightning Connect. While many are beyond the scope of this post, I shall call out the most pertinent based on our integration experience:

  • Salesforce subscriptions are limited to 10,000 OData based requests per hour as standard, although higher limits are available on request.
    • Consider all the use cases which could result in an external OData request when estimating usage.  Searches, list view and record details navigation as part of typical customer service agent workflow will all impact metrics. Do not forget to account for any reporting aspects.  
  • MuleSoft OData APIKit module currently supports the OData 2.0 protocol only.  
    • If you require an OData 4.0 implementation the OData APIkit module cannot be used.
  • MuleSoft OData APIKit does not support model and generation of navigation properties that address relationships between OData entries (i.e. identifying a product with a category via the URI).
    • Parent-child relationships between OData entries are defined in Salesforce itself, rather than the OData model so impact of this limitation is mitigated.
  • MuleSoft OData APIKit does not support model and generation of complex type definitions.  
    • Depending on the complexity of your OData Entity Data Model, complex types may need to be omitted or modelled alternatively, such as entries.

In summary, there is no one-size fits all approach; your specific requirements will dictate which approach is the most suitable.

Following the acquisition announcement I hope to see first class support between Salesforce and MuleSoft for RAML and OpenAPI v3.0 specifications in Lightning Flow for External Services, which currently supports Swagger 2.0, as well as continued enhancements to the OData support forged through Lightning Connect.

This vision allows businesses to more readily self-service their data consumption and business process needs through seamless connectivity to systems and low code user-interfaces, without the need for IT assistance.

Author:
Kevin Jervis

Comments

Contact Us

Ricston Ltd.
Triq G.F. Agius De Soldanis,
Birkirkara, BKR 4850,
Malta
MT: +356 2133 4457
UK: +44 (0)2071935107

Send our experts a message

Need Help?
Ask our Experts!