Intentional 404 error code

Hi guys,

I’m trying to set up a GET API call with filterByFormula that would return an error instead of empty value. Imagine that I have two fields - {user_id} and {full_name}. {user_id} field always exists, but based on formula it should return:

A) 200 OK response if full_name does not exist
b) ERROR response if full_name field already has a value

Any help would be much appreciated!

Thanks!

You can’t change those responses from Airtable’s API.

If you want to create your own custom responses, then you would need to setup a scenario in a webhook automation platform like Make.com.

Setup a webhook to receive your GET call, perform your Airtable search, and then setup a router with 2 different filtered paths (i.e. conditional paths) based on the results of your search.

You can then customize a different webhook response for each conditional path.

Here’s a screenshot of how this would look in Make.com — it’s very easy:

This topic was solved and automatically closed 15 days after the last reply. New replies are no longer allowed.