INTEGRATION-ARCHITECTURE-DESIGNER practice question 11 of 25

When user clicks Check Preferences as part of a Lightning flow in Salesforce, preferences from an externally hosted RESTful service are to be checked in real-time. The RESTful service has OpenAPI 2.0 JSON definitions, responding in data types of Boolean and string values. Which integration pattern and mechanism should be selected to meet the conditions?

Full set: 106 questions

Domain Design an Integration Solution

Answer options
A: Fire and Forget: Process-driven platform events publishes events on Salesforce Event Bus.
B: Remote Call-In: Salesforce REST API with REST Composite Resources.
C: Request-Reply: Enhanced External Services invokes a REST API. Correct answer
D: Data Virtualization: Salesforce Connect map data external REST data in external objects.
Correct Answer:
C. Request-Reply: Enhanced External Services invokes a REST API.
Explanation

The scenario describes a user-initiated action within a Lightning Flow that requires an immediate, real-time response from an external system. This synchronous interaction, where Salesforce sends a request and waits for a response, is a classic example of the Request-Reply integration pattern. The specified mechanism, Enhanced External Services, is the most suitable Salesforce feature. It is designed to declaratively consume external REST APIs that have an OpenAPI 2.0 specification. External Services automatically generates invocable actions that can be directly called from a Lightning Flow, perfectly matching the requirement to invoke the external service and use its response within the flow's logic.

Why Incorrect

A. Fire and Forget: Process-driven platform events publishes events on Salesforce Event Bus. This is an asynchronous pattern. The user requires a real-time response, which this pattern does not provide.
B. Remote Call-In: Salesforce REST API with REST Composite Resources. This pattern describes an external system calling into Salesforce. The scenario requires Salesforce to call out to an external service.
D. Data Virtualization: Salesforce Connect map data external REST data in external objects. This pattern is for representing external data as Salesforce external objects, not for invoking a specific, action-oriented endpoint like "Check Preferences."

References

1. Salesforce Architects - Integration Patterns and Practices: The "Request and Reply" section describes this pattern: "In this pattern, a remote system is invoked by Salesforce code, which then waits for a response from that system... This is a synchronous call." This aligns directly with the user waiting for a real-time check. (Found in the Salesforce Architect Journey: Integration Architecture documentation).

2. Salesforce Help - External Services Overview: "External Services connects your Salesforce org to an external API... It uses your API specification to create Apex classes and corresponding invocable actions that you can use in Salesforce tools like Flow Builder... External Services supports OpenAPI 2.0 JSON schema format." This confirms External Services is the correct mechanism for an OpenAPI 2.0 defined service invoked from a Flow.

3. Salesforce Developer Documentation - Flow Core Action for External Services: "When you register an external service, its operations are available in Flow Builder as invocable actions." This directly links the mechanism (External Services) to the context (Lightning Flow).

Scroll to Top