Help

Upcoming database upgrades. to improve our reliability at 03:30 UTC on Feb. 25 / 7:30pm PT on Feb. 24. Some users may briefly experience slow load times or error messages. Learn more here

Run a script form within a script

Topic Labels: Extensions
433 2
cancel
Showing results for 
Search instead for 
Did you mean: 

This doesn’t seem to have been asked before, which suprises me.
Is it possible to do this? ie use an existing script like a procedure?

2 Replies 2

No, this is not possible. All of the code for a script must fit in the single script editor at once.

Some people have creative systems where the script retrieves code stored externally (either in the base or on the internet) and then the script uses eval to run the additional code. However, this technique only works in Scrpting App (not in Automation Scripting Actions), and it introduces a additional complexity and risk.

A more advanced option would be to use a service like Autocode or Pipedream to create a custom endpoint that can be called from within a script. Setting up something like this would take a good bit of work, it wouldn’t be literally as easy as calling a procedure, and would probably only be worth it for non-trivial use cases. However, that may be what some are looking for.