flow http callout and transform element
This content dives into using Salesforce Flow's HTTP callout and transform elements for integration with external APIs like Petfinder and trade.gov. It clarifies when to use HTTP callouts versus external services, handling response parsing, data typing, and authentication setup. Practical tips are shared for displaying API data in Flow screens, leveraging LWCs for complex UI needs, and creating/updating Salesforce records asynchronously. The author also compares transform element usage against loops, highlighting current limitations and workarounds in Flow. Overall, it's a hands-on exploration to help Salesforce professionals build integrations using declarative and code-extended patterns.
- Use external services when an open API spec is available for more robust integration.
- HTTP callouts require manual data type setting and careful response management.
- Leverage Flow loops with text templates or LWCs to display collection data from callouts.
- Transform element and loops offer similar capabilities for creating/updating records in Flow.
- Use named credentials for easier and secure API authentication in callouts and services.
in preparation for a user group session with peter churchill re extending flow with http callouts and lwc for a dc user group meeting, i tested http callout and external services against the petfinder api, developer.trade.gov consolidated screening list api, and the boldsign api. my notes and observations re http callout and transform element are below. peter figured out a bunch of cool things One of the first decisions to make is whether to use http callout or use external service. My conclusion is that if the endpoint provides an open api spec, it is easier to create an external service and select the methods you need in the flow, for the following reasons: when you create a http callout action, you paste in the response and then salesforce parses it. in this process, you have to go through and manually set the types (string, date, boolean, etc) for any properties that the system is not able to interpret (typically because they are blank/null in the response).