Budget Tracker App – Initial Design

I’ve never liked the fact that many apps track all of your personal data and use it to serve you all kinds of ads and feed their large big data algorithms with data about your spending and browsing habits. Enter a new budget tracker written by yours truly. The goals are as follows:

  • Must be lightweight
  • Support basic csv formats directly from bank or credit card statements
  • Uses NodeJS (for personal learning)
  • Uses Python Pandas library (for learning and development – also because it supports great data manipulation functions)
  • Uses MongoDB or SQLite
  • Supports tagging of expenses by type
  • Can do some recognition of common expenses (i.e. recurring expenses like subscriptions)

Potential future stuff:

  • Track habits and report on what you’re spending your money on
  • Make suggestions on what you need to cut back on
  • Support a “saving up” feature. Figure out a dollar amount to put away for a month and have goal setting feature to predict future spending habits
  • Dockerize application for easy deployment

Architecture:

Let’s talk architecture…boring stuff ;). The idea for the initial design is 3 tables: expenses, expense sources, and users. Let’s talk schema…

The first thing to think about is where the expenses are coming from. How many expenses are we going to aggregate and from where? For starters, we’ll make a table that has all of the expense sources.

Expense Source NameDescriptionExpense Source UID
My Bank USABank Account Expenses5ef3e862-abdd-4e05-b45d-4d6a437ce5de
North American ExpressMain credit cardec676c66-2a63-4c29-b682-b93beeea91c5
Expense Sources Table

In this Expense Sources table, you’ll see we have a couple of sources: a bank and a credit card. The idea is that someone can easily add new expenses manually and tag them to the correct expense source easily. You could also bulk import expenses from csv such as from a credit card company and upon import, tag the correct source.

Next up is the expenses table. In here, we’ll define the expenses themselves. You can see there’s a column for “expense_uid_source”. This will match up with the credit card, bank account, etc where the expense is linked. I’ve also added tags where one can link the common expenses together by expense type. Eating out too much? link it as “eating out”, and easily track how often you eat out. Comments have been added as well for clarifications.

expense_dateexpense_amountexpense_uidexpense_nametagsuser_idcommentslinked_expensesexpense_uid_source
8/9/2022$12.00fa90d34d-bd93-4a3e-bd32-92c739548ac5Taco Belleating outfa90d34d-bd93-4a3e-bd32-92c739548ac5late night snack 🙂ec676c66-2a63-4c29-b682-b93beeea91c5
8/1/2022$1,200.005afa3bc7-c870-40ac-8d86-2c92a02c91f5Rent Companymonthly,recurringfa90d34d-bd93-4a3e-bd32-92c739548ac5monthly rent5ef3e862-abdd-4e05-b45d-4d6a437ce5de
8/1/2022$40.003f8be5b8-85e3-4c0f-b824-b1d2c2e8b5c9Electric Company INCmonthlyfa90d34d-bd93-4a3e-bd32-92c739548ac5monthly electric billec676c66-2a63-4c29-b682-b93beeea91c5
8/1/2022$30.009665a182-c870-4d7d-bced-876ce04f56f3Gym Membershipmonthly,recurring5afa3bc7-c870-40ac-8d86-2c92a02c91f5monthly gym membershipec676c66-2a63-4c29-b682-b93beeea91c5
8/4/2022$115.009fd927df-a239-4d5d-bf05-94d5ffe5238aGrocery Storeweekly5afa3bc7-c870-40ac-8d86-2c92a02c91f5groceriesec676c66-2a63-4c29-b682-b93beeea91c5
Expenses Table

Last is the profiles table. This table is very basic and simply will allow expenses to be tied to a person. This allows you to figure out whose card or bank account is being tracked. As I’m writing this, I think that it would be good to have a “shared” option for stuff like rent, electric bill, etc that would be shared between a spouse or girlfriend/boyfriend, etc.

uidusernamefirst_namelast_name
fa90d34d-bd93-4a3e-bd32-92c739548ac5brandonBrandonJameson
5afa3bc7-c870-40ac-8d86-2c92a02c91f5user1UserOne
3f8be5b8-85e3-4c0f-b824-b1d2c2e8b5c9user2UserTwo
9665a182-c870-4d7d-bced-876ce04f56f3user3UserThree
9fd927df-a239-4d5d-bf05-94d5ffe5238auser4UserFour
Profiles Table

This seems like a good start. Next, we’ll try tackle front end ideas, method for import, and key features.

Leave a Comment

Your email address will not be published. Required fields are marked *