v1

latestOpenAPI 3.0.0Apache 2.02026-07-244385400.4 KB
Credit Insights

Retrieve Cashflow Insights (Bank Account)

Returns cashflow and balance insights derived from a submitted customer bank account.

get/customers/{customer_id}/bank_accounts/{bank_account_id}/credit_analysis/cashflow_insights

Path parameters

customer_idstring uuid required

The id of the customer to return.

bank_account_idstring uuid required

The id of the bank account to return.

Query parameters

start_datestring date

Specifies the start date for data retrieval. Only data with a date on or after this will be considered. This helps in filtering the data to a specific time frame of interest.

end_datestring date

Specifies the end date for data retrieval. Only data with a date before this will be considered. This helps in filtering data to a specific time frame of interest.

document_idsstring

A comma separated list of document UUIDs. Only data from these documents will be considered (as well as open banking data). This helps in filtering data to include/exclude certain documents.

include_unreconciled_documentsboolean

Unreconciled bank statements are statements where the difference between the parsed opening and closing balances is not explained by the sum of the parsed transaction amounts. Statements are typically unreconciled if the uploaded document has poor quality or is missing some of its original pages. It can also happen when the parsing models fail to parse and extract all relevant data. If this parameter is set to False, unreconciled bank statements will be excluded from the credit insights. This parameter defaults to True, keeping all documents included.

Response

Successfully retrieved customer cashflow insights.

average_credit_amountnumber

The average transaction amount across all credit transactions (in cents).

average_debit_amountnumber

The average transaction amount across all debit transactions (in cents).

count_credit_transactionsnumber

The count of all credit transactions.

count_debit_transactionsnumber

The count of all debit transactions.

total_creditsnumber

The summed amount of all credit transactions (in cents).

total_debitsnumber

The summed amount of all debit transactions (in cents).

total_netnumber

This is equivalent to total_credits minus total_debits.

count_self_transfersnumber

The quantity of self-transfers. We define a self-transfer as a bank transfer between separate bank accounts within the same entity (e.g. an individual transferring money from their checking to their savings account).

max_balancenumber

The highest daily balance found (in cents). Daily balances are taken from the end of each day.

min_balancenumber

The lowest daily balance found (in cents). Daily balances are taken from the end of each day.

beginning_balancenumber

The beginning balance for the bank account (in cents).

ending_balancenumber

The ending balance for the bank account (in cents).

average_daily_balancenumber

The average daily balance found (in cents). Daily balances are taken from the end of each day.

count_negative_balance_daysnumber

The number of days for which there was a negative balance. Daily balances are taken from the end of each day.

30_day_balance_changenumber

Balance change over the last 30 days for the account (in cents). This value will be set to null if the time period does not cover sufficient days.

60_day_balance_changenumber

Balance change over the last 60 days for the account (in cents). This value will be set to null if the time period does not cover sufficient days.

90_day_balance_changenumber

Balance change over the last 90 days for the account (in cents). This value will be set to null if the time period does not cover sufficient days.

daily_balance_volatilitynumber

This is the standard deviation of all daily balances. This represents the volatility of the customers bank account balances. For customers with multiple bank accounts, we calculate the standard deviation of the sum of the bank account balance variables.

confidence_scorenumber float

The confidence score represents the degree of certainty for the accuracy of the Credit Insights outputs. We calculate this score using a weighted combination of parsing and transaction categorization certainties. Confidence scores above 0.5 represent high confidence.

Example response

{
  "average_credit_amount": 5000,
  "average_debit_amount": 4000,
  "count_credit_transactions": 10,
  "count_debit_transactions": 15,
  "total_credits": 30000,
  "total_debits": 10000,
  "total_net": 20000,
  "count_self_transfers": 2,
  "max_balance": 1455800,
  "min_balance": 1164686,
  "beginning_balance": 1343187,
  "ending_balance": 1237381,
  "average_daily_balance": 1319166,
  "cashflow_by_category": {
    "entertainment": {
      "gambling": {
        "total_net": 20000,
        "total_debit": 10000,
        "total_credit": 30000
      }
    }
  },
  "cashflow_by_method": {
    "bank_transfer": {
      "total_credits": 300,
      "total_debits": 200,
      "total_net": 100
    },
    "card_payment": {
      "total_credits": 300,
      "total_debits": 200,
      "total_net": 100
    },
    "cash": {
      "total_credits": 300,
      "total_debits": 200,
      "total_net": 100
    },
    "check": {
      "total_credits": 300,
      "total_debits": 200,
      "total_net": 100
    }
  },
  "daily_balances": {
    "2022-12-23": 1341028,
    "2022-12-24": 1455800,
    "2022-12-25": 1455800,
    "2022-12-26": 1440853,
    "2022-12-27": 1440853,
    "2022-12-28": 1440853,
    "2022-12-29": 1440853,
    "2022-12-30": 1440853,
    "2022-12-31": 1440853,
    "2022-01-01": 1440853,
    "2022-01-02": 1316303,
    "2022-01-03": 1316303,
    "2022-01-04": 1316303,
    "2022-01-05": 1282373,
    "2022-01-06": 1282373,
    "2022-01-07": 1282373,
    "2022-01-08": 1282373,
    "2022-01-09": 1282373,
    "2022-01-10": 1282373,
    "2022-01-11": 1282373,
    "2022-01-12": 1257426,
    "2022-01-13": 1248295,
    "2022-01-14": 1247241,
    "2022-01-15": 1247241,
    "2022-01-16": 1247241,
    "2022-01-17": 1247241,
    "2022-01-18": 1247241,
    "2022-01-19": 1247241,
    "2022-01-20": 1164686,
    "2022-01-21": 1238802,
    "2022-01-22": 1237381
  },
  "30_day_balance_change": -103647,
  "daily_balance_volatility": 119,
  "metadata": {
    "confidence_score": 0.99,
    "included_data_sources": {
      "documents": [
        {
          "document_id": "b3de84cf-97aa-4321-a223-51640d5d8fca"
        }
      ],
      "open_banking": [
        {
          "open_banking_data_id": "e959ed48-a9e4-44f3-a6f8-b9dddd21f27c"
        }
      ]
    },
    "excluded_data_sources": {
      "documents": [
        {
          "document_id": "fd7abd7d-5d62-42d0-b49e-62eae1fd4e22",
          "exclusion_reason": "UNRECONCILED_BANK_ACCOUNT"
        }
      ],
      "open_banking": [
        {
          "open_banking_data_id": "920b148f-db30-46fe-8da9-3de2c9e55b04"
        }
      ]
    }
  },
  "confidence_score": 0.99
}