Skip to main content

Documentation Index

Fetch the complete documentation index at: https://docs.keystn.com/llms.txt

Use this file to discover all available pages before exploring further.

How Rules Work

Every commission template starts with a base commission — the default amount paid per loan. Commission rules act as overrides: when a loan matches a rule’s filters, the rule’s commission is used instead of the base.
Loan funded
  |
  +--> Check rules (most specific first)
  |      |
  |      +--> Rule matches? --> Use rule's commission
  |      |
  |      +--> No match? --> Check next rule
  |
  +--> No rules match --> Use base commission
Each rule has its own:
  • Commission amount (percentage, flat, or bps)
  • Commission basis (loan amount or broker compensation)
  • File fee (optional, overrides the template’s file fee)
  • Minimum and maximum commission (optional)
  • One or more filters that determine when the rule applies

Creating a Commission Rule

Rules are created within a commission template, in the Rules tab.

Step 1: Open the Template Editor

  1. Navigate to Commission Templates and click on a template.
  2. Click Edit.
  3. Switch to the Rules tab.

Step 2: Add a New Rule

  1. Click Add Rule.
  2. A new rule form expands with commission settings and filter options.

Step 3: Set the Rule’s Commission

Configure the commission for this rule, which will override the template’s base commission when the rule matches:
FieldDescription
Amount TypePercentage (%), Flat ($), or Basis Points (bps)
AmountThe commission value
Commission BasisLoan Amount or Broker Compensation
Minimum CommissionOptional floor
Maximum CommissionOptional ceiling
File FeeOptional per-loan deduction (overrides template file fee)
Deducts From Loan OfficerWhether this commission reduces the LO’s pay
Apply File Fee FirstWhether the file fee adjusts the basis before calculation

Step 4: Configure Filters

Filters determine which loans trigger this rule. A rule with no filters matches all loans (effectively replacing the base commission). Add one or more filters to narrow the match.

Available Filters

Lead Source Filter

Matches loans that originated from a specific lead source (e.g., “Zillow”, “Realtor Referral”, “Company Website”).
SettingDescription
Lead SourceSelect from your configured lead sources
InvertWhen enabled, the rule matches loans that are NOT from this lead source
Example: A rule with Lead Source = “Zillow” pays 40 bps instead of 50 bps because Zillow leads have a lower margin.

Lender Filter

Matches loans submitted to a specific lender/investor.
SettingDescription
LenderSelect from your configured lenders
InvertWhen enabled, the rule matches loans NOT with this lender
Example: A rule with Lender = “Wholesale Lender A” pays a $200 flat bonus on top of the base because this lender offers better pricing.

Branch Filter

Matches loans originated by loan officers in a specific branch office.
SettingDescription
BranchSelect from your configured branches
Example: The downtown branch has a different cost structure, so loans from that branch earn 45 bps instead of 50 bps.

Loan Purpose Filter

Matches loans with a specific purpose.
SettingDescription
Loan PurposePurchase or Refinance
InvertWhen enabled, matches the opposite purpose
Example: Refinance loans earn 40 bps while purchase loans earn the base 50 bps.

Loan Type Filter

Matches loans of a specific product type.
SettingDescription
Loan TypeOne of: Conventional, FHA, VA, USDA, Non-QM, Reverse Mortgage, HELOC, Commercial, HELOAN
InvertWhen enabled, matches all loan types EXCEPT the selected one
Example: VA loans earn a flat $400 commission because the margins are typically lower.

Payer Type Filter

Matches loans based on who is paying the broker compensation.
SettingDescription
Payer TypeLender, Borrower, Investor, or Seller
Example: Lender-paid compensation (LPMI) loans earn 45 bps, while borrower-paid loans earn the base 50 bps.

Tax Classification Filter

Matches based on the employee’s tax classification.
SettingDescription
Tax ClassificationW-2 or 1099
InvertWhen enabled, matches the opposite classification
Example: 1099 contractors earn a higher base rate of 75 bps to offset the lack of benefits, while W-2 employees earn 50 bps.

Property State Filter

Matches loans where the property is located in one or more specific states.
SettingDescription
Property StatesSelect one or more U.S. states
InvertWhen enabled, matches loans in states NOT in the list
Example: Loans in California and New York earn 40 bps due to higher regulatory costs, while all other states earn the base 50 bps.

