The foundation of the categorisation engine is the Nordigen’s categorisation tree. It has three-level depth, where the highest level - named level 0 - can have level 1 sub-category, and level 1 level can have level 2 sub-category. Each transaction is described with at least one level and, at most, three level granularity; and the final category for each transaction is always assigned to the lowest possible level.
As there are more than 5 thousand unique categories across all levels in both transaction types - income and expenses - categorised bank account should be analyzed with full category tree hierarchy to extract most information. Full category tree can be retrieved via category tree endpoint.
Let’s assume that we have four transactions. One transaction has been assigned to the category ID 85, two transactions have been assigned to the categories ID 26 and ID 714, respectively, and the last transaction is assigned to the category ID 5239.
Categorisation response will return category_id
and title
of category for each transaction.
...
"transactions":[
{
"amount":-15.45,
"category_id":26,
"date":"2019-08-01",
"info":"PURCHASE 201620190406111 15.45GBP",
"partner":"Local Groceries",
"title":"Groceries",
"transaction_id":"unique-id-123"
},
{
"amount":900.8,
"category_id":85,
"date":"2019-08-05",
"info":"SALARY 201620190406222 900.80GBP",
"partner":"Job Ltd",
"title":"Salary",
"transaction_id":"unique-id-234"
},
{
"amount":-200.0,
"category_id":714,
"date":"2019-08-07",
"info":"Thanks for picking us up",
"partner":"",
"title":"Other personal transfers",
"transaction_id":"unique-id-345"
},
{
"amount":-300.5,
"category_id":5239,
"date":"2019-08-15",
"info":"MORTGAGE PAYMENT, AGREEMENT A201664 300.50GBP",
"partner":"Loan Bank",
"title":"Loan bank",
"transaction_id":"unique-id-456"
}
]
...
And full category tree for each assigned category_id
is listed below.
Assigned category ID | Level 0 ID | Level 1 ID | Level 2 ID | Level 0 Title | Level 1 Title | Level 2 Title | |
---|---|---|---|---|---|---|---|
#1 | 85 | 85 | Salary | ||||
#2 | 26 | 24 | 26 | Food | Groceries | ||
#3 | 714 | 237 | 714 | Personal Transfers | Other personal transfers | ||
#4 | 5239 | 79 | 97 | 5239 | Loans | Mortgage | Loan Bank |