Skip to main content
Available in version 0.10.1 and later.

Overview

The Balance from Source endpoint allows you to compute a balance directly from its transactions instead of using the default running balance. This is useful when you need to verify balance accuracy, perform audits, or ensure consistency by calculating balances independently from the stored balance values.
GET http://YOUR_BLNK_INSTANCE_URL/balances/{balance_id}?from_source=true
Example response
{
  "balance": {
    "balance": 9620000,
    "balance_id": "bin_be16c4a1-b5a6-4b64-a733-de2f6b24813d",
    "credit_balance": 9620000,
    "currency": "USD",
    "debit_balance": 0,
    "ledger_id": ""
  }
}

How it works

When you call the balance from source endpoint, Blnk reconstructs the balance by:
  1. Getting all applied transactions: Blnk retrieves all applied transactions for the balance and aggregates them together. As a result, it may take longer to process for balances with extensive transaction history.
  2. Calculating credits and debits: It aggregates all credit transactions (money moving into the balance) and debit transactions (money moving out of the balance) to compute the total credit balance, debit balance, and net balance.
  3. Returning the computed balance: The final computed balance, reflecting the exact state based on transaction history, is returned in the response.

Historical balances

Learn how to retrieve balances at specific historical timestamps

Balance snapshots

Learn how to create snapshots of your running balances

Need help?

We are very happy to help you make the most of Blnk, regardless of whether it is your first time or you are switching from another tool. To ask questions or discuss issues, please contact us or join our Discord community.
Tip: Connect to Blnk Cloud to see your Core data.You can view your transactions, manage identities, create custom reports, invite other team members to collaborate, and perform operations on your Core — all in one dashboard.Check out Blnk Cloud →