Paying The Bills (with Automation)
Both my and my girlfriend get our wages paid into separate bank accounts. This is quite common for a lot of couples but can present quite an organizational challenge when you've got joint bills to pay.
For example, does one person pay the mortgage and the other pay the food & utility bills (I think this was how my dad arranged it when he was married), is this always fair? Or would you both pay X amount into a set account and then hope that the value doesn't change too much.
An alternative solution might be to have both wages paid into a single joint account and then divide the total income evenly once the bills have been processed but that can sometimes also be undesirable depending on how close you are with your partner and how large the pay gap is between you.
I bring this question up in conversation with friends sometimes and I get a range of responses so clearly everyone has a different approach to this problem
Not so simple after all
The approach I take is the "both pay X amount into a joint account" option. We have a joint account that is responsible for ensuring that the bills get paid and we top it up on payday to ensure there are funds in the account to pay for the bills when they are needed. This is really good for us as it means that a bulk of our wages are ring fenced away so that they cannot be spent on other items during the month. Whatever is left after payday is "fair game".
This presents a few issues however
- How do we top it up? Bank Transfer or Standing Order?
- What if the amount changes? How will we know?
- Will we even remember to pay into this account?
- How do we keep track of who pays what?
I feel as though the system I currently use (and have been using for the last 2 years is the most simple solution to this issue for me). Here's the explanation:
We'll start with the data
To keep things simple here, I store all this data in Excel. Since we're storing a simple single table with generally no overlapping or relational elements, a simple flat file table is much easier here than any sort of complicated database. Here's what this looks like:
Bill | Amount | Owner | Provider |
---|---|---|---|
Mobile Phone | 20 | Dan | The Blue Phone Company |
Car | 200 | Dan | Super Car Finance Corp |
Mobile Phone | 30 | Mrs Dan | The Purple Phone Company |
Mortgage | 500 | Joint | Big Banker Plc |
The provider field is surplus to requirements but it does help keep track of things.
With a couple of Excel formula's and we can find out exactly who owes what:
=(SUMIF(Table1[Owner],"Joint",Table1[Amount])/2)+(SUMIF(Table1[Owner],[@People],Table1[Amount]))
In my example above, we'd have 2 additional cells in our sheet with the formula calculating that Dan owes 450 whilst Mrs Dan owes 280
That's all pretty cool if this was the 90's and everyone still ran Windows 95. But it doesn't solve our main issues and that is:
- How do we update it easily?
- How do we get reminded to pay it?
Enter Nextcloud...
We're not running Windows 95 anymore. We're running beefy AlmaLinux 8 servers with Docker. So how can I leverage that to allow me to update this from many machines.
For this, I use my Nextcloud container.
Nextcloud is a system that is similar to Dropbox or Google Drive. It's a system where changes can be made to a file on the local machine and these changes will get automatically uploaded to the Nextcloud server. Changes that are made server side are also synced locally back to the machine. I like to think of this concept almost like if IMAP and FTP had a baby except it all runs over HTTPS instead.
In my case, I would use this as one central location for my spreadsheet that can be accessed via my phone's native "Files" app whilst also appearing as a document on my computer. The easy part about this is that no matter which company contacts me to tell me that a bill has changed and no matter how they contact me, I can always ensure that I can update the spreadsheet with the correct information.
Consider the following:
You're in a car shop looking for a new car. With this system, you know how much you pay for your current car. You know how much you pay for all of your other bills. You know with a single change in an excel cell exactly what you would be paying in total if you bought the car and if you did buy the car, you could save the change to ensure that you're reminded to pay the bill upfront after pay day.
All sounds great so far, but how do we remember to pay it after payday?
Enter Node Red...
Onto the reminder system, I used Node Red. It's a graphical system for arranging predefined function blocks that execute specific tasks. The Node Red flow
I used for my reminder looks like so:
To explain this, the first part of the flow is a essentially a cronjob with specific formula's for mine and my girlfriend's payday. Whilst my payday is fairly regular, Mrs Dan's payday seems to be based on the whim of the finance team that week. Generally however it more or less the last working day before the 21st of the month so it can be entered programmatically.
Once the schedule is triggered using the Telegram chat ID as the ID for each person, the system will then query this information against a very basic JSON object (very crude I know) which also contains which excel cell the total value for each person is location on the spreadsheet.
The cell is then queried for it's value by taking the formulaic cell value directly from the spreadsheet. This is then formatted into a payload and sent directly to the Telegram user who's payday it is. A very basic but very reliable system for monthly bill's updates via a push notification.
This can also be queried manually by typing "/bills" to the telegram bot.
Once the alert comes through Telegram, the recipient can then log into the mobile banking and proceed with the transaction for the correct amount. The left over money is disposable income.
Closing Thoughts
This system is a very basic but surprisingly reliable solution to an organization problem. It's an easy way to relieve the mind of the stresses of managing bills.
My university lecturer once gave me the advice to "program your future self" as if your future self was some sort of zombie with no decision making capability. We're not always 100% switched on all of the time and sometimes we need to be told what to do, even if this is by our past self. To think about what bills need to be paid and when only serves to cause headaches and stress.
However to allow an automated system to manage this process for us means that we can take the lazy approach of ensuring that the money ends up in the right place at the right time and leaving the rest to pre-planned actions.
Future Plans
For the future, I've looked into ways to automate this further but as you can imagine, banking system's APIs are fairly locked down. For example, the Open Banking API allows you to be logged in but the log in only lasts a few months before you need to authenticate again. You also need to authenticate every transaction and the API is generally overly complicated and inaccessible to the general public without some FCA registered middleman system - so much for being "open"
There is one company however that do offer a potential silver lining to this issue and that is Monzo. Monzo appear to offer you standard run of the mill REST API which can be used to query accounts and to move money into "pots". Not quite as good as moving money into different accounts but this pots idea might work. Is it enough for me to switch current accounts?
This means that the system might at least be able to send follow up reminders if the money hasn't been transferred with the ultimate goal of making the process as automated as possible. If only....