Interact
4 min read
How I Over-engineered a Swear Jar
This guide assumes you have an iPhone.
One of the things I want to improve this year is the habit my wife and I share of cursing too often. Especially, around our son. Casual swearing is a sign of poor vocabulary and a lack of being able to properly express yourself. Swearing has it’s place but it’s not exactly cordial. It would be mortifying for one of my son’s earliest words to be a swearword.
How do we stop swearing so often? Well, ways to break a habit include, identifying triggers, having a great reason and developing a counter-habit. I think my primary triggers are stress and environment. My reasons is not wanting me son to become a potty mouth pleb.
A common practice when attempting to curb the curse-words is to adopt a swear jar. I created a swear jar Pot on Monzo and have decided that each infraction costs £0.10. This is my count-habit, binding swearing to something I don’t like, spending money, will raise my awareness and hopeful help in the long run.
However, depositing to a pot each time I say a bad word was a bit cumbersome. Having to open the app, enter in the amount, and transfer it. This made the barrier to actually doing it a little bit too high. As an engineer I thought, I can do better. Here is the story of me doing better.
I knew I could integrate with Monzo via Ifttt because I already had an Applet (integration on Ifttt) set up for whenever I Tweet. There’s a £0.50 penalty for tweeting as I wanted to discourage myself saying dumb or unhelpful things online. It makes you think twice before saying anything. I think a lot of Twitter Warriors could benefit from this.
My first attempt was to create an Ifttt button, when the button is pressed the money is deposited into the Pot. This worked exactly as expected but had its own caveats. The Ifttt widget is only in the old style so in order to use the button I have to open the app or navigate to the widget on the far left home screen. This isn’t ideal as it’s slow and the widget placement is at the bottom. I needed a better solution.
Enter webhooks. If you don’t know what a web-hook is, Google it or just trust the wizardry. In this case a webhook on Ifttt is a url that when its receives a successful request with run the next action, deposit the money.
Once I had the web-hook version of the Applet it set up, I knew I could trigger the webhook via a Siri Shortcut. I love Siri Shortcuts. With the Shortcut created, I can have a widget on any home screen and also invoke it via Siri. “Hey Siri, Naughty Word”.
There you have it, one over-engineered Swear Jar.
He’s a step-by-step guide to create your own.
This guide assumes you have an iPhone.
Pre-requisites: a Monzo account, an Ifttt and an iPhone with iOS 14+.
On Ifftt create a new Applet, set the If to a webhook and choose “Receive a web request”. Give the trigger event a name (no space) and remember it you’ll need it later.
Then you need a trigger Monzo, Move money into a pot. Select the pot you wish to use and set the amount to move.
Once the Applet is ready to just need the webhook to use in the Shortcut. Below in the url for the webhook to use in the Shortcut, you need to replace “{event}” with your event name and “{your_key}” with your Ifttt api key. Find your key here https://ifttt.com/maker_webhooks and click documentation.
Base URL: https://maker.ifttt.com/
Slug: ...trigger/{event}/with/key/{your_key}
You can get the Shortcut via the following link all you need to do is enter your api-key and event name and you’re good to go.
I have been using this for 4 days and have already amassed an amount of £3.50. Don’t judge me. It’s been a stressful few days 😬