MuleSoft Accelerator for Financial Services
Prerequisites
This page provides guidance on configuring the various systems and products required to implement the use cases provided by this solution.
Salesforce Financial Services Cloud
This section describes how to configure an existing Salesforce Financial Services Cloud (FSC) instance to support the default MuleSoft Accelerator for Financial Services functionality. These instructions assume that the required FSC packages have been deployed to the target Salesforce instance and that the appropriate permissions have already been assigned.
Record types
The following record type must be created in the corresponding object.
Salesforce Object | Record Type |
---|---|
FinServ__FinancialAccount__c | Money Market Account |
FinServ__FinancialAccount__c | Blockchain Account |
FinServ__FinancialAccount__c | General Ledger Account |
FinServ__FinancialAccountTransaction__c | Financial Account Transfer Transaction |
To create the Money Market Account
record type in the Financial Account object, first create a page layout for it based on an existing account layout.
- Click the Salesforce Setup icon.
- Select
Object Manager
tab from the Setup home page. - Select the
FinServ__FinancialAccount__c
object. - Select
Page Layouts
from the left nav and click New. - Select an existing page layout (e.g., "Financial Account (Savings Account) Layout").
- Set the
Page Layout Name
field to "Financial Account (Money Market Account) Layout". - Click Save to create the new layout.
Now create the new record type:
- Select
Record Type
from the left nav and click New. - Select an existing record type (e.g., "Savings Account").
- Fill out the following fields as indicated.
Record Type Label
-> "Money Market Account".Record Type Name
-> "Money_Market".Description
-> "Represents a money market account".
- Enable the
Active
checkbox. - In the list of profiles, check the
Make available
option the profile assigned to the target API service account (at a minimum). - Click Next and select the option
Apply one layout to all profiles
. - Select the page layout "Financial Account (Money Market Account) Layout".
- Click Save.
The new record type should now be available in the Record Types
section. You can verify that the new record type is also available to the target user profile as follows:
- Click the Salesforce Setup icon.
- Navigate to
Users -> Profiles
. - Select the target profile.
- Navigate to
Object Settings -> Financial Accounts
and click the Edit link. - Verify that the new record type is listed under
Record Types and Page Layout Assignments
.
Repeat the above steps with the below options to create Financial Account Transfer Transaction
record type.
In Page Layouts
section, follow the below steps:
1. Select an existing page layout (e.g., "Financial Account Transaction Layout").
1. Set the Page Layout Name
field to "Financial Account Transfer Transaction Layout".
In Record Types
section, follow the below steps:
1. Select an existing record type (e.g., "Financial Account Transaction").
1. Fill out the following fields as indicated.
Record Type Label
-> "Financial Account Transfer Transaction".
Record Type Name
-> "Financial_Account_Transfer_Transaction".
* Description
-> "Defines a transaction that represents a generic transfer from one account to another".
The OOTB record type Financial Account Transaction supports the following transaction types: DebitTransaction
and CreditTranction
.
The Financial Account Transfer Transaction record type supports following transaction types: TransferTransaction
and PaymentTransaction
.
To enable the Household
record type in Account
object, follow the below steps:
- Click the Salesforce Setup icon.
- Navigate to
Users -> Profiles
. - Select the target profile for the service account user.
- Navigate to
Object Settings -> Accounts
and click the Edit link. - Under
Record Types and Page Layout Assignments
check theHousehold
record type. - Click
Save
.
Custom fields
The following fields must be created in the corresponding objects.
Salesforce Object | Field Name | Data Type | Length | Unique | ExternalId |
---|---|---|---|---|---|
Account | Ach_Transfer_Auth_Document_Id__c | String | 36 | N | N |
Account | Asset_Transfer_Auth_Document_Id__c | String | 36 | N | N |
Account | FinServ__Status__c | Picklist | - | N | N |
Account | Global_Customer_Id__c | Text | 36 | Y | Y |
Account | Global_BillingAddress_Id__c | Text | 36 | Y | Y |
Account | Global_MailingAddress_Id__c | Text | 36 | Y | Y |
Account | Global_ShippingAddress_Id__c | Text | 36 | Y | Y |
Account | Global_EmailAddress_Id__c | Text | 36 | Y | Y |
Account | Global_FaxNumber_Id__c | Text | 36 | Y | Y |
Account | Global_MobileNumber_Id__c | Text | 36 | Y | Y |
Account | Global_Party_Id__c | Text | 36 | Y | Y |
Account | Global_PhoneNumber_Id__c | Text | 36 | Y | Y |
Contact | Global_EmailAddress_Id__c | Text | 36 | Y | Y |
Contact | Global_Individual_Id__c | Text | 36 | Y | Y |
Contact | Global_PostalAddress_Id__c | Text | 36 | Y | Y |
Contact | Global_PhoneNumber_Id__c | Text | 36 | Y | Y |
FinServ__Card__c | Card_Type__c | Picklist | - | N | N |
FinServ__Card__c | Cardholder_Name__c | Text | 100 | N | N |
FinServ__Card__c | Credit_Card_Type__c | Picklist | - | N | N |
FinServ__Card__c | Global_Card_Id__c | Text | 36 | Y | Y |
FinServ__FinancialAccount__c | Global_Account_Id__c | Text | 36 | Y | Y |
FinServ__FinancialAccount__c | Initial_TransactionId\_c | Text | 36 | N | N |
FinServ__FinancialAccount__c | LastStatementDate__c | Date | - | N | N |
FinServ__FinancialAccount__c | LastTransactionAmount__c | Currency | (16,2) | N | N |
FinServ__FinancialAccount__c | LastPaymentDate__c | Date | - | N | N |
FinServ__FinancialAccount__c | LastPaymentAmount__c | Currency | (16,2) | N | N |
FinServ__FinancialAccount__c | LastTransactionType__c | Picklist | - | N | N |
FinServ__FinancialAccount__c | Last_Transaction_Id__c | Text | 36 | N | N |
FinServ__FinancialAccount__c | Monthly_Withdrawal_Limit__c | Number | (16,2) | N | N |
FinServ__FinancialAccount__c | Maximum_Monthly_Withdrawals__c | Number | 18 | N | N |
FinServ__FinancialAccountTransaction__c | Credit_Financial_Account__c | Lookup | - | - | - |
FinServ__FinancialAccountTransaction__c | Debit_Financial_Account__c | Lookup | - | - | - |
FinServ__FinancialAccountTransaction__c | Global_Transaction_Id__c | Text | 36 | Y | Y |
FinServ__FinancialAccountTransaction__c | Originator_Id__c | Text | 36 | Y | N |
Note:
- The Card_Type__c picklist values are DebitCard and CreditCard.
- The Credit_Card_Type__c picklist values are Amex, Discover, Mastercard, Visa, and Other.
- The LastTransactionType__c picklist values are CreditTransaction, DebitTransaction, TransferTransaction, and PaymentTransaction.
- The field FinServ__Status__c is added as part of the Financial Services Cloud package and must be added as a custom field if the package is not used in the Salesforce Org. The picklist values are Prospect, Closed, Deceased, Delinquent, Dormant, Inactive, Onboarding, and Active.
- The Debit_Financial_Account__c and Credit_Financial_Account__c fields looks up respective Financial Accounts.
To create each of these custom fields and enable visibility for them on page layouts:
- Click the Salesforce Setup icon.
- Select
Object Manager
tab from the Setup home page. - Find and select the target Salesforce object.
- Select the
Fields & Relationships
page. - Click the New button and create the field as specified above.
- Once the field has been created, click the
Set Field-Level Security
button. - Enable for desired profile, or tick the master checkbox next to
Visible
to enable visibility for all profiles.
Repeat these steps for each custom field in the above list.
Enable Financial Accounts in Sales
When the Financial Services Cloud feature is added to the Salesforce instance, the Commercial and Retail Banking apps are provided to work with financial accounts. If you want to enable the Financial Accounts tab on the Sales app, follow these steps:
- Navigate to the
Sales
app home page. - Click the pencil icon on the right corner of the navigation pane, which opens the
Edit Sales App Navigation Items
dialog box. - Click Add More Items.
- Navigate to
All
under theAvailable Items
menu. - Search for
Financial Accounts
and Select it. - Click
Add 1 Nav Item
and then click Save.
Enable transaction status
The default implementation of the solution requires the enablement of transaction statuses in the existing picklist in the target FSC instance. This can be done as follows:
- Click the Salesforce Setup icon.
- Select
Object Manager
tab from the Setup home page. - Find and select the
FinServ__FinancialAccountTransaction__c
Salesforce object. - Navigate to
Fields and Relationships
and select theFinServ__TransactionStatus__c
picklist field. - Add the new transaction status -
Cancelled
andInitial
. - Click Save.
Enable transaction types
The default implementation of the solution requires the enablement of transaction types in the existing picklist in the target FSC instance. This can be done as follows:
- Click the Salesforce Setup icon.
- Select
Object Manager
tab from the Setup home page. - Find and select the
FinServ__FinancialAccountTransaction__c
Salesforce object. - Navigate to
Fields and Relationships
and select theFinServ__TransactionType__c
picklist field. - Add the new transaction types -
Payment
andTransfer
. - Click Save.
Workflow Rules
To display a specific page layout based on the record type, a Workflow rule is created. To ensure the page layout changes based on the record type Financial Account Transfer Transaction
, follow the below steps:
- Click the Salesforce Setup icon.
- Navigate to
Process Automation -> Workflow Rules
. - Select
New Rule
. - Select
FinServ\_\_FinancialAccountTransaction\_\_c
from the Object dropdown. - Enter Rule Name as
Transfer Transaction Type
and description asDefines a transaction that represents a generic transfer from one account to another
. - Set
Evaluation Criteria
ascreated, and any time it
s edited to subsequently meet criteria`. - In the
Rule Criteria
section, selectcriteria are met
. - In the first row, select the field as
Financial Account Transaction: Transaction Type
, operator asequals
, and value asTransfer
. - In the second row, select the field as
Financial Account Transaction: Transaction Type
, operator asequals
, and value asPayment
. - Set filter logic
1 OR 2
. Click Save. - In
Workflow Actions
, underImmediate Actions
, selectNew Field Update
. - Set
Name
asTransfer Transaction Type
. - In
Field to Update
, selectRecord Type
. Click Next. - In
Specify New Field Value
, selectFinancial Account Transfer Transaction
from the record type dropdown. - Click Save.
Enable multiple currencies
The default implementation of the solution requires the enablement of multiple currency support in the target FSC instance. This can be done as follows:
- Click the Salesforce Setup icon.
- Navigate to
Company Settings -> Company Information
. - Click Edit and enable the
Activate Multiple Currencies
option. - Click Save.
If desired, click the Currency Setup button to add support for additional currency codes (e.g., EUR).
Create PushTopics
The following PushTopics must be created in order to capture updates from Salesforce. The apex scripts to create these PushTopics are located in the fins-salesforce-topic-listener integration template.
Salesforce Object | Apex script location | PushTopic name |
---|---|---|
Account | /src/test/resources/scripts/accounts-push-topic.apxc | Accounts |
Contact | /src/test/resources/scripts/contacts-push-topic.apxc | Contacts |
Account | /src/test/resources/scripts/accounts-address-push-topic.apxc | AccountAddresses |
Account | /src/test/resources/scripts/households-push-topic.apxc | Households |
Opportunity | /src/test/resources/scripts/opportunities-push-topic.apxc | Opportunities |
FinServ__FinancialAccount__c | /src/test/resources/scripts/financial-accounts-push-topic.apxc | FinancialAccounts |
FinServ__FinancialAccountTransaction__c | /src/test/resources/scripts/transactions-push-topic.apxc | Transactions |
FinServ__Card__c | /src/test/resources/scripts/cards-push-topic.apxc | Cards |
Follow the below steps to create the above PushTopics
- Click on Salesforce Setup icon.
- Select
Developer Console
->Debug
->Open Execute Anonymous Window
. - Copy and paste the script from the
Apex script location
column in the above table and execute. - Repeat above step #3 for all the Salesforce objects in the above table.
Notes
- All the PushTopics created above filters records based on LastModifiedBy <>
Service account user Id
. This is to filter out updates done by thefins-salesforce-customers-sys-api
andfins-salesforce-financial-sys-api
to avoid cyclical updates. This can be obatined by running the querySELECT Id FROM User WHERE Username='<service-account-username>'
in the Developer Console. Ensure to replace the ID in the Apex scripts. - PushTopic Accounts, AccountAddresses, and Households also filters records based on record type id. The record type id can be obtained by running the query
SELECT Id,Name FROM RecordType where Name='Household' and sObjectType='Account'
in the Developer Console. Ensure to replace the Id in the Apex scripts.
Generating token for a User in Salesforce Org
- Login to Salesforce with the Service Account User Id.
- Click Username in the top right and select Setup or My Settings from the menu.
- Under Personal Setup, click My Personal Information > Reset My Security Token.
- Click Reset Security Token.
- Check the Service Account User email inbox for the email from Salesforce with the new security token.
Adding MailingAddress to Person Account Details page in Salesforce Org
The following instructions assume you have already Salesforce Org created and PersonAccount is enabled. Perform the following actions to enable MailingAddress on PersonAccount detail page.
- Open the Salesforce SetUp -> Object Manager -> Search for
PersonAccount
and Select. - From the menu on the left Click on
Page Layouts
-> Select the Page layout that is assigned to the user profile logged in. - Click on
Fields
tab on the palatte and it shows all the available fields. - Search for
MailingAddress
. Drag from the palette and drop it in theAddress Information
section of the layout and click onSave
.
Creating Contacts that are not associated with an Account
These instructions assume an Org was created in Salesforce with access to Contact object.
- From the object management settings for contacts, go to Page Layouts.
- Select the layout you want to edit.
- Find the
Account Name
field on the layout and hover over it. Then, click the wrench icon to show the field properties. - Deselect the Required checkbox and confirm your changes.
Configure Connected App in Salesforce
Follow the below steps to generate Consumer Key
and Consumer Secret
for Salesforce authentication:
- Click the Salesforce Setup icon.
- Navigate to
Apps -> App Manager
. - Select
New Connected App
. - Enter Connected App Name:
Mulesoft Accelerator
, API Name:Mulesoft_Accelerator
and set your email address. - Under
API (Enable OAuth Settings)
section, check the boxEnable OAuth Settings
. - Set the callback URL
http://localhost
. - From the
Selected OAuth Scopes
list, selectFull access (full)
. - Click Save.
- Copy the
Consumer Key
andConsumer Secret
. These will be updated in the settings.xml file assfdc.fsc.client-id
andsfdc.fsc.client-secret
in FSC-BANKING-DEV, FSC-Insurance-DEV and FSC-WEALTH-DEV profiles. - Click
Manage -> Edit Policies
. - In
OAuth Policies
section, forPermitted Users
selectAll users may self-authorize
and forIP Relaxation
selectRelax IP restrictions
. - Click Save.
Anypoint MQ Configuration
The Anypoint-MQ-Queues-Exchanges postman collection in the fins-common-resources project will pre-create all MQ destinations required by the accelerator components.
The collection will require the "dev" environment template be imported into your Postman workspace and assigned proper values first. The following MQ destinations will be created on successful execution.
Queue Name | Bound to Exchange | Dead Letter Queue Name |
---|---|---|
fins-partyrole-update-queue | fins-partyrole-update-exchange | fins-partyrole-update-dl-queue |
fins-party-update-queue | fins-party-update-exchange | fins-party-update-dl-queue |
fins-account-update-queue | fins-account-update-exchange | fins-account-update-dl-queue |
fins-transaction-update-queue | fins-transaction-update-exchange | fins-transaction-update-dl-queue |
fins-card-update-queue | fins-card-update-exchange | fins-card-update-dl-queue |
fins-ach-inbound-queue | fins-ach-inbound-exchange | fins-ach-inbound-dl-queue |
fins-ach-outbound-queue | fins-ach-outbound-exchange | fins-ach-outbound-dl-queue |
fins-fedwire-inbound-queue | fins-fedwire-inbound-exchange | fins-fedwire-inbound-dl-queue |
fins-fedwire-outbound-queue | fins-fedwire-outbound-exchange | fins-fedwire-outbound-dl-queue |
fins-swift-inbound-queue | fins-swift-inbound-exchange | fins-swift-inbound-dl-queue |
fins-swift-outbound-queue | fins-swift-outbound-exchange | fins-swift-outbound-dl-queue |
fins-address-update-queue | fins-address-update-exchange | fins-address-update-dl-queue |
fins-lead-update-queue | fins-lead-update-exchange | fins-address-update-dl-queue |
fins-opportunity-update-queue | fins-opportunity-update-exchange | fins-opportunity-update-dl-queue |
fins-loan-document-update-queue | fins-document-update-exchange | fins-loan-document-update-dl-queue |
fins-wam-document-update-queue | fins-document-update-exchange | fins-wam-document-update-dl-queue |