> ## Documentation Index
> Fetch the complete documentation index at: https://docs.lead.bank/llms.txt
> Use this file to discover all available pages before exploring further.

# Balance Reconciliation

> Understand end-of-day account balances.

## Overview

Lead tracks the end-of-day account balance for `type` = `credit` or `deposit`, along with other applicable balances depending on your programs.

<Info>
  For specific validations performed, refer to [Balances and Transactions Files Validations](/file-integrations/balances-and-transactions/balance-validations).
</Info>

## Deposit Balance

| **Reconciliation**                              | **Description**                                                                                                                                                                                                                                                                                                                                                                                         |
| ----------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| balance                                         | Tracks the end-of-day deposit balances (e.g., debit cards, deposit accounts, FBO accounts) for the customer. `balance` reconciles against the daily activity of `transactions.amount`.                                                                                                                                                                                                                  |
| interest\_accrued\_balance<br />(if applicable) | Applies to deposit programs that offer interest to customers. It reconciles against the daily activity of `transactions.amount` for `transactions.type` across `interest_accrued` and `interest_paid`.<br /><br />See [Interest Accrued Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                                                            |
| rewards\_balance<br />(if applicable)           | Applies to deposit programs that offer rewards (e.g., a debit card with rewards). It reconciles against the daily activity of `transactions.amount` for `transactions.type` across `rewards_earned`, `rewards_spent`, `rewards_redeemed`, `debit`, `credit`, and `refund`.<br /><br />See [Rewards Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples. |
| dispute\_balance                                | Tracks the end-of-day dispute balances (e.g., disputes on card transactions) for the customer. It reconciles against the daily activity of `transactions.amount` for `transactions.type` across `dispute_provisional`,`dispute_lost`, and `dispute_won`.<br /><br />See [Dispute Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                   |
| charge\_off\_balance                            | Applies to overdrawn deposit balances that have been charged off. It tracks the end-of-day charge-off balance for the customer and reconciles against the daily activity of `transactions.amount` for `transactions.type` across `charge_off`.<br /><br />See [Charge Off Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                          |

## Credit Balance

| **Reconciliation**                    | **Description**                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                          |
| :------------------------------------ | :------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| balance                               | Tracks the end-of-day credit balances (e.g., loans, credit cards) for the customer. It reconciles against the daily activity of `transactions.amount` except for `transactions.type` across `charge_off_recovery` and `dispute_won`, which do not affect the credit balance.                                                                                                                                                                                                                                                                                                                                                                                                                             |
| balance                               | Represents the outstanding balance across principal, fees, and interest:  - Each sub-amount of outstanding balance is reconciled against day over day transactions that affect that sub-amount. For example, if outstanding interest is increased by \$10, then we would expect to see a transaction that has an `interest_amount` of \$10. Similarly, if outstanding fees are decreased by \$20 due to a payment, then we would expect to see a transaction that has a `fees_amount` of -\$20. - Additionally, `reallocation` transaction types can be used to move outstanding amounts from one sub-amount to another e.g. \$10 from outstanding interest is reduced and instead applied to principal. |
| rewards\_balance<br />(if applicable) | Applies to credit programs that offer rewards (e.g., a credit card with rewards). It reconciles against the daily activity of `transactions.amount` for `transactions.type` across `rewards_earned`, `rewards_spent`, `rewards_redeemed`, `disbursement`, `client_credit`, and `refund`.<br /><br />See [Rewards Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                                                                                                                                                                                                                                                                                    |
| dispute\_balance                      | Tracks the end-of-day dispute balances (e.g., disputes on card transactions) for the customer. It reconciles against the daily activity of `transactions.amount` for `transactions.type` across `dispute_provisional`,`dispute_lost`, and `dispute_won`.<br /><br />See [Dispute Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                                                                                                                                                                                                                                                                                                                    |
| charge\_off\_balance                  | Applies to charged-off credit balances. It tracks the end-of-day charge-off balance for the customer and reconciles against the daily activity of `transactions.amount` for `transactions.type` across `charge_off` and `charge_off_recovery`.<br /><br />See [Charge Off Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                                                                                                                                                                                                                                                                                                                           |
| past\_due\_balance                    | Applies to past due balances. It tracks the end-of-day past due balance for the customer. There is no reconciliation against `transactions.amount` and credit balance enters past due status if the customer fails to make the scheduled payment by the due date.<br /><br />See [Past Due Balance](/file-integrations/balances-and-transactions/balance-reconciliation#examples) for examples.                                                                                                                                                                                                                                                                                                          |

## Examples

<AccordionGroup>
  <Accordion title="Rewards" icon="sparkles">
    <Info>
      Applicable to Both Deposit and Credit Balances if your program offers rewards.
    </Info>

    For rewards, Lead tracks `rewards_balance` and `rewards_unit` in the Balance file as well as rewards transactions affecting the balance.

    ### Rewards on the Debit Card or Deposit Balance

    | **Type**             | **Amount Action**               | **Rewards Amount**                    | **Example**                                                                                                                                                                                                                                                                                                |
    | -------------------- | ------------------------------- | ------------------------------------- | ---------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | debit                | Applied (-) / Reversed (+)      | 0 or positive (+) / 0 or negative (-) | A \$100 `debit` transaction earns 1,000 rewards units. Not all transactions affect rewards.  - `balance` decreases by `amount`. - `rewards_balance` may or may not increase by `rewards_amount` depending on whether `debit` transaction affects rewards.                                                  |
    | refund               | Applied (+) /<br />Reversed (-) | 0 or negative (-) / 0 or positive (+) | A \$100 `refund` reverses 1,000 rewards units. Not all transactions affect rewards.  - `balance` increases by `amount`. - `rewards_balance` may or may not decrease by `rewards_amount` depending on whether `refund` transaction affects rewards.                                                         |
    | credit               | Applied (+) /<br />Reversed (-) | 0 or negative (-) / 0 or positive (+) | A \$100 `credit` reverses 1,000 rewards units. Not all transactions affect rewards.  - `balance` increases by `amount`. - `rewards_balance` may or may not decrease by `rewards_amount` depending on whether `credit` transaction affects rewards.                                                         |
    | dispute\_provisional | Applied (+)                     | 0 or negative (-)                     | A dispute for a transaction is in progress. This transaction originally had 1,000 rewards associated with it.  - `balance` increases by `amount`. - `rewards_balance` may or may not decrease by `rewards_amount` depending on whether client reduces the rewards associated with the dispute transaction. |
    | dispute\_lost        | Applied (-)                     | 0 or positive (+)                     | A dispute for a transaction is lost.  - `balance` decreases by `amount`. - `rewards_balance` may or may not increase by `rewards_amount` depending on whether client increases the rewards associated with the dispute lost transaction.                                                                   |
    | rewards\_earned      | Applied (0) /<br />Reversed(0)  | Positive (+) /<br />negative (-)      | 1,000 rewards units are added to the rewards balance, which increases to 1,000 units. This does not affect the deposit balance.  - `balance` is unaffected. - `rewards_balance` increases by `rewards_amount`.                                                                                             |
    | rewards\_spent       | Applied (0) /<br />Reversed(0)  | Negative (-) /<br />Positive (+)      | 1,000 rewards units are deducted from the rewards balance. This does not affect the deposit balance.  - `balance` is unaffected. - `rewards_balance` decreases by `rewards_amount`.                                                                                                                        |
    | rewards\_redeemed    | Applied (+) /<br />Reversed (-) | Negative (-) /<br />Positive (+)      | A \$1.00 cashback is credited to the deposit balance, reducing the rewards amount accordingly.  - `balance` increases by `amount`. - `rewards_balance` decreases by `rewards_amount`.                                                                                                                      |

    ### Rewards on the Credit Card

    | **Type**             | **Amount Action**               | **Rewards Amount**                    | **Example**                                                                                                                                                                                                                                                                                                |
    | :------------------- | :------------------------------ | :------------------------------------ | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | disbursement         | Applied (+) / Reversed (-)      | 0 or positive (+) / 0 or negative (-) | A \$100 disbursement earns 1,000 rewards units. Not all transactions affect rewards.  - `balance` increases by `amount`. - `rewards_balance` may or may not increase by `rewards_amount` depending on whether `disbursement` transaction affects rewards.                                                  |
    | refund               | Applied (-) /<br />Reversed (+) | 0 or negative (-) / 0 or positive (+) | A \$100 refund reverses 1,000 rewards units. Not all transactions affect rewards.  - `balance` decreases by `amount`. - `rewards_balance` may or may not decrease by `rewards_amount` depending on whether `refund` transaction affects rewards.                                                           |
    | client\_credit       | Applied (-) /<br />Reversed (+) | 0 or negative (-) / 0 or positive (+) | A \$100 client credit reverses 1,000 rewards units. Not all transactions affect rewards.  - `balance` decreases by `amount`. - `rewards_balance` may or may not decrease by `rewards_amount` depending on whether `client_credit` transaction affects rewards.                                             |
    | dispute\_provisional | Applied (-) /<br />Reversed (+) | 0 or negative (-) / 0 or positive (+) | A dispute for a transaction is in progress. This transaction originally had 1,000 rewards associated with it.  - `balance` decreases by `amount`. - `rewards_balance` may or may not decrease by `rewards_amount` depending on whether client reduces the rewards associated with the dispute transaction. |
    | dispute\_lost        | Applied (+) /<br />Reversed (-) | 0 or positive (+) / 0 or negative (-) | A dispute for a transaction is lost.  - `balance` increases by `amount` - `rewards_balance` may or may not increase by `rewards_amount` depending on whether client increases the rewards associated with the dispute lost transaction.                                                                    |
    | rewards\_earned      | Applied (0) /<br />Reversed(0)  | Positive (+) /<br />Negative (-)      | 1,000 rewards units are added to the rewards balance, increasing it to 1,000 units. This does not affect the credit balance.  - `balance` is unaffected. - `rewards_balance` increases by `rewards_amount`.                                                                                                |
    | rewards\_spent       | Applied (0) /<br />Reversed(0)  | Negative (-) /<br />Positive (+)      | 1,000 rewards units are deducted from the rewards balance. This does not affect the credit balance.  - `balance` is unaffected. - `rewards_balance` decreases by `rewards_amount`.                                                                                                                         |
    | rewards\_redeemed    | Applied (-) /<br />Reversed (+) | Negative (-) /<br />Positive (+)      | A \$1.00 cashback is applied to the credit balance, reducing both the credit balance and the rewards amount accordingly.  - `balance` decreases by `amount`. - `rewards_balance` decreases by `rewards_amount`.                                                                                            |
  </Accordion>

  <Accordion title="Dispute Balance" icon="sparkles">
    <Info>
      Applicable to both deposit and credit balances.
    </Info>

    For disputes, Lead tracks `dispute_balance` (if Credit: across balance, principal, interest and fees) in the Balances file as well as dispute transactions affecting the balance. Below are examples of disputes for deposit and credit balances.

    ### Disputes on the Deposit Balance

    | **Type**             | **Amount Action** | **Example**                                                                                                                                                                                                                                             |
    | -------------------- | ----------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | dispute\_provisional | Applied (+)       | The customer's deposit balance is \$1,000. Customer disputes a \$50 charge from a merchant.  - `balance` increases by \$50 to \$1,050 while the dispute is in progress. - `dispute_balance` increases by \$50 to \$50 while the dispute is in progress. |
    | dispute\_won         | Applied (-)       | Customer wins the dispute of \$50 transaction.  - `balance` is unaffected at \$1,050. - `dispute_balance` decreases by \$50 to \$0.                                                                                                                     |
    | dispute\_lost        | Applied (-)       | Customer loses the dispute of \$50 transaction.  - `balance` decreases by \$50 to \$1,000. - `dispute_balance` decreases by \$50 to \$0.                                                                                                                |

    ### Disputes on the Credit Balance

    | **Type**             | **Amount Action** | **Example**                                                                                                                                                                                                                                          |
    | :------------------- | :---------------- | :--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | dispute\_provisional | Applied (-)       | The customer's credit balance is \$1,000. Customer disputes a \$50 charge from a merchant.  - `balance` decreases by \$50 to \$950 while the dispute is in progress. - `dispute_balance` increases by \$50 to \$50 while the dispute is in progress. |
    | dispute\_won         | Applied (-)       | Customer wins the dispute of \$50 transaction.  - `balance` is unaffected at \$950. - `dispute_balance` decreases by \$50 to \$0.                                                                                                                    |
    | dispute\_lost        | Applied (+)       | Customer loses the dispute of \$50 transaction.  - `balance` increases by \$50 to \$1,000. - `dispute_balance` decreases by \$50 to \$0.                                                                                                             |
  </Accordion>

  <Accordion title="Charge Off Balance" icon="sparkles">
    <Info>
      Applicable to both deposit and credit balances.
    </Info>

    For charge offs, Lead tracks `charge_off_balance` (if Credit: across balance, principal, interest and fees) in the Balances file as well as charge-off transactions affecting the balance. Below are examples of charge-offs for deposit and credit balances.

    ### Charge Offs on the Deposit Balance

    | **Type**              | **Amount Action** | **Example**                                                                                                                                                                                                                                     |
    | --------------------- | ----------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | charge\_off           | Applied (+)       | The customer is overdrawn \$100 (deposit balance = -\$100) and has surpassed the threshold for repayment. A charge-off transaction of \$100 is run.  - `balance` increases by \$100 to \$0. - `charge_off_balance` increases by \$100 to \$100. |
    | charge\_off\_recovery | Applied (-)       | Customer deposits \$100 to pay off the `charge_off_balance`.  - `balance` is unaffected at \$0. - `charge_off_balance` decreases by \$100 to \$0.                                                                                               |

    ### Charge Offs on the Credit Balance

    | **Type**              | **Amount Action** | **Example**                                                                                                                                             |
    | :-------------------- | :---------------- | :------------------------------------------------------------------------------------------------------------------------------------------------------ |
    | charge\_off           | Applied (-)       | A \$100 loan (credit balance = \$100) has been charged off.  - `balance` decreases by \$100 to \$0. - `charge_off_balance` increases by \$100 to \$100. |
    | charge\_off\_recovery | Applied (-)       | Customer deposits \$100 to pay off the `charge_off_balance`.  - `balance` is unaffected at \$0. - `charge_off_balance` decreases by \$100 to \$0.       |
  </Accordion>

  <Accordion title="Interest Accrued Balance" icon="sparkles">
    <Info>
      Applicable to deposit balance only if your program offers interest.
    </Info>

    For deposit balances, Lead tracks `interest_accrued_balance` to record cumulative interest accrued. `interest_accrued` and `interest_paid` impact `interest_accrued_balance`, while `interest_paid` also affects the deposit balance.

    For example, with a beginning deposit balance of \$100, interest accrues at \$1 daily, reaching \$30 by month-end.

    * day 1-30: The `interest_accrued_balance` increases daily. At month-end, the deposit balance remains \$100, and `interest_accrued_balance` is \$30.
    * After `interest_paid`, the deposit balance becomes \$130, and `interest_accrued_balance` resets to \$0.

    ### Interest on the Deposit Balance

    | **Type**          | **Amount Action**          | **Example**                                                                                                                                                 |
    | ----------------- | -------------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
    | interest\_accrued | Applied (+) / Reversed (-) | Interest accrues \$1 daily.  - `balance` is unaffected. - `interest_accrued_balance` increases by \$1 daily. By day 30, `interest_accrued_balance` is \$30. |
    | interest\_paid    | Applied (+) / Reversed (-) | \$30 of accrued interest is paid to the customer on day 30.  - `balance` increases by \$30 to \$30. - `interest_accrued_balance` decreases by \$30 to \$0.  |
  </Accordion>

  <Accordion title="Past Due Balance" icon="sparkles">
    <Info>
      Applicable to credit balance only.
    </Info>

    For credit balances, Lead tracks `past_due_balance` for any loans that are past due. `past_due_balance` is not directly affected by `transactions.amount`. Instead, credit balance enters past due status if the customer fails to make the scheduled payment by the due date.

    See the example below for how `past_due_balance` interacts with `balance`.

    For simplicity, we assume all past due balances apply to principal only. However, in reality, past due amounts may be distributed across principal, fees, and interest.

    * A \$500 loan payment is due on March 1st, but the customer misses the payment.
    * April 1st: Loan is 30+ Days Past Due. `balance` remains unchanged at \$500, but the loan is now classified as past due. Outstanding balances and past due balances are updated accordingly across principal, interest, and fees.
      * `balance`: \$500
        * `outstanding_principal`: \$500
        * `outstanding_interest`: \$0
        * `outstanding_fees`: \$0
      * `past_due_balance`: \$500
        * `past_due_principal`: \$500
        * `past_due_interest`: \$0
        * `past_due_fees`: \$0
    * July 1st: Loan is 120+ Days Past Due and Charged Off. Loan remains unpaid for 120+ days.\
      Client charges off the loan, moving the balance to `charge_off_balance`. `transactions.amount` of \$500 is recorded under `transactions.type` = `charge_off`. Note: Charge-off timelines may vary between closed-end and open-end loans and must follow applicable regulatory guidelines.
      * `balance`: \$0 (loan is fully charged off)
        * `outstanding_principal`: \$0
        * `outstanding_interest`: \$0
        * `outstanding_fees`: \$0
      * `past_due_balance`: \$0 (past due balance is cleared)
        * `past_due_principal`: \$0
        * `past_due_interest`: \$0
        * `past_due_fees`: \$0
      * `charge_off_balance`: \$500 (loan is now recorded as a charge-off)
        * `charge_off_principal`: \$500
        * `charge_off_interest`: \$0
        * `charge_off_fees`: \$0
  </Accordion>
</AccordionGroup>
