Using Script in Automation

I wrote my first script, tested it and it works ! I Used the Script template from " Table optimizer" to convert “wide” table to “long” one.

Now I am trying to utilize this script in my Automation routine using trigger and it doesnt run. I coped and pasted script into Automation, but when I test it, it give me error:

TypeError: input.config.table is not a function

Any help ?

Not the same environment, automations run on Airtable’s own servers. input.config is no the same thing in the cloud, it’s basically a variable.

edit: come to think of it, it is the same thing, you’re just observing the test run and tackling an issue from a different perspective.

anyway, re-declare the symbols giving you trouble and get rid of the input.config object from the original Automation script.

ìnput.config() works very differently in scripting app compared to in an automation action script. In an automation action script, you cannot get a table directly. You can only get input variables.

For more information, see the documentation here.