FINS Bank Loans Process API - Implementation Template
Data mappings
This document provides information generated from the DataWeave scripts included in the project, such as function definitions, variable definitions, and data mapping tables.
| Module | Description |
|---|---|
| map-create-customer-request | This script upserts the customer from the incoming loan application with updated values |
| map-create-docusign-request | This script maps an incoming create envelope request to DocuSign System API format. |
| map-create-document-in-LOS | This script maps an incoming request to Loan Document format. |
| map-create-loan-account | This script maps Loan Application to Loan Account format. |
map-create-customer-request
This script upserts the customer from the incoming loan application with updated values
Source:
./src/main/resources/dwl/map-create-customer-request.dwl
Mapping Tables
Maps the incoming loan application to the Customer (customers-prc-api) format.
| customers-prc-api property | API property | Description |
|---|---|---|
| partyRoleType | "Customer" | Hard-coded value |
| customerStatus | If customer exists in Global Party System then "Active" else "Prospect" | Status of the customer |
| party | customer.party | Party associated with the customer |
map-create-docusign-request
This script maps an incoming create envelope request to DocuSign System API format.
Source:
./src/main/resources/dwl/map-create-docusign-request.dwl
Mapping Tables
Creates the DocuSign API Envelope structure.
| API property | DocuSign API property | Description |
|---|---|---|
| emailSubject | emailSubject | Hard-coded subject line of the email to send |
| emailBlurb | emailBlurb | Hard-coded body of the email to send |
| compositeTemplates.customFields | textCustomFields | A list of custom text properties to include in the envelope such as documentUsageType and applicationType |
| compositeTemplates.documents | payload | Dynamic document and base64 document content to include in the envelope |
| compositeTemplates.recipients | mdmCustomer | List of recipients to include in the envelope |
| envelopeStatus | "SENT" | The target status of the created envelope |
map-create-document-in-LOS
This script maps an incoming request to Loan Document format.
Source:
./src/main/resources/dwl/map-create-document-in-LOS.dwl
Mapping Tables
Maps the incoming request to Document format.
| Loan Document property | API property | Description |
|---|---|---|
| id | null | Hard-coded value |
| documentStatus | "CURRENT" | Status of the document |
| signatureStatus | UNSIGNED | Initial signature status |
| documentType | LoanDocument | Type of document |
| loanApplication | loanApplicationId | Loan Application Id stored in DocuSign |
| externalIds | docuSignEnvelopeId | DocuSign Envelope Id |
map-create-loan-account
This script maps Loan Application to Loan Account format.
Source:
./src/main/resources/dwl/map-create-loan-account.dwl
Mapping Tables
Maps the incoming loan application to loan account format.
| Loan Account | Loan Application property | Description |
|---|---|---|
| id | null | Hard-coded value |
| name | concat(loanPurpose & "Loan") | Name of the Loan |
| accountNumber | UUID | Loan account number |
| accountType | LoanAccount | Hard-coded |
| primaryAccountOwner | customerId | Primary Account of the loan account |
| accountStatus | OPEN | Hard-coded |
| accountBalance | requestedLoanAmount | Account balance |
| availableBalance | requestedLoanAmount | Available balance |
| accountCurrency | USD | Hard-coded |
| accountLabel | loanPurpose | Account label |
| loanType | loanPurpose | Type of loan account |
| loanDurationInMonths | loanDurationInMonths | Duration of Loan in Months - Default to 12 |
| interestRate | interestRate | Interest Rate of the loan |
| taxIdentificationNumber | taxIdentificationNumber | Tax identification number |
| openedDate | now() | Current date |
| loanAmount | requestedLoanAmount | Requested loan amount |
| notes | loanPurpose | Notes on purpose of loan |
| originalLoanAmount | requestedLoanAmount | Original Loan Amount |
| principalBalance | requestedLoanAmount | Principal balance |