Business Contact Filter

Matches loans where a business contact (e.g., realtor, title company, builder) matches a name or email pattern.
SettingDescription
Business Contact NameText to match against contact names (case-insensitive, partial match)
Business Contact EmailText to match against contact emails (case-insensitive, partial match)
InvertWhen enabled, matches loans WITHOUT a matching business contact
Example: Loans with a business contact from “ABC Realty” earn a $100 bonus because of a referral partnership.

Filter Inversion

Most filters support an Invert toggle. When inversion is enabled, the filter logic is reversed:
NormalInverted
Loan IS from Lender ALoan is NOT from Lender A
Loan IS a PurchaseLoan is NOT a Purchase (i.e., Refinance)
Property IS in CaliforniaProperty is NOT in California
This is useful for creating “everything except” rules. For example, instead of creating separate rules for 49 states, you can create one rule for “NOT California” that applies to all other states.

Rule Matching and Precedence

When the commission engine processes a loan, it evaluates rules in a specific order to find the best match.

Matching Process

  1. Only rules matching the current role context are considered.
  2. Employee-specific rules are evaluated before template-level defaults.
  3. More specific rules rank higher than less specific rules.
  4. All filters on a rule must match (AND logic).
  5. If the rule is linked to a special case group, that group’s conditions must also be satisfied.
  6. The first matching rule wins.

Specificity Example

Given these rules on a template:
RuleFiltersCommission
Rule ALoan Type = FHA, Payer Type = Lender35 bps
Rule BLoan Type = FHA40 bps
Rule C(no filters)50 bps
For an FHA loan with Lender-paid compensation:
  • Rule A matches (both filters pass) — 35 bps is used
For an FHA loan with Borrower-paid compensation:
  • Rule A does not match (payer type does not match)
  • Rule B matches — 40 bps is used
For a Conventional loan:
  • Rule A does not match
  • Rule B does not match
  • Rule C matches (no filters = always matches) — 50 bps is used

Employee-Specific vs. Template Rules

When a template is assigned to an employee, all rules are copied into employee-bound rules. Employee-bound rules take precedence over template-level rules. If an admin creates an employee-specific override rule directly on the employee, it will rank above the template-generated rules.

Combining Multiple Filters

When a rule has multiple filters set, all of them must match for the rule to apply (AND logic). For example:
FilterValue
Loan TypeFHA
Property StateTexas
Payer TypeLender
This rule only matches FHA loans in Texas with lender-paid compensation. A loan must satisfy all three conditions. If you need OR logic (e.g., “FHA OR VA loans”), create separate rules — one for FHA and one for VA.

Worked Example

A brokerage wants to set up the following commission structure for loan officers:
  • Default: 50 bps on loan amount
  • FHA loans: 40 bps on loan amount
  • VA loans: $400 flat
  • Zillow leads: 35 bps on loan amount (regardless of loan type)
  • California properties: Minimum commission of $500

Template Configuration

Base Commission:
  • Basis: Loan Amount
  • Amount Type: Basis Points
  • Amount: 50
Rule 1 — FHA Override:
  • Amount Type: Basis Points, Amount: 40
  • Filter: Loan Type = FHA
Rule 2 — VA Override:
  • Amount Type: Flat, Amount: 400
  • Filter: Loan Type = VA
Rule 3 — Zillow Lead Override:
  • Amount Type: Basis Points, Amount: 35
  • Filter: Lead Source = Zillow
Rule 4 — California Minimum:
  • Amount Type: Basis Points, Amount: 50
  • Minimum Commission: 500
  • Filter: Property State = California

Calculation Results

LoanTypeStateLead SourceAmountCommission
Loan 1ConventionalTexasDirect$350,000$1,750 (50 bps)
Loan 2FHAFloridaReferral$300,000$1,200 (40 bps)
Loan 3VAGeorgiaDirect$500,000$400 (flat)
Loan 4ConventionalOhioZillow$400,000$1,400 (35 bps)
Loan 5ConventionalCaliforniaDirect$250,000$1,250 (50 bps)
Loan 6ConventionalCaliforniaDirect$80,000$500 (min applied; 50 bps = $400 < $500 min)