Oct 23, 2023 02:30 AM
Hello everyone,
I have used scripts a lot in the Automations pannel. However, I'd like to create more user friendly experiences using the Script Extension.
Upon creating my system, it appears that buttons that trigger script extensions can not be run from an Airtable interface. Can anyone confirm that? Is there a way to create better experiences directly in the interface pannel by allowing users to follow a set of actions as defined in those scripts? Can it only be run from the data pannel?
Thank you very much,
Simon
Oct 23, 2023 04:04 AM - edited Dec 08, 2024 01:57 PM
Airtable offers 2 native ways of running Javascripts:
1. You can run JavaScripts with the scripting extension. However, the gigantic limitation with all Airtable extensions is that they can ONLY be run at the Data layer. Extensions can NOT be run at the Interface layer.
2. You can run JavaScripts with Airtable's automations. Airtable automations can be triggered anywhere throughout all of Airtable, including interfaces. However, the limitation here is that Airtable's automations only offer very limited Javascript capabilities, and there is a 30-second time limit on each Javascript that you run.
So, if you're looking to write more complex JavaScript scripts that you would like to trigger from within Airtable's interfaces, the only solution that I know of for this problem is to use external apps that support running full JavaScript code, such as 0CodeKit.
But then the question becomes: How can you trigger your full Javascript programming code in 0CodeKit?
You can do this by using one of 3 methods:
1. You can use Make’s 0CodeKit automations. Make has full support for 0CodeKit, so from within Airtable, you can have your Airtable automation call a webhook in Make which will run your 0CodeKit code. I discuss how to call webhooks in Make in this thread.
2. From within Airtable, you can have your Airtable automation run a custom script that communicates directly with 0CodeKit. Be careful with this method, because Airtable’s automation scripts have a 30-second time limit, as I mentioned above.
3. Bypass Airtable’s automations altogether by simply placing a button on your interface. This button can open a Make webhook URL directly, which would then run your Javascript code in 0CodeKit. This would enable you to bypass Airtable’s automations altogether, and you can also setup a custom webhook response to be shown to your user in their browser window. I show how to do that in this episode of the BuiltOnAir podcast (although I show how to do it in the context of an email).
There is a small learning curve with Make, which is why I created this basic navigation video to help. I also provide the links to a few other Make training resources there as well. For example, as I mentioned above, to instantly trigger your Make scenarios from Airtable, check out this thread.
Hope this helps! If you’d like to hire an expert Airtable consultant to help you with anything Airtable-related, please feel free to contact me through my website: Airtable consultant — ScottWorld