Q. Does integrator․io impose a time limit for executing JavaScript?
A. Exceeding either of two key limits will cause a timeout error within a flow step or API call:
- A JavaScript routine – such as all of the custom functions called within a hook or a transformation – must finish processing at the integrator․io server within 4 seconds.
- There is also a 120-second limit on time spent calling integrator․io APIs, invoked from an integrator․io API connection or the JavaScript runtime. The time spent processing is cumulative, meaning that you can make multiple successive API calls, as long as they do not exceed 120 seconds total.
If your code’s execution length is causing the flow to fail, look for ways to improve its runtime efficiency, especially when processing large record sets.
Advanced developers also have the option of starting a timer and printing the time elapsed in debug statements throughout the script.
Another tip is to move time-consuming string or regex manipulation to an external resource, such as a saved search. (SuiteScript processing does not count against integrator․io limits.)