Health Cloud gives care teams a full view of the patient, but only if the data from EHRs, payers and government programs actually reaches it. Our team has built FHIR R4, HL7, C-CDA and EDI 837 integrations on Salesforce for US healthcare providers. These are the lessons we would share with anyone starting out.
1. Validate against the profile, not just the base spec
A FHIR resource can be valid R4 and still be rejected. Programs such as the CMS ACCESS Model publish implementation guides with profiles, required elements, value sets and slicing rules. Most HTTP 400 errors we have fixed came from closed slices and value-set mismatches, not malformed JSON.
Tip: run every payload through the official validator with the program’s implementation guide loaded, and keep sample payloads as test fixtures.
2. Keep terminology mapping out of your code
Salesforce picklists rarely match standard value sets one-to-one. Store the mapping in Custom Metadata Types, so a change in the specification is a configuration update, not a deployment.
3. Design for specification changes
Programs change their questionnaires and mandatory fields during the year. Build payload builders that are driven by metadata where you can, and version them, so you can tell which specification each submission followed.
4. Real-time where it matters, batch where it is cheaper
Diagnostic results should reach care coordinators as soon as they are published, so webhooks and REST callouts are worth the effort. Large reference data sets are better synced in scheduled Batch Apex jobs with retry logic. We run batch jobs syncing over 250,000 records a day this way.
5. Treat PHI as radioactive in the UI
HIPAA-aligned access is more than profiles and sharing rules. Watch for PHI leaking into places nobody audits: browser history, page titles, error messages and debug logs. We have built components specifically to keep patient names out of browser history.
6. Billing rules belong before the claim, not after the denial
When generating EDI 837P/837I claims, validate program rules (for example tier codes and new-patient windows) and provider data such as taxonomy codes before the claim leaves Salesforce. A rejected claim costs far more to fix than a validation rule.
7. Log everything, alert on what matters
Every outbound and inbound message should be logged with its status, so support teams can answer “did it go?” without a developer. Alert on failure rates, not single failures.
Building on Health Cloud? See our healthcare work or book a call with our healthcare team.