There are certain features to consider for Mortgage vertical when mapping inputs for a campaign on Step 2 of API Configuration.
According to PX specification for Mortgage vertical, the user selects preferred ranges of values (i.e. Property Value, First Mortgage Balance fields, etc.) or specifies the percentage (i.e. DownPayment field). However, there are situations when buyer specification requires these fields to be sent as one value instead of range, or a value instead of the percentage.
For this purpose, PX specification includes a set of fields calculated automatically in the API. If required fields are mapped in API Builder, values specified by end-user are transformed into ones accepted by buyer API.
Such fields are marked in code with <!-- calculated in the API --> comment:
<Mortgage> <LoanType>Purchase</LoanType> <!-- mandatory --> <PropertyType>Single family home</PropertyType> <!-- mandatory --> <PropertyUse>Primary home</PropertyUse> <!-- mandatory --> <PropertyValue>$50,000 or less</PropertyValue> <!-- mandatory --> <FirstMortgageBalance>$50,000 or less</FirstMortgageBalance> <!-- mandatory when refinance + home equity --> <SecondMortgageBalance>$50,000 or less</SecondMortgageBalance> <!-- mandatory when refinance + home equity and second mortgage --> <CashOutAmount>0 (No cash)</CashOutAmount> <!-- mandatory refinance + home equity--> <DownPayment>0%</DownPayment> <!-- mandatory purchase, please URL encode percentage (%) character like: %25 --> <LoanAmount>1</LoanAmount><!-- calculated in the API --> <LoanToValue>1</LoanToValue><!-- calculated in the API --> <DownPaymentAmount>1</DownPaymentAmount><!-- calculated in the API --> <FirstMortgageCalc>1</FirstMortgageCalc><!-- calculated in the API --> <SecondMortgageCalc>1</SecondMortgageCalc><!-- calculated in the API --> <PropertyValueCalc>1</PropertyValueCalc><!-- calculated in the API --> </Mortgage>
How Fields Are Calculated in PX API
The following fields are calculated automatically:
- Loan Amount
- Loan To Value
- Down Payment Amount
- First Mortgage Calc
- Second Mortgage Calc
- Property Value Calc
Loan Amount is calculated as the sum of First Mortgage Calc, Second Mortgage Calc and Cash Out fields:
LoanAmount = FirstMortgageCalc + SecondMortgageCalc + CashOut,
- FirstMortgageCalc is the average from FirstMortgageBalance range selected by user;
- SecondMortgageCalc is the average from SecondMortgageBalance range selected by user;
- CashOut - the minimum value from CashOutAmount range selected by the user.
Loan To Value is calculated as the ratio of Loan Amount to Property Value Calc:
Loan To Value = Loan Amount / PropertyValueCalc * 100%,
where Property Value Calc is the maximum value from PropertyValue range.
Down Payment Amount is calculated as the product of DownPayment (value entered by the user in %) and Property Value Calc fields:
Down Payment Amount = (DownPayment * Property Value Calc)/100
For example, customer entered the following information:
- Cash Out Amount ($) - 0 (No cash)
- First Mortgage Balance ($) - 50001 - 75000
- Property Value ($) - 125001 - 150000
- Second Mortgage Balance ($) - 50001 - 75000
If everything is mapped properly on Step 2 of API Builder, the following fields will be calculated in PX API and sent to the buyer:
- First Mortgage Calc = (50000+75000)/2 = 62500
- Second Mortgage Calc = (50000+75000)/2 = 62500
- Property Value Calc = 150000
- Loan Amount = 62500+62500+0 = 125000
- Loan To Value (%) = 125000/150,000 *100 = 83.33