Make webhook status visual feedback in Airtable

I've been working on my Airtable and Make automations, and I wanted to share a small trick I've implemented to improve error handling and visibility.

I use Airtable interfaces equipped with various buttons that, when clicked, trigger webhooks in Make, that in turn update my Airtable record with additional data. However, I found it quite frustrating that there was no visual feedback indicating the status of the webhook. Was it still running? Did it succeed? Did it fail? I had to open my Make dashboard each time, which was far from ideal.

So I added a simple status feature. I added a new field called automationStatus to my table. It's a select with three states: OK (default), In Progress, or Error. By default, it's set to OK.

Now, when the webhook starts, instead of fetching the relevant Airtable record, it updates it instead by changing its automationStatus to In Progress. The Make module to update an Airtable record also returns the whole record, so I don't need to actually fetch it. I display the status next to the button, so now I can get visual feedback.

At the end of a successful scenario, when I update the record with new data, I also set the automationStatus back to OK. And if any module fails along the way I add an Error Handler to set the automationStatus to Error.

For some very nasty scenarios, I even went further and added the automationScenarioUrl and automationErrorDetails, so I could have more visibility on what was really happening, and quickly click on the link to get to the Make Scenario page.

This approach of course has limitations (there is no history, and all automations of a given record share the same field), but it is already way better than what I used to have (ie. nothing) before.

Counting Elements in Airtable

Airtable is an impressive tool that keeps surprising me with its power. But sometimes, it seems to be missing what I assume would be very basic features.

For example, it has powerful linking capabilities; let's say you have a companies table and an employees table, you can have a company field in employees that automatically allows selecting an existing company. The mirroring effect is automatically enabled as well, when you look at your company table, you can see all its linked employees.

You can even use a Rollup field to, for example, gather all names of the linked employees. By default it's displayed as a comma-separated list of values, but in reality it returns an array-like structure, and you can call a bunch of array-related methods on it, like ARRAYUNIQUE, ARRAYJOIN, ARRAYCOMPACT or ARRAYSLICE.

But I couldn't find a way to get the length of the array. There is no ARRAYLENGTH method.

Edit: Seems like there is a Count type that does exactly that. It was there, in plain sight, and I never saw it. It's a much better solution than the hack I'm describing here.

The workaround

Still, I found a clever / hackish way to get that information, by using a mix of string and regexp functions. Let me walk you through it:

First, I define a UUID field in the employees table, a formula that only contains RECORD_ID(). That way, I have a relatively short and very unique identifier for each employee.

Now, let's see what we need to do in the companies table. It is going to be a pretty long and complex formula, so we'll go step by step. You could technically put the very long formula in the Rollup, but to make it clearer, I'll create several fields, and reference them.

First, I create a an employeeCountStep1 Rollup of the UUID field of the employees field, but instead of joining it with the default , separator, I'll use a less common character, like . I could have used any character, but I find this blocky square to be more visible. So, this is our Rollup formula for now: ARRAYJOIN(ARRAYUNIQUE(values), "▮").

Now, as this returns a string, we'll be able to execute some regexp search and replace on it. What we'll do is remove all characters, except our blocky squares. Essentially it means replacing everything that is not , with an empty string, like this: REGEX_REPLACE(employeeCountStep1, "[^▮]", "")

The last step is to count the number of we now have, using the LEN method. But as the only separates values, we'll have an off-by-one error; if we have 3 employees, we'll only have two . No problem, we just need to add 1 to the total… But that means that it will also add 1 even if there are no employees… Ok, so let's wrap that in one final condition to handle that edge-case: IF(employees = "", 0, LEN(employeeCountStep2) + 1)

All in all, here is the final Rollup formula: IF(employees = "", 0, LEN(REGEX_REPLACE(ARRAYJOIN(ARRAYUNIQUE(values), "▮"), "[^▮]", "")) + 1)

Well, that wasn't easy, but it works. It's a bit hackish, but it does the job. It's a neat trick to have in your Airtable toolkit.

Best Practices for Airtable IDs

When working with Airtable, I've started to develop some good practices regarding IDs in my tables.

Airtable has a concept of a Primary Field, which is the "main" field of a given entry, displayed as the first column in Grid view. It can be any field of the table (even a formula aggregating several fields), and will be used in the UI to represent the row.

But Airtable also has an internal notion of a RECORD_ID() (a string like recR5nCNhl3SHbC1z). It's an internal ID, and if you're only using the Airtable UI, you'll never see them.

But the moment you start using the API, it's everywhere, as it's the canonical way to identify a record.

I developed the habit of making the RECORD_ID() visible in all my tables. The first thing I do when I create a new table, is to add a field called UUID, set it as a formula, with a value of RECORD_ID(). That way, I have an easier mental mapping between what I can see in the UI and what I interact with in the API.

I also tend to name my Primary Field code, and make it a concatenation of unique (but short) identifiers of my record. That way, I can easily identify them, sort them, etc. I never use that field anywhere but in the UI.

Coming from a dev background, not understanding the difference between the visible Primary Field and the hidden RECORD_ID() has been one of the first things that tripped me up when I started plugging Airtable with Make. Having the UUID clearly exposed in the UI and the record makes everything way simpler.

My first steps into automating knowledge sharing

I’ve been saying, “I’ve been coding for over ten years.” for more than a decade now (so yeah, I've been coding for a long time). And I still love it.

Coding feels like a deeply creative process to me. It’s about long-term problem-solving and crafting elegant solutions. But it's also about diving into the nitty-gritty and getting your hands dirty. I take pride in writing clean, maintainable code, but also in finding a clever hack to glue everything together.

The one thing that I never found fun are the repetitive tasks. They’re fun the first time but quickly become tedious after the tenth. I think that's for hat reason that I’ve always been fascinated by automation. Recently, after attending the dotAI conference, I saw the incredible potential of AI and automation tools, which pulled me into yet another rabbit hole.

Make is the new Zapier

Of course, I've already automated most of my code-oriented tasks, using tools like CircleCI or Netlify/Vercel/Cloudflare functions. Those tools are great, but they fall short when the task to automate requires some UI (like getting data from a website, automatically downloading invoices from your emails, etc).

For those tasks, I had tried tools like IFTTT and Zapier in the past. I found IFTTT a genius idea the first time I used it, but its functionality was quite limited. Zapier, while more advanced, felt similar and quickly became prohibitively expensive. So, I came back once again to my custom bash and JavaScript scripts.

But then, Make happened. I gave it a try and it has completely changed how I approach automation. Make combines the best of IFTTT and Zapier with a much more intuitive UI, powerful debugging tools, and is way cheaper. It’s incredibly versatile, allowing me to complete projects in an afternoon that I’d postponed for years. Every day, I experience "wow" moments as I connect this API and that API to automate stuff I didn't think I could automate. Make feels like a superpower, I'm feeling that exhilarating feeling of "I can do anything!" just like the first time I started coding.

More wow effects

If Make can replace much of my need for scripting, Airtable has given me a similar “wow” effect for data management. Airtable is an incredibly powerful database with a clean UI that makes it easy to view, edit, and manipulate data visually. I can create formulas, so one field is derived from another, link tables together, upload files directly in tables, build visual custom interfaces to show specific data. Everything is of course accessible through the API... and through Make; double "wow" effect!

And then you can even plug ChatGPT in Make, to enrich data you have in Airtable, and dynamically transform it. Triple "wow" effect. And since I've started to discover this strange new world of "no-code automation", I'm discovering more and more of those awesome tools every day. I keep being amazed at how powerful and accessible they’ve become.

Posting more here

I started this blog many years ago, when I started to learn web development, and I used it as a platform to share what I learned. I think it's only fitting if today, I use what I learn in the realm of no-code automation to post more here, and post more about what I learn, and use what I learn to post more.

I know I have ideas worth sharing. My thought process is that if I, after 20 years of experience, am still learning new things, I'm sure others can learn from them too. This blog is a modest platform, but it’s a way to connect with you, readers, and contribute to the pool of shared knowledge. Just as my coding skills allowed me to build and customize this site many years ago, I hope my growing expertise in automation will help me bring more meaningful content to it.

Hope to see you soon, once I've posted more!

Writing faster: just speak

As a web and software developer, I often see coding as a creative way to solve problems. After years in the field, I take pride in writing clean, understandable, and maintainable code. Understanding the quality of my work gives me satisfaction, much like an artisan. Recently, I have been diving into automation tools that help streamline repetitive tasks, enhancing my productivity.

My journey with automation tools started with IFTTT, which I found quite useful but limited in functionality. Zapier was a step up, but it’s pricey for what it offers. Then I stumbled upon Make. This platform provides many features at a lower cost, allowing me to work faster. Even with some quirks, the speed and ease of development I gain from Make give me a "wow effect" that would have taken years to achieve otherwise.

Integrating tools like ChatGPT and Airtable has changed how I manage information. ChatGPT, as an API, allows me to manipulate data easily. Airtable acts as my source of truth, offering a user-friendly graphic interface and flexible views for managing data. Notion complements this by providing a smooth note-taking experience, especially with its new API. Working with these tools is not just efficient; it feels empowering.

I also find myself wanting to share what I learn. As a public-speaking trainer, I hear many interesting topics and wish to help others communicate their ideas effectively. I often think about the time I spend solving problems; sometimes I learn concepts that, if I could explain simply, would benefit others. However, creating an article or preparing a talk takes time I often don’t have.

To bridge this gap, I've embarked on a project to automate how I turn raw ideas into polished content. Through voice notes, I can quickly express my thoughts, and I want to transform these unstructured ideas into useful formats like articles or conference talks. The thought is to create a system that organizes and refines my notes, making it easier to share knowledge.

This process of transforming spoken ideas into written content involves leveraging AI tools that can help refine and structure my raw notes. I imagine a comprehensive database where I store these ideas, making the content creation process easier and faster. The audio notes I take can serve as the seed from which various media, such as blog posts or presentations, can grow.

In fact, this blog post is an example of what I’m trying to achieve. It all began with a simple audio note I recorded on my phone. By analyzing and refining that five-minute monologue, I've created something that I hope is engaging and useful to you. This journey of integrating automation and AI into my workflow has only begun, and I look forward to sharing more about this exploration as it evolves.

Disclaimer: This blog post hasn't been written by me. I recorded an audio note of what I wanted to say, then built an automation process (using the tools I mention) to generate the final blogpost. The ideas are mine, the way it's written is not. It's not good enough (I feel), but is a good start.