Today we’re going to look at how to automate hours of mindless busywork using a free open source piece of software called “Katalon Studio.”
The specific challenge we’re automating is the bulk deletion of records in an Adalo collection. Currently the Adalo tool (as amazing as it is) offers no way to wipe all the records in a collection. Currently your only options are:
- Drop and recreate the collection, which then means you have to re-establish all the relational connections to other collections not to mention rewire all the data in the screens that reference that collection.
- Go through one by one and delete each record individually.
No bueno either way.
I talked to one gentleman in the Adalo forums who had this issue and he had 5k records to delete.
Unfortunately he tackled it the manual way before I had the chance to document this method. Guess how long that took him?
That’s four hours of mind-numbing work. Computers are meant to work for us, not the other way around. We can do better.
I’m going to show you now a superpower in how you can take a four-hour task like this one, automate it once and solve it forever. So let’s get started.
Browser automation with Katalon Studio
Katalon is an open source piece of unit testing software based on the Selenium project. It’s entirely free to use. It’s typically a tool for QA testing in software applications that allows you to run a set of unit tests on an Android or web application. We’re not going to use it as a testing tool though. We’re just using it to perform the busywork we don’t want to do here.
The easiest way to tinker with Katalon is to get the Katalon Chrome Extension and play with it in your browser.
We need the looping capability which is only present in the desktop version so you’ll need to download and install that before you go on.
Showing it in action
First check out how the end result works in this video:
That’s four hours of your time you win back not to mention in the process you acquire a new superpower which can save you from future scenarios like this…
This video shows you the steps necessary to build the script I used in the above video:
The basic procedural steps here are:
- Record the initial automation.
- Fix anything that needs to be parameterized as a variable.
- Loop just the repetitive portion so you’re not wasting time on unnecessary steps.
- Execute the script and go do something fun while your computer is working for you 😉
As I mentioned in the video there are other further optimizations that could be made to the script to make it even more dynamic, like setting the number of loop iterations based on figuring out the record count of the items in the db… but, diminishing returns.
Additional resources and ideas
If you happen to have this exact scenario and just want to delete a bunch of records in Adalo, I put the Katalon Studio deletion script in Github. You can just download it and change the start URL to your Adalo collection and update it with your username/password and it should work without any other modification assuming nothing changes in the Adalo interface between now and then.
And that brings up a good point about this tactic: it’s incredibly powerful to be able to automate anything you could do in a browser but unlike API’s, user interfaces are prone to changing. If Adalo changes anything about how their user interface works it will likely require updating the script to work. It’s somewhat resillient because it uses Xpath and regular expressions for finding elements on the page but this this is something to be aware of about this approach is that it’s inherently brittle based on UI.
The best resource I found for learning the basics of Katalon was this free Udemy course. One of the great things is that there are a ton of people on Upwork who know how to write browser automation scripts so if you don’t have the time or ability to generate this (and you’re comfortable giving access to whatever system you’re using to an outsider) you can hire a freelance engineer from Upwork to write the script for you. Win-win, they make a few bucks and you save a few hours…
I’ll write up in another post the process I use delegating something like this to Upwork. That’s a whole topic unto itself but even that can be automated 😉
I hope this technique saves you time and frustration and frees you up to do something else productive. If you want to receive more awesomeness like this from me be sure to join my email list below. Happy automating.
Get more tutorials like this one
Hi I'm Sean. As EIR for Portugal’s largest incubator I’m helping early-stage founders with customer development, product validation, nocode, demand generation, automation, CRM, analytics, sales systematization and lifecycle marketing. Join me on the journey and receive a free copy of my eBook, Nonreliant as well as an infrequent email digest of what works.