Provider Bulk Sync
Setup
Pre-requisites
- MuleSoft Direct setup is required. For more information, see the MuleSoft Direct setup guide.
- Connect to the external MDM system and fetch the credentials for establishing a connection.
- To integrate this application with Salesforce Life Sciences or Health Cloud, you must first set up a Local External Client App within your Salesforce instance. When configuring the external client app, ensure you select the Run as Integration User option. The credentials from this external app are required during the MuleSoft Direct setup process.
- To integrate the application with Life Sciences Cloud or Health Cloud, set up a Local External Client App in your Salesforce org. When you configure the external client app, select Run as Integration User. You’ll need the credentials from this external app during the MuleSoft Direct setup.
- Make sure the Integration User connected to the external client app has read and write access to all mapped entities and fields in Life Sciences Cloud or Health Cloud.
- For Life Sciences Cloud:
- Create a custom permission set that uses the Life Sciences Commercial license and grants access to all required entities and fields.
- Create a second custom permission set that uses the Salesforce API Integration license, and enable the following System Permissions:
- Modify All Data
- Customize Application
- Assign both custom permission sets and the Life Sciences Medical permission set to the integration user.
- Enable Field-Level Security (FLS) for the integration user profile for all mapped fields.
- If you use the out-of-the-box field mappings, make sure FLS is enabled for the following fields:
- Account
- Phone
- Fax
- PersonBirthDate
- PersonTitle
- PersonHomePhone
- PersonMobilePhone
- ContactPointAddress
- IsActive
- HealthcareProvider
- SourceSystemModifiedDate
- ProfessionalTitle
- IsPrivacyLawEnabled
- OperatingCountryCode
- IsActive
- BusinessLicence
- ContactPointAddressId
- ContactPointBestContactTime
- SourceSystemIdentifier
- DayOfWeek
- IsActive
- ProviderAffiliation
- SourceSystemIdentifier
- IsActive
- HealthcareProviderSpecialty
- Rank
- Account
- For Life Sciences Cloud:
- Ensure that the IntegrationJobRun.Status picklist values has these values added:
- New
- InProgress
- Completed
- CompletedWithError
- Failure
- AbortInitiated
- Aborted
- Make sure the PrimaryProviderRestriction Salesforce org preference is enabled in the setup page.
- Make sure State and Country/Territory Picklists are enabled.
- Create the Batch Management jobs and Salesforce flows for HCP address processing in your Salesforce org.
Setup
- Log in to Salesforce and navigate to the Setup page.
- Search for the MuleSoft Direct page.
- Select the Provider Bulk Sync API application and click Enable.
- Enter the application display name, target business group, and environment for deployment, then click Next.
- Select the Provider Bulk Sync tab and enter these details to configure the application properties:
| Key name | Sample value | Description |
|---|---|---|
| Salesforce Domain URL | test-instance.salesforce.com | Salesforce domain URL |
| Salesforce Consumer Key | - | Client ID to use for generating a Salesforce access token |
| Salesforce Consumer Secret | - | Client Secret to use for generating a Salesforce access token |
- To add any optional configuration parameters, click Add Additional Parameters and enter the required details.
- Select the Onekey System API tab and enter these details to configure the application properties:
| Key name | Sample value | Description |
|---|---|---|
| Onekey Host | okws.ok.imshealth.com | Onekey Host name |
| Onekey Username | 123 | Username for Onekey System |
| Onekey Password | 123 | Password for Onekey System |
| Onekey Connector Identifier | 4812 | Onekey Connector ID |
| Salesforce Business Account Record Id | 012SM000000tnBNYAY | Salesforce record type Id for Workplace |
| Salesforce Person Account Record Id | 012SM000000tnCzYAI | Salesforce record type Id for Individual |
- Click Proceed to deploy the application.
Post Deployment
- Trigger the MuleSoft endpoints as described in the API documentation.
- The main app requires a minimum of 0.2 vCores and an additional 0.2 vCore for the System API.
- The base path for the main app is provider-sync/v1. Example URL to initiate sync : https://{{processapi-host-name}}/provider-sync/v1/sync
- Run the Codes Job before you start Provider Bulk Sync to load required dynamic picklist values.
- The OneKey System API retrieves codes based on the configured country list. To enable this, configure the OneKey-supported countries using their two-character country codes in the runtime propertyonekey.download.codesCountryList.
Customizations
- Download the application code from the Mulesoft Direct screen to make enhancements.
- To modify the field mapping or country-specific enhancements, refer to the Onekey System API documentation to make the appropriate changes.
- The out-of-the-box mapping doesn't contain segmentation. To include segmentation mapping, create custom entities and fields and include the respective mapping in the System API mapping templates.
Limitations
- Ensure Provider Bulk Sync and Onekey System API use a minimum of 0.2 vcore when deployed to Anypoint Platform.
- An initial sync load of about 4 million records and downloading these many records may reach the Salesforce API call governor limits. Check the API call governance limits for initial data load and raise the limit if necessary.
- The deliveryId must be sent as input while initiating a delta sync. If deliveryId isn't received from Salesforce, then the next deliveryId at Onekey is considered.
- When pick-list conversion for codes coming from OneKey aren't defined in the Mule application, the application upserts OneKey Value as it is in the field. For a restricted pick-list, if upsert fails, the record is skipped and the job continues processing subsequent records. Errors are logged in MuleSoft Logs and the LifeScienceErrorLog entity.
- An abort job ends the running job and doesn’t rollback the successful data transfer.
- This application uses Object Store V2 and Anypoint MQ for managing status and processing data. Any limitations on Object Store V2 and Anypoint MQ are applicable to the application.
- Relations are processed after all HCP and HCO records are successfully created in Life Sciences or Health Cloud. If any of the related records are missing or failed to insert, then corresponding relations are skipped.
- When you use the out-of-the-box mapping, the Codes Job supports only the following Salesforce fields. To include additional dynamic enum fields, update the field mapping in the Codes mapping.
- HealthcareProvider.ProfessionalTitle
- ProviderAffiliation.Role
- The Codes Job uses the Salesforce Metadata API to load picklist values. The API has a limit of 1,000 values (active and inactive combined). To exceed this limit, manually add the values in Object Manager using the Fields & Relationships UI